Getting childId from IncomingMessage
-
Hi there guys,
I'm not a coder and struggling to expand the LED dimmer example to work as a three channel RGB driver.
Could someone please show me how to extract the childId in the message received from the gateway?
Any help is greatly appreciated. Here is what I'm trying to do:
void incomingMessage(const MyMessage &message) {
if (message.type == V_DIMMER && message.childId = 0) {
-
-
Hek,
OK, thanks for that however it still wont compile.
void incomingMessage(const MyMessage &message) {
if (message.type == V_DIMMER && message.childId == 0) {Here is the error.
_150309_RBG_LED_Driver.ino: In function ‘void incomingMessage(const MyMessage&)’:
_150309_RBG_LED_Driver.ino:82:43: error: ‘const class MyMessage’ has no member named ‘childId’
-
-
@bluman said:
Hek,
OK, thanks for that however it still wont compile.
void incomingMessage(const MyMessage &message) {
if (message.type == V_DIMMER && message.childId == 0) {Here is the error.
_150309_RBG_LED_Driver.ino: In function ‘void incomingMessage(const MyMessage&)’:
_150309_RBG_LED_Driver.ino:82:43: error: ‘const class MyMessage’ has no member named ‘childId’Use message.sensor == 0
-
you should post your entire sketch... put between three backticks (the character left of your "1" key on you keyboard
<three backticks>
your code
<three backticks>