Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: decawave_network.cpp
- Revision:
- 1:93fcc351837a
- Parent:
- 0:bd42ff91c25b
- Child:
- 2:fb2268373246
- Child:
- 4:01caa2302657
--- a/decawave_network.cpp Wed Feb 15 17:23:19 2017 +0000
+++ b/decawave_network.cpp Wed Feb 15 17:51:48 2017 +0000
@@ -224,11 +224,11 @@
if(mavlink_parse_char(MAVLINK_COMM_0,byte,&msg,&status)) {
- // printf("Parse Successfully msg id %d\r\n",msg.msgid);
+ //printf("Parse Successfully msg id %d\r\n",msg.msgid);
if(msg.msgid == MAVLINK_MSG_ID_HEARTBEAT) {
mavlink_heartbeat_t hb_msg;
mavlink_msg_heartbeat_decode(&msg,&hb_msg);
- //printf("System ID %d Comp ID %d \r\n",msg.sysid,msg.compid);
+ printf("System ID %d Comp ID %d \r\n",msg.sysid,msg.compid);
nodes_in_range[msg.sysid]= msg.compid;
last_heartbeat[msg.sysid]=LocalTimer.read();
// dwm_LED = !dwm_LED;
@@ -277,4 +277,7 @@
nodes_in_range[i] = 0;
}
}
+}
+float DecaWaveNetwork::getRange(int node){
+ return ranges[node];
}
\ No newline at end of file