!MCO:PRO:RC=1 in debug logs
-
When enabling MyDebug on a node I'm working on, I sometimes see bursts of this:
100776 !MCO:WAI:RC=1 100780 !MCO:PRO:RC=1 100782 !MCO:PRO:RC=1 100784 !MCO:PRO:RC=1 100786 !MCO:PRO:RC=1 100788 !MCO:PRO:RC=1 100790 !MCO:PRO:RC=1 100792 !MCO:PRO:RC=1 100794 !MCO:PRO:RC=1 100796 !MCO:PRO:RC=1 100798 !MCO:PRO:RC=1 100800 !MCO:PRO:RC=1 100802 !MCO:PRO:RC=1 100804 !MCO:PRO:RC=1 100806 !MCO:PRO:RC=1 100808 !MCO:PRO:RC=1 100810 !MCO:PRO:RC=1 100812 !MCO:PRO:RC=1 100814 !MCO:PRO:RC=1 100816 !MCO:PRO:RC=1 100818 !MCO:PRO:RC=1 100820 !MCO:PRO:RC=1 100823 !MCO:PRO:RC=1 100825 !MCO:PRO:RC=1 100827 !MCO:PRO:RC=1 100829 !MCO:PRO:RC=1 100831 !MCO:PRO:RC=1 100833 !MCO:PRO:RC=1 100835 !MCO:PRO:RC=1 100837 !MCO:PRO:RC=1 100840 !MCO:PRO:RC=1 ...etc... 102779 !MCO:PRO:RC=1I don't see anything about this on the forum. I did find that MCO means "MySensors core".
It seems to happen during the
waitpart of the code below, which is in the receive function:// Change relay state desiredState = message.getBool()?RELAY_ON:RELAY_OFF; if(desiredState == RELAY_ON){ send(relay_message.setSensor(message.sensor).set(RELAY_ON)); // Send on state digitalWrite(RELAY_1, RELAY_ON); Serial.println(F("Turning on")); wait(PULSELENGTH); digitalWrite(RELAY_1, RELAY_OFF); Serial.println(F("Turned off")); //send(relay_message.setSensor(message.sensor).set(RELAY_OFF)); // Send off state } send(relay_message.setSensor(message.sensor).set(RELAY_OFF)); // Send off state }Perhaps I should keep the receive function as brief as possible?
-
Yes, that was it. I love it when I answer my own questions :-)
-
When enabling MyDebug on a node I'm working on, I sometimes see bursts of this:
100776 !MCO:WAI:RC=1 100780 !MCO:PRO:RC=1 100782 !MCO:PRO:RC=1 100784 !MCO:PRO:RC=1 100786 !MCO:PRO:RC=1 100788 !MCO:PRO:RC=1 100790 !MCO:PRO:RC=1 100792 !MCO:PRO:RC=1 100794 !MCO:PRO:RC=1 100796 !MCO:PRO:RC=1 100798 !MCO:PRO:RC=1 100800 !MCO:PRO:RC=1 100802 !MCO:PRO:RC=1 100804 !MCO:PRO:RC=1 100806 !MCO:PRO:RC=1 100808 !MCO:PRO:RC=1 100810 !MCO:PRO:RC=1 100812 !MCO:PRO:RC=1 100814 !MCO:PRO:RC=1 100816 !MCO:PRO:RC=1 100818 !MCO:PRO:RC=1 100820 !MCO:PRO:RC=1 100823 !MCO:PRO:RC=1 100825 !MCO:PRO:RC=1 100827 !MCO:PRO:RC=1 100829 !MCO:PRO:RC=1 100831 !MCO:PRO:RC=1 100833 !MCO:PRO:RC=1 100835 !MCO:PRO:RC=1 100837 !MCO:PRO:RC=1 100840 !MCO:PRO:RC=1 ...etc... 102779 !MCO:PRO:RC=1I don't see anything about this on the forum. I did find that MCO means "MySensors core".
It seems to happen during the
waitpart of the code below, which is in the receive function:// Change relay state desiredState = message.getBool()?RELAY_ON:RELAY_OFF; if(desiredState == RELAY_ON){ send(relay_message.setSensor(message.sensor).set(RELAY_ON)); // Send on state digitalWrite(RELAY_1, RELAY_ON); Serial.println(F("Turning on")); wait(PULSELENGTH); digitalWrite(RELAY_1, RELAY_OFF); Serial.println(F("Turned off")); //send(relay_message.setSensor(message.sensor).set(RELAY_OFF)); // Send off state } send(relay_message.setSensor(message.sensor).set(RELAY_OFF)); // Send off state }Perhaps I should keep the receive function as brief as possible?
@alowhum the warning is emitted at https://github.com/mysensors/MySensors/blob/dd91aeb9c30dbd658bd02c34445669a7cd996c0f/core/MySensorsCore.cpp#L60
Calling wait and send from within receive can cause recursive loops, which is why the log message is shown.
-
Ah, interesting, thanks for the explanation.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login