[−][src]Trait obd::Uds
Unified diagnostic services. This is the standard protocol used for reading PIDs and communicating with ECUs.
Required methods
pub fn query_uds(
&mut self,
arbitration_id: u32,
request_sid: u8,
data: &[u8]
) -> Result<Vec<u8>, Error>
[src]
&mut self,
arbitration_id: u32,
request_sid: u8,
data: &[u8]
) -> Result<Vec<u8>, Error>
Sends a UDS message and waits for a response.
Arguments
arbitration_id
- the CAN arbitration ID to use when sending. This is incremented by 8 to calculate the expected response ID.request_sid
- the requested service ID.data
- the message data.
Provided methods
pub fn query_vin(&mut self, arbitration_id: u32) -> Result<String, Error>
[src]
Sends a query for a VIN (vehicle identification number).
pub fn query_trouble_codes(
&mut self,
arbitration_id: u32
) -> Result<Vec<DTC>, Error>
[src]
&mut self,
arbitration_id: u32
) -> Result<Vec<DTC>, Error>
Queries the list of diagnostic trouble codes
pub fn query_pending_trouble_codes(
&mut self,
arbitration_id: u32
) -> Result<Vec<DTC>, Error>
[src]
&mut self,
arbitration_id: u32
) -> Result<Vec<DTC>, Error>
Queries the list of diagnostic trouble codes
pub fn set_diagnostic_session(
&mut self,
arbitration_id: u32,
id: u8
) -> Result<(), Error>
[src]
&mut self,
arbitration_id: u32,
id: u8
) -> Result<(), Error>
Sets the diagnostic session type
pub fn request_security_seed(
&mut self,
arbitration_id: u32
) -> Result<Vec<u8>, Error>
[src]
&mut self,
arbitration_id: u32
) -> Result<Vec<u8>, Error>
Requests a security access seed
pub fn request_security_key(
&mut self,
arbitration_id: u32,
key: &[u8]
) -> Result<(), Error>
[src]
&mut self,
arbitration_id: u32,
key: &[u8]
) -> Result<(), Error>
Authenticates with a security access key. Usually, this is generated
using the seed retrieved from [request_security_seed
].
pub fn read_memory_address(
&mut self,
arbitration_id: u32,
address: u32,
length: u16
) -> Result<Vec<u8>, Error>
[src]
&mut self,
arbitration_id: u32,
address: u32,
length: u16
) -> Result<Vec<u8>, Error>
Requests memory at specified address. Usually, this requires an
authentication procedure with [request_security_key
].