summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dummy_functions.c40
-rw-r--r--error_utils.c2
-rw-r--r--instr-daemon.c4
-rw-r--r--monitor.c20
-rw-r--r--parser.c134
5 files changed, 112 insertions, 88 deletions
diff --git a/dummy_functions.c b/dummy_functions.c
index 7aaefeb..232cb71 100644
--- a/dummy_functions.c
+++ b/dummy_functions.c
@@ -3,18 +3,36 @@
void Menu_Refresh() {}
void Menu_Update_Display() {}
-int Menu_Clear_Buttons(void) {return 0;}
+int Menu_Clear_Buttons(void)
+{
+ return 0;
+}
-int IO_Setup_RS232() {return 0;}
+int IO_Setup_RS232()
+{
+ return 0;
+}
void GPIB_Set_Command_Error() {}
void GPIB_Set_Query_Error() {}
void GPIB_Set_Device_Dependent_Error() {}
void GPIB_Set_Execution_Error() {}
-unsigned int GPIB_get_ESR () {return 0;}
-unsigned int GPIB_get_SRE () {return 0;}
-unsigned int GPIB_get_ESE () {return 0;}
-unsigned int GPIB_get_STB () {return 0;}
+unsigned int GPIB_get_ESR ()
+{
+ return 0;
+}
+unsigned int GPIB_get_SRE ()
+{
+ return 0;
+}
+unsigned int GPIB_get_ESE ()
+{
+ return 0;
+}
+unsigned int GPIB_get_STB ()
+{
+ return 0;
+}
void GPIB_set_ESR (unsigned int byte,int operation) {}
void GPIB_set_SRE (unsigned int byte,int operation) {}
void GPIB_set_ESE (unsigned int byte,int operation) {}
@@ -23,5 +41,11 @@ void GPIB_change_address(int new_address) {}
void Main_update_shift_registers() { }
-int Set_Sav(int setting_num) {return 0;}
-int Set_Rcl(int setting_num) {return 0;}
+int Set_Sav(int setting_num)
+{
+ return 0;
+}
+int Set_Rcl(int setting_num)
+{
+ return 0;
+}
diff --git a/error_utils.c b/error_utils.c
index a0c694d..ec713cd 100644
--- a/error_utils.c
+++ b/error_utils.c
@@ -500,7 +500,7 @@ void get_error_text(gchar **response, int error_num)
case ThisShouldntHappen:
format_error_text(response,-200,"Invalid execution path. Programming error.");
- break;
+ break;
default:
format_error_text(response,-200,"Specific problem unknown.");
diff --git a/instr-daemon.c b/instr-daemon.c
index 329addc..9b8b923 100644
--- a/instr-daemon.c
+++ b/instr-daemon.c
@@ -244,8 +244,8 @@ int main(int argc, char **argv)
int i;
for (i=0; i<8; i++) {
- set_dac(i,globals.Flash.initial_dac_settings[i]);
- }
+ set_dac(i,globals.Flash.initial_dac_settings[i]);
+ }
fixFlash(&globals.Flash);
diff --git a/monitor.c b/monitor.c
index 0fc319a..28d25e3 100644
--- a/monitor.c
+++ b/monitor.c
@@ -177,7 +177,7 @@ int I2C_Check_Monitors(void)
if (seconds_since_last > 0) {
if ( (globals.ChannelState[channel].func_mode==dc_mode_on)
- || (globals.ChannelState[channel].output_state==output_off)) {
+ || (globals.ChannelState[channel].output_state==output_off)) {
/* force monitor measurement every second in DC mode (because no TTL
trigger is present) and output-off mode */
force_monitor_cal(channel,NO);
@@ -199,19 +199,19 @@ int I2C_Check_Monitors(void)
/* 5.0V is the full-scale voltage of the 12bit ADC */
globals.ChannelState[channel].Curr_Mon_value=((((float) monitor_word)/4095.0) * 5.0)
- / globals.Flash.mon_vi_ratio[channel][ampl_range][use_neg_data];
+ / globals.Flash.mon_vi_ratio[channel][ampl_range][use_neg_data];
/* convert to even step size */
step_size=globals.Flash.monitor_step[channel];
globals.ChannelState[channel].Curr_Mon_value=
- ((float)
- ((long) (globals.ChannelState[channel].Curr_Mon_value/step_size))
- )
- * step_size;
+ ((float)
+ ((long) (globals.ChannelState[channel].Curr_Mon_value/step_size))
+ )
+ * step_size;
/* AVO-8D2: check for duty cycle problems, as a function of measured amplitude */
if ( globals.Flash.hard_current_limit_enabled[channel] &&
- (globals.ChannelState[channel].output_state == output_on)) {
+ (globals.ChannelState[channel].output_state == output_on)) {
for (i=0; i<max_channels; ++i) {
TestState[i]=globals.ChannelState[i];
}
@@ -223,11 +223,11 @@ int I2C_Check_Monitors(void)
}
if (globals.Flash.soft_current_limit_enabled[channel] &&
- (globals.Flash.fully_programmed != Being_Programmed) &&
- (globals.ChannelState[channel].Curr_Mon_value > globals.ChannelState[channel].soft_current_limit)) {
+ (globals.Flash.fully_programmed != Being_Programmed) &&
+ (globals.ChannelState[channel].Curr_Mon_value > globals.ChannelState[channel].soft_current_limit)) {
Set_Output_State(channel,output_off);
queue_and_broadcast_sensor_alarm(Soft_Limit_Exceeded);
- }
+ }
// FIXME - menus
// else if (Type_Of_Menu==Main_Menu_On && Error_Screen==NO && Nonstd_Display==NO
// && globals.ChannelState[channel].Curr_Mon_value!=globals.ChannelState[channel].displayed_mon_val
diff --git a/parser.c b/parser.c
index f0c9423..d7cf46e 100644
--- a/parser.c
+++ b/parser.c
@@ -1249,7 +1249,7 @@ static int Go_int_eprom_48(gchar** response, int channel, char *loc_string,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1284,7 +1284,7 @@ static int Go_Float_eprom51(gchar** response, int channel, char *loc_string,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1319,7 +1319,7 @@ static int Go_char_eprom_70(gchar** response, int channel, char *loc_string,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1335,7 +1335,7 @@ static int Go_eprom_siz_86(gchar** response, int channel, int command_type)
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1358,7 +1358,7 @@ static int Go_sys_net_91(gchar **response, int channel, char *loc_string,char *s
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1647,7 +1647,7 @@ static int Go_syst_err_11(gchar** response, int channel, char *parameter,char *u
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
static int Go_syst_errcnt66(gchar** response, int channel, char *parameter,char *units,int command_type)
@@ -1662,7 +1662,7 @@ static int Go_syst_errcnt66(gchar** response, int channel, char *parameter,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1727,7 +1727,7 @@ static int Go_ampl_26(gchar** response, int channel, char *parameter,char *units
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1782,7 +1782,7 @@ static int Go_pw_36(gchar** response, int channel, char *parameter,char *units,i
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1827,7 +1827,7 @@ static int Go_duty_37(gchar** response, int channel, char *parameter,char *units
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1884,7 +1884,7 @@ static int Go_offset_29(gchar** response, int channel, char *parameter,char *uni
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1903,7 +1903,7 @@ static int Go_idn_5(gchar** response, int channel, char *loc_string,char *store_
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1956,7 +1956,7 @@ static int Go_period_35(gchar** response, int channel, char *parameter,char *uni
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -1998,7 +1998,7 @@ static int Go_delay_39(gchar** response, int channel, char *parameter,char *unit
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2030,7 +2030,7 @@ static int Go_dbl_pulse_40(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2083,7 +2083,7 @@ static int Go_func_34(gchar** response, int channel, char *parameter,char *units
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2125,7 +2125,7 @@ static int Go_polarity_42(gchar** response, int channel, char *parameter,char *u
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2163,7 +2163,7 @@ static int Go_hold_38(gchar** response, int channel, char *parameter,char *units
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2195,7 +2195,7 @@ static int Go_output_55(gchar** response, int channel, char *parameter,char *uni
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2248,7 +2248,7 @@ static int Go_trig_source46(gchar** response, int channel, char *parameter,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2292,7 +2292,7 @@ static int Go_gate_type_56(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2331,7 +2331,7 @@ static int Go_gate_level_67(gchar** response, int channel, char *parameter,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2357,7 +2357,7 @@ static int Go_delay_test58(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2376,7 +2376,7 @@ static int Go_wai_10(gchar** response, int channel, char *parameter,char *units,
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2400,7 +2400,7 @@ static int Go_opc_5(gchar** response, int channel, char *parameter,char *units,i
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2427,7 +2427,7 @@ static int Go_ese_2(gchar** response, int channel, char *parameter,char *units,i
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2447,7 +2447,7 @@ static int Go_esr_3(gchar** response, int channel, char *parameter,char *units,i
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2465,7 +2465,7 @@ static int Go_cls_1(gchar** response, int channel, char *parameter,char *units,i
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2506,7 +2506,7 @@ static int Go_stb_8(gchar** response, int channel, char *parameter,char *units,i
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2522,7 +2522,7 @@ static int Go_tst_9(gchar** response, int channel, char *parameter,char *units,i
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2538,7 +2538,7 @@ static int Go_syst_ver_12(gchar** response, int channel, char *parameter,char *u
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2554,7 +2554,7 @@ static int Go_event_13(gchar** response, int channel, char *parameter,char *unit
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2580,7 +2580,7 @@ static int Go_oper_enable15(gchar** response, int channel, char *parameter,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2606,7 +2606,7 @@ static int Go_ques_enable18(gchar** response, int channel, char *parameter,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2624,7 +2624,7 @@ static int Go_preset_19(gchar** response, int channel, char *parameter,char *uni
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2667,7 +2667,7 @@ static int Go_zout_20(gchar** response, int channel, char *parameter,char *units
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2687,7 +2687,7 @@ static int Go_prot_trip_21(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2717,7 +2717,7 @@ static int Go_gpib_addr_59(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2769,7 +2769,7 @@ static int Go_ser_baud_60(gchar** response, int channel, char *parameter,char *u
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2808,7 +2808,7 @@ static int Go_ser_par_61(gchar** response, int channel, char *parameter,char *un
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2852,7 +2852,7 @@ static int Go_ser_bits_62(gchar** response, int channel, char *parameter,char *u
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2896,7 +2896,7 @@ static int Go_ser_sbits_63(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2932,7 +2932,7 @@ static int Go_ser_rts_64(gchar** response, int channel, char *parameter,char *un
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -2969,7 +2969,7 @@ static int Go_ser_echo_65(gchar** response, int channel, char *parameter,char *u
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3015,7 +3015,7 @@ static int Go_load_68(gchar** response, int channel, char *parameter,char *units
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3040,7 +3040,7 @@ static int Go_meas_ampl_69(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3057,7 +3057,7 @@ static int Go_rst_6(gchar** response, int channel, char *parameter,char *units,i
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3102,7 +3102,7 @@ static int Go_calib_amp_72(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3140,7 +3140,7 @@ static int Go_calib_mon_73(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3203,7 +3203,7 @@ static int Go_mon_step_74(gchar** response, int channel, char *parameter,char *u
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3244,7 +3244,7 @@ static int Go_outputtype_75(gchar** response, int channel, char *parameter,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3289,7 +3289,7 @@ static int Go_calib_os_76(gchar** response, int channel, char *parameter,char *u
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3327,7 +3327,7 @@ static int Go_calib_pw_77(gchar** response, int channel, char *parameter,char *u
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3377,7 +3377,7 @@ static int Go_routeclose_78(gchar** response, int channel, char *parameter,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3540,7 +3540,7 @@ static int Go_dly_shift_82(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3675,7 +3675,7 @@ static int Go_amp_pnt_83(gchar** response, int channel, char *parameter,char *un
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3748,7 +3748,7 @@ static int Go_puls_count_88(gchar** response, int channel, char *parameter,char
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3796,7 +3796,7 @@ static int Go_puls_sep_89(gchar** response, int channel, char *parameter,char *u
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3837,7 +3837,7 @@ static int Go_eprom_sus_93(gchar** response, int channel, char *parameter,int co
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3864,7 +3864,7 @@ static int Go_eprom_reset_102(gchar** response, int channel, char *parameter,cha
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3909,7 +3909,7 @@ static int Go_rise_time_94(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3931,7 +3931,7 @@ static int Go_rcl_53(gchar** response, int channel, char *parameter,char *units,
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -3953,7 +3953,7 @@ static int Go_sav_54(gchar** response, int channel, char *parameter,char *units,
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -4000,7 +4000,7 @@ static int Go_soft_current_limit_96(gchar** response, int channel, char *paramet
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -4045,7 +4045,7 @@ static int Go_curr_slew_98(gchar** response, int channel, char *parameter,char *
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -4107,7 +4107,7 @@ static int Go_avrq_ampl(gchar** response, int channel, char *parameter,char *uni
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}
@@ -4175,7 +4175,7 @@ static int Go_cal_interval_101(gchar** response, int channel, char *parameter,ch
break;
}
- return ThisShouldntHappen;
+ return ThisShouldntHappen;
}