1
0
mirror of https://github.com/esphome/esphome.git synced 2025-03-23 11:08:16 +00:00

mcp2515: Add missing CFG1 assignment to be able to use 50kbps with a 16MHz crystal. (#8375)

This commit is contained in:
djasper-ha 2025-03-11 12:31:01 +01:00 committed by GitHub
parent 42e432754e
commit 4aa7ad1e33
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -550,6 +550,7 @@ canbus::Error MCP2515::set_bitrate_(canbus::CanSpeed can_speed, CanClock can_clo
cfg3 = MCP_16MHZ_40KBPS_CFG3;
break;
case (canbus::CAN_50KBPS): // 50Kbps
cfg1 = MCP_16MHZ_50KBPS_CFG1;
cfg2 = MCP_16MHZ_50KBPS_CFG2;
cfg3 = MCP_16MHZ_50KBPS_CFG3;
break;