2016-02-17 21:25:26 -04:00
|
|
|
#pragma once
|
2015-09-04 13:37:09 -03:00
|
|
|
|
|
|
|
#define RCINPUT_UDP_NUM_CHANNELS 8
|
2020-01-15 08:22:35 -04:00
|
|
|
#define RCINPUT_UDP_NUM_CHANNELS_V3 16
|
2015-09-04 13:37:09 -03:00
|
|
|
|
|
|
|
struct __attribute__((packed)) rc_udp_packet {
|
|
|
|
uint32_t version;
|
|
|
|
uint64_t timestamp_us;
|
|
|
|
uint16_t sequence;
|
|
|
|
uint16_t pwms[RCINPUT_UDP_NUM_CHANNELS];
|
|
|
|
};
|
2020-01-15 08:22:35 -04:00
|
|
|
|
|
|
|
struct __attribute__((packed)) rc_udp_packet_v3 {
|
|
|
|
uint32_t version;
|
|
|
|
uint64_t timestamp_us;
|
|
|
|
uint16_t sequence;
|
|
|
|
/* Up-to 16 channels, but client can transmit less channels */
|
|
|
|
uint16_t pwms[RCINPUT_UDP_NUM_CHANNELS_V3];
|
|
|
|
};
|