Kevin Sullivan / Mbed 2 deprecated summerlab2020q2_1

Dependencies:   mbed C12832

Files at this revision

API Documentation at this revision

Comitter:
kevinsullivan
Date:
Sun Jul 19 19:46:59 2020 +0000
Parent:
0:94dcb8c6ed26
Child:
2:cc5021b73dc1
Commit message:
summerlab2020q2_1

Changed in this revision

C12832.lib Show annotated file Show diff for this revision Revisions of this file
main.cpp Show annotated file Show diff for this revision Revisions of this file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/C12832.lib	Sun Jul 19 19:46:59 2020 +0000
@@ -0,0 +1,1 @@
+https://os.mbed.com/users/chris/code/C12832/#7de323fa46fe
--- a/main.cpp	Sat Jul 18 08:59:16 2020 +0000
+++ b/main.cpp	Sun Jul 19 19:46:59 2020 +0000
@@ -6,15 +6,15 @@
  pc.printf("Press 'u' to turn LED1 brightness up, 'd' to turn it down\n");
  while(1) {
  char c = pc.getc();
- if((c == 'u') && (brightness < 0.5)) {
+ if((c == 'u') & (brightness < 0.5)) {
  brightness += 0.01;
  led = brightness;
- pc.putc('^');// using "^" for LED brightness up 
+ pc.putc('^');// using "^" for LED brightness up
  }
- if((c == 'd') && (brightness > 0.0)) {
+ if((c == 'd') & (brightness > 0.0)) {
  brightness -= 0.01;
  led = brightness;
- pc.putc('&&');//using "&&" for down LED brightness down
+ pc.putc('~');//using " ~ " for down LED brightness down
  }
  }
 }
\ No newline at end of file