LIN-bus transceivers

Status
Not open for further replies.

Oznog

Active Member
I was looking at maybe setting up a LIN bus between a few PIC controllers located some distance apart. Otherwise I was thinking CAN bus, but the 1-wire aspect of LIN looks interesting. CAN tranceivers are also somewhat expensive and only come on the more advanced/expensive PICs.

However I tried to look through Digikey and Mouser and found only a couple of LIN transceivers. Did I mess up the search term (LIN,LINbus,LIN-bus?) or are there just really slim pickins for this type of tranceiver? Or is there some general purpose part/schematic to make your own LIN tranceiver, making special purpose LIN tranceivers unnecessary?
 
LIN hardware layer is really just a 12v level shifter which can be replicated with a couple transistor and some diodes. (I saw a simple schematic somewhere, but I can't find it now)

Anyways, I've been using the MCP201 and it works well enough. Reseting it is a bit annoying.
 
Can you just use 5v for the physical layer instead?
How tough is it to implement LIN bus with a PIC USART (18F2520 in mind) which doesn't have specific LIN bus support?
 
LIN is pretty easy to implement. How easy depends on how close you want to keep to the software and hardware standards. If you want to be able to talk to other LIN devices, you have to support the 12v data line, and the software protocol with collision detection properly. If you really don't care, you can implement it all simpler.

In my own project I have no need of implementing LIN software layer perfectly, so it's a slimmed down version.

Even implementing the software layer perfectly is not difficult if you've used a bit banged serial interface before. You can adapt a premade bit banged serial interface without too much trouble. I doubt you could implement true LIN on a hardware USART layer as you need to send some datastreams that don't conform to serial data.

You can use any voltage you want, if you don't care about the standard. Remember that this is meant for use on automobiles and is designed around. 12v-13.5v is the cars electrical system. The hardware layer is meant to decouple the microcontroller from the data line in case of shorts or surges. Otherwise you could just tie RX/TX together and run them to all the targets and use a 9bit or other addressing uart scheme with some type of collision detection.

I don't know where al my LIN info is, but I know the Microchip datasheet was excellent, and I think they have a very good appnote describing the protocol.
 
I have a datasheet for a Motorola MC33399 LIN Interface Chip. Freescale Semiconductor has it now, and they say the budgetary price is $0.53. Sounds pretty cheap to me.

Microchip application notes are:

AN-237
AN-239
AN-240
AN-729
 
I like LIN. It does work very well.

But, If you are interested in CAN.... you could always do SWC (single wire can tranceivers).

Saves having to find a 12V supply.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…