1 #ifndef HARDWARE_ABSTRACTION_LAYER_HPP
2 #define HARDWARE_ABSTRACTION_LAYER_HPP
6 namespace nes {
namespace rob {
The hardware abstraction layer interface.
Definition: hardware_abstraction_layer.hpp:14
static const int PIN_MODE_INPUT_PULLUP
The GPIO mode used to sample digital signals with internal pullup resistor enabled.
Definition: hardware_abstraction_layer.hpp:28
static const int PIN_MODE_INPUT
The GPIO mode used to sample digital signals.
Definition: hardware_abstraction_layer.hpp:22
static const int PIN_STATE_HIGH
The digital signal value indicating high voltage (typically Vcc)
Definition: hardware_abstraction_layer.hpp:39
virtual nes::rob::error_code init(void *reserved=nullptr)=0
Initialize the HAL.
virtual ~HardwareAbstractionLayer(void)
Definition: hardware_abstraction_layer.hpp:47
static const int PIN_STATE_LOW
The digital signal value indicating low voltage (typically Vdd)
Definition: hardware_abstraction_layer.hpp:45
virtual nes::rob::error_code delayMicroseconds(unsigned int us) const =0
Delay program execution for the specified number of microseconds.
virtual nes::rob::error_code digitalWrite(unsigned int pin, int state) const =0
Drive the output voltage of a digital GPIO pin.
static const int PIN_MODE_OUTPUT
The GPIO mode used to write digital signals.
Definition: hardware_abstraction_layer.hpp:33
virtual nes::rob::error_code pinMode(unsigned int pin, int mode) const =0
Drive the output voltage of a digital GPIO pin.
std::error_code error_code
Definition: hal_error.hpp:24
Definition: arduino_debug_driver.hpp:6