Go to advanced search

by gja
Tue Jul 10, 2012 7:50 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

Hello, MCP2515 has only two receive buffer. If only INT pin is used you need to read read which buffer received message (one SPI transmission). One possibility is to use pins RX0BF and RX1BF which can be directly use as receive interrupts and indication which receive buffer is needed to be read. Wi...
by gja
Fri Jul 06, 2012 8:30 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

From the link in the post above it seems that we need to be adding a filled in copy of the struct in https://github.com/raspberrypi/linux/blob/rpi-patches/include/linux/can/platform/mcp251x.h in the platform/board definition file. Apparently this Raspberry Pi uses a BCM2835 SoC. However this SoC bel...
by gja
Fri Jul 06, 2012 7:39 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

by gja
Tue Jul 03, 2012 8:39 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

Next action: I'm now replacing my vanilla RPI kernel sources with the kernel of Chris Boot to have the SPI driver in. http://elinux.org/RPi_Kernel_Compilation#Ubuntu_Linux In these instructions, simply replace the git command with git clone https://github.com/bootc/linux.git So SPI is in, MCP2515 dr...
by gja
Tue Jul 03, 2012 8:00 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

For the driver approach I'm definitely going for socketcan. We have been using this at work for a few years with a 2.6 kernel. That sw came prepackaged, so unfortunately I don't know the config details. The MCP kernel driver is able to use one interrupt line from the MCP2515. https://www.ridgerun.co...
by gja
Sat Jun 30, 2012 7:36 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

Maybe it can be easier on 3v3, but since I'm using a pre-made SPI-CAN board I have done the conversion anyway. For the kernel build the voltage level doesn't matter. For my first attempt I used these instructions: http://elinux.org/RPi_Kernel_Compilation#Ubuntu_Linux and tried to do the menuconfig b...
by gja
Sat Jun 23, 2012 6:48 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

https://www.ridgerun.com/developer/wiki/index.php/How_to_configure_and_use_CAN_bus#MC2515 About half-way down in the post I just noticed that a GPIO needs to be available to receive interrupts from the mcp2515. Seems like the conversion board will be fully used then: MISO : Raspberry Pi 3v3 Tx in - ...
by gja
Sat Jun 23, 2012 6:29 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

Ok, So a colleague pointed me to this level conversion board: http://www.sparkfun.com/products/8745 So i have one wired up: MISO : Raspberry Pi 3v3 Tx in - 5V Tx out to SPI-CAN Board MOSI: 3v3 Rx out - 5V Rx in SCLK: 3v3 Tx in - 5V Tx out For the chip select: that would need an extra Tx, so an extra...
by gja
Sat Jun 23, 2012 6:14 pm
Forum: Other projects
Topic: CAN Interface
Replies: 103
Views: 101684

Re: CAN Interface

There is another thread where I referred to this.
Please check there.
http://www.raspberrypi.org/phpBB3/viewt ... bus#p90788
by gja
Sun Jun 03, 2012 4:11 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

That applies to the bus controller, but there is also a transceiver there (PCA82C251), and that seems, unfortunately, to be a 5V only device. Should still be usable with Raspi, but will need to be powered from the 5V rail, and level conversion
Indeed.
I'll do it with conversion then.
by gja
Sat Jun 02, 2012 9:35 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

I just ordered the AVR CAN-SPI adapter.
Looking forward to try and get it to work.
by gja
Sat Jun 02, 2012 3:31 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: CAN controller
Replies: 813
Views: 336117

Re: CAN controller

See older thread on CANbus here: http://www.raspberrypi.org/phpBB3/viewtopic.php?f=41&t=2298&hilit=canbus Zorce, If you find a decent MCP2515 board available, please post here. I have been looking around and found one for AVR: http://www.avrcard.com/products/can_adapter.htm But I still need to read ...
by gja
Sun Apr 15, 2012 11:52 am
Forum: Other projects
Topic: Car Management/Information Capture/Replay Mashup
Replies: 3
Views: 2819

Re: Car Management/Information Capture/Replay Mashup

Please check the CANbus topic. This covers several of your suggestions.
by gja
Sun Apr 15, 2012 11:35 am
Forum: Other projects
Topic: CAN Interface
Replies: 103
Views: 101684

Re: CAN Interface

<r>mpsteffen said: <br/> <br/> Is there a SPI Driver yet ?<br/> <br/> From what I read, eather SocketCan or CAN4Linux both support the mcp2515, but<br/> <br/> as far as I know, there is no SPI Driver support for the RPi yet.<br/> <br/> ( definately none which works with the CAN4Linux driver<br/> <br...
by gja
Sat Mar 17, 2012 12:10 pm
Forum: Other projects
Topic: CAN Interface
Replies: 103
Views: 101684

Re: CAN Interface

hzrnbgy said:


If you have GPS, you already have extremely accurate timing source



IF you have a GPS connection, that is. 

If not, (at boot time, in tunnels, in the garage) you need to work around it.
by gja
Fri Mar 16, 2012 11:20 am
Forum: Other projects
Topic: CAN Interface
Replies: 103
Views: 101684

Re: CAN Interface

<t>An attempt to make a requirements list. Please shoot at it.<br/> <br/> Raspberry CAN add-on board specs:<br/> <br/> Need to have<br/> mechanical:<br/> - plug on gpio header, stay within pcb boundaries of Raspberry<br/> - CAN connection on edge of PCB<br/> <br/> electrical:<br/> - mcp2515  SPI-CAN...
by gja
Wed Mar 07, 2012 4:07 pm
Forum: Other projects
Topic: CAN Interface
Replies: 103
Views: 101684

Re: CAN Interface

<r>Another schematic can be found here:<br/> <br/> <URL url="http://www.sparkfun.com/datash.....ld-v12.pdf">http://www.sparkfun.com/datash.....ld-v12.pdf</URL><br/> <br/> <URL url="http://www.sparkfun.com/products/10039">http://www.sparkfun.com/products/10039</URL><br/> <br/> An Arduino CANbus shiel...
by gja
Wed Mar 07, 2012 8:23 am
Forum: Other projects
Topic: CAN Interface
Replies: 103
Views: 101684

Re: CAN Interface

<r>Schematic on p26 from MCP2515 application AN212 from Microchip:<br/> <URL url="http://ww1.microchip.com/downl.....00212c.pdf">http://ww1.microchip.com/downl.....00212c.pdf</URL><br/> <br/> It handles the part from CANbus to SPI interface.<br/> Check earlier posts on level conversion between Raspb...
by gja
Mon Mar 05, 2012 7:42 pm
Forum: Other projects
Topic: CAN Interface
Replies: 103
Views: 101684

Re: CAN Interface

<r>In case anyone has an ELM327 OBD-USB interface and a Linux PC at hand: here's a link to some pointers on how to install a scantool utility. (also CAN-Bluetooth info inside)<br/> <br/> <URL url="http://ubuntuforums.org/archiv.....01550.html">http://ubuntuforums.org/archiv.....01550.html</URL><br/>...
by gja
Mon Mar 05, 2012 7:06 am
Forum: Other projects
Topic: CAN Interface
Replies: 103
Views: 101684

Re: CAN Interface

<t>I agree that having full access to a CANbus interface can present some security issues. You don't want to start sending your own CAN messages in a vehicle if you're not exactly sure what you're doing.<br/> <br/> However, the MCP2515 does have a listen-only mode. So you could hook it up to a car f...
by gja
Sun Mar 04, 2012 9:17 pm
Forum: Other projects
Topic: CAN Interface
Replies: 103
Views: 101684

Re: CAN Interface

<r>The cheap "USB-CAN converters" are mostly ELM327 based.<br/> <br/> IIRC the ELM 327 CAN interface are not full CAN. They are OBD diagnostics interfaces. The ELM 327 is based on a microcontroller that filters data from the vehicle CANbus.<br/> So for monitoring a car, they can do the basics.<br/> ...
by gja
Sat Mar 03, 2012 9:33 pm
Forum: Other projects
Topic: CAN Interface
Replies: 103
Views: 101684

Re: CAN Interface

<r>There is already a CANbus implementation for Linux.<br/> It's called SocketCAN.<br/> <URL url="http://en.wikipedia.org/wiki/SocketCAN">http://en.wikipedia.org/wiki/SocketCAN</URL><br/> <br/> It turns the CAN interface into a network device.<br/> It supports the MCP2515 over SPI.<br/> <br/> I beli...

Go to advanced search