mirror of
https://github.com/bleackstorm/SteamFrame-FPV-Control-Center.git
synced 2026-12-03 07:31:57 +01:00
fix(g29): corriger le verrouillage de plage angulaire et le recentrage FFB
- Suppression de la commande 0x14 (default autocenter) qui écrasait la butée 180° - Déclaration volatile pour les variables d'état partagées inter-cœurs - Ajout de find_g29() dynamique dans isolate_led.py et test_matrix.py - Ajout du script de diagnostic FFB et butée test_spring.py
This commit is contained in:
1 parent
c28d89c088
commit
70a03ed3c0
4 files changed
+129
-9
No files matched your search
+4
-7
@@ -106,9 +106,9 @@ volatile bool logRejetRequis = false;
|
||||
volatile uint16_t rejet_vid = 0;
|
||||
volatile uint16_t rejet_pid = 0;
|
||||
|
||||
uint8_t dernierMasqueLedG29 = 0xFF;
|
||||
uint8_t etapeEnvoiLed = 0;
|
||||
uint8_t etapeInitMoteur = 0;
|
||||
volatile uint8_t dernierMasqueLedG29 = 0xFF;
|
||||
volatile uint8_t etapeEnvoiLed = 0;
|
||||
volatile uint8_t etapeInitMoteur = 0;
|
||||
|
||||
char serialBuffer[32];
|
||||
uint8_t serialBufferIdx = 0;
|
||||
@@ -394,13 +394,10 @@ void gererInitMoteurG29() {
|
||||
uint16_t angle = (uint16_t)ANGLE_SOUHAITE_TOTAL;
|
||||
const uint8_t cmdRange[7] = {0xF8, 0x81, (uint8_t)(angle & 0xFF), (uint8_t)(angle >> 8), 0x00, 0x00, 0x00};
|
||||
const uint8_t cmdSpring[7] = {0xFE, 0x0D, (uint8_t)(PENTE_RESSORT_G29 & 0x07), (uint8_t)(PENTE_RESSORT_G29 & 0x07), (uint8_t)FORCE_RESSORT_G29, 0x00, 0x00};
|
||||
const uint8_t cmdEnable[7] = {0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
|
||||
|
||||
switch (etapeInitMoteur) {
|
||||
case 0: if (envoyerTrameG29_0x30(cmdRange)) etapeInitMoteur++; break;
|
||||
case 1: if (envoyerTrameG29_0x30(cmdSpring)) etapeInitMoteur++; break;
|
||||
case 2: if (envoyerTrameG29_0x30(cmdEnable)) etapeInitMoteur++; break;
|
||||
case 3: etapeInitMoteur = 6; break;
|
||||
case 1: if (envoyerTrameG29_0x30(cmdSpring)) etapeInitMoteur = 6; break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user