Managed Code control Side A / B
Hi,
is it possible to control Side A oder B separately with the Managed Blink API? For Example: Side A in red, Side B in blue. I did not found a way to do that.
Can you give me an example in Managed Code?
Sorry for bringing up this old thread, but I think the solution is still relevant for a lot of us:
It is actually quite easy to control the different LEDs independently with managed code, although you have to implement a few small changes in the Blink1 class.
If you take a look at the FadeToColor method, you can see that there is a buffer array declared. There are seven bytes already defined. Setting the eight byte (buffer[7]) can be used to set the LED which the call refers to: 0 for both LEDs, 1 or 2 for LED1 or LED2.
Thanks for the tip, this worked out well.
However, this led me to a possible issue in the firmware: While FadeToColor (command code 'c') works well with 0 for both LEDs and 1 or 2 for LED1 or LED2, I fear that SetToColor (command code 'n') has a bug: it only works with 0 for both LEDs and 1 LED1 - however, using a value of 2 for LED2 doesn't seem to activate anything. I will post this as a separate issue.