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.
Dependencies: C12832 LM75B mbed EthernetInterface mbed-rtos
potentiometer.cpp@0:88d3b9015f7c, 2018-02-26 (annotated)
- Committer:
- bertgereels
- Date:
- Mon Feb 26 11:25:59 2018 +0000
- Revision:
- 0:88d3b9015f7c
- Child:
- 1:b5c534165dfe
First Commit
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| bertgereels | 0:88d3b9015f7c | 1 | #include "potentiometer.h" |
| bertgereels | 0:88d3b9015f7c | 2 | |
| bertgereels | 0:88d3b9015f7c | 3 | namespace ProjectOne{ |
| bertgereels | 0:88d3b9015f7c | 4 | |
| bertgereels | 0:88d3b9015f7c | 5 | Potentiometer::Potentiometer(PinName analogPin) : pot1(analogPin){ |
| bertgereels | 0:88d3b9015f7c | 6 | |
| bertgereels | 0:88d3b9015f7c | 7 | } |
| bertgereels | 0:88d3b9015f7c | 8 | |
| bertgereels | 0:88d3b9015f7c | 9 | int Potentiometer::getPotValue(void){ |
| bertgereels | 0:88d3b9015f7c | 10 | return pot1.read_u16(); |
| bertgereels | 0:88d3b9015f7c | 11 | } |
| bertgereels | 0:88d3b9015f7c | 12 | |
| bertgereels | 0:88d3b9015f7c | 13 | } |