You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+34-24Lines changed: 34 additions & 24 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,31 +1,31 @@
1
1
# HyperSerialESP32
2
-
3
-
Exposes USB high speed serial port at 2Mb baud for driving led strip using NeoPixelBus library. It's intended to replace slow Arduino solutions (level shifter 3.3V to 5v may be required). **Data integrity check (Fletcher's checksum) included in new 'Awa' protocol for HyperHDR. So no more random flashing caused by serial transmission errors.** That option must be checked in HyperHDR to make system works as on the screen below.
4
-
5
-
**Make sure that your serial chip on the ESP32 can handle 2Mb speed: for example CP2102 can't as its max speed is 1Mb and you can compile a version for that speed but I think that's not the point, cheap CH340G can do it without any problems. CH9102x also should work for you, even at 4Mb speed.**
6
-
7
-
There is also my fork named HyperSerialWLED available with the support for the AWA serial protocol at @2Mb speed for both ESP8266 and ESP32: https://github.com/awawa-dev/HyperSerialWLED Can't guarantee it will work as stable as HyperSerialESP32 because WLED has a lot of other things to do in the backgrounds (ex. handling Wifi) and timing control for the serial port could be at danger for larger number of LEDs. But you don't need to abandon all the benefits offered by the WLED which can be a big advantage for some users.
8
-
9
-
RGB to RGBW conversion is calibrated for the neutral white channel BTF SK6812 but it can be easily changed (for cool and warm temperature) in the code. Search for "color calibration". In HyperHDR use "1.5" gamma for red, blue and green for best effect in the "Image Processing" tab.
10
2
3
+
Exposes a high-speed USB serial port at 2Mb baud for driving LED strips using the NeoPixelBus library. It’s intended to replace slow Arduino-based solutions (a 3.3V to 5V level shifter may be required). **A data-integrity check (Fletcher's checksum) is included in the new 'Awa' protocol for HyperHDR, eliminating random flashing caused by serial transmission errors.** This option must be enabled in HyperHDR for the system to work correctly, as shown in the configuration screenshot below.
11
4
5
+
**Make sure that the serial chip on your ESP32 can handle 2Mb baud: for example, the CP2102 cannot, as its maximum speed is 1Mb. You can compile a version for that lower speed, but that defeats the purpose. The inexpensive CH340G handles 2Mb without issues, and the CH9102x should also work — even at 4Mb.**
6
+
7
+
There is also my fork, HyperSerialWLED, which includes support for the AWA serial protocol at 2Mb for both ESP8266 and ESP32: https://github.com/awawa-dev/HyperSerialWLED I can’t guarantee it will be as stable as HyperSerialESP32 because WLED performs many additional background tasks (e.g., handling Wi-Fi), and serial-port timing may become problematic with a larger number of LEDs. However, it allows you to keep all the benefits offered by WLED, which may be a significant advantage for some users.
Why the data integrity check was introduced which causes incompatibility with other software? Because at 2Mb speed many chip-makers allow few percent error in the transmission. And we do not want to have any distracting flashes. Broken frames are abandon without showing them. At 100Hz for 250 leds approximately 1-5% of the frames are broken.
26
+
Why the data integrity check was introduced which causes incompatibility with other software? Because at 2Mb speed many chip-makers allow few percent error in the transmission. And we do not want to have any distracting flashes. Broken frames are abandon without showing them. At 100Hz and with 250 LEDs, up to approximately 1–5% of frames may be corrupted.
27
+
28
+
---
29
29
30
30
# Flashing
31
31
@@ -58,27 +58,38 @@ For **RGB LED strip** like WS8212b or RGB SK6812 variant choose: *firmware_esp32
58
58
59
59
For **SPI driven RGB LED strip** APA102: *firmware_esp32_SPI_APA102_SK9822_HD107.bin*, WS8201: *firmware_esp32_SPI_WS2801.bin*
60
60
61
-
If you want to disable your first LED because it's used as a sacrificial level shifter, please use [HyperHDR v19](https://github.com/awawa-dev/HyperHDR/pull/379)
61
+
To disable the first LED used as a sacrificial level shifter, use [this](https://github.com/awawa-dev/HyperHDR/pull/379) HyperHDR feature
62
62
63
63
For the RGBW firmware the white channel is automatically calculated and R,G,B channels are corrected.
64
+
65
+
---
66
+
67
+
# Pinout
64
68
69
+
**ESP32:**
70
+
**LED output (non-SPI):** GPIO 2
71
+
**LED output (SPI):** GPIO 4 for Clock, GPIO 2 for Data
72
+
73
+
---
74
+
65
75
# Usage in HyperHDR
66
76
67
77
**In HyperHDR `Image Processing→Smoothing→Update frequency` you should do not exceed the maximum capacity of the device. Read more here: [how to get statistics](https://github.com/awawa-dev/HyperHDR/wiki/HyperSerial)**
68
78
69
79
To test the maximum performance in HyperHDR, enable `Image Processing→Smoothing→Continuous output`, set a high value for `Update Frequency` in the same tab and set any color in the `Remote Control` tab as the active effect. Get the statistics and optionally adjust `Update Frequency`. After testing, you need to disable `Continuous output`and set `Update frequency`" according to your results.
70
80
71
-
Configuring HyperHDR v19beta2 or above.
81
+
Configure HyperHDR:
72
82
- set `Refresh time` to zero
73
83
- set `Baudrate` to 2000000
74
-
- enabled `HyperHDR's AWA protocol`.
84
+
- enable `HyperHDR's AWA protocol`
85
+
- enable `ESP8266/ESP32/Rp2040 handshake` that may help you to properly initialize the ESP board
75
86
76
87
Enabling `White channel calibration` is optional, if you want to fine tune the white channel balance of your sk6812 RGBW LED strip.
77
-
`ESP8266/ESP32 handshake` could help you to properly initialize the ESP device and enables statistics output to the logs (you must stop the LED device first to get them).
Currently we use PlatformIO to compile the project. Install [Visual Studio Code](https://code.visualstudio.com/) and add [PlatformIO plugin](https://platformio.org/).
@@ -87,13 +98,8 @@ This environment will take care of everything and compile the firmware for you.
87
98
But there is also an alternative and an easier way. Just fork the project and enable its Github Action. Use the online editor to make changes to the ```platformio.ini``` file, for example change default pin-outs/speed or enable multi-segments support, and save it. Github Action will compile new firmware automatically in the Artifacts archive. It has never been so easy!
You can configure LED power pin in the `platformio.ini` to power off LEDs while not in use.
129
137
Review the comments at the top of the file:
@@ -132,7 +140,9 @@ Review the comments at the top of the file:
132
140
133
141
Note: For static color configuration this mechanism will turn off the LEDs. To counter this enable "Continuous Output" in HyperHDR "Smoothing" module. For esp32 and relay control, you may want to disable the "Handshake" option in the Adalight HyperHDR driver to avoid the relay immediately shutting down when resetting the device while initializing the connection.
134
142
135
-
# Some benchmark results
143
+
---
144
+
145
+
# Benchmark results
136
146
137
147
ESP32 MH-ET LIVE mini is capable of 4Mb serial port speed and ESP32-S2 lolin mini is capable of 5Mb. But to give equal chances for a single-segment mode all models were tested using the default speed of 2Mb which should saturate Neopixel data line. Parallel multi-segment mode uses the highest option available because communication performance is critical here.
0 commit comments