CAN bus UDS throws multiple errors

I have been trying to get a basic UDS server with a Seeed CAN Bus Shield and Mega 2560.

I am trying to use code sample from here : GitHub - altelch/uds: ISO 14229-1 UDS protocol implementation for Arduino

When I try to compile the output field is filled with error messages like "MCP_ANY " not defined. I have the libraries exactly as suggested in the page there.

Anyone have luck with this setup ?

Much more information is needed in order to help

Start by posting your full sketch, using code tags when you do, and the full error message, copied from the IDE, again using code tags

Which Arduino board are you using ?

1 Like

Post your annotated schematic showing exactly how you have wired it. Show all connections, power, ground and power sources. Show any external components as well.

MCP_ANY is defined here:

Maybe you installed the version from Longan-Labs and not the extended version from coryjfowler.

1 Like

Thanks . The problem was the Longan Labs version ... and unless you pointed out there was no way to know that. Or I missed it somewhere. Now that it compiled OK , I can get on with the project instead of searching for the elusive MCP_ANY :sweat_smile:

@UKHeliBob ... Apologies !! Normally I try to give as much info as possible but in this case I really did not know which was the offending CAN library ( I had a few ) and the Error screen ....well I was swamped by the amount of errors it threw up !! So tried to get help by referring to the library . Thanks . It compiles fine now. ( Its a Seed CAN shield on a Mega 2560 )

Now that I have been able to cross the first stage and check out send / receive CAN frames , was just wondering if anyone has had success with the standard UDS implementation ? I have a controller that listens on 0x1BDA08F1 and sends response back on 0x1BDAF108. With queries resulting in Single frame responses, there should be no issue. But the problem as expected is with queries that result in Multi Frame queries. For now I am restricting myself to SIDs 0x10 and 0x22 !

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.