PBtnToggle
Public Member Functions | List of all members
PBtnTogglePISOController Class Reference

Controller class for PISO buttons. More...

#include <PBtnTogglePISOController.h>

Public Member Functions

 PBtnTogglePISOController (int chips, int data_pin, int clock_pin, int latch_pin_)
 Initialize PISO chip controller. More...
 
void add (PBtnTogglePISO *btn)
 Add PBtnTogglePISO button to controller. More...
 
void check ()
 Check buttons state. More...
 

Detailed Description

Controller class for PISO buttons.

All PBtnTogglePISO buttons will be add()-ed to this controller. PISO chips can be daisy chained. PL /active low/, CP, Q7 pins of first chip are wired to Arduino digital pins. All chips have common PL /active low/, CP, Vcc, CE /active low/, GND pins. Pin DS will be wired with pin Q7 of next chip.

Constructor & Destructor Documentation

PBtnTogglePISOController::PBtnTogglePISOController ( int  chips,
int  data_pin,
int  clock_pin,
int  latch_pin 
)

Initialize PISO chip controller.

Parameters
chipsNumber of chips daisy chained
data_pinpin number wired to chip Q7 (serial out)
clock_pinpin number wired to chip CP (clock input)
latch_pinpin number wired to PL /active low/ (parallel load input)

Member Function Documentation

void PBtnTogglePISOController::add ( PBtnTogglePISO btn)

Add PBtnTogglePISO button to controller.

Parameters
*btnPBtnTogglePISO pointer
void PBtnTogglePISOController::check ( )

Check buttons state.

This method must be called in loop()


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