Smart Knob Controller

Wrapper class for STM32 GPIO pin control. More...

#include <gpio.h>

Public Member Functions

 GPIO (GPIO_TypeDef *port, uint16_t pin)
 Constructs a GPIO object.
void write (GPIO_PinState state) const
 Writes a logic level to the GPIO pin.
void high () const
 Sets the GPIO pin high.
void low () const
 Sets the GPIO pin low.

Detailed Description

Wrapper class for STM32 GPIO pin control.

Constructor & Destructor Documentation

◆ GPIO()

GPIO::GPIO ( GPIO_TypeDef * port,
uint16_t pin )

Constructs a GPIO object.

Parameters
portGPIO port (e.g., GPIOA, GPIOB).
pinGPIO pin number (e.g., GPIO_PIN_5).

Member Function Documentation

◆ write()

void GPIO::write ( GPIO_PinState state) const

Writes a logic level to the GPIO pin.

Parameters
stateGPIO_PIN_SET or GPIO_PIN_RESET.

The documentation for this class was generated from the following files:
  • C:/Users/nickl/OneDrive - Cal Poly/POLY4TH/SPRING'25/507/LAB WORKSPACE/SmartKnobController_REV2/Core/DoxCommd/gpio.h
  • C:/Users/nickl/OneDrive - Cal Poly/POLY4TH/SPRING'25/507/LAB WORKSPACE/SmartKnobController_REV2/Core/DoxCommd/gpio.cpp