Rpi-hw  0.7.2
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Pages
Public Member Functions | List of all members
rpihw::iface::output Class Reference

Output interface. More...

#include <output.hpp>

+ Inheritance diagram for rpihw::iface::output:

Public Member Functions

 output (std::initializer_list< uint8_t > pins)
 Constructor method. More...
 
 output (const std::vector< uint8_t > &pins)
 Constructor method. More...
 
virtual ~output ()
 Destructor method.
 
virtual void setPin (uint8_t index, uint8_t pin)
 Sets an output pin. More...
 
virtual void write (size_t data)
 Writes a data on the interface. More...
 
virtual void write (uint8_t index, bool data)
 Writes a data on the interface pin. More...
 
- Public Member Functions inherited from rpihw::iface::base
 base (std::initializer_list< uint8_t > pins)
 Constructor method. More...
 
 base (const std::vector< uint8_t > &pins)
 Constructor method. More...
 
virtual ~base ()
 Destructor method.
 
virtual uint8_t getPin (uint8_t index) const
 Returns an interface pin. More...
 
virtual uint8_t size () const
 Returns the number of the pins.
 

Additional Inherited Members

- Protected Attributes inherited from rpihw::iface::base
std::vector< uint8_t > m_pins
 Vector containing interface pins.
 
gpiom_gpio
 Virtual GPIO controller.
 

Detailed Description

Output interface.

Definition at line 43 of file output.hpp.

Constructor & Destructor Documentation

rpihw::iface::output::output ( std::initializer_list< uint8_t >  pins)

Constructor method.

Parameters
[in]pinsSequence of uint8_t containing the GPIO pins.
rpihw::iface::output::output ( const std::vector< uint8_t > &  pins)

Constructor method.

Parameters
[in]pinsVector containing the GPIO pins.

Member Function Documentation

void rpihw::iface::output::setPin ( uint8_t  index,
uint8_t  pin 
)
inlinevirtual

Sets an output pin.

Parameters
[in]indexThe index position of the output pin.
[in]pinThe new GPIO pin.

Reimplemented from rpihw::iface::base.

Definition at line 30 of file output-inl.hpp.

virtual void rpihw::iface::output::write ( size_t  data)
virtual

Writes a data on the interface.

Parameters
[in]dataThe data to be written.

Reimplemented in rpihw::iface::decoderOut, and rpihw::iface::encoderOut.

virtual void rpihw::iface::output::write ( uint8_t  index,
bool  data 
)
virtual

Writes a data on the interface pin.

Parameters
[in]indexThe index position of the interface pin.
[in]dataThe data to be written.

The documentation for this class was generated from the following files: