Railway Challenge
/
challenge
Uncommenting of part that allow supercaps to charge up from the batteries
dashboard.h
- Committer:
- rwcjoliver
- Date:
- 2020-03-13
- Revision:
- 0:4788e1df7b55
File content as of revision 0:4788e1df7b55:
#ifndef _DASHBOARD_H_ #define _DASHBOARD_H_ #include <mbed.h> class Dashboard { public: Dashboard(InterruptIn& hallSensor); // CONSTRUCTOR void tachoInterrupt(); void getCurrentSpeed(); int currentSpeed; float currentDistance; private: InterruptIn& _hallSensor; Timer tachoTimer; int passedTime_ms; float passedTime; float lastTime; float wheelFreq; float wheelCircumference; int numberOfMagnets; int tachoCounter; int currentTime; }; #endif