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@0:b22f610d83fd, 2019-07-23 (annotated)
- Committer:
- manishb
- Date:
- Tue Jul 23 11:33:30 2019 +0000
- Revision:
- 0:b22f610d83fd
lm35;
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| manishb | 0:b22f610d83fd | 1 | #include "mbed.h" |
| manishb | 0:b22f610d83fd | 2 | AnalogIn LM35(p15); |
| manishb | 0:b22f610d83fd | 3 | |
| manishb | 0:b22f610d83fd | 4 | int main() { |
| manishb | 0:b22f610d83fd | 5 | float value; |
| manishb | 0:b22f610d83fd | 6 | while(1) { |
| manishb | 0:b22f610d83fd | 7 | value = ((LM35.read()*3276)/10); |
| manishb | 0:b22f610d83fd | 8 | printf("Temp: %2.2f degree C\r\n", value); |
| manishb | 0:b22f610d83fd | 9 | wait(1); |
| manishb | 0:b22f610d83fd | 10 | } |
| manishb | 0:b22f610d83fd | 11 | } |