From cec654a75be8a9477c0c0263d8fa0c878328fac8 Mon Sep 17 00:00:00 2001 From: Dennis Date: Fri, 1 Dec 2017 08:13:06 -0500 Subject: [PATCH 1/2] Update Protocol Details for CABELL protocol (#117) * Added CABELL Protocol * Added additional disclaimer to license. * Revert "Added additional disclaimer to license." This reverts commit a00bc9956a155a1a73dbbcd21fd19633d6d121ff. * Added additional disclaimer * Added CABELL_NRF24L01_INO define to config * Updated available protocol list Added CABELL protocol * Removed unused variables * Changed changel range to 45 channels that comply with USA FCC part 97 rules. This change allows licenced HAMs to operate under part 97 rules instead of part 15. These channels are still in the ISM band, but overlap with the part 97 amateur portion of the band. * Changed protocol number to 33 Was previously 30, but the main branch has now allocated up to 32, so changing to 33 * Corrected permutation calculation * Added sub-protocol for setting failsafe values * Opened up a free bit in the option byte for future use * Fixed packet errors when trying to unbind when in bind mode This use case didn't really make any sense, but it should not cause packet errors, so fixed it. * RSSI Telemetry for CABELL protocol * Pins back to stock configuration * Split checksum into MSB and LSB fields to avoid endian issue * struct change for checksum * Added analog values to telemetry packet that could be used for LIPO voltage * Added MODE_CABELL to frsk_link_frame * Updated packet layout comments * Fixed telemetry conditional compiles in CABELL protocol * Telemetry working; moved power override bit * Changed telemetry to 250 kbps and adjustable packet period - imporves reliability/range * Changed CABELL protocol number to 34 * Fixed typos in comments * Fix ATMEGA BASH_SERIAL buffer overrun Changed the compare to TXBUFFER_SIZE to >= If next wasn't set to zero until > TXBUFFER_SIZE then the next time the routines get called the the array index references outside the buffer (e.g tail+1) * Revert "Fix ATMEGA BASH_SERIAL buffer overrun" This reverts commit ba4526ee89c2b5a946a659eea2c9581c36254809. * Updated documentation for CABELL V3 Protocol * Updated Documentation for the CABELL V3 Protocol --- Multiprotocol/CABELL_nrf224l01.ino | 2 +- Multiprotocol/Multiprotocol.h | 2 +- Multiprotocol/Multiprotocol.ino | 2 +- Multiprotocol/Pins.h | 4 +--- Multiprotocol/Validate.h | 2 +- Protocols_Details.md | 14 ++++++++++---- 6 files changed, 15 insertions(+), 11 deletions(-) diff --git a/Multiprotocol/CABELL_nrf224l01.ino b/Multiprotocol/CABELL_nrf224l01.ino index e272eb2..6c50ba8 100644 --- a/Multiprotocol/CABELL_nrf224l01.ino +++ b/Multiprotocol/CABELL_nrf224l01.ino @@ -439,4 +439,4 @@ uint16_t initCABELL(void) return packet_period; } -#endif +#endif \ No newline at end of file diff --git a/Multiprotocol/Multiprotocol.h b/Multiprotocol/Multiprotocol.h index a16757c..6e486e3 100644 --- a/Multiprotocol/Multiprotocol.h +++ b/Multiprotocol/Multiprotocol.h @@ -803,4 +803,4 @@ Commands from TX to module use values > 127 for command type data[1-22] Failsafe data, encoded like normal channel data, with the expection that 0 means hold for that channel and 2047 means no pulses -*/ +*/ \ No newline at end of file diff --git a/Multiprotocol/Multiprotocol.ino b/Multiprotocol/Multiprotocol.ino index a433319..99a90e1 100644 --- a/Multiprotocol/Multiprotocol.ino +++ b/Multiprotocol/Multiprotocol.ino @@ -1589,4 +1589,4 @@ static uint32_t random_id(uint16_t address, uint8_t create_new) WDTCSR = 0; // Disable Watchdog interrupt } } -#endif +#endif \ No newline at end of file diff --git a/Multiprotocol/Pins.h b/Multiprotocol/Pins.h index e455326..e760180 100644 --- a/Multiprotocol/Pins.h +++ b/Multiprotocol/Pins.h @@ -3,12 +3,10 @@ it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. - Multiprotocol is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. - You should have received a copy of the GNU General Public License along with Multiprotocol. If not, see . */ @@ -338,4 +336,4 @@ #define eeprom_read_byte EEPROM.read #else #define EE_ADDR uint8_t* -#endif +#endif \ No newline at end of file diff --git a/Multiprotocol/Validate.h b/Multiprotocol/Validate.h index 42efac6..02ba70b 100644 --- a/Multiprotocol/Validate.h +++ b/Multiprotocol/Validate.h @@ -165,4 +165,4 @@ #endif #if MAX_PPM_CHANNELS>16 #error MAX_PPM_CHANNELS must be below or equal to 16. The default for this value is 16. -#endif +#endif \ No newline at end of file diff --git a/Protocols_Details.md b/Protocols_Details.md index 4638474..034ef6e 100644 --- a/Protocols_Details.md +++ b/Protocols_Details.md @@ -410,19 +410,25 @@ TAKE_OFF|EMG_STOP ## Cabell - *34* Homegrown protocol with variable number of channels (4-16) and telemetry (RSSI, V1, V2). -RXs details are located here: https://github.com/soligen2010/RC_RX_CABELL_V3_FHSS +It is a FHSS protocol developed by Dennis Cabell (KE8FZX) using the NRF24L01+ 2.4 GHz transceiver. 45 channels are used frequency hop from 2.403 through 2.447 GHz. The reason for using 45 channels is to keep operation within the overlap area between the 2.4 GHz ISM band (governed in the USA by FCC part 15) and the HAM portion of the band (governed in the USA by FCC part 97). This allows part 15 compliant use of the protocol, while allowing licensed amateur radio operators to operate under the less restrictive part 97 rules if desired. -CH1|CH2|CH3|CH4|CH5|CH6|CH7|CH8|CH9|CH10|CH11|CH12|CH13|CH14|CH15|CH16 ----|---|---|---|---|---|---|---|---|----|----|----|----|----|----|---- -CH1|CH2|CH3|CH4|CH5|CH6|CH7|CH8|CH9|CH10|CH11|CH12|CH13|CH14|CH15|CH16 +Additional details about configuring and using the protocol are available at the RX project at: https://github.com/soligen2010/RC_RX_CABELL_V3_FHSS + +CH1|CH2|CH3|CH4|CH5 |CH6 |CH7 |CH8 |CH9 |CH10|CH11|CH12|CH13|CH14 |CH15 |CH16 +---|---|---|---|----|----|----|----|----|----|----|----|----|-----|-----|----- + A | E | T | R |AUX1|AUX2|AUX3|AUX4|AUX5|AUX6|AUX7|AUX8|AUX9|AUX10|AUX11|AUX12 ### Sub_protocol CABELL_V3 - *0* +4 to 16 channels without telemetry ### Sub_protocol CABELL_V3_TELEMETRY - *1* +4 to 16 channels with telemetry (RSSI, V1, V2). V1 & V2 can be used to return any analog voltage between 0 and 5 volts, so can be used for battery voltage or any other sensor that provides an analog voltage. ### Sub_protocol CABELL_SET_FAIL_SAFE - *6* +Stores failsafe values in the RX. The channel values are set when the sub-protocol is changed to 6, so hold sticks in place as the sub-protocol is changed. ### Sub_protocol CABELL_UNBIND - *7* +The receiver bound to the model is un-bound. This happens immediately when the sub-protocol is set to 7. ## CG023 - *13* Autobind protocol From 937601919843513305041022079fea76240fba7f Mon Sep 17 00:00:00 2001 From: pascallanger Date: Fri, 1 Dec 2017 14:19:19 +0100 Subject: [PATCH 2/2] Update README.md --- README.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 706f367..46e839c 100644 --- a/README.md +++ b/README.md @@ -79,10 +79,9 @@ For example, if you have no interest in binding your Tx to an model with and FrS ## **Choice 3:** Which protocols to upload to the MULTI-Module -Of course there is always a catch. In this case it is the 32KB memory limit on the ATmega328 processor. Due to the amazing work done by devs on this project, the memory required by all the possible protocols exceeds this limit considerably. This means that you will need to make a choice of which protocols you will compile into your firmware. Fortunately, the process of selecting and compiling is not too difficult and it is fully documented on the [Compiling and Programming](docs/Compiling.md) page. -Also, the lead dev Pascal Langer (rcgroups:hpnuts) makes this process even easier for many users by making compiled binaries available for three popular combinations of RF modules. These are always “fresh” (based on the latest stable firmware) and available on the [Releases](https://github.com/pascallanger/DIY-Multiprotocol-TX-Module/releases) page. +In the case of the ATmega328, the memory required by all the possible protocols exceeds the 32KB flash limit considerably. This means that you will need to make a choice of which protocols you will compile into your firmware. Fortunately, the process of selecting and compiling is not too difficult and it is fully documented on the [Compiling and Programming](docs/Compiling.md) page. -An alternatice is to use a STM32 ARM microcontroller based module. If you go the route of building this version of the DIY MULTI-Module then the memory limits do not apply anymore. +An alternative is to use a STM32 ARM microcontroller based module which can hold all the protocols. ## **Choice 4:** Choosing the type of interface between the MULTI-Module and your radio (PPM or Serial)