mirror of
https://gitlab.com/wirelos/sprocket-lib.git
synced 2025-12-16 21:34:08 +01:00
rename message type
This commit is contained in:
@@ -43,7 +43,7 @@ void Sprocket::loop(){
|
||||
}
|
||||
|
||||
void Sprocket::dispatch( uint32_t from, String &msg ) {
|
||||
MeshMessage mMsg;
|
||||
SprocketMessage mMsg;
|
||||
if(mMsg.fromJsonString(msg)){
|
||||
dispatchMessageToPlugins(mMsg);
|
||||
}
|
||||
@@ -60,8 +60,8 @@ void Sprocket::activatePlugins(Scheduler* scheduler, Network* network){
|
||||
}
|
||||
}
|
||||
|
||||
void Sprocket::dispatchMessageToPlugins(MeshMessage msg){
|
||||
if(msg.type != MeshMessage::NONE){ // baaaa
|
||||
void Sprocket::dispatchMessageToPlugins(SprocketMessage msg){
|
||||
if(msg.type != SprocketMessage::NONE){ // baaaa
|
||||
for(Plugin* p : plugins){
|
||||
Serial.println("dispatch to plugins");
|
||||
p->onMessage(msg);
|
||||
|
||||
Reference in New Issue
Block a user