Seems like krag is super MIA. Curious if anyone out there has a really solid understanding of how this library works? I've been trying to figure it out but I've never worked with wifi packets before so I'm starting from scratch.
The biggest feature I want to implement is starting the motors for manual takeoff. In the official app this can be accomplished by moving the left stick to 4 o clock & the right stick to 8. I have tried replicating this with tellolib by both setting values for multiple seconds via
Tello.controllerState.setAxis(), as well as with a game controller. Unfortunately I haven't had any success yet. My hope is that taking off manually will avoid the giant offset in the position tracking that occurs when you use auto-takeoff.
Other libraries support this function, and the creator of aTelloPilot says this is the cmd that needs to be sent to the
tello.
Code:
User Datagram Protocol, Src Port: 6525, Dst Port: 8889
TELLO_CMD
SOP : 0xcc
SIZE : 176
CRC8 : 0x7f
PACT : 0x60
DIR : -> TO DRONE
CMD : TELLO_CMD_STICK (80)
SEQ : 0
DATASZ: 11
DATA : 6c 61 0b 5b 28 0d 06 13 21 45 02
STICK - roll: 364, pitch: 364, thr: 364, yaw:1684, fastmode:0
CRC16 : 0x7cec
I tried converting that Data packet to this which was also unsuccessful. I kind of just guessed at the conversion to tellolibs packet values.
C#:
public static void StartMotors()
{
var packet = new byte[] { 0x6c, 0x61, 0x0b, 0x5b, 0x28, 0x0d, 0x06, 0x13, 0x21, 0x45, 0x02, };
setPacketSequence(packet);
setPacketCRCs(packet);
client.Send(packet);
}