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

feature-request: sleepmode and changing filters #6

Open
thezenox opened this issue Feb 7, 2019 · 3 comments
Open

feature-request: sleepmode and changing filters #6

thezenox opened this issue Feb 7, 2019 · 3 comments

Comments

@thezenox
Copy link

thezenox commented Feb 7, 2019

nice lib, but I am missing sleep mode and changing filters on the fly. Do you plan to add it?

Bits 5-7 of CANCTRL_REGISTER
000 = Set Normal Operation mode
001 = Set Sleep mode
010 = Set Loopback mode
011 = Set Listen-only mode
100 = Set Configuration mode

Would be nice with bit modifing and readback.
Before setting filters, enter configuration mode and change back to normal mode afterwards.

@qwec01
Copy link

qwec01 commented Feb 11, 2019

HI thezenox
To change filters, just change the filters[x].mMask, rxm0, rxm1, and recall "begin", this is what I did.
rxm0 = standard2515Mask(***);
rxm1 = standard2515Mask(***);
filters[x].mMask = standard2515Filter (***);
...
errorCode = PRI.begin (settings, [] { PRI.isr (); }, rxm0, rxm1, filters, 6);

@pierremolinaro
Copy link
Owner

pierremolinaro commented Feb 11, 2019 via email

@ravelab
Copy link

ravelab commented Aug 10, 2019

I would love to have those functions. @thezenox ?

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

4 participants