arduino_tss463_van icon indicating copy to clipboard operation
arduino_tss463_van copied to clipboard

simulate CDC on autoradio Peugeot RD1 Clarion PU-2294

Open bagou9 opened this issue 10 months ago • 4 comments

Hi @morcibacsi

Today i continue tests with your library TSS463 and Arduino for simulate CDC (as the Yatour box). And with ESP32 + library esp32_rmt_van_rx, i dump the frame that Arduino send.

I tested multiple sending combinations, but i'm not obtain the good frame.

for reminder: Dump with yatour:

#yatour connected
15:57:25.996 -> FE 8C 4C 96 D8 48
15:57:25.996 -> 0E 4E CE 80 00 41 16 00 00 89 06 01 00 00 80 B4 7E
15:57:26.183 -> 0E 8C 4C 96 D8 48
15:57:26.183 -> 0E 4E CE 81 00 41 16 00 00 89 06 01 00 00 81 37 3E
15:57:26.492 -> 0E 8C 4C 96 D8 48
15:57:26.524 -> 0E 4E CE 82 00 41 16 00 00 89 06 01 00 00 82 AD C4
15:57:27.024 -> 0E 8C 4C 96 D8 48
15:57:27.066 -> 0E 4E CE 83 00 41 16 00 00 89 06 01 00 00 83 2E 84
15:57:27.472 -> 0E 8C 4C 96 D8 48
15:57:27.472 -> 0E 4E CE 84 00 41 16 00 00 89 06 01 00 00 84 87 0A
15:57:28.024 -> 0E 8C 4C 96 D8 48
15:57:28.024 -> 0E 4E CE 85 00 41 16 00 00 89 06 01 00 00 85 04 4A
#switch src CDC
15:57:58.104 -> 0E 8E CC 11 83 0E 84
15:57:58.104 -> 0E 8C 4C 96 D8 48
15:57:58.150 -> 0E 4E CE 80 00 D3 16 00 00 89 06 01 00 00 80 D6 88
15:57:59.641 -> 0E 8C 4C 96 D8 48
15:57:59.641 -> 0E 4E CE 81 00 C3 16 00 00 01 01 10 00 03 81 58 A6
15:58:00.529 -> 0E 8C 4C 96 D8 48
15:58:00.571 -> 0E 4E CE 82 00 C3 16 00 01 01 01 10 00 03 82 C5 50
#switch src radio
15:58:03.319 -> 0E 8E CC 11 81 30 F0
15:58:03.319 -> 0E 8C 4C 96 D8 48
15:58:03.319 -> 0E 4E CE 86 00 C1 16 00 04 01 01 10 00 03 86 30 80

Now, the instruction send by my sketch Arduino, and the dump see with esp32:

uint8_t packet[12] = { headerByteCDC, 0x00, status, cartridge, DecToBcd(minutes), DecToBcd(seconds), trackNo, cdNo, trackCount, 0x00, b10, headerByteCDC };
VANInterface->set_channel_for_immediate_reply_message(8, 0x4EC, packet, 12);

17:24:59.954 -> 0E 4E CF 97 68 if I read corectly doc VAN: flag = F corresponds to: EXT=1,RW=1, ACK=1, RTR=1 but in your library, function set_channel_for_immediate_reply_message, I see this: id2Command.data.RNW = 1; id2Command.data.RTR = 0; id2Command.data.EXT = 1; id2Command.data.RAK = 0; There is a bug ? Or it's me who does not understand well... Another strange thing: data sent is 12 bytes, but dump no see data (if i send data with: set_channel_for_transmit_message(3, 0x4EC, packet, 12, 1), dump see data correctly, but flag = C) VANInterface->set_channel_for_transmit_message(3, 0x4EC, packet, 12, 1); 17:43:49.333 -> 0E 4E CC 81 00 41 16 00 00 17 02 21 00 00 81 57 68

the dump with yatour, frame 4EC have flag = E, EXT=1,RW=1, ACK=1, RTR=0 How can I get the right flag? Or is not possible to implement this with actual library ?

Thank you for your help

bagou9 avatar Jan 12 '25 16:01 bagou9