Simple library for controlling a shift register using only three pins on the mbed. Defaults to controlling an 8 bit shift register.
Dependents: Lab07_RTOS_display Lab07_RTOS_queue
Revision 3:31000094ef1e, committed 2015-07-14
- Comitter:
- ollie8
- Date:
- Tue Jul 14 07:28:28 2015 +0000
- Parent:
- 2:78bb6ead1c28
- Child:
- 4:7333dc6fca5c
- Commit message:
- documentation update
Changed in this revision
ShiftOut.h | Show annotated file Show diff for this revision Revisions of this file |
--- a/ShiftOut.h Tue Jul 14 07:24:10 2015 +0000 +++ b/ShiftOut.h Tue Jul 14 07:28:28 2015 +0000 @@ -4,17 +4,17 @@ #include <mbed.h> /** A simple serial driver for a shift register that uses only three digital out pins leaving SPI and i2c free. - * ShiftOut can be configured bitness shift register but defaults to eight bits. + * ShiftOut can be configured for any size shift register but defaults to eight bits. */ class ShiftOut { public : - /** Constructs a new ShiftOut with the given three pins. - * clk - the pin to use for the shift register clock. - * data - the pin to use for the shift register data line. - * latch - the pin to use for the shift register latch. - * registerCount - the number of registers in the shift register, defaults to eight. + /** Constructs a new ShiftOut with the given three pins.\n + * clk - the pin to use for the shift register clock.\n + * data - the pin to use for the shift register data line.\n + * latch - the pin to use for the shift register latch.\n + * registerCount - the number of registers in the shift register, defaults to eight.\n */ ShiftOut(PinName clk, PinName data, PinName latch, int8_t registerCount = 0x08) { clkout = new DigitalOut(clk);