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.
Diff: main.cpp
- Revision:
- 2:f91fc3b8d8f7
- Parent:
- 1:fdb8ecdf954f
- Child:
- 3:cbacf69dbed5
--- a/main.cpp Wed Mar 15 01:54:31 2017 +0000 +++ b/main.cpp Wed Mar 15 02:24:10 2017 +0000 @@ -1,8 +1,23 @@ #include "mbed.h" /* Serial2RGB main by C. S. Tritt, Last revised 3/14/17 (v. 1.0) - Toggles RGB LED junctions in response to serial input. Uses "unbuffered" - reads (Enter, CR/LF not required). + + Toggles RGB LED junctions in response to serial input. + + Suggested wiring... + + Common Anode LED (active low) + + /-- 1 kΩ -- D9 (red) + + 3.3 to 5.0 V ----LED<--- 680 Ω -- D10 (green) + \-- 680 Ω -- D11 (blue) + + Common Cathode LED (active high) + + /-- 1 kΩ -- D9 (red) + GND ----LED<--- 680 Ω -- D10 (green) + \-- 680 Ω -- D11 (blue) + */ DigitalOut RedLED(D9); // Physically same as Arduino Digital pin 9. DigitalOut GrnLED(D10); // Physically same as Arduino Digital pin 10.