sscanf是错误使用
错误:想不接受最后的000,结果还是接受了,导致溢出
sscanf("1707796440000","%u000",&secondsDiff);
sscanf("1707796440000","%10u",&secondsDiff);
错误用法: 不想接收后面的: 结果还是接收了
sscanf(bt_rx_buffer, "wp%s%[^:]:", data);
正确用法:
sscanf(bt_rx_buffer, "wp%[^:]:", data);