summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael J. Chudobiak <mjc@avtechpulse.com>2018-05-03 10:03:53 -0400
committerMichael J. Chudobiak <mjc@avtechpulse.com>2018-05-03 10:03:53 -0400
commit0c186f13f4397ab9fe04f38a8fcbd1aaad89ff6a (patch)
tree29f9762180fedc1762e416e74269c36feb82bef8
parent201bfbfb5a6242b3cfc534c6b7015eb0be623c5e (diff)
Use correct range size in flash init. Old unused vars not initialized any more.
-rw-r--r--flash.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/flash.c b/flash.c
index 634e980..b339eb9 100644
--- a/flash.c
+++ b/flash.c
@@ -530,7 +530,7 @@ static void initFlashValues(FlashStruct *mem)
power_of_two=24.0e-9;
for (j=0; j<timing_ranges; j++) {
for (k=0; k<timing_polarities; k++) {
- for (m=0; m<old_range_size_ten; m++) {
+ for (m=0; m<std_range_size; m++) {
mem->slew_pwl[i][j][k][m]=0.0;
mem->slew_dacval[i][j][k][m]=0;
@@ -605,7 +605,7 @@ static void initFlashValues(FlashStruct *mem)
power_of_two=20.0e-9;
for (j=0; j<ampl_ranges; j++) {
for (k=0; k<ampl_polarities; k++) {
- for (m=0; m<old_range_size_ten; m++) {
+ for (m=0; m<std_range_size; m++) {
if (m==0) {
mem->rise_time_dacval[i][j][k][m]=dac_max;
mem->rise_time_pwl[i][j][k][m]=(1e-9+power_of_two);
@@ -637,7 +637,7 @@ static void initFlashValues(FlashStruct *mem)
mem->ampl_pwl[i][k][m][j]=0.0;
mem->distort_dacval[i][k][m][j]=dac_max; /* EA shunt is max at zero ampl,
zero at max ampl */
- for (j=1; j<10; j++) {
+ for (j=1; j<std_range_size; j++) {
mem->ampl_dacval[i][k][m][j]=0;
mem->ampl_pwl[i][k][m][j]=0.0;
mem->distort_dacval[i][k][m][j]=0;
@@ -677,7 +677,7 @@ static void initFlashValues(FlashStruct *mem)
mem->load_type_dacval[i][0][0][0] = dac_max;
mem->load_type_dacval[i][0][0][1] = dac_max / 60;
- for (j=2; j<10; j++) {
+ for (j=2; j<std_range_size; j++) {
mem->load_type_pwl[i][0][0][j] = 0;
mem->load_type_dacval[i][0][0][j] = 0;
}
@@ -774,7 +774,7 @@ static void initFlashValues(FlashStruct *mem)
mem->zout_min[i]=2;
mem->zout_max[i]=50;
- for (j=0; j<10; j++) {
+ for (j=0; j<std_range_size; j++) {
for (k=0; k<5; k++) {
mem->os_dacval[i][k][0][j]=0;
mem->os_pwl[i][k][0][j]=0.0;