Compare commits
9 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
37fa95ea8d | ||
|
|
d0fc78260b | ||
|
|
bb785b8a73 | ||
|
|
3b6f0df0f2 | ||
|
|
ae2de54c48 | ||
|
|
67724d3a39 | ||
|
|
febf865737 | ||
|
|
9eb6a00bd8 | ||
|
|
5b52a14bc7 |
3 changed files with 9 additions and 7 deletions
6
.github/workflows/githubci.yml
vendored
6
.github/workflows/githubci.yml
vendored
|
|
@ -7,11 +7,11 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/setup-python@v1
|
||||
- uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: '3.x'
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v3
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
repository: adafruit/ci-arduino
|
||||
path: ci
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
name=CAN Adafruit Fork
|
||||
version=1.0.2
|
||||
version=1.2.1
|
||||
author=Sandeep Mistry <sandeep.mistry@gmail.com>
|
||||
maintainer=adafruit <info@adafruit.com>
|
||||
sentence=An Arduino library for sending and receiving data using CAN bus.
|
||||
|
|
|
|||
|
|
@ -9,8 +9,6 @@
|
|||
#include "CANSAME5x.h"
|
||||
#include "wiring_private.h"
|
||||
|
||||
#include "same51.h"
|
||||
|
||||
#define DEBUG_CAN (0)
|
||||
#if DEBUG_CAN
|
||||
#define DEBUG_PRINT(...) (Serial.print(__VA_ARGS__), ((void)0))
|
||||
|
|
@ -458,6 +456,8 @@ int CANSAME5x::filter(int id, int mask) {
|
|||
state->extended_rx_filter[0].XIDFE_0.bit.EFEC = CAN_XIDFE_0_EFEC_REJECT_Val;
|
||||
state->extended_rx_filter[0].XIDFE_1.bit.EFID2 = 0; // mask
|
||||
state->extended_rx_filter[0].XIDFE_1.bit.EFT = CAN_XIDFE_1_EFT_CLASSIC_Val;
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
int CANSAME5x::filterExtended(long id, long mask) {
|
||||
|
|
@ -467,11 +467,13 @@ int CANSAME5x::filterExtended(long id, long mask) {
|
|||
state->standard_rx_filter[0].SIDFE_0.bit.SFEC = CAN_SIDFE_0_SFEC_REJECT_Val;
|
||||
state->standard_rx_filter[0].SIDFE_0.bit.SFT = CAN_SIDFE_0_SFT_CLASSIC_Val;
|
||||
|
||||
// reject all extended messages
|
||||
// accept matching extended messages
|
||||
state->extended_rx_filter[0].XIDFE_0.bit.EFID1 = id;
|
||||
state->extended_rx_filter[0].XIDFE_0.bit.EFEC = CAN_XIDFE_0_EFEC_STF0M_Val;
|
||||
state->extended_rx_filter[0].XIDFE_1.bit.EFID2 = mask;
|
||||
state->extended_rx_filter[0].XIDFE_1.bit.EFT = CAN_XIDFE_1_EFT_CLASSIC_Val;
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
int CANSAME5x::observe() {
|
||||
|
|
|
|||
Loading…
Reference in a new issue