Create an object of type Octofet to communicate with a particular Octofet board. One Octofet board provides 8 power switches also known as "channels".
Constructs a new Octofet board object that uses the default hardware SPI bus.
pin_CE: the chip enable (also known as chip select or slave select) pin used to control the shift-register latch. It can take the values0or1, which corresponds to theCE0orCE1pins on the Raspberry Pi board.device_count: the number of Octofet boards connected in a daisy-chain. If omitted, defines a single Octofet board.
Sets the state ("on" or "off") of one power switch.
channel: the power switch index. Ranges from0to7.value: defines the desired switch state. Valid values:Trueto turn on orFalseto turn off.device: the index of the affected Octofet in the daisy-chain. Ranges from0ton - 1, wherenis the number of Octofets in the chain. If omitted, targets Octofet nearest to the controller.
Sets the state ("on" or "off") of all power switches at once.
value: list of boolean values for all of 8 power switches. One value for one channel:Trueis "on" andFalseis "off".device: the index of the affected Octofet in the daisy-chain. Ranges from0ton - 1, wherenis the number of Octofets in the chain. If omitted, targets Octofet nearest to the controller.
Returns the last (i.e., current) set state for one power switch of the device. Returns True if
turned on or False otherwise.
channel: the power switch index. Ranges from0to7.device: the index of the affected Octofet in the daisy-chain. Ranges from0ton - 1, wherenis the number of Octofets in the chain. If omitted, targets Octofet nearest to the controller.
Returns a boolean list of the last (i.e., current) set state for all 8 power switches of the device
at once. One value from the list corresponds to one channel: True is "on" and False is "off".
The argument device is the index of the affected Octofet in the daisy-chain. Ranges from 0 to
n - 1, where n is the number of Octofets in the chain. If omitted, targets Octofet nearest to
the controller.