![]() There are also classes to support a Spektrum DX8 transmitter with an adapter cable, as well as a Logitech Extreme 3D Pro joystick and a Sony PS3 controller. The idea is that you can specify the labels associated with the three-position switch on a typical R/C transmitter like this. This example works with the FrSky Taranis transmitter. Where pitch, roll, yaw, and climb are in the interval and switch is 0, 1, or 2. Pitch, roll, yaw, climb, switch = controller.poll() For example: from quadstick.rc.frsky import Taranis as ControllerĬontroller = Controller(('Altitude hold', 'Position hold', 'Autopilot')) To avoid having to deal with this complexity directly, I bundled the code for various controllers into a package, which requires only a few lines of code to use. Naturally we turned to PyGame, but we soon ran into the complications resulting from using different controllers on different operating systems. My students and I had been writing a Quadcopter simulator in Python, and we needed a way to control the vehicle from a joystick or R/C transmitter. PyQuadStick: An open-source Python package for quadcopter flight-simulator / remote autopilot control on Linux, Windows, and Mac OS X ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |