Skip to content

Commit

Permalink
Merge pull request #46 from matsstaff/work
Browse files Browse the repository at this point in the history
Work
  • Loading branch information
matsstaff committed Jan 2, 2015
2 parents cdc6ccc + 1ef8da7 commit 77fdd37
Show file tree
Hide file tree
Showing 7 changed files with 870 additions and 849 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ Updates
|2014-05-25|v1.04|A couple of minor improvements and a minor bugfix|
|2014-08-02|v1.05|Reset both heating and cooling delay when either heating or cooling cycle ends. Improved power off| functionality, increased button debounce time, allow longer heating delays.|
|2014-09-14|v1.06|Add functionality for 2nd temp probe (to limit heating/cooling). Display 'OFF' in soft off mode. Added user definable temperature alarm. Added profile 'editor' webpage.|
|2015-01-02|v1.07|Fixed bug where every other profile had wrong limits. Fixed soft on tempprobe switch bug.|

Some excellent user provided content
------------------------------------
Expand Down
852 changes: 429 additions & 423 deletions picprog.ino

Large diffs are not rendered by default.

425 changes: 214 additions & 211 deletions src/build/stc1000p_celsius.hex

Large diffs are not rendered by default.

425 changes: 214 additions & 211 deletions src/build/stc1000p_fahrenheit.hex

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/page0.c
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,8 @@ static void update_profile(){
* properly, so the variables below were moved from temperature_control()
* and made global.
*/
static unsigned int cooling_delay = 60; // Initial cooling delay
static unsigned int heating_delay = 60; // Initial heating delay
unsigned int cooling_delay = 60; // Initial cooling delay
unsigned int heating_delay = 60; // Initial heating delay
static void temperature_control(){
int setpoint = eeprom_read_config(EEADR_SET_MENU_ITEM(SP));
int hysteresis2 = eeprom_read_config(EEADR_SET_MENU_ITEM(hy2));
Expand Down
10 changes: 9 additions & 1 deletion src/page1.c
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@
/* Help to convert menu item number and config item number to an EEPROM config address */
#define EEADR_MENU_ITEM(mi, ci) ((mi)*19 + (ci))

extern unsigned int heating_delay;
extern unsigned int cooling_delay;

/* Set menu struct */
struct s_setmenu {
unsigned char led_c_10;
Expand Down Expand Up @@ -70,6 +73,9 @@ static int RANGE(int x, int min, int max){
/* Check and constrain a configuration value */
static int check_config_value(int config_value, unsigned char eeadr){
if(eeadr < EEADR_SET_MENU){
while(eeadr >= 19){
eeadr-=19;
}
if(eeadr & 0x1){
config_value = RANGE(config_value, 0, 999);
} else {
Expand Down Expand Up @@ -216,7 +222,9 @@ void button_menu_fsm(){
TMR4ON = 0;
TMR4IF = 0;
} else {
reset();
heating_delay=60;
cooling_delay=60;
TMR4ON = 1;
}
state = state_idle;
} else if(!BTN_HELD(BTN_PWR)){
Expand Down
2 changes: 1 addition & 1 deletion src/stc1000p.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@

/* Define STC-1000+ version number (XYY, X=major, YY=minor) */
/* Also, keep track of last version that has changes in EEPROM layout */
#define STC1000P_VERSION 106
#define STC1000P_VERSION 107
#define STC1000P_EEPROM_VERSION 11

/* Define limits for temperatures */
Expand Down

0 comments on commit 77fdd37

Please sign in to comment.