this is the working code for the xdot to read in serial from the pi and send it over LoRa

Committer:
Jenkins@KEILDM1.dc.multitech.prv
Date:
Fri Nov 08 09:29:24 2019 -0600
Revision:
21:bc12c888e7dc
Parent:
19:aa5b1fcd05be
xdot-library revision 3.2.5 and mbed-os revision mbed-os-5.13.4

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 1 /*
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 2 / _____) _ | |
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 3 ( (____ _____ ____ _| |_ _____ ____| |__
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 4 \____ \| ___ | (_ _) ___ |/ ___) _ \
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 5 _____) ) ____| | | || |_| ____( (___| | | |
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 6 (______/|_____)_|_|_| \__)_____)\____)_| |_|
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 7 (C)2013 Semtech
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 8
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 9 Description: Generic radio driver definition
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 10
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 11 License: Revised BSD License, see LICENSE.TXT file include in the project
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 12
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 13 Maintainer: Miguel Luis and Gregory Cristian
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 14 */
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 15 #ifndef __SXRADIOEVENTS_H__
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 16 #define __SXRADIOEVENTS_H__
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 17
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 18 /*!
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 19 * \brief Radio driver callback functions
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 20 */
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 21 class SxRadioEvents
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 22 {
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 23 public:
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 24 /*!
Jenkins@KEILDM1.dc.multitech.prv 14:f0c24ce93427 25 * \brief Tx Start callback prototype.
Jenkins@KEILDM1.dc.multitech.prv 14:f0c24ce93427 26 */
Jenkins@KEILDM1.dc.multitech.prv 14:f0c24ce93427 27 virtual void TxStart( void ) {}
Jenkins@KEILDM1.dc.multitech.prv 14:f0c24ce93427 28 /*!
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 29 * \brief Tx Done callback prototype.
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 30 */
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 31 virtual void TxDone( void ) {}
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 32 /*!
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 33 * \brief Tx Timeout callback prototype.
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 34 */
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 35 virtual void TxTimeout( void ) {}
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 36 /*!
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 37 * \brief Rx Done callback prototype.
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 38 *
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 39 * \param [IN] payload Received buffer pointer
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 40 * \param [IN] size Received buffer size
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 41 * \param [IN] rssi RSSI value computed while receiving the frame [dBm]
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 42 * \param [IN] snr Raw SNR value given by the radio hardware
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 43 * FSK : N/A ( set to 0 )
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 44 * LoRa: SNR value is two's complement in 1/4 dB
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 45 */
Jenkins@KEILDM1.dc.multitech.prv 21:bc12c888e7dc 46 virtual void RxDone( uint8_t *payload, uint16_t size, int16_t rssi, int16_t snr ) {}
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 47 /*!
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 48 * \brief Rx Timeout callback prototype.
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 49 */
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 50 virtual void RxTimeout( void ) {}
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 51 /*!
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 52 * \brief Rx Error callback prototype.
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 53 */
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 54 virtual void RxError( void ) {}
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 55 /*!
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 56 * \brief FHSS Change Channel callback prototype.
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 57 *
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 58 * \param [IN] currentChannel Index number of the current channel
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 59 */
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 60 virtual void FhssChangeChannel( uint8_t currentChannel ) {}
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 61 /*!
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 62 * \brief CAD Done callback prototype.
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 63 *
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 64 * \param [IN] channelActivityDetected Channel Activity detected during the CAD
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 65 */
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 66 virtual void CadDone( bool channelActivityDetected ) {}
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 67 /*!
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 68 * \brief Mac Event callback prototype.
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 69 */
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 70 virtual void MacEvent( void ) {}
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 71
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 72 virtual void LinkIdle(void) {}
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 73 };
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 74
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 75 #endif // __SXRADIOEVENTS_H__
Jenkins@KEILDM1.dc.multitech.prv 11:be2a6466d680 76