-
-
Notifications
You must be signed in to change notification settings - Fork 103
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ftdi led device #521
base: master
Are you sure you want to change the base?
Ftdi led device #521
Conversation
097f613
to
03fd56e
Compare
Hi Have you tried bit banging to control the Neopixel LEDs? In theory at least 4*800kHz clock would be needed and then: |
yep, I had similar idea about neopixel implementation, shouldn't be quite complicated. I'll try to implement, maybe will find someone who's willing to test it :) Btw I've removed change in LedDevice and overloaded start method in ProviderFtdi instead :) I still don't get that close in start logic |
ebb43b1
to
fef0ea8
Compare
ccd1f4a
to
5fc191e
Compare
f8affa8
to
57480ed
Compare
Hi @awawa-dev, I've implemented ws2812 support |
Great 👍 Did you test it on larger LED strips? Similar sk6812 SPI driver doesn't work for my LED strip that's why I suggested approach that is used e.g. by Neopixelbus library (fixed not adjustable clock that is set to multiply of Neopixel frequency, a bit different bit encoding) but not sure if it was caused by the Rpi SPI limitation/configuration. |
I'd love to test on larger led strips, but my ws2812 test setup is made of a single led, there's not much I can do about it. |
Ambilight FT232H implementation. |
Hint: there is a white channel algorithm in HyperSerialEsp8266/ESP32/HyperSPI that in my opinion outperforms this algos from WLED and also allows custom settings. And it's also easy to implement. |
That would be fantastic, of course, if it's possible. |
Hi, sk6812_ftdi_Wled1.auto.mp4sk6812ftdi_Hyperserial.neutral.white1.mp4 |
I'm hoping to get the FT232H (BTW and 100M logic analyzer and oscilloscope) next month so I can test it out. |
Haha, someone broke the piggy bank 😀 congratulations on getting new hardware! 🤩 |
Hello, I hope that someday, when you have tested everything, you will integrate the FTDI implementation of @nurikk in your release version. |
0456edc
to
083d622
Compare
hyperion-project/hyperion.ng#1595 (comment) And it also makes code way simplier |
What is the probability that a user will try to use more than one such device in the setup? I assume that since he used such an unusual and advanced configuration, he will be aware that the output will be given only on one of them and he must specify which one? Auto-discovery works fine in HyperHDR, in certain situations it's even mandatory (e.g. on some systems ESP32-S2 jumping from one COM path to another after restart, without auto-discovery it simply won't work). |
Ftdi chips don't change it's ports/indexes, current implementation makes sure to use only specific device which is chosen by user |
Still I prefer using auto discovery when it handles almost 100% cases without forcing user to specify a unnecessary path. It's different situation than e.g. configuring path for SPI devices which provide no feedback if the device is present at the path or not which may mislead auto-discovery, ftdi reports only valid device. Please revert that commit. |
e6448b4
to
b80185b
Compare
Hello, is there any chance to implement the Hyperion FTDI for Windows? |
Yes, I fixed the windows build. It detects devices and tries to open in "auto" mode (selecting a specific device didn't work before). But there are two main problems: libusb has nasty requirements when it comes to accessing physical devices on Windows (non-root users have a similar problem on Linux, but at least there is a workaround for that OS) and brew doesn't provide backwards compatible libftdi /libusb libraries for 10.15. And many Apple devices continued to use this version of macOS without being able to upgrade to 12.x. |
Hello, @awawa-dev and @Nurrik |
Hi @nurikk The frequency is a bit too high from the ideal 800KHz, but the timing are the most correct for sk6812 RGBW. It's worse here. The frequency is also a bit too high, but it's not a problem. ws2812b has been featured in several revisions over time, the recommended timings have changed but the only critical change was the increase in reset time from 50us to about 280-300us in the latest revisions which broke some ws2812b support libraries at the time. The pulse timing of the bit was backwards compatible regardless of what the manufacturer recommended in the documentation. For ws2812b, practical tests showed that high-time of encoded Do you know if libftdi was replaced with a proprietary API from the FTDI manufacturer, wouldn't that solve the permissions issues on all systems? The ftdi library doesn't need to be distributed or included in the build if it will be loaded dynamically: a header file is enough. |
Hi there! I'd love to try this out. Is it going to work with ws2801? I have one spare lying around.. |
Since the WS2801 LED is an SPI 3 channel IC with 2.5kHz and has different parameters than the Apa102 and WS2812 Neo-Pixel and the SK6812 RGBW 5050 IC respectively, which have completely different clock frequencies, will not work here. It is necessary that @nurikk also integrates the WS2801 in drivers. |
Too bad :(. Thanks for the detailed answer! |
Hi, |
hey @satgit62 I just build latest version https://github.com/nurikk/hyperhdr-webos-loader/actions/runs/8036974919 |
Thank you very much, @nurikk, I've managed that too. I'm already looking forward to the further development. |
@nurikk |
It's because (e)udev was ~recently enabled in the default buildroot-nc4 config (openlgtv/buildroot-nc4@5696b70), and things that link against our libudev get a reference to We can't just switch to an older eudev with This doesn't affect the build on Homebrew Channel because it's built using the |
@throwaway96 Hi, thanks for the explanation, so I will delete the libudev.pc from arm-webos-linux-gnueabi/sysroot/usr/lib/pkgconfig/ and see if the daemon starts then. |
Hello! This PR introduces
ftdilib1
led device implementation. FTDI chips are common usb2serial/spi/whatever chips, and are available for 5-10$ from Chinese website as various breakout boards.My wiring is following:
Current implementation will try to use any (first) fetid chip it discovers in system.
I've tested my code on MacOS and webos7(lg tv c2), no extra drivers required.
This implementation is tested against APA102, WS1218 and SK6812.
There are two channel chips like FT2232HQ which can drive more that one led segments.
I built
webos-hyperhdr-loader
with latest buildroot and have following debug build for testing for webos usersLatest build attracts can be found here
What kind of change does this PR introduce? (check at least one)
If changing the UI of web configuration, please provide the before/after screenshot:
Does this PR introduce a breaking change? (check one)
Furutre improvements:
PS: This PR doesn't require to be merged straight away, let's test it for some time