Baudrate and BTR0/BTR1

baudratebit ratecan

I am creating an application that uses standard function that sets bitrate. The parameters required are BTR0 and BTR1. But the user of my application will enter the standard value of the Baudrate (eg. : Bitrate = 125000). How can i calculate BTR0 and BTR1 from the given value?

Best Answer

The CanCase parameters are compatible to the SJA1000. Chapter 6.5 of its datasheet should answer your question.