diff --git a/extras/decoder/DebugDecoder.py b/extras/decoder/DebugDecoder.py index 330326f6..c5c9b371 100644 --- a/extras/decoder/DebugDecoder.py +++ b/extras/decoder/DebugDecoder.py @@ -8,7 +8,6 @@ TODO list: 1. Parse macro values (the names of bits in all registers in header file) 2. Failed SPI write handling 3. SX126x/SX128x handling - 4. AT handling ''' diff --git a/extras/template/ModuleTemplate.cpp b/extras/template/ModuleTemplate.cpp index 07267305..1efb1fc0 100644 --- a/extras/template/ModuleTemplate.cpp +++ b/extras/template/ModuleTemplate.cpp @@ -17,6 +17,6 @@ int16_t ::begin() { /* "begin" method SHOULD implement some sort of mechanism to verify the connection between Arduino and the module. - For example, sending AT command for UART modules, or reading a version register for SPI/I2C modules + For example, reading a version register */ } diff --git a/extras/template/ModuleTemplate.h b/extras/template/ModuleTemplate.h index 4d957cb0..ee121942 100644 --- a/extras/template/ModuleTemplate.h +++ b/extras/template/ModuleTemplate.h @@ -13,7 +13,7 @@ */ #if !defined(_RADIOLIB__H) && !defined(RADIOLIB_EXCLUDE_) -#ifndef _RADIOLIB__H +#if !defined(_RADIOLIB__H) #define _RADIOLIB__H /* @@ -23,16 +23,6 @@ #include "../../Module.h" #include "../../TypeDef.h" -/* - Only use the following include if the module implements methods for OSI transport layer control. - This concerns only modules similar to e.g. ESP8266. - - In this case, your class MUST implement all virtual methods of TransportLayer class. - You also MUST provide crystal oscillator frequency and frequency configuration divisor step resolution - to the TransportLayer constructor. -*/ -//#include "../../protocols/PhysicalLayer/TransportLayer.h" - /* Only use the following include if the module implements methods for OSI physical layer control. This concerns only modules similar to SX127x/RF69/CC1101 etc. @@ -43,7 +33,7 @@ /* Register map - Definition of SPI/I2C register map SHOULD be placed here. The register map SHOULD have two parts: + Definition of SPI register map SHOULD be placed here. The register map SHOULD have two parts: 1 - Address map: only defines register names and addresses. Register names MUST match names in official documentation (datasheets etc.). @@ -52,11 +42,11 @@ See RF69 and SX127x header files for examples of register maps. */ -// register map | spaces up to this point -#define _REG_ 0x00 +// register map | spaces up to this point +#define RADIOLIB__REG_ 0x00 -// _REG_ MSB LSB DESCRIPTION -#define _ 0b00000000 // 7 0 +// _REG_ MSB LSB DESCRIPTION +#define RADIOLIB__ 0b00000000 // 7 0 /* @@ -64,10 +54,8 @@ The module class MAY inherit from the following classes: - 1 - ISerial: Interface for Arduino Serial class, intended as a thin wrapper for modules that directly take - Serial input (e.g. HC-05). - 2 - TransportLayer: In case the module implements methods for OSI transport layer control (e.g. ESP8266). - 3 - PhysicalLayer: In case the module implements methods for OSI physical layer control (e.g. SX127x). + 1 - PhysicalLayer: In case the module implements methods for OSI physical layer control (e.g. SX127x). + 2 - Common class: In case the module further specifies some more generic class (e.g. SX127x/SX1278) */ class { public: @@ -90,7 +78,7 @@ class { All implemented methods SHOULD return the status as int16_t type. */ -#ifndef RADIOLIB_GODMODE +#if !defined(RADIOLIB_GODMODE) private: #endif /*