-
1Step 1
Test your board with the following code:
#!/bin/bash IP=192.168.123.456 while true do sleep 0.04 dd if=/dev/urandom bs=1200 count=1|nc -u $IP 60001 echo -n 'La'|nc -u $IP 60000 done
All the available channels should now blink with pretty colors !
If you have several boards, send the data to each board in turn then broadcast the 'La' sync packet to the x.x.x.255 address so they all receive the signal at the same time.
-
2Step 2
You can check the order of the strips and verify the pixel mapping with this slightly more elaborate script :
#!/bin/bash [ "$IP" ] || IP=192.168.41.104 while true do WHITE=$(printf "\377\377\377") HEAD="" for i in $(seq 0 399) do sleep 0.1 HEAD=$HEAD$WHITE echo -n $HEAD|nc -u $IP 60001 echo -n 'La'|nc -u $IP 60000 done done
It should be recoded in C or Python because it only tests the first 400 pixels (due to packet size limitations).Note that the physical and logical order of the inputs are reversed. It's a litlle idiosynchrasy of the variable-output logic, it must be reversed in software but it makes the hardware faster and smaller.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.