Lines Matching refs:can
9 This test suite uses `python-can`_ for testing Controller Area Network (CAN) communication between a
17 * The python-can library installed on the host PC.
20 The Zephyr end of the CAN fixture can be configured as follows:
24 :kconfig:option:`CONFIG_CAN_DEFAULT_BITRATE_DATA`, but can be overridden on a board level using
29 The host end of the CAN fixture can be configured through python-can. Available configuration
30 options depend on the type of host CAN adapter used. The python-can library provides a lot of
31 flexibility for configuration as decribed in the `python-can configuration`_ page, all centered
32 around the concept of a configuration "context. The configuration context for this test suite can be
35 * By default, the python-can configuration context is not specified, causing python-can to use the
37 * A specific configuration context can be provided along with the ``can`` fixture separated by a
38 ``:`` (i.e. specify fixture ``can:zcan0`` to use the ``zcan0`` python-can configuration context).
39 * The configuration context can be overridden using the ``--can-context`` test suite argument
40 (i.e. run ``twister`` with the ``--pytest-args=--can-context=zcan0`` argument to use the ``zcan0``
41 python-can configuration context).
60 Next, python-can needs to be configured for the ``zcan0`` interface. One option is to use a
70 Once the virtual SocketCAN interface has been created, brought up, and configured the test suite can
75 west twister -v -p native_sim/native/64 -X can:zcan0 -T tests/drivers/can/host/
77 After the test suite has completed, the virtual SocketCAN interface can be removed again:
87 adapter must be supported by python-can. The examples below assumes using a Linux SocketCAN
88 interface named ``can0``. For other platforms/adapters, please see the `python-can`_ documentation.
98 sudo ip link set can0 type can restart-ms 1000 bitrate 125000 dbitrate 1000000 fd on
101 Next, python-can needs to be configured for the ``can0`` interface. One option is to use a dedicated
112 Once the SocketCAN interface has been brought up and configured the test suite can be launched using
117 …55s36/lpc55s36 --device-testing --device-serial /dev/ttyACM0 -X can:can0 -T tests/drivers/can/host/
119 After the test suite has completed, the SocketCAN interface can be brought down again:
125 .. _python-can:
126 https://python-can.readthedocs.io
128 .. _python-can configuration:
129 https://python-can.readthedocs.io/en/stable/configuration.html
132 https://www.kernel.org/doc/html/latest/networking/can.html