Struct rust_cryptoauthlib::AteccDevice [−][src]
An ATECC cryptochip context holder.
Implementations
impl AteccDevice
[src]
Implementation of CryptoAuth Library API Rust wrapper calls
pub fn new(r_iface_cfg: AtcaIfaceCfg) -> Result<AteccDevice, String>
[src]
ATECC device instance constructor
pub fn sha(&self, message: Vec<u8>, digest: &mut Vec<u8>) -> AtcaStatus
[src]
Request ATECC to compute a message hash (SHA256)
pub fn random(&self, rand_out: &mut Vec<u8>) -> AtcaStatus
[src]
Request ATECC to generate a vector of random bytes
pub fn gen_key(&self, key_type: KeyType, slot_number: u8) -> AtcaStatus
[src]
Request ATECC to generate a cryptographic key
pub fn get_device(&self) -> AtcaDevice
[src]
pub fn get_device_type(&self) -> AtcaDeviceType
[src]
Request ATECC to return own device type
pub fn configuration_is_locked(&self, is_locked: &mut bool) -> AtcaStatus
[src]
Request ATECC to check if its configuration is locked. If true, a chip can be used for cryptographic operations
pub fn read_config_zone(&self, config_data: &mut Vec<u8>) -> AtcaStatus
[src]
Request ATECC to read and return own configuration zone. Note: this function returns raw data, function get_config(..) implements a more structured return value.
pub fn cmp_config_zone(
&self,
config_data: &mut Vec<u8>,
same_config: &mut bool
) -> AtcaStatus
[src]
&self,
config_data: &mut Vec<u8>,
same_config: &mut bool
) -> AtcaStatus
Compare internal config zone contents vs. config_data. Diagnostic function.
pub fn release(&self) -> AtcaStatus
[src]
ATECC device instance destructor
pub fn get_config(&self, atca_slots: &mut Vec<AtcaSlot>) -> AtcaStatus
[src]
Request ATECC to read the configuration zone data and return it in a structure
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for AteccDevice
impl Send for AteccDevice
impl Sync for AteccDevice
impl Unpin for AteccDevice
impl UnwindSafe for AteccDevice
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,