GithubHelp home page GithubHelp logo

saeedkaregar / lin Goto Github PK

View Code? Open in Web Editor NEW

This project forked from gandrewstone/lin

0.0 1.0 0.0 15 KB

The LIN protocol implemented over Arduino APIs (Serial and Digital IO)

C++ 66.78% Arduino 28.94% Makefile 4.28%

lin's Introduction

This is a LIN (http://en.wikipedia.org/wiki/Local_Interconnect_Network) protocol
master implementation that supports LIN 1.X or LIN 2.X frame types.  

It is built on top of the "Arduino" Serial and digital IO APIs.  These 
"underface" APIs form a useful abstraction layer for any chip.  So its better to
implement them for your new microcontroller and then get LIN for free using this
library than to implement LIN over a raw register set.

The library supports injection of immediate LIN frames, or a "skew heap" based
schedule table.  The skew heap schedule table differs from what is suggested
by the LIN specification (which defines a linked list of LIN frames and time
intervals between them).  This implementation provides a similar "pile" of 
LIN frames, but instead of being a static list, the skew heap essentially 
dynamically sorts the frames to find the next scheduled frame.  This allows
frames to be easily inserted and removed from the schedule, and frame interval 
periods (the time between 2 issues of the same frame) to be changed
dynamically.  It also means that the frame interval period does not depend on
the total length of the schedule table (as it does for the specced linked list
implementation) which eliminates an unnecessary interaction between otherwise
independent LIN devices.

The library was tested on a Lightuino 5 (Arduino Duemilanove/Uno compatible 
board) using a LIN slave LED of unknown provenance.  So you will have to change
the test code to generate frames for whatever LIN device you have on hand.

lin's People

Contributors

gandrewstone avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.