#include <Solenoid.h>


Public Member Functions | |
| Solenoid (unsigned channel) | |
| Solenoid (unsigned slot, unsigned channel) | |
| ~Solenoid () | |
| void | Set (bool on) |
| bool | Get (void) |
Protected Member Functions | |
| unsigned | SlotToIndex (unsigned slot) |
The Solenoid class is typically used for pneumatics solenoids, but could be used for any device within the current spec of the 9472 module.
| Solenoid::Solenoid | ( | unsigned | channel | ) |
Constructor.
| channel | The channel on the module to control. |
| Solenoid::Solenoid | ( | unsigned | slot, | |
| unsigned | channel | |||
| ) |
Constructor.
| slot | The slot that the 9472 module is plugged into. | |
| channel | The channel on the module to control. |
| Solenoid::~Solenoid | ( | ) |
Destructor.
| void Solenoid::Set | ( | bool | on | ) |
Set the value of a solenoid.
| on | Turn the solenoid output off or on. |
| bool Solenoid::Get | ( | void | ) |
Read the current value of the solenoid.
| unsigned Solenoid::SlotToIndex | ( | unsigned | slot | ) | [protected] |
Convert slot number to index.
| slot | The slot in the chassis where the module is plugged in. |
1.5.5