Commit 96679bb4 authored by PhiBo's avatar PhiBo 🚀

Move rpc code to new file

parent 9ee28619
#include "sensor_node.h"
ArduRPC_SensorNode::ArduRPC_SensorNode(ArduRPC &rpc, char *name) : ArduRPCHandler()
{
this->type = 0x9999;
this->registerSelf(rpc, name, (void *)this);
}
uint8_t ArduRPC_SensorNode::call(uint8_t cmd_id)
{
if (cmd_id == 0x10) {
return RPC_RETURN_SUCCESS;
}
return RPC_RETURN_COMMAND_NOT_FOUND;
}
......@@ -161,17 +161,3 @@ void SensorNode::writeValue(uint8_t type, float value)
this->value_count++;
}
ArduRPC_SensorNode::ArduRPC_SensorNode(ArduRPC &rpc, char *name) : ArduRPCHandler()
{
this->type = 0x9999;
this->registerSelf(rpc, name, (void *)this);
}
uint8_t ArduRPC_SensorNode::call(uint8_t cmd_id)
{
if (cmd_id == 0x10) {
return RPC_RETURN_SUCCESS;
}
return RPC_RETURN_COMMAND_NOT_FOUND;
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment