pub struct Stream {
    pub tx: Tx,
    pub rx: Rx,
    /* private fields */
}
Expand description

An active encryption/decryption stream

You can get an instance of this struct by calling AES::enable.

Fields

tx: Tx

Can be used to write data to the AES peripheral

rx: Rx

Can be used to read data from the AES peripheral

Implementations

Processes one block of data

Writes one block of data to the AES peripheral, wait until it is processed then reads the processed block and returns it.

Whether this is encryption or decryption depends on the mode that was selected when this Stream was created.

Disable the AES peripheral

Consumes the stream and returns the disabled AES instance. Call this method when you’re done encrypting/decrypting data. You can then create another Stream using AES::enable.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.