Braille Glove
 
Loading...
Searching...
No Matches
TabbingActuator Class Reference

A class representing a tabbing actuator. More...

#include <TabbingActuator.h>

Inheritance diagram for TabbingActuator:
Actuator

Public Member Functions

 TabbingActuator (int pin)
 Constructor for TabbingActuator.
 
void activate () override
 Activates the tabbing actuator.
 
void deactivate () override
 Deactivates the tabbing actuator.
 
- Public Member Functions inherited from Actuator
 Actuator (int pin, ActuatorType type)
 Constructor for the Actuator class.
 

Additional Inherited Members

- Protected Attributes inherited from Actuator
int pin
 GPIO pin number the actuator is connected to.
 
ActuatorType actuatorType
 Type of actuator (e.g., vibration, stroking, tabbing).
 
bool turnedOn = false
 Flag to check if the actuator is currently active.
 

Detailed Description

A class representing a tabbing actuator.

This actuator is designed to create a tapping or tabbing sensation using a servo motor.

Constructor & Destructor Documentation

◆ TabbingActuator()

TabbingActuator::TabbingActuator ( int pin)
inline

Constructor for TabbingActuator.

Initializes the tabbing actuator by attaching the servo to the specified pin and setting it to the initial position (180 degrees).

Parameters
pinThe GPIO pin to which the actuator is connected.

Member Function Documentation

◆ activate()

void TabbingActuator::activate ( )
inlineoverridevirtual

Activates the tabbing actuator.

Moves the servo to 90 degrees to simulate a tabbing motion.

Implements Actuator.

◆ deactivate()

void TabbingActuator::deactivate ( )
inlineoverridevirtual

Deactivates the tabbing actuator.

Moves the servo back to 180 degrees.

Implements Actuator.


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