rospy.spin() not working in real nor sim #305
Replies: 2 comments
-
The current 3D simulator is not ROS time-related. A ROS compatible simulator would be quite useful for myself and many others in the future. Perhaps I could get some precisions on how to change crazyflieSim.py to work on ROS data? |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I wish to create a ROS subscriber node for cf2 position callbacks. This is integrated in my code below, where I attempt to hover cf3 above cf2.
When doing real drone tests:
I cannot
init_node
(unable to register with CrazyflieAPI) nor userospy.spin()
(needs a node). A previous issue Interaction with objects in real time #54 says to remove both - but then only one callback occurs... Unless there is some method I am not aware of. I do however want the subscriber to continue running. How do I do so?When testing with the simulator:
The matplotlib sim currently bugs when I register a node, stops updating right after takeoff.
Currently it bugs at 2.4s. I have been able to trace a multithread problem between
rospy.spin()
and matplotlib's running thread. How do I use ROS in simulation? Is there some other method I am not aware of?Worth noting that I am using
cmdPosition()
without problems.The cf2 drone's position is captured correctly in the callback (verified).
Beta Was this translation helpful? Give feedback.
All reactions