Guide: Flying the Crazyflie 2.0 with T-Skin

This guide provides you with everything that is necessary to fly the Crazyflie 2.0 quadcopter with the T-Skin as a controller. The following instructions assume you followed this guide on how to set up your Crazyflie/T-Skin environment.

 

Used hardware
  • Crazyflie 2.0
  • Crazyradio USB Dongle
  • Z-Ranger deck for the Crazyflie 2.0
  • T-Skin
  • Linux computer with Crazyflie/T-Skin environment already set up
Installation guide
  •  Flash the attached ComunicazioneCrazyflie.ino file to your T-Skin/Tactigon using the Arduino IDE.
  • On your Linux computer, copy both __init__.py and tactigon.py files to the following directory:
    /crazyflie-clients-python/src/cfclient/utils/input/inputinterfaces/
    You have to replace the existing __init__.py file with the attached one since there were some adjustments needed in order to recognise the T-Skin as an input device. The Crazyflie client (cf-client) allows developers to create custom input interfaces in order to allow further control devices (apart from X-Box and Playstation Contollers) to be used as an input device for the cf-client. The tactigon.py file serves as such a custom input interface, written to receive data sent by the T-Skin. __init__.py runs every time the cf-client is started and scans for available input interfaces.
  • Adjust the tactigon.py file to your needs. A mandatory step is to replace the given MAC address with the one specific to the T-Skin/Tactigon you use in the following line:
    p = btle.Peripheral("BE:A5:7F:47:54:65")
  • Make sure your computer’s bluetooth interface is powered on and is able to scan for new devices in order to establish a bluetooth connection to the T-Skin in the next steps.
  • In a terminal window, direct to your cf-client installation (crazyflie-clients-python directory) and start the client by issuing the following command:
    python3 bin/cfclient
  • After starting the client, it should be indicated that a connection to the T-Skin/Tactigon has been established and is selected as an in input device (See screenshot below: Connection to the Tactigon is indicated in the bottom left corner).
  • Make sure the Crazyradio USB Dongle is plugged in and the Crazyflie 2.0 is powered on. Use the Scan and Connect buttons to establish a connection between the client and the quadcopter.
  • Assuming a connection has been established you are now ready to control the Crazyflie with your T-Skin/Tactigon device. On the T-Skin, press button 4 to enter hover mode and control Pitch and Roll by tilting the T-Skin accordingly. To land the quadcopter, simply press button 4 again, and hover mode will be exited.

The Crazyflie PC Client

Troubleshooting and issues

If you follow every step there should be no problems establishing a connection between the cf-client and the T-Skin. Also make sure you followed this guide to correctly set up the development environment of the cf-client as well as all steps necessary to ensure compatibility between your bluetooth interface and the T-Skin device. If the cf-client does not recognise the T-Skin as an input device, make sure both your bluetooth interface and the T-Skin are powered on. You should also check if you changed the MAC address in tactigon.py correctly.

 

Download Files

Download all the files mentioned in this Guide as an archive here .

 


Teile diese Seite