Fixed addressing as specified in ISO 15765-2 encodes the source and
target address of a device or function inside the CAN ID according to
SAE J1939.
In order to allow to receive incoming requests from different nodes,
the CAN filter mask has to be set such that the source address is
ignored in the receive context. In addition to that, flow control
frames have to be sent back to the actual source of the request, which
requires adjustments to the TX CAN ID.
This commit implements above features and thus allows ISO-TP to be
used in a network based on SAE J1939 or NMEA-2000.
Signed-off-by: Martin Jäger <martin@libre.solar>
Now that device_api attribute is unmodified at runtime, as well as all
the other attributes, it is possible to switch all device driver
instance to be constant.
A coccinelle rule is used for this:
@r_const_dev_1
disable optional_qualifier
@
@@
-struct device *
+const struct device *
@r_const_dev_2
disable optional_qualifier
@
@@
-struct device * const
+const struct device *
Fixes#27399
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
Add program download (firmware update) support according to the CAN in
Automation (CiA) 302-3 draft standard proposal v4.1.0.
The implementation supports a Zephyr specific vendor command allowing
external confirmation of a newly booted firmware image. If this is not
desired, the application can confirm the image by other means.
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
Convert all canbus related API/samples/tests/subsys
to the new timeout API with k_timeout_t.
Signed-off-by: Alexander Wachter <alexander@wachter.cloud>
This commit adds a ISO-TP (ISO15765-2) library.
The library makes use of net buffers and spawns a workqueue thread.
The CAN device that is passed to bind and send can be used concurrently
beside this library.
Signed-off-by: Alexander Wachter <alexander.wachter@student.tugraz.at>
Add support for CANopen LED indicators according to the CAN in
Automation (CiA) 303-3 specification.
This fixes#15278.
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
Add support for storing the CANopen object dictionary to non-volatile
storage.
This fixes#15278.
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>