Page 1 of 1

model H not read j1939 protocol

Posted: Sat Sep 18, 2021 12:06 am
by maicollbellpi
Hi Stanley, please read this,


The model H does not read protocol J1939, because the chip version elm327 v1.5 that you are using is not compatible with it.
I read this code: FrematicsOBD.ccp and I tried to send the following AT commands:

link->sendCommand("ATZ\r", buffer, sizeof(buffer), OBD_TIMEOUT_SHORT);
link->sendCommand("AT SP A\r", buffer, sizeof(buffer), OBD_TIMEOUT_SHORT);
link->sendCommand("AT DP\r", buffer, sizeof(buffer), OBD_TIMEOUT_SHORT);

The response of the chip was the following:

[UART SEND] AT Z
>UART RECV] LM327 v1.5
[UART SEND] AT SP A
>UART RECV] OK
[UART SEND] AT DP
>UART RECV] AUTO, ERROR

Searching in the web, I found that the datasheet of this chip (elm327 v1.5) says: Elm Electronics never made a v1.5,


I appreciate your help in finding a solution to read the J1939 protocol whit this chip (ELM327 v 1.5). Or if you have a device that has a chip that reads the J1939 protocol that we can purchase.

Re: model H not read j1939 protocol

Posted: Mon Sep 20, 2021 8:53 pm
by stanley
Since we don't use any ELM327 chips, we have our way of J1939 traffic monitoring. Use example code j1939_monitor.

Re: model H not read j1939 protocol

Posted: Mon Sep 20, 2021 11:49 pm
by maicollbellpi
HI Stanley,

we already use the example that you say, and it doesn't detect any value. in (FreematicsPlus.cpp), I check up the tag "#define VERBOSE LINK" to see UART traffic, and add line to check protocol setted in (FreematicsOBD.cpp), like that:

if (protocol != PROTO_AUTO) {
sprintf(buffer, "ATSP %X\r", protocol);
if (!link->sendCommand(buffer, buffer, sizeof(buffer), OBD_TIMEOUT_SHORT) || !strstr(buffer, "OK")) {
return false;
}
}
stage = 2;
if (protocol == PROTO_J1939) {
link->sendCommand("AT DP\r", buffer, sizeof(buffer), OBD_TIMEOUT_SHORT); // add line to check protocol setted.
m_state = OBD_CONNECTED;
errors = 0;
return true;
}

the response is:

[UART BEGIN]
[UART SEND]ATI
>UART RECV]OBD2USART V1.5
[UART SEND]ATZ
>NO DATACV]ELM327 v1.5
[UART SEND]ATE0
>UART RECV]OK
[UART SEND]ATH0
>UART RECV]OK
[UART SEND]ATSP B
>UART RECV]OK
[UART SEND]AT DP
>UART RECV]AUTO, ERROR
J1939 data monitor started

I still can't read the J1939 protocol on trucks.

please Help us
screenshot VS code
screenshot VS code
Captura.JPG (179.43 KiB) Viewed 14712 times
....

Re: model H not read j1939 protocol

Posted: Thu Sep 23, 2021 11:37 am
by stanley
I see you have modified the FreematicsOBD.cpp and added some code. Please use the original. Please don't think you are working with ELM327 although it appears to be. Also we have stated on the product page that only broadcast traffic of J1939 can be obtained.

Re: model H not read j1939 protocol

Posted: Tue Jan 10, 2023 3:29 pm
by sharase
Use screen sample code j1939 to monitor traffic subway surfers