Taranis menu always use 8 channels as default opposed to 9x and Horus, which use the maximum number as default channel count (which is 6 on dsm2). This commit does not change that logic.
* Fix Multimodule showing up as Crossfire when only multimode and not crossfire is enabled.
* Don't hardcode telemetry to be Frysky on non STM32 arm targets
* Port multi module code to 9X platforms
* Allow Spektrum telemetry protocol to be selected as protocol for the telemetry selection
* Fix infinite loop in spektrum code
* Fix cosmetics
Changes also done for Horus and Taranis UI where appropriate
* Implementation of Spektrum Telemetry for the DYI Multimodule.
I can only test a subset of sensors and these look okay
* Implement conversion from Fahrenheit to Celsius
* Minor fixes for Spektrum telemetry
* Add some more sensors, show sensor ID instead of instance in the overview
* Add cmake configuration for Libfox.
CMake on OS X does not find libfox in the homebrew location otherwise
* Fix findpackage(Fox) for case sensitive systems
The second element of the modulePulsesData was never forced to be correctly aligned. Without the new
pulses and without the Multimodule code the second element was never misaligned since the PXX pulses
union member was always the largest member and was 4 byte aligned by coincidence, also making the
second modulePulseData array member 4 byte aligned.
With the Multimodule option enabled the dsm pulses struct becomes the largest union member with 607 bytes
and the second modulePulsesData is not aligned to anything anymore which completely screws up the pulses
generation.
Forcing the alignment of the ModulePulsesData fixes this issue.
Only tested on my X9D+. It allows me to boot the device into the OpenTX firmware by using 'make flash' (on switch must be on), combined with -DUSB=SERIAL and -DCLI=YES and the reboot command I can test a new firmware on the device without removing/plugging the usb cable
Changing the size of a struct by accident lead to random the wrong data from the eeprom and can screw the eeprom up pretty bad. Better bail out if the eeprom size changes and let the developer make that an intentional choice. The template magic is there to print out the actual and expected size:
/Users/arne/oss/opentx/radio/src/datastructs.h:1045:3: error: static_assert failed "struct size changed"
static_assert(expectedSize == realSize, "struct size changed");
^ ~~~~~~~~~~~~~~~~~~~~~~~~
/Users/arne/oss/opentx/radio/src/datastructs.h:1181:3: note: in instantiation of function template specialization 'check_size<TrainerData, 168, 16>' requested here
CHKSIZE(TrainerData, 168);
Specifying a custom prtocol is useful if OpenTX firmware is older than the multi module firmware
and the protocol in question is not yet in the protocol list of the OpenTX firmware.
Reuse some of the DSM2 routines to avoid code duplication.
This first version only implements the protocol on the Taranis. (and not
Telemetry code is currently untested and will not work (Polarity mismatch). The main protocols to use telemetry are FrSky protocols and not a high priority on the Taranis.
Patch v3: Fix myeeprom.h, include option value in menu.
Patch v4: Fix identing, name substructs of modeldata
the code is a bit more complicated since unions can have structs or simple types. Also change Telemetry sensor to be a struct, since a class with all public is identical to a struct in C++