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.
Revision 1:b89b54759940, committed 2014-04-01
- Comitter:
- frankvnk
- Date:
- Tue Apr 01 20:03:30 2014 +0000
- Parent:
- 0:1258ad754d9c
- Commit message:
- Added global intensity function
Changed in this revision
PCA9635_6.cpp | Show annotated file Show diff for this revision Revisions of this file |
PCA9635_6.h | Show annotated file Show diff for this revision Revisions of this file |
diff -r 1258ad754d9c -r b89b54759940 PCA9635_6.cpp --- a/PCA9635_6.cpp Mon Mar 31 18:38:01 2014 +0000 +++ b/PCA9635_6.cpp Tue Apr 01 20:03:30 2014 +0000 @@ -241,4 +241,9 @@ *B = RGB_LED[LEDn].BLUE.buf[RGB_LED[LEDn].BLUE.n]; } +void PCA9635_6::set_global_intensity(uint8_t globi) +{ + GLOBAL_INTENSITY[2] = globi; +} +
diff -r 1258ad754d9c -r b89b54759940 PCA9635_6.h --- a/PCA9635_6.h Mon Mar 31 18:38:01 2014 +0000 +++ b/PCA9635_6.h Tue Apr 01 20:03:30 2014 +0000 @@ -109,10 +109,23 @@ */ void read_LED( int LEDn, uint8_t *R, uint8_t *G, uint8_t *B); + /** Send GLOBAL_INTENSITY to LED board. + * + * @param none. + * @return none. + */ + void LED_INTENSITY(void); + + /** Change GLOBAL_INTENSITY. + * + * @param intensity value. + * @return none. + */ + void set_global_intensity(uint8_t globi); + private: void i2cfail(void); void I2C_Write(I2C_MESSAGE *mp); - void LED_INTENSITY(void); I2C _i2c; DigitalOut _en; };