Struct rustduino::atmega2560p::hal::pin::Pins[][src]

#[repr(C, packed)]
pub struct Pins { pub analog: [AnalogPin; 16], pub digital: [DigitalPin; 54], }
Expand description

The ATMEGA2560P microcontroller IC has a total of 100 pins to configure the functioning of the microcontroller. Out of those 86 pins are set as I/O pins which are configured into 11 ports each controlling 8 pins except port G which controls 6 pins. All 8 pins of port F and K are Analog pins and total 54 digital pins are available and the rest 16 pins are for various other purposes. This structure declaration contains the space to control all the 86 pins in one memory mapped I/O.

Fields

analog: [AnalogPin; 16]digital: [DigitalPin; 54]

Implementations

Returns all pins at once as a single struct. No new memory is created, just the already created space is given a name so it is a memory mapped I/O.

Returns

  • a Pins object - used to control all pins of AVR chip at one place.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

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

Performs the conversion.

Performs the conversion.

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.