diff options
author | root <root@avtech.domain.avtechpulse.com> | 1970-01-01 09:14:14 +0900 |
---|---|---|
committer | root <root@avtech.domain.avtechpulse.com> | 1970-01-01 09:14:14 +0900 |
commit | 347f3f886ea54470f340def6a7af981f5845cc01 (patch) | |
tree | ee0b53caff48b05e0b18af074daa1a0c33dc38c4 /flash.c | |
parent | f4bf2894fa2e1b05958f0828d932e9068bc9b828 (diff) |
Allow 64-char model numbersINSTRUMENT_6_0_10
Diffstat (limited to 'flash.c')
-rw-r--r-- | flash.c | 13 |
1 files changed, 12 insertions, 1 deletions
@@ -414,7 +414,7 @@ static void initFlashValues(FlashStruct *mem) mem->logic_level_enabled=0; mem->ChanKey_logic_level=0; - strcpy(mem->model_num,"unprogrammed"); + strcpy(mem->model_num,"AV-unprogrammed"); strcpy(mem->serial_num,"00000"); mem->fully_programmed=Being_Programmed; @@ -936,6 +936,14 @@ void fixFlash(FlashStruct *mem) int i, fix_initial_constants; + fix_initial_constants = 0; + + // handle change in model number location + if ((mem->model_num[0] != 'A') && (mem->model_num[1] != 'V')) { + strcpy(mem->model_num, mem->model_num_old); + ++fix_initial_constants; + } + for (i=0; i<max_channels; i++) { globals.Constraints.composite_min_burst_time[i]=mem->min_burst_gap[i]; @@ -1008,6 +1016,9 @@ void fixFlash(FlashStruct *mem) eprom_loc = (char *) &(mem->rcl_amplitude) - (char *) &(mem->flash_start); writeUserBlock(&globals.Flash, eprom_loc, sizeof(mem->rcl_amplitude)); + + eprom_loc = (char *) &(mem->model_num) - (char *) &(mem->flash_start); + writeUserBlock(&globals.Flash, eprom_loc, sizeof(mem->model_num)); } } |