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.
main.cpp
- Committer:
- kevinsullivan
- Date:
- 2020-07-18
- Revision:
- 1:44729c5f024a
- Parent:
- 0:376219f61e79
- Child:
- 2:6bc37de37167
File content as of revision 1:44729c5f024a:
#include "mbed.h"
#include "C12832.h"
Serial pc(USBTX, USBRX); // tx, rx
PwmOut led1(LED1);
AnalogIn pot1(p19);
C12832 lcd(p5,p7,p6,p8,p11);
int main()
{
while(1) {
float t = pot1;
led1 = pot1;
wait(0.01);
lcd.locate(0,0); //brings the cursor on the LCD back to the top left corner
lcd.printf("value = %.2f\n",t); // displays the value on the LCD
lcd.printf("value = %.2e\n",t);
}
}