pub struct UdsClient { /* private fields */ }
Expand description
Main struct providing all API calls.
Implementations§
Source§impl UdsClient
impl UdsClient
pub async fn clear_diagnostic_information( &self, group_of_dtc: u32, ) -> EcuResponseResult
Source§impl UdsClient
impl UdsClient
pub async fn ecu_reset(&self, reset_type: ResetType) -> EcuResponseResult
Source§impl UdsClient
impl UdsClient
pub async fn read_data_by_identifier( &self, data_identifiers: &[u16], ) -> EcuResponseResult
Source§impl UdsClient
impl UdsClient
Sourcepub async fn report_number_of_dtc_by_status_mask(
&self,
dtc_status_mask: u8,
) -> EcuResponseResult
pub async fn report_number_of_dtc_by_status_mask( &self, dtc_status_mask: u8, ) -> EcuResponseResult
0x01
Sourcepub async fn report_dtc_by_status_mask(
&self,
dtc_status_mask: u8,
) -> EcuResponseResult
pub async fn report_dtc_by_status_mask( &self, dtc_status_mask: u8, ) -> EcuResponseResult
0x02
Sourcepub async fn report_dtc_ext_data_record_by_dtc_number(
&self,
dtc_mask_record: u32,
dtc_ext_data_record_number: u8,
) -> EcuResponseResult
pub async fn report_dtc_ext_data_record_by_dtc_number( &self, dtc_mask_record: u32, dtc_ext_data_record_number: u8, ) -> EcuResponseResult
0x06
Sourcepub async fn report_most_recent_confirmed_dtc(&self) -> EcuResponseResult
pub async fn report_most_recent_confirmed_dtc(&self) -> EcuResponseResult
0x0E
Source§impl UdsClient
impl UdsClient
Sourcepub async fn read_memory_by_address(
&self,
address_and_memory_length_format_identifier: u8,
memory_address: &[u8],
memory_size: &[u8],
) -> EcuResponseResult
pub async fn read_memory_by_address( &self, address_and_memory_length_format_identifier: u8, memory_address: &[u8], memory_size: &[u8], ) -> EcuResponseResult
address_and_memory_length_format_identifier (explained in ISOTP table 152) is two values encoded in single message - could be split into two separate values mem_length and address_length. Or create wrapper, that would take two parameters.
Or could be even more simplified, by accepting just address and mem_size values, but that would be less flexible
Takes memory address and byte size encoded in u8 slice. MSB is at position 0. Examples are shown in ISOTP documentation chapter 10.3.5.2
Sourcepub async fn read_memory_by_address_simplified(
&self,
memory_address: u64,
memory_size: u64,
memory_address_len: Option<u8>,
memory_size_len: Option<u8>,
) -> EcuResponseResult
pub async fn read_memory_by_address_simplified( &self, memory_address: u64, memory_size: u64, memory_address_len: Option<u8>, memory_size_len: Option<u8>, ) -> EcuResponseResult
Simplified method, where address_and_memory_length_format_identifier will be assumed from provided arguments if not specified. If assumption will take place, the lowest possible size will be used.
Source§impl UdsClient
impl UdsClient
pub async fn write_data_by_identifier( &self, data_identifier: u16, data_record: &[u8], ) -> EcuResponseResult
Auto Trait Implementations§
impl Freeze for UdsClient
impl !RefUnwindSafe for UdsClient
impl Send for UdsClient
impl Sync for UdsClient
impl Unpin for UdsClient
impl !UnwindSafe for UdsClient
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more