the title already says it: I want to send more than 240 bits to the commander. In fact i need to send the roll, pitch, yaw, thrust and a 4x6 matrix containing float-values to the commander. I've already compressed the data (lossy) but it's still to large. So my idea was to split the data and send two packages instead. But there is only for a very short time a connection to the crazyflie and then I always lose the connection with the message: "Too many packets lost"
I thought maybe the problem is, that I try to send two packets in quick succession to the commander. So I tried:
When I get new data from the joystick then I calculate that 4x6 matrix (depends on RPY and thrust) and send the first part of my data to the commander. The next RPY and thrust values from the joystick will be ignored. Instead I send the second part of my data to the commander. But I get the same error: "Too many packets lost"
My next guess is, that I pack the data wrong!? Right now it's like that:
Code: Select all
pk = CRTPPacket()
pk.port = CRTPPort.COMMANDER
pk.data = struct.pack('<BhhbBbBbBbBbBbBbBbBbBbBbBbB', self._id+1,int(roll*100),int(pitch*100),m11,e11,m12,e12,m13,e13,m14,e14,m15,e15,m16,e16,m21,e21,m22,e22,m23,e23,m24,e24,m25,e25,m26,e26)
self._cf.send_packet(pk)
Of course I adjusted the struct "CommanderCrtpValues" on the crazyflie-firmware.
Are there any other restrictions I miss?
Thanks,
CrazyGuy