SlippyMesh
1.0.0
用C ++编写的轻量级Lora网络网络
向所有人发送消息,打开您的序列号并输入
send 0xFFFFFFFF "hello world"
获取命令列表
help
将一团糟发送到目标地址
send <address> <message>
例子
sendex 0x01234567 "hello"
将消息发送到0x01234567
sendex 0xFFFFFFFF "hello everyone"
向所有人发送消息
将消息发送到目标地址,并带有一些额外的选项
sendex <address> <message> <type> <service> <flags>
例子
sendex 0x01234567 "hello" 0 0 0b00000000
将消息发送到0x01234567(与'send 0x01234567“ hello”'相同)
sendex 0x01234567 "ping" 0 1 0b00000000
将远程命令发送到0x01234567
sendex 0xFFFFFFFF "hello everyone" 0 0 0b00000000
向所有人发送消息(与'send 0xffffffff“你好所有人”相同)
sendex 0xFFFFFFFF "hello neighbors" 0 0 0b10000000
向相邻节点发送消息
通过一些额外的选项和base64将消息发送到目标地址
send64 <address> <base64> <type> <service> <flags>
例子
send64 0x01234567 "aGVsbG8=" 0 0 0b00000000
将消息发送到0x01234567(这是带有base64的sendex)
要发送远程命令,您需要使用sendx
sendex <address> "<command> <args>" 0 1 0b00000000
ping
会返回“乒乓球”
uptime
将在“ HH:MM:SS”中返回节点正常运行时间
在src/commands.cpp中创建一个名为rcmd_yourcommandname的函数
void rcmd_yourcommandname (MyRemoteCommandParser::Argument *args, char *res) {
char * response = " hello world " ;
strlcpy (res, response, MyRemoteCommandParser::MAX_RESPONSE_SIZE);
}然后在void registerRemoteCommands() {}的底部添加它
remoteParser.registerCommand( " yourcommandname " , " " , &rcmd_yourcommandname);最后将其添加到#endif in src/commands.h中
void rcmd_yourcommandname (MyRemoteCommandParser::Argument *args, char *res);