Keywords: can bus, microcontrollers, asynchronous serial, CAN, ds80c400,ds80c390, micro, microcontroller, crystal selection
Related Parts 


Design Considerations for CAN Bus and Asynchronous Serial 
The bit rate is determined by the following equation:
Now, we calculate the reload and actual bit rate:
All useful frequencies will have an error of less than 0.005.
Example of unusable crystal for 1Mbps CAN bit rate:
reload = 36.864E6 / (2*1E6) = 18.432
actual bit rate = 36.864E6 / (2*18) = 1024000
error = (1024000  1000000) / 1000000 = 0.024
Example of acceptable crystal for 1Mbps CAN bit rate:
reload = 36E6 / (2*1E6) = 18
actual bit rate = 36E6 / (2*18) = 1000000
error = (1000000  1000000) / 1000000 = 0.0
(t_{SEG1} + t_{SEG2} + t_{SYNC_SEG}) = 18 / BPR
Remembering that t_{SYNC_SEG} is always 1, and choosing 1 for BPR gives:
(t_{SEG1} + t_{SEG2}) = 17
The designer picks the appropriate TSEG values from this constraint.
The bit rate is determined by the following equations:
All useful frequencies will have an error of less than 0.025.
Example of unusable crystal for 115200 bit/s:
reload = 16E6 / (32 x 115200) = 4.340
actual = 16E6 / (32 x 4) = 125000
error = (125000  115200) / 115200 = 0.0851
Example of acceptable crystal for 115200 bit/s:
reload = 18E6 / (32 x 115200) = 4.883
actual = 18E6 / (32 x 5) = 112500
error = (112500  115200) / 115200 = 0.0234
Timer 1 in Divideby4 Mode
The bit rate is determined by the following equations:
All useful frequencies will have an error of less than 0.025
Example of unusable crystal:
reload = 20E6 / (64 x 115200) = 2.713
actual = 20E6 / (64 x 3) = 104167
error = (104167  115200) / 115200 = 0.096
Example of acceptable crystal:
reload = 22E6 / (64 x 115200) = 2.984
actual = 22E6 / (64 x 3) = 114583
error = (114583  115200) / 115200 = 0.0054
Timer 1 in Divideby12 Mode
All useful frequencies will have an error of less than 0.025
Example of unusable crystal for 115200 bit/s:
reload = 18E6 / (192 x 115200) = 0.814
actual = 18E6 / (192 x 1) = 93750
error = (93750  115200) / 115200 = 0.186
Example of acceptable crystal for 115200 bit/s:
reload = 22E6 / (192 x 115200) = 0.995
actual = 22E6 / (192 x 1) = 114583
error = (114583  115200) / 115200 = 0.0054
Note: These values assume that the designer is not using the system clock multiplier.
CRYSTAL  CAN ERROR (%)  SERIAL ERROR (%) 
18000000  0.00  2.34 
22000000  0.00  0.54 
26000000  0.00  0.76 
30000000  0.00  1.73 
34000000  0.00  2.48 
36000000  0.00  2.34 
40000000  0.00  1.36 
44000000  0.00  0.54 
48000000  0.00  0.16 
52000000  0.00  0.76 
54000000  0.00  2.34 
56000000  0.00  1.27 
60000000  0.00  1.73 
64000000  0.00  2.12 
66000000  0.00  0.54 
68000000  0.00  2.48 
72000000  0.00  2.34 
Related Parts  
DS80C390  Dual CAN HighSpeed Microprocessor  Samples 
DS80C400  Network Microcontroller  
DS80C410  Network Microcontrollers with Ethernet and CAN  
DS80C411  Network Microcontrollers with Ethernet and CAN 
Next Steps  
EEMail  Subscribe to EEMail and receive automatic notice of new documents in your areas of interest. 
Download  Download, PDF Format (225kB) 
© Jan 05, 2004, Maxim Integrated Products, Inc. 
APP 2935: Jan 05, 2004
APPLICATION NOTE 2935, AN2935, AN 2935, APP2935, Appnote2935, Appnote 2935 