[Taranis] Issue #554 Radio part done. We have now modes on trims.

Let's say we are configuring the Rudder Trim on phase 1:
- R:0  => Rudder trim = Rudder trim(phase 0)
- R+0  => Rudder trim = Rudder trim(phase 0) + Rudder trim(phase 1)
- R--  => Rudder trim is OFF

Still needs to be done:
- The result on screen is awful. I need ideas. Martin?
- Companion conversions / UI for this feature
- R+1 when configuring Rudder Trim on phase 1 should be impossible
This commit is contained in:
Bertrand Songis
2014-01-27 11:28:10 +01:00
parent 6fd9c47649
commit 046a4d253d
5 changed files with 128 additions and 47 deletions
+10 -1
View File
@@ -1070,8 +1070,17 @@ PACK(typedef struct t_SwashRingData { // Swash Ring data
#if defined(PCBSTD)
#define TRIMS_ARRAY int8_t trim[4]; int8_t trim_ext:8
#define TRIMS_ARRAY_SIZE 5
#define trim_t int16_t
#else
#define TRIMS_ARRAY int16_t trim[4]
#if defined(PCBTARANIS)
PACK(typedef struct {
int16_t value:11;
int16_t mode:5;
}) trim_t;
#else
#define trim_t int16_t
#endif
#define TRIMS_ARRAY trim_t trim[4]
#define TRIMS_ARRAY_SIZE 8
#endif