forked from adafruit/circuitpython
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMatch.c
More file actions
24 lines (21 loc) · 739 Bytes
/
Match.c
File metadata and controls
24 lines (21 loc) · 739 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// This file is part of the CircuitPython project: https://circuitpython.org
//
// SPDX-FileCopyrightText: Copyright (c) 2020 Jeff Epler for Adafruit Industries
//
// SPDX-License-Identifier: MIT
#include "shared-module/canio/Match.h"
#include "shared-bindings/canio/Match.h"
void common_hal_canio_match_construct(canio_match_obj_t *self, int id, int mask, bool extended) {
self->id = id;
self->mask = mask;
self->extended = extended;
}
int common_hal_canio_match_get_id(const canio_match_obj_t *self) {
return self->id;
}
int common_hal_canio_match_get_mask(const canio_match_obj_t *self) {
return self->mask;
}
bool common_hal_canio_match_get_extended(const canio_match_obj_t *self) {
return self->extended;
}