commaai / panda

code powering the comma.ai panda
MIT License
1.54k stars 783 forks source link

can_printer.py only prints few messages #1992

Open dzid26 opened 3 months ago

dzid26 commented 3 months ago

If there is only one node other than panda (C3X), the can_printer.py usually prints only few messages (or none).

Example: 6 messages printed but the timer is rolling:

CAN=2 /data/openpilot/panda/tests/can_printer.py

 33.92
022F( 559)(     6) b'5614000054d3ff3e'

When there is another, third, node on the CAN (acking messages), the printing seems to work. The moment that node is disconnected, the can_printer.py stops printing.

This seems like a CAN silent mode, but even though panda is set to SAFETY_ALLOUTPUT

Additionally, on CAN3 (obd), I usually can't get the printer to roll even with two nodes connected. https://github.com/commaai/panda/pull/1991

adeebshihadeh commented 3 months ago

Is the other node an ECU or another panda/jungle?

dzid26 commented 3 months ago

Only one panda (C3X) on the bus. One node is an MCU configured to continuously send. I have also attached PCAN tool configured to sending. Those two nodes work fine together.

I was triple checking my setup and I tried can_printer one more time. Now it stops reading after few messages even when listening to the conversation between the two other nodes.

123.84
01F1( 497)(     2) b'0200000000000000'   node 1
022F( 559)(     3) b'c217000056d4ff1f'   node 2
dzid26 commented 3 months ago

Ok, I think the issue again related to pandad running in the background.. When I kill pandad, the messages get printed even with a single node.

adeebshihadeh commented 3 months ago

Yeah, always make sure to kill openpilot when running other things on device :)

adeebshihadeh commented 3 months ago

I would like to setup a full HITL test suite for all expected CAN behavior though