Thanh Nguyen / libmDot-dev-mbed5
Revision:
179:578d8030ba57
Parent:
172:7ec44396a51b
Child:
182:b642f4d0c95b
diff -r 8f7d93f3bbb5 -r 578d8030ba57 SxRadio.h
--- a/SxRadio.h	Wed Sep 12 15:04:15 2018 -0500
+++ b/SxRadio.h	Tue Sep 18 08:25:04 2018 -0500
@@ -45,7 +45,7 @@
         RF_CAD,
     }RadioState_t;
 
-    SxRadio(uint32_t WakeupTime) : WakeupTime(WakeupTime), State(RF_IDLE), Modem(MODEM_LORA) { }
+    SxRadio(uint32_t WakeupTime) : WakeupTime(WakeupTime), freq_offset(0), State(RF_IDLE), Modem(MODEM_LORA) { }
     virtual ~SxRadio() {};
 
     /*!
@@ -186,6 +186,8 @@
                               bool fixLen, bool crcOn, bool FreqHopOn,
                               uint8_t HopPeriod, bool iqInverted, uint32_t timeout ) = 0;
 
+    virtual void SetTxPower(int8_t power) = 0;
+
     virtual void SetTxContinuous(bool enable) = 0;
 
     /*!
@@ -278,9 +280,15 @@
     void GrabMutex(void) { mutex.lock(); }
     void ReleaseMutex(void) { mutex.unlock(); }
 
+    int32_t GetFrequencyOffset() { return freq_offset; }
+    void SetFrequencyOffset(int32_t offset) { freq_offset = offset; }
+
     const uint32_t WakeupTime;
 
+
 protected:
+    int32_t freq_offset;
+
     RadioState_t State;
 
     RadioModems_t Modem;
@@ -289,6 +297,7 @@
      * Access protection
      */
     Mutex mutex;
+
 };
 
 #endif // __SXRADIO_H__