CANopenNode / CANopenPIC

CANopenNode on PIC microcontrollers.
Apache License 2.0
60 stars 33 forks source link

Canopenpic #12

Closed marioles50 closed 4 months ago

marioles50 commented 4 months ago

after cloning with the command as indicated

git clone https://github.com/CANopenNode/CANopenPIC.git cd CANopenPIC git submodule init git submodule update

After I compile in Mplabx 5

I opened two projects: example_PIC32 example_Dsìic33_ex16_IO

The first one compiles without errors

the second (which I would like to use) gives errors:

main_dsPIC33F.c:94:5: error: 'OD_CANNodeID' undeclared (first use in this function) main_dsPIC33F.c:94:5: note: each undeclared identifier is reported only once for each function it appears in main_dsPIC33F.c:95:5: error: 'OD_CANBitRate' undeclared (first use in this function) etc. etc more errors actually the definitions for OD_xxxx are missing

CANopenNode commented 4 months ago

Yes, dsPIC is on todo list for a very long time. It broke vith new version of canopennode, new object dictionary. There is a solution in pull request, i think. Please check this, othervise i will try to fix it.

marioles50 commented 4 months ago

I have already seen the pull request For me it is quite complex to update as per pull request If one day you will try to fix it I will be very grateful Thanks in advance

CANopenNode commented 4 months ago

Ok, I will try in next days.

CANopenNode commented 4 months ago

It is updated. You have to update the project (git)

16-bit dsPIC33 has quite rich CANopen configuration and consumes about 10% memory.

I tested on Expolrer16 board. There was a bootup messge. Then I configured Heartbeat message via SDO and all worked as expected. Didn't do further tests, but it seems it works.