Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why does CPU% increase significantly once the CAN bus is physically disconnected? #13

Open
rpereira-FS opened this issue Jan 24, 2023 · 1 comment

Comments

@rpereira-FS
Copy link

Hello!

I implemented the CANopen project, canopend, into my controller and am able to use it just fine with I/O modules through the CAN bus. When I physically disconnect the CAN bus from my controller, however, I notice the CPU% of the canopend command in linux shoots up to 5-6x from what is was before.

When the CAN bus is disconnected, I see these log messages from the canopend:
(CO_CANsend) Transmitting CAN msg OID 0x202 failed(can0)
...and it persists until I reconnect the CANbus back into the controller. I found

My best guess for the CPU% increase at this moment is that canopend sees that there is no CAN bus and it is stuck on a cycle where it keeps retrying often, and maybe that's whats taking up the extra CPU? Is there any setting in the stack that I can set in order to mitigate this?

Any insight/direction on this would be much appreciated, thank you!

@CANopenNode
Copy link
Owner

You are right. Actually there is missing detection of disconnected CAN bus or disconnected adapter. Not yet implemented.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants