fix somes values

This commit is contained in:
2023-09-05 17:43:12 +02:00
parent e0b94c5250
commit 8cec88d658
5 changed files with 20 additions and 14 deletions

View File

@@ -97,7 +97,7 @@ void CM_processIncome(uint8_t idSender, uint8_t idMsg, bool rtr, uint32_t data){
// TODO set alive times
// start alives
CM_DISPLAY_SETUP(NULL);
CM_STEERING_SETUP(&ALWAYSFALSE);
CM_STEERING_SETUP(&ALWAYS0);
}
@@ -161,6 +161,7 @@ void CM_processIncome(uint8_t idSender, uint8_t idMsg, bool rtr, uint32_t data){
// posX posY button -
calcTorque(incomeData.separate.byte1);
calcPosition(incomeData.separate.byte0);
STEERING_emitPollDir(steering());
}
@@ -225,6 +226,7 @@ void CM_processIncome(uint8_t idSender, uint8_t idMsg, bool rtr, uint32_t data){
if(idMsg == 0x1) { // STEERING_GET_CENTER
// valHH valH valL valLL
eKart.center = revertData.full;
ALIVE_emitReady(&steering()->myChecker, 0, 0);
}
if(idMsg == 0x2) { // STEERING_GET_POSITION
@@ -232,11 +234,6 @@ void CM_processIncome(uint8_t idSender, uint8_t idMsg, bool rtr, uint32_t data){
}
if(idMsg == 0x3) { // STEERING_READY
// - - - -
}
if(idMsg == 0xF) { // STEERING_ALIVE
// statusH statusL - -
ALIVE_ISALIVE(&steering()->myChecker);
@@ -340,7 +337,7 @@ void CM_STEERING_SETUP(void* p) {
// reset/init homing setCenter aliveTime
// TODO not working have to fix it
BYTES_4 tmpData;
uint8_t choice = (uint8_t) p;
uint8_t choice = *(uint8_t*) p;
switch (choice) {
case 1:
tmpData.separate.byte0 = 1;