dinomycle 1 Posted January 21, 2016 Share Posted January 21, 2016 Hello All, Is there any sample program for using the CAN with Stellaris/Tiva-C with energia IDE ? I could see D:\energia-0101E0017\hardware\lm4f\cores\lm4f\driverlib can.c and can.h files. How to include this .h files and have a program which transmit some data Thanks for your support Dino Quote Link to post Share on other sites
spirilis 1,265 Posted January 21, 2016 Share Posted January 21, 2016 Those provide the TivaWare Peripheral Driver Library functions for CAN. Look at the Tiva's PDL user guide for details on that API. You should also be able to access the ROM_ versions of those which live on the chip's burned ROM. No Energia examples around that I've seen. Quote Link to post Share on other sites
energia 485 Posted January 21, 2016 Share Posted January 21, 2016 Attached are a couple of example Sketches that one of the community members put together with my guidance a while back. I have not tested these but they seemed to work for that person. I think these are loopback examples. Should be easy to change them to talk to a CAN tranceiver like the http://www.ti.com/product/sn65hvd251. Robert CANExamples.zip spirilis, bluehash and dinomycle 3 Quote Link to post Share on other sites
dinomycle 1 Posted February 1, 2016 Author Share Posted February 1, 2016 thanks a lot of the sample code, it worked for me with changes i did for my project with MCP2551 CAN tranceiver energia 1 Quote Link to post Share on other sites
energia 485 Posted February 5, 2016 Share Posted February 5, 2016 @@dinomycle thanks for reporting back! Happy to hear that it worked. I'll work on wrapping this into a library. Robert Fmilburn 1 Quote Link to post Share on other sites
energia 485 Posted February 5, 2016 Share Posted February 5, 2016 @@dinomycle can you share the change you had to make? Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.