mirror of https://github.com/rusefi/rusefi-1.git
Merge branch 'master' of https://github.com/rusefi/rusefi into second_can
This commit is contained in:
commit
fb197d40da
|
@ -14,15 +14,44 @@ static char *buffer[2048];
|
|||
|
||||
|
||||
void handleTsR(char *input) {
|
||||
if (input[1] == 0 && input[2] == 7) {
|
||||
const uint16_t* data16 = reinterpret_cast<uint16_t*>(input);
|
||||
|
||||
if (input[0] == 0 && input[1] == 1) {
|
||||
scheduleMsg(&sharedLogger, "TS_SD: RTC read command");
|
||||
memset(buffer, 0, 9);
|
||||
}
|
||||
|
||||
} else if (input[0] == 0 && input[1] == 0x11) {
|
||||
int length = data16[2];
|
||||
scheduleMsg(&sharedLogger, "TS_SD: fetch buffer command, length=%d", length);
|
||||
|
||||
|
||||
if (length == 16) {
|
||||
|
||||
} else {
|
||||
// SD read directory command
|
||||
|
||||
}
|
||||
|
||||
|
||||
} else if (input[0] == 0 && input[1] == 0x14) {
|
||||
scheduleMsg(&sharedLogger, "TS_SD: fetch data command blockNumber=");
|
||||
|
||||
} else {
|
||||
scheduleMsg(&sharedLogger, "TS_SD: unexpected r");
|
||||
}
|
||||
}
|
||||
|
||||
void handleTsW(char *input) {
|
||||
const uint16_t* data16 = reinterpret_cast<uint16_t*>(input);
|
||||
|
||||
if (input[0] == 0 && input[1] == 0x11) {
|
||||
int code = data16[2];
|
||||
scheduleMsg(&sharedLogger, "TS_SD: w, code=%d", code);
|
||||
|
||||
|
||||
} else {
|
||||
scheduleMsg(&sharedLogger, "TS_SD: unexpected w");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue