mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-30 01:13:35 +08:00
Set default node id to 1, default bitrate to 1M
This commit is contained in:
committed by
Lorenz Meier
parent
8d66e1c0ef
commit
76da9ab82b
@@ -1252,7 +1252,7 @@ int uavcan_main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Node ID
|
// Node ID
|
||||||
int32_t node_id = 0;
|
int32_t node_id = 1;
|
||||||
(void)param_get(param_find("UAVCAN_NODE_ID"), &node_id);
|
(void)param_get(param_find("UAVCAN_NODE_ID"), &node_id);
|
||||||
|
|
||||||
if (node_id < 0 || node_id > uavcan::NodeID::Max || !uavcan::NodeID(node_id).isUnicast()) {
|
if (node_id < 0 || node_id > uavcan::NodeID::Max || !uavcan::NodeID(node_id).isUnicast()) {
|
||||||
@@ -1261,7 +1261,7 @@ int uavcan_main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
|
|
||||||
// CAN bitrate
|
// CAN bitrate
|
||||||
int32_t bitrate = 0;
|
int32_t bitrate = 1000000;
|
||||||
(void)param_get(param_find("UAVCAN_BITRATE"), &bitrate);
|
(void)param_get(param_find("UAVCAN_BITRATE"), &bitrate);
|
||||||
|
|
||||||
// Start
|
// Start
|
||||||
|
|||||||
Reference in New Issue
Block a user