X-Git-Url: http://git.droids-corp.org/?p=protos%2Fxbee.git;a=blobdiff_plain;f=rc_proto.h;h=dd5895119aee914036a768a445fc09f118b924a4;hp=96716d296f67e5476a5387bb467485f5ebbbc2ac;hb=HEAD;hpb=735209cdbe2c6d67c8473e17cdce0ac9496c42d1 diff --git a/rc_proto.h b/rc_proto.h index 96716d2..dd58951 100644 --- a/rc_proto.h +++ b/rc_proto.h @@ -34,17 +34,29 @@ #define RC_PROTO_TYPE_RANGE 1 +#define RX_DB_THRESHOLD 0x40 + /* TODO: Authenticate packet!! */ +extern uint64_t rc_send_dstaddr; + +struct rc_proto_hdr { + uint8_t type; +} __attribute__((packed)); + struct rc_proto_channel { uint8_t type; int16_t axis[AXIS_NUMBER]; -}; +} __attribute__((packed)); struct rc_proto_range { uint8_t type; uint8_t power_level; -}; +} __attribute__((packed)); + +void rc_proto_rx_range(int power_level); +void rc_proto_send_channels(void); +void rc_proto_init(void); #endif