avr-gcc-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] Anyone interface an AVR with a CAN bus?


From: Reza Naima
Subject: Re: [avr-gcc-list] Anyone interface an AVR with a CAN bus?
Date: Sun, 25 Jul 2004 21:00:22 -0700
User-agent: Mutt/1.5.5.1i

I'm looking at interfacing with the OBD2 CAN inteface that is starting
to appear on cars these days.  However, the document that describes how
they encapsulate OBD2 over CAN is not yet available, although it was
drawn up over 2 years ago.  So I'm not even sure what speed the bus is
going to operate at either -- but I've got a good logic analyzer that
should help determine the clocking speed..

I'm looking at going with the MCP2515 controllre IC, though I'm not sure
how fast of an oscillator it needs.  I found one schematic that shows it
hooked up to a 16mhz resonator.  The data sheet doesn't provide a value
either, just a description of how to hook it up.  I'm going to draw up a
schematic, order the parts, and try to get it work.  Wish me luck ;)

I'm curious, if I want both the MCP2515 and the ATmega16 to operate at
16mhz, any issues with having one of them clock the other one to save on
xtal costs?

Reza

 
>   Reza,
> 
>     It depends on how fast your CAN bus is operating and which exact
>     AVR processor you want to use.
> 
>     Some CAN busses run at 1 megabit-per-second, and trying to sample
>     I/O pins to read and write the bus will be difficult I think.
> 
>     If you choose to wait for the AT90CAN128, then you can just
>     wire the AVR to the interface chip and be done. Although getting
>     a 64-pin QFP package on a PCB will also eb a challenge.
> 
>     I'm not planning on trying to bit-bang CAN anytime soon, so I 
>     think I'll look at a CAN controller like the SJA1000 and
>     then I can use any old AVR to talk to it.
> 
>     What are you planning on using CAN for?
> 
>                              -Alan
> 
> -- 
> - Alan Kilian <alank(at)timelogic.com> 
> Director of Bioinformatics, TimeLogic Corporation 763-449-7622


reply via email to

[Prev in Thread] Current Thread [Next in Thread]