mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-22 15:33:34 +08:00
Tests fixes, the library should compile now
This commit is contained in:
@@ -65,7 +65,7 @@ uavcan_linux::NodePtr initNodeWithDynamicID(const std::vector<std::string>& ifac
|
||||
*/
|
||||
node->setNodeID(client.getAllocatedNodeID());
|
||||
|
||||
node->setStatusOk();
|
||||
node->setModeOperational();
|
||||
|
||||
return node;
|
||||
}
|
||||
|
||||
@@ -406,7 +406,7 @@ static uavcan_linux::NodePtr initMainNode(const std::vector<std::string>& ifaces
|
||||
const int start_res = node->start();
|
||||
ENFORCE(0 == start_res);
|
||||
|
||||
node->setStatusOk();
|
||||
node->setModeOperational();
|
||||
return node;
|
||||
}
|
||||
|
||||
@@ -483,7 +483,7 @@ static void runSubNode(const uavcan_linux::SubNodePtr& node)
|
||||
virtual void handleNodeStatusChange(const NodeStatusChangeEvent& event) override
|
||||
{
|
||||
std::cout << "Remote node NID " << int(event.node_id.get()) << " changed status: "
|
||||
<< int(event.old_status.status_code) << " --> " << int(event.status.status_code) << std::endl;
|
||||
<< event.old_status.toString() << " --> " << event.status.toString() << std::endl;
|
||||
}
|
||||
};
|
||||
NodeStatusMonitor nsm(*node);
|
||||
|
||||
@@ -33,7 +33,7 @@ static uavcan_linux::NodePtr initNode(const std::vector<std::string>& ifaces, ua
|
||||
/*
|
||||
* Say Hi to the world.
|
||||
*/
|
||||
node->setStatusOk();
|
||||
node->setModeOperational();
|
||||
node->logInfo("init", "Hello world! I'm [%*], NID %*",
|
||||
node->getNodeStatusProvider().getName().c_str(), int(node->getNodeID().get()));
|
||||
return node;
|
||||
|
||||
Reference in New Issue
Block a user