ENEL400
/
Aloha
Aloha implementation of LoRa technology
Fork of SX1276PingPong by
Aloha.h
- Committer:
- rba90
- Date:
- 2016-05-31
- Revision:
- 15:f790f35839db
- Child:
- 16:c3c6b13c3c42
File content as of revision 15:f790f35839db:
#ifndef ALOHA_H_ #define ALOHA_H_ #include "mbed.h" #define ALOHA_MAX_ATTEMPT 3 class Aloha { public: typedef enum { IDLE = 0, PENDING, RETRANSMIT, EXPIRED } AlohaState_t; public: Timeout AlohaAckTimeout; uint32_t delay; int attempts; AlohaState_t state; public: Aloha() { attempts = 0; state = Aloha::IDLE; } ~Aloha() { } }; #endif