Skip to content

Commit 78bdf3d

Browse files
committed
Fix CAN FD bitrate switching
Set the BRS bit for pythoncan transports when the interface operates in CAN FD mode. Fixes #368
1 parent d5eb647 commit 78bdf3d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

pycyphal/transport/can/media/pythoncan/_pythoncan.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,6 +300,7 @@ async def send(self, frames: typing.Iterable[Envelope], monotonic_deadline: floa
300300
is_extended_id=(f.frame.format == FrameFormat.EXTENDED),
301301
data=f.frame.data,
302302
is_fd=self._is_fd,
303+
bitrate_switch=self._is_fd,
303304
)
304305
try:
305306
desired_timeout = monotonic_deadline - loop.time()

0 commit comments

Comments
 (0)