Seth Forslund / Mbed 2 deprecated ECE595_VehicleBrakingsystem

Dependencies:   mbed mbed-http ESP8266

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers RGBLED.h Source File

RGBLED.h

00001 #ifndef MBED_RGBLED_H
00002 #define MBED_RGBLED_H
00003 
00004 #include "mbed.h"
00005 
00006 //Class to control an RGB LED using three PWM pins
00007 
00008 class RGBLed
00009 {
00010 public:
00011     RGBLed(PinName redpin, PinName greenpin, PinName bluepin);
00012     void write(float red,float green, float blue);
00013 private:
00014     PwmOut _redpin;
00015     PwmOut _greenpin;
00016     PwmOut _bluepin;
00017 };
00018  
00019 
00020 
00021 #endif