snakebyte
Posts: 19
Joined: Thu Sep 09, 2021 7:44 pm

Unicorn Hat HD: SPI communication spec

Sun Sep 12, 2021 4:39 pm

I have bought an Unicorn Hat HD and I would like to write some golang code in order to use it, just to have a challenge

I have just read some code of the python library and it seems that I need to send the first byte as the address, and the following 768 bytes containing the RGB values for each led (1 byte for each color, 3 bytes with RGB values for each led)

I tried and it won't work, so probably I am missing something else

Is there some low level guide about how to use the Unicorn Hat HD?

trejan
Posts: 3718
Joined: Tue Jul 02, 2019 2:28 pm

Re: Unicorn Hat HD: SPI communication spec

Sun Sep 12, 2021 5:00 pm

You need to contact Pimoroni for that.

snakebyte
Posts: 19
Joined: Thu Sep 09, 2021 7:44 pm

Re: Unicorn Hat HD: SPI communication spec

Mon Sep 13, 2021 8:33 am

ok found this on the Pimoroni official forum

https://forums.pimoroni.com/t/c-example ... -hd/5149/2

It works as I explained, probably I used the wrong function of the library I am using for the SPI communication (periph.io), when I have time I'll try again

Return to “HATs and other add-ons”