Good evening!
I've successfully created my own system task, and i'm attempting to implement a "pairing" sequence for the CrazyFlie. I'm able to send messages to the client through the drone's firmware, but now im looking to send messages the other way.
For example, if I wanted to send a simple "hello!" message to the drone, what would be the best way to go about this? Is there an "easy way" to go about creating the message where the packet construction is done for me?
Something tells me i'm going to have to construct the message myself and split it into <40byte packets.
Send message to custom System Task
Re: Send message to custom System Task
Hi,
You can construct packets using the CRTPPacket class in the cflib and send them with for instance the send_packet method on the Crazyflie class.
See the API reference for guidance: https://www.bitcraze.io/documentation/r ... api/cflib/
And to see how this packets get deconstructed you can look in the firmware for instance in param.c to see how packets to the CRTP_PORT_PARAM is treated.
For extra information see: https://www.bitcraze.io/documentation/r ... reas/crtp/
You can construct packets using the CRTPPacket class in the cflib and send them with for instance the send_packet method on the Crazyflie class.
See the API reference for guidance: https://www.bitcraze.io/documentation/r ... api/cflib/
And to see how this packets get deconstructed you can look in the firmware for instance in param.c to see how packets to the CRTP_PORT_PARAM is treated.
For extra information see: https://www.bitcraze.io/documentation/r ... reas/crtp/
Re: Send message to custom System Task
im really not seeing a way to send messages FROM the client TO the crazyflie.
The only place i can really find some good info is radiodriver.py on the client side. So if i'm making my own python script, do you think i'll need to import radiodriver and use their radio/packet handling functions?
We already have a swarm capability as well as end-to-end encryption. Something tells me i'm going to have to completely integrate the radiodriver for us to truly be able to send custom stuff to the drone.
The only place i can really find some good info is radiodriver.py on the client side. So if i'm making my own python script, do you think i'll need to import radiodriver and use their radio/packet handling functions?
We already have a swarm capability as well as end-to-end encryption. Something tells me i'm going to have to completely integrate the radiodriver for us to truly be able to send custom stuff to the drone.
Re: Send message to custom System Task
You can check this PR where I want to add new API for parameters, it sends message from the client to the crazyflie: https://github.com/bitcraze/crazyflie-l ... n/pull/280
And a branch that accepts them: https://github.com/bitcraze/crazyflie-f ... f858d4R204
And a branch that accepts them: https://github.com/bitcraze/crazyflie-f ... f858d4R204
Re: Send message to custom System Task
you're the best, thank you