Coordinator v2
Dependencies: NerfUSXbee PinDetect EthernetInterface JSON MFRC522 WebSocketClient mbed-rtos mbed
includes/Target.hpp@1:e1c5259b7d9a, 2017-04-10 (annotated)
- Committer:
- Ismael Balafrej
- Date:
- Mon Apr 10 15:02:24 2017 -0400
- Revision:
- 1:e1c5259b7d9a
- Child:
- 2:019d8848cf7e
V1
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Ismael Balafrej |
1:e1c5259b7d9a | 1 | #pragma once |
Ismael Balafrej |
1:e1c5259b7d9a | 2 | #include <vector> |
Ismael Balafrej |
1:e1c5259b7d9a | 3 | #include "ports.hpp" |
Ismael Balafrej |
1:e1c5259b7d9a | 4 | #include "RealXbeeTransmitter.hpp" |
Ismael Balafrej |
1:e1c5259b7d9a | 5 | |
Ismael Balafrej |
1:e1c5259b7d9a | 6 | extern RealXbeeTransmitter xbee_transmitter; |
Ismael Balafrej |
1:e1c5259b7d9a | 7 | |
Ismael Balafrej |
1:e1c5259b7d9a | 8 | struct Target |
Ismael Balafrej |
1:e1c5259b7d9a | 9 | { |
Ismael Balafrej |
1:e1c5259b7d9a | 10 | int target_number; //0 or 1 |
Ismael Balafrej |
1:e1c5259b7d9a | 11 | int addr_table[8]; //64 bit addr |
Ismael Balafrej |
1:e1c5259b7d9a | 12 | |
Ismael Balafrej |
1:e1c5259b7d9a | 13 | Target(int address_msb, int address_lsb, int target_number); |
Ismael Balafrej |
1:e1c5259b7d9a | 14 | |
Ismael Balafrej |
1:e1c5259b7d9a | 15 | //mode: ally (0) or enemy (1), timeout 16 bits in ms |
Ismael Balafrej |
1:e1c5259b7d9a | 16 | void rise(int mode, int timeout); |
Ismael Balafrej |
1:e1c5259b7d9a | 17 | |
Ismael Balafrej |
1:e1c5259b7d9a | 18 | void get_address_for_xbee(int address_msb, int address_lsb); |
Ismael Balafrej |
1:e1c5259b7d9a | 19 | }; |