Technical discussions related to Analog Devices DSPs (including Blackfin, TigerSHARC, SHARC and ADSP-21xx DSPs).
|
Hello, I'm trying to configure the CAN BUs on the ADSP21992 EZ kit and I have a lot of problems, Does somebody worked on or have a code examples of using the CAN bus on this DSP? Thanks,* Haithem |
|
|
|
Hi Haithem, to configure CAN means to set the CANBCR0 and CANBCR1 for desired speed. CANBCR0 holds BRP, while CANBCR0 holds TSEG1 (PHASESEG1+PROPSEG), TSEG2 (PHASESEG2), SAM and SJW. The formula is: speed = HCLK /((3+TSEG1+TSEG2)(1+BRP)). for this board HCLK is 8MHz (not 80MHz!!!). TSEG1 >= TSEG2 and you have to make BRP as small as possible. All combinations are only candidate, so you have to tried it. From my experience, we cannot reach speed higher than 111.111kHz. If you can get higher speed, please tell me. This combination depends on the cable you used. Either you do it in assembly or c/c++, the way you can configure is the same. Don't forget to change the memory page if you access the peripheral register!! Hany Quoting haythemsalah <>: > Hello, > > I'm trying to configure the CAN BUs on the ADSP21992 EZ kit and I > have a lot of problems, > Does somebody worked on or have a code examples of using the CAN bus > on this DSP? > > Thanks,* > > Haithem |
|
|
|
BTW, for general CAN discussion (not specific to ADI implementations), there's a low-traffic list here: <http://www.vector-informatik.com/canlist/> The list is mirrored to a Yahoo Groups list but the YG list is read-only, so if you want to post you have to subscribe at the Vector Informatik site. |