Update readme, cleanup files

This commit is contained in:
Ben V. Brown
2017-09-27 11:41:37 +10:00
parent 82a5ed042d
commit 77204f306e
3 changed files with 4 additions and 1 deletions

View File

@@ -82,7 +82,7 @@ void resetSettings() {
systemSettings.sensitivity = 8; //Default high sensitivity
systemSettings.voltageDiv = 144; //Default divider from schematic
systemSettings.ShutdownTime = 30; //How many minutes until the unit turns itself off
systemSettings.boostModeEnabled = 0; //Default to safe, with no boost mode
systemSettings.boostModeEnabled = 1; //Default to safe, with no boost mode
systemSettings.BoostTemp = 420; //default to 400C
systemSettings.powerDisplay = 0; //default to power display being off
systemSettings.autoStartMode = 0; //Auto start off for safety

View File

@@ -202,6 +202,8 @@ static void settings_setCalibrate(void) {
uint8_t maxOffset = strlen(SettingsCalibrationWarning);
uint32_t descriptionStart = HAL_GetTick();
lcd.setFont(0);
lcd.clearScreen();
lcd.setCursor(0, 0);
for (;;) {
int16_t descriptionOffset = ((HAL_GetTick() - descriptionStart) / 150) % maxOffset;
@@ -214,6 +216,7 @@ static void settings_setCalibrate(void) {
//User confirmed
//So we now perform the actual calculation
lcd.clearScreen();
lcd.setCursor(0, 0);
lcd.print(".....");
lcd.refresh();
setCalibrationOffset(0); //turn off the current offset

View File

@@ -1,33 +0,0 @@
/*
* gui.h
*
* Created on: 3Sep.,2017
* Author: Ben V. Brown
*/
#ifndef GUI_H_
#define GUI_H_
//GUI holds the menu structure and all its methods for the menu itself
#include "main.hpp"
#include "Settings.h"
#include "Translation.h"
//Declarations for all the methods for the settings menu (at end of this file)
//Wrapper for holding a function pointer
typedef struct state_func_t {
void (*func)(void);
} state_func;
//Struct for holding the function pointers and descriptions
typedef struct {
const char *description;
const state_func incrementHandler;
const state_func draw;
} menuitem;
extern bool settingsResetRequest;
extern const menuitem settingsMenu[];
#endif /* GUI_H_ */