MAV'RIC
Classes | Public Member Functions
Gpio_chibios Class Reference
Inheritance diagram for Gpio_chibios:
Inheritance graph
[legend]
Collaboration diagram for Gpio_chibios:
Collaboration graph
[legend]

List of all members.

Classes

struct  conf_t
 GPIO configuration. More...

Public Member Functions

 Gpio_chibios (conf_t config)
 Constructor.
bool init (void)
 Hardware initialization.
bool configure (gpio_dir_t dir, gpio_pull_updown_t pull)
 Configures the GPIO.
bool set_high (void)
 Write 1 to the gpio.
bool set_low (void)
 Write 0 to the gpio.
bool toggle (void)
 Toggle the gpio value.
bool write (bool level)
 Write to the gpio pin.
bool read (void)
 Read the current gpio level.

Member Function Documentation

bool Gpio_chibios::configure ( gpio_dir_t  dir,
gpio_pull_updown_t  pull 
) [virtual]

Configures the GPIO.

Parameters:
dirPin direction (one of enum gpio_dir_t)
pullPin pull up/down (one of enum gpio_pull_updown_t)
Returns:
success

Implements Gpio.

bool Gpio_chibios::init ( void  ) [virtual]

Hardware initialization.

Returns:
true Success
false Error

Implements Gpio.

Here is the call graph for this function:

Here is the caller graph for this function:

bool Gpio_chibios::read ( void  ) [virtual]

Read the current gpio level.

Returns:
Level

Implements Gpio.

bool Gpio_chibios::set_high ( void  ) [virtual]

Write 1 to the gpio.

Returns:
true Success
false Failed

Implements Gpio.

Here is the caller graph for this function:

bool Gpio_chibios::set_low ( void  ) [virtual]

Write 0 to the gpio.

Returns:
true Success
false Failed

Implements Gpio.

Here is the caller graph for this function:

bool Gpio_chibios::toggle ( void  ) [virtual]

Toggle the gpio value.

Writes 0 if currently high, writes 1 if currently low

Returns:
true Success
false Failed

Implements Gpio.

Here is the call graph for this function:

bool Gpio_chibios::write ( bool  level) [virtual]

Write to the gpio pin.

Parameters:
levelValue to write
Returns:
true Success
false Failed

Implements Gpio.

Here is the call graph for this function:


The documentation for this class was generated from the following files:
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines