NodeManager icon indicating copy to clipboard operation
NodeManager copied to clipboard

Dimmer not responding to new percentage values -- with fix

Open brahmafear opened this issue 7 years ago • 3 comments

MySensors 2.3.0 NodeManager 1.7 Homeassistant 0.73.2 controller

Default SensorDimmer does not respond to changing brightness. onReceive function seems to only respond to V_STATUS messages.

Changed SensorDimmer::onReceive() code to this as temporary fix:

  // handle a SET command
  if (message->getCommand() == C_SET ) {
    // if changing the status
    if (message->type == V_STATUS) setStatus(message->getInt());
    // if changing the percentage of the dimmer
    if (message->type == V_PERCENTAGE) setPercentage(message->getInt());
  }  

brahmafear avatar Jul 20 '18 12:07 brahmafear

Thanks for reporting it, adding to the v1.8 dev queue

user2684 avatar Jul 20 '18 13:07 user2684

@brahmafear I'm reviewing this in more details and seems weird the original code with child->getType() == V_PERCENTAGE is not working as expected. Are you sure you are sending the V_PERCENTAGE message to the second child? Your workaround unfortunately would make both the child responding to both V_STATUS and V_PERCENTAGE which is not ideal. Thanks!

user2684 avatar Oct 01 '18 15:10 user2684

Moving out of v1.8 development queue

user2684 avatar Nov 17 '18 18:11 user2684