Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: 4DGL-uLCD-SE_ PinDetect SDFileSystem mbed
Fork of mythermostat by
Diff: Shiftbrite.h
- Revision:
- 2:58d85409f7ff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/Shiftbrite.h Thu Jan 31 03:15:20 2013 +0000
@@ -0,0 +1,26 @@
+#include "mbed.h"
+
+//Setup a new class for a Shiftbrite RGB LED module
+class Shiftbrite
+{
+public:
+ Shiftbrite(PinName pin_e, PinName pin_l, PinName pin_do, PinName pin_di, PinName pin_clk);
+ void write(int red, int green, int blue);
+
+private:
+//class sets up the pins
+ DigitalOut _pin_e;
+ DigitalOut _pin_l;
+ SPI _spi;
+};
+
+Shiftbrite::Shiftbrite(PinName pin_e, PinName pin_l, PinName pin_do, PinName pin_di, PinName pin_clk)
+ : _pin_e(pin_e), _pin_l(pin_l), _spi(pin_do, pin_di, pin_clk)
+{
+ // ADD CODE HERE
+}
+
+void Shiftbrite::write(int red, int green, int blue)
+{
+ // ADD CODE HERE
+}
