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: BSP_DISCO_F746NG F746_GUI LCD_DISCO_F746NG SDFileSystem TS_DISCO_F746NG ResistiveTouchController Map CYS8218Controller MedianFilter
Diff: Screens/ManualSetpointScreen.cpp
- Revision:
- 20:70c5b1e499f0
- Child:
- 21:aa3074b237e0
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Screens/ManualSetpointScreen.cpp Sun Oct 02 23:16:00 2016 +0200 @@ -0,0 +1,38 @@ +#include "ManualSetpointScreen.hpp" + +ManualSetpointScreen::ManualSetpointScreen(int *nextScreen, float *xSP, float *ySP) : + Screen(), + _lbTitle( SCREEN_W/2, 0, "Manual Setpoint", Label::CENTER, Font24), + _btBack( 0, SCREEN_H-30, 100, 30, "Back"), + _npSetpoint( (SCREEN_W/2)-90 ,57, 180,180, -120.0, 120.0, -136,136), + _btStart( 110, SCREEN_H-30, SCREEN_W-120, 30, "Start"), + _btStop( 110, SCREEN_H-30, SCREEN_W-120, 30, "Stop"), + _nlbXSP(0,26,"x (mm)=%.0f",*xSP), + _nlbYSP(0,40,"x (mm)=%.0f",*xSP), + _btReset( SCREEN_W-100, SCREEN_H-30, 100, 30, "Reset") +{ + _nextScreen = nextScreen; + _xSP = xSP; + _ySP = ySP; +} + +void ManualSetpointScreen::Draw() +{ + Clear(); + _lbTitle.Draw(); + _btBack.Draw(); + _npSetpoint.Draw(); + _btStart.Draw(); + _btStop.Draw(); + _nlbXSP.Draw(); + _nlbYSP.Draw(); +} + +void ManualSetpointScreen::Process() +{ + if( _btBack.Touched() ) + { + *_nextScreen = AUTOMATIC_MORE_SCREEN; + } + +}