Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
9 years, 7 months ago.
Nucleo-F091RC: Compiler error in CAN bus program
Hi,
I am trying to develop CAN application using Nucleo-F091RC. I am getting following compiler error. I have just created an object of CAN class which is available in mbed library.
I have already tried building a CAN program on mbed LPC1768. There it compiled without any problem. I am not able to understand this compiler error. Can you please suggest a solution?
Thanks.
Abhijeet
1 Answer
9 years, 7 months ago.
Download STM32CubeMX and paste the output into your mbed program it should work. I just tried and it compiles ok, but i don't have anything to test using CAN. Try it and post back on how you get on. Try this /media/uploads/dflet/nucleo_ticker_f091rc.zip .
Hi David,
I imported mbed-src library just to locate CAN functions and files. I could see no CAN API file for Nucleo-F091RC, although it is available for other targets like mbed-LPC1768.
So solution was to use your code . I just pasted your code in main.cpp and it worked.
Thanks.
Abhijeet
posted by 03 Apr 2015
This type of error normally means you have chosen / using incorrect pins for the function, in your case CAN. At the moment i can't see what pins should be used.
EDIT: Your pin selection appears to be correct. Maybe CAN has not been implemented yet, or a syntax error i don't see?
posted by David Fletcher 29 Mar 2015