Skip to main content

rsiot/components/cmp_esp_can/
can_id.rs

1use crate::components_config::can_general::CanId;
2
3impl From<embedded_can::Id> for CanId {
4    fn from(value: embedded_can::Id) -> Self {
5        match value {
6            embedded_can::Id::Standard(v) => CanId::Standard(v.as_raw()),
7            embedded_can::Id::Extended(v) => CanId::Extended(v.as_raw()),
8        }
9    }
10}