Skip to content

Commit

Permalink
getDeviceInfo for serial communication
Browse files Browse the repository at this point in the history
  • Loading branch information
snoutmate committed May 1, 2019
1 parent 342b091 commit 6b48624
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/protocol.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,14 @@ void CC_Protocol::setDefaultCallbacks()
CCLOGI("Parameter '%s' updated to '%s'",name.c_str(), value.c_str());
}
});

if (m_is_remote == false) {
setCommandCallback("getDeviceInfo", [this](const JsonDocument& j) {
sendHello();
sendDiagnostics();
sendAllParameters();
});
}
}

void CC_Protocol::importCallbacks(CC_Protocol* source)
Expand Down

0 comments on commit 6b48624

Please sign in to comment.