Closed BUGBEAR7 closed 3 years ago
That device ttyAMA0 is not available for communication. I guess it's /dev/ttyAMA0 in fact. Check all the logs related to initialization of Adalight if everything is set correctly. Execute ls -ltr /dev/tty* and dmesg to verify it's there. And are you sure that your version of wemos has cp2104 or ch340g chip? In case of trouble I recommend to flash WLED first and set and verify adalight to 115200 (disabling AWA protocol) because there are few things that can block serial port on Rpi3 and it is a long story.
Also you can execute 'screen /dev/ttyAMA0 2000000' and while it's running reset the wemos by the button. There should be output from HyperSerialEsp8266 if it's in the latest version. HYPERHDR/HYPERION MUST NOT BE RUNNING.
Thanks for the quick response
I am so sorry but I do not much about these stuff so you have to be more specific It is ch340g chip for sure. Previously I used the HyperHDR with 'udpraw' with a nodemcu ESP8266 board. It works perfectly.
This is the log
2021-01-11T13:25:57.952Z [hyperiond LEDDEVICE] (INFO) Stopped LedDevice 'adalight'
2021-01-11T13:25:57.954Z [hyperiond LEDDEVICE] (INFO) Start LedDevice 'adalight'.
2021-01-11T13:25:57.954Z [hyperiond LEDDEVICE] (DEBUG) (LedDevice.cpp:149:init()) deviceConfig: [{"awa_mode":true,"colorOrder":"rgb","currentLedCount":176,"delayAfterConnect":0,"hardwareLedCount":176,"latchTime":5,"lightberry_apa102_mode":false,"output":"auto","rate":2000000,"rewriteTime":1000,"type":"adalight"}]
2021-01-11T13:25:57.954Z [hyperiond LEDDEVICE] (DEBUG) (LedDevice.cpp:408:setLatchTime()) LatchTime updated to 5ms
2021-01-11T13:25:57.954Z [hyperiond LEDDEVICE] (DEBUG) (LedDevice.cpp:429:setRewriteTime()) Refresh interval = 1000ms
2021-01-11T13:25:57.955Z [hyperiond LEDDEVICE] (DEBUG) (LedDevice.cpp:435:setRewriteTime()) RewriteTime updated to 1000ms
2021-01-11T13:25:57.955Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:36:init()) DeviceType : adalight
2021-01-11T13:25:57.955Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:37:init()) LedCount : 176
2021-01-11T13:25:57.955Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:38:init()) ColorOrder : rgb
2021-01-11T13:25:57.955Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:39:init()) RefreshTime : 1000
2021-01-11T13:25:57.955Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:40:init()) LatchTime : 5
2021-01-11T13:25:57.955Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:52:init()) deviceName : auto
2021-01-11T13:25:57.955Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:53:init()) AutoDevice : 1
2021-01-11T13:25:57.956Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:54:init()) baudRate_Hz : 2000000
2021-01-11T13:25:57.956Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:55:init()) delayAfCon ms: 0
2021-01-11T13:25:57.956Z [hyperiond LEDDEVICE] (DEBUG) (LedDeviceAdalight.cpp:53:init()) Adalight driver with activated high speeed & data integration check AWA protocol
2021-01-11T13:25:57.956Z [hyperiond LEDDEVICE] (DEBUG) (LedDeviceAdalight.cpp:63:init()) Adalight header for 176 leds: Awa 0x00 0xaf 0xfa
2021-01-11T13:25:58.021Z [hyperiond LEDDEVICE] (INFO) found serial device: ttyAMA0
2021-01-11T13:25:58.021Z [hyperiond LEDDEVICE] (INFO) Opening UART: ttyAMA0
2021-01-11T13:25:58.022Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:141:tryOpen()) _rs232Port.open(QIODevice::ReadWrite): ttyAMA0, Baud rate [2000000]bps
2021-01-11T13:25:58.138Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:146:tryOpen()) portName: ttyAMA0
2021-01-11T13:25:58.140Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:147:tryOpen()) systemLocation: /dev/ttyAMA0
2021-01-11T13:25:58.141Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:148:tryOpen()) description:
2021-01-11T13:25:58.141Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:149:tryOpen()) manufacturer:
2021-01-11T13:25:58.141Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:150:tryOpen()) productIdentifier: 0x0
2021-01-11T13:25:58.142Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:151:tryOpen()) vendorIdentifier: 0x0
2021-01-11T13:25:58.142Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:152:tryOpen()) serialNumber:
2021-01-11T13:25:58.143Z [hyperiond COMPONENTREG] (DEBUG) (ComponentRegister.cpp:36:setNewComponentState()) LED device: enabled
2021-01-11T13:25:59.190Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:218:writeBytes()) Timeout after 1000ms: 0 frames already dropped
2021-01-11T13:26:04.221Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:218:writeBytes()) Previous line repeats 5 times
2021-01-11T13:26:04.221Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:93:close()) Flush was successful
2021-01-11T13:26:04.221Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:95:close()) Close UART: ttyAMA0
2021-01-11T13:26:04.222Z [hyperiond LEDDEVICE] (ERROR) Device disabled, device 'adalight' signals error: 'Timeout writing data to ttyAMA0'
2021-01-11T13:26:04.222Z [hyperiond COMPONENTREG] (DEBUG) (ComponentRegister.cpp:36:setNewComponentState()) LED device: disabled
2021-01-11T13:26:11.071Z [hyperiond WEBSOCKET] (DEBUG) (JsonAPI.cpp:1087:handleLoggingCommand()) log streaming activated for client ::ffff:192.168.0.129
In that case you must verify for sure that ttyAMA0 is correct one. I described you what it's need to be done in the first place. 'Auto' settings is not fool-proof and serial port MUST be working and not be used by other app or service under Rpi before HyperHDR could use it. That's my log for my Wemos, as you can see it's quite different: 2021-01-10T22:49:58.703Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:146:tryOpen()) portName: ttyUSB0 2021-01-10T22:49:58.703Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:147:tryOpen()) systemLocation: /dev/ttyUSB0 2021-01-10T22:49:58.703Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:148:tryOpen()) description: FT232R USB UART 2021-01-10T22:49:58.704Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:149:tryOpen()) manufacturer: FTDI 2021-01-10T22:49:58.704Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:150:tryOpen()) productIdentifier: 0x6001 2021-01-10T22:49:58.704Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:151:tryOpen()) vendorIdentifier: 0x403
Ok, I got that working now the logs shows the device and the led interact 2021-01-11T17:26:33.148Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:146:tryOpen()) portName: ttyUSB0 2021-01-11T17:26:33.149Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:147:tryOpen()) systemLocation: /dev/ttyUSB0 2021-01-11T17:26:33.149Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:148:tryOpen()) description: USB Serial 2021-01-11T17:26:33.150Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:149:tryOpen()) manufacturer: 1a86 2021-01-11T17:26:33.151Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:150:tryOpen()) productIdentifier: 0x7523 2021-01-11T17:26:33.152Z [hyperiond LEDDEVICE] (DEBUG) (ProviderRs232.cpp:151:tryOpen()) vendorIdentifier: 0x1a86
But new problem is occuring no matter what LED byte order I choose it shows me incorrect colors. Black is usally white , I can see the effect but color are not correct.
What exactly type of LED strip do you have and what version of firmware did you upload to ESP8266? Also please stop hyperiond service and execute screen /dev/ttyUSB0 2000000 and then reset Wemos: it should report some infos. EDIT: screen /dev/ttyUSB0 2000000
LED is WS2812b
screen showed
you need to reset it by the button on Wemos board to see more important information that it should output then ;)
Oh , sorry totally forgot to reset
It was Welcome! Awa driver. Color mode: RGBW First LED: disabled Stats for the last full frame. Frames per second: 0 Good frame--------- Stats for the last full frame. Frames per second: 0 Good frameStats for the last full frame. Frames per second: 0 Good frames: 0 Bad frames: 0
Does it suppose to RBGW
during the configuration it was commented
OK, you have uploaded RGBW version . It's for RGBW SK6812. For WS2812b you need RGB version. Dont see your code but that line must be un-commentated somehow or the firmware was not rebuilt before flashing.
it is already commented If comment is added it won't compile
I tried it with
then i get
Welcome! Awa driver. Color mode: RGB First LED: disabled Stats for the last full frame. Frames per second: 0 Good frameStats for the last full frame. Frames per second: 0 Good frame
define THIS_IS_RGBW
nope, it's not commented. it's c/c++ style to define something
plz let me know what the code should be for WS2812b
HyperSerialEsp8266.ino.d1_mini_RGB_FIRSTLED_DISABLED.bin or HyperSerialEsp8266.ino.d1_mini_RGB_FIRSTLED_ENABLED.bin in the download section.
Thanks Will try that , I feel so stupid now . I was compiling it via Ardunio Did not saw it is already available
I think that you completely unintentional managed to have a working version for RGB anyway ;) Not by commenting out that defined but by removing it's definition. Should work anyway :)
Welcome! Awa driver. Color mode: RGB First LED: disabled Stats for the last full frame. Frames per second: 0 Good frameStats for the last full frame. Frames per second: 0 Good frame
Thanks for the help , everything is working now . Currently using Flat buffers waiting my ezcap 269 for the better hdmi capture. I want to know what can be maximum length for data line after the logic shifter that was made from one led . Currently my raspberry pi is near the TV but I am planning to put it away in a separate box which will be approx 7 meter away. Will it work ?
Quite unique configuration, haven't met it before and it's hard to tell if it will work. Voltage drop is not as critical as interference (if the power cable are similar length the drop is common for all). If I have to guess I would tell it won't work. Maybe inserting modules similar like logic shifter from one led every 2m would help in that situation but not sure about it.
You can work it out in different way: use 5m USB cable +hub+2m USB cable as it is much more resistant to interference and put ESP with level shifter just beside led strip. Some reports that even over 10m shielded USB cable can work.
Yes , I am also thinking on doing this. I have an old logitech hub lying around. I will test on it.
Hello
I installed the HyperHDR in my RPi 3 with wemos di mini Flashed it with HyperSerialEsp8266 with first led disabled, but when I select the 'adalight' as Controller type (as instructed with that baudrate) it gives me error as nothing works Log shows: [hyperiond LEDDEVICE] (ERROR) Device disabled, device 'adalight' signals error: 'Timeout writing data to ttyAMA0'