Tobi's ubw test branch
Dependencies: mavlink_bridge mbed
Fork of AIT_UWB_Range by
Diff: MMRanging/MMRanging.h
- Revision:
- 36:883de6f9a73b
- Parent:
- 35:95d838d33bf5
- Child:
- 37:40f94c634c3e
diff -r 95d838d33bf5 -r 883de6f9a73b MMRanging/MMRanging.h --- a/MMRanging/MMRanging.h Tue Feb 17 10:58:58 2015 +0000 +++ b/MMRanging/MMRanging.h Fri Feb 20 09:07:52 2015 +0000 @@ -12,20 +12,23 @@ class MMRanging { public: MMRanging(DW1000& DW); - void requestRanging(); - void requestTime(); + void requestRanging(uint8_t destination); //private: DW1000& dw; void callbackRX(); void callbackTX(); - void sendRangingframe(uint8_t type, uint8_t sequence_number, uint64_t time_difference_receiver); + void sendRangingframe(uint8_t destination, uint8_t sequence_number, uint8_t type, uint64_t time_difference_receiver); + uint8_t address; struct rangingframe { - uint32_t type; - uint32_t sequence_number; + uint8_t source; + uint8_t destination; + uint8_t sequence_number; + uint8_t type; uint64_t time_difference_receiver; - } ; + }; + uint64_t rangingtimingsSender[10][2]; uint64_t rangingtimingsReceiver[10][2]; uint64_t tofs; @@ -38,7 +41,6 @@ uint64_t RX_timestamp; int event_i; char event[10][20]; - uint64_t eventtimes[10]; uint8_t counter; };