summaryrefslogtreecommitdiff
path: root/instr-daemon.c
diff options
context:
space:
mode:
Diffstat (limited to 'instr-daemon.c')
-rw-r--r--instr-daemon.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/instr-daemon.c b/instr-daemon.c
index b8a24c7..ec4e27e 100644
--- a/instr-daemon.c
+++ b/instr-daemon.c
@@ -237,17 +237,19 @@ int main(int argc, char **argv)
initFlash (&globals.Flash, FALSE, 0);
- // count startups
- if (globals.Flash.self_cal) {
- ++globals.Flash.self_cal_startups;
- int eprom_loc = (char *) &(globals.Flash.self_cal_startups) - (char *) &(globals.Flash.flash_start);
- writeUserBlock(eprom_loc,&globals.Flash.flash_start + eprom_loc,sizeof(globals.Flash.self_cal_startups));
- }
-
gchar *message = g_strdup_printf ("%s, S/N %s", globals.Flash.model_num, globals.Flash.serial_num);
LCD_display_extended_message (message, 0);
g_free (message);
+ fixFlash(&globals.Flash);
+
+ // count startups
+ if (globals.Flash.self_cal) {
+ ++globals.Flash.self_cal_startups;
+ int eprom_loc = (char *) &(globals.Flash.self_cal_startups) - (char *) &(globals.Flash.flash_start);
+ writeUserBlock(eprom_loc,&globals.Flash.flash_start + eprom_loc,sizeof(globals.Flash.self_cal_startups));
+ }
+
nicinfo info;
strcpy(info.ip,"-");
nicutils_infofordefaultroute(&info);