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: mbed
Fork of RT2_P3_students by
LinearCharacteristics.h@13:724759951a6f, 2018-05-07 (annotated)
- Committer:
 - Kiwicjam
 - Date:
 - Mon May 07 09:06:54 2018 +0000
 - Revision:
 - 13:724759951a6f
 - Parent:
 - 9:dc0eb7dd0d92
 
fertig komentiert
Who changed what in which revision?
| User | Revision | Line number | New contents of line | 
|---|---|---|---|
| altb | 0:78ca29b4c49e | 1 | // Linear Characteristics for different purposes (map Voltage to acc etc.) | 
| altb | 1:a30512c3ac73 | 2 | |
| altb | 1:a30512c3ac73 | 3 | |
| altb | 1:a30512c3ac73 | 4 | #ifndef LINEAR_CHARACTERISTICS_H_ | 
| altb | 1:a30512c3ac73 | 5 | #define LINEAR_CHARACTERISTICS_H_ | 
| altb | 1:a30512c3ac73 | 6 | |
| altb | 1:a30512c3ac73 | 7 | |
| altb | 0:78ca29b4c49e | 8 | class LinearCharacteristics{ | 
| altb | 0:78ca29b4c49e | 9 | public: | 
| altb | 7:72982ede2ff6 | 10 | LinearCharacteristics(float, float); | 
| Kiwicjam | 9:dc0eb7dd0d92 | 11 | LinearCharacteristics(float, float ,float ,float); | 
| altb | 7:72982ede2ff6 | 12 | float evaluate(float); | 
| altb | 7:72982ede2ff6 | 13 | float operator()(float x){ | 
| altb | 7:72982ede2ff6 | 14 | return evaluate(x); | 
| altb | 7:72982ede2ff6 | 15 | } | 
| altb | 6:2cc56521aa16 | 16 | //... | 
| altb | 3:769ce5f06d3e | 17 | virtual ~LinearCharacteristics(); | 
| altb | 6:2cc56521aa16 | 18 | // here: the calculation function | 
| altb | 0:78ca29b4c49e | 19 | |
| altb | 0:78ca29b4c49e | 20 | private: | 
| altb | 0:78ca29b4c49e | 21 | // here: private functions and values... | 
| altb | 7:72982ede2ff6 | 22 | float gain; | 
| altb | 7:72982ede2ff6 | 23 | float offset; | 
| altb | 1:a30512c3ac73 | 24 | }; | 
| altb | 1:a30512c3ac73 | 25 | |
| altb | 1:a30512c3ac73 | 26 | |
| altb | 1:a30512c3ac73 | 27 | #endif // LINEAR_CHARACTERISTICS_H_ | 
