More refactoring
Lots of things removed but compiles again
This commit is contained in:
@@ -13,7 +13,6 @@
|
||||
#include "eeprom.h"
|
||||
#include "display.h"
|
||||
#include "utils.h"
|
||||
#include "frq.h"
|
||||
#include "psu_ctrl.h"
|
||||
#include "amps.h"
|
||||
#include "main.h"
|
||||
@@ -62,6 +61,7 @@ extern ClampData_t clampData;
|
||||
|
||||
uint8_t Error, Suspend_Step_Chk;
|
||||
|
||||
|
||||
uint8_t Check_Output_Status(char Connector)
|
||||
{
|
||||
uint32_t x = 1;
|
||||
@@ -114,6 +114,7 @@ GPIO_PinWrite(GPIO, 0, PORT_LE, 1); // De-select CS
|
||||
|
||||
void Select_Bypass(RELAY_SELECT_t bypass) // Bypass allows transmitting w/o full protection
|
||||
{
|
||||
#if 0
|
||||
sys.status[BYPASS] = bypass;
|
||||
|
||||
if (bypass)
|
||||
@@ -127,7 +128,7 @@ void Select_Bypass(RELAY_SELECT_t bypass) // Bypass allows transmitting w/o full
|
||||
{
|
||||
EXPANDER_CLEAR(BYPASS_ON, true);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
@@ -152,7 +153,7 @@ void Select_Estop(ESTOP_SELECT_t stop)
|
||||
}
|
||||
void Select_Transformer()
|
||||
{
|
||||
|
||||
#if 0
|
||||
if (freqArray[frequency].frequency1 > MAX_LOW_FRQ)//ie. > 80K Was MAX_DTYPE
|
||||
{
|
||||
Port_State[MID_SR] |= SLCT_XFMR; // Switch to High freq xfrmr Taps O/P
|
||||
@@ -179,6 +180,7 @@ void Select_Transformer()
|
||||
// or not
|
||||
|
||||
SPI0_SendBytes(Port_State, 3, EXPANDER);
|
||||
#endif
|
||||
}
|
||||
|
||||
void Select_Amp_Xfrmr_Rly(AMP_XFRMR_SLCT_t Amp2xfrmr) // Allows any combination of Amp and transformer
|
||||
@@ -219,6 +221,7 @@ void Power_ON_OFF(RELAY_SELECT_t Power)
|
||||
|
||||
void Check_Clamp_OverVoltage(void)
|
||||
{
|
||||
#if 0
|
||||
if (Cur_Mode != BROADCAST)
|
||||
{
|
||||
|
||||
@@ -231,6 +234,7 @@ void Check_Clamp_OverVoltage(void)
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
void Check_Live_Voltage()
|
||||
{
|
||||
@@ -276,6 +280,7 @@ bool Compare_Voltage(float32_t source, float32_t limit)
|
||||
|
||||
void Check_Over_Current()
|
||||
{
|
||||
#if 0
|
||||
float x;
|
||||
|
||||
x = Get_Max_Current();
|
||||
@@ -291,18 +296,22 @@ float x;
|
||||
}
|
||||
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
float Get_Max_Current(void)
|
||||
{
|
||||
#if 0
|
||||
if (freqArray[frequency].frequency1 <= MAX_DTYPE)
|
||||
return (MAX_CURRENT);
|
||||
else
|
||||
return (MAX_HF_CURRENT);
|
||||
#endif
|
||||
}
|
||||
|
||||
void Check_Over_Power(void)
|
||||
{
|
||||
#if 0
|
||||
//uint8_t New_Pot_Val;
|
||||
if (Cur_Mode != BROADCAST)
|
||||
{
|
||||
@@ -315,20 +324,23 @@ void Check_Over_Power(void)
|
||||
}
|
||||
}
|
||||
// Delay_Ticks(100);
|
||||
#endif
|
||||
}
|
||||
|
||||
float32_t Get_Power_Limit(void)
|
||||
{
|
||||
#if 0
|
||||
if (freqArray[frequency].frequency1 < MAX_DTYPE)
|
||||
return(sys.maxPowerLimit);
|
||||
else
|
||||
return(1.0);
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
// if over power, scale amplitude
|
||||
void Adjust_Output_Power(float32_t New_Power_Limit)
|
||||
{
|
||||
#if 0
|
||||
if (Watts_Filt > New_Power_Limit)
|
||||
{
|
||||
uint8_t New_Pot_Val;
|
||||
@@ -345,6 +357,7 @@ void Adjust_Output_Power(float32_t New_Power_Limit)
|
||||
}
|
||||
else
|
||||
Suspend_Step_Chk = false;
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
@@ -468,6 +481,7 @@ void Count_Down_PWR_OFF(void) //Display_Bat_Error();
|
||||
|
||||
void Adjust_Clamp_Volts(void) // Set clamp output voltages to PL1
|
||||
{
|
||||
#if 0
|
||||
if (freqArray[frequency].frequency1 <= MAX_DTYPE)
|
||||
{
|
||||
Dds_Pot_Val[1] = Pot_Value_CLAMP1[1]; // data
|
||||
@@ -481,10 +495,12 @@ void Adjust_Clamp_Volts(void) // Set clamp output voltages to PL1
|
||||
|
||||
Dds_Pot_Val[0] = 0; // address
|
||||
SPI0_SendBytes(Dds_Pot_Val, 2, AMPLITUDE);
|
||||
#endif
|
||||
|
||||
}
|
||||
void Check_Over_Voltage(void) // Check Direct Connect Over voltage
|
||||
{
|
||||
#if 0
|
||||
uint8_t New_Pot_Val;
|
||||
uint8_t test1;
|
||||
if (Over_Voltage_tmr == 0)
|
||||
@@ -513,10 +529,12 @@ void Check_Over_Voltage(void) // Check Direct Connect Over voltage
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void Controlled_Pwr_Dwn()
|
||||
{
|
||||
#if 0
|
||||
uint8_t count;
|
||||
uint8_t avalue; // for debugging only
|
||||
|
||||
@@ -549,10 +567,12 @@ void Controlled_Pwr_Dwn()
|
||||
|
||||
Set_PSU_Voltage(V_18V); // switch off main psu down
|
||||
Delay_Ticks(DELAY_250MS);
|
||||
#endif
|
||||
}
|
||||
|
||||
void Update_Amp_Pot(void)
|
||||
{
|
||||
#if 0
|
||||
uint8_t avalue; // for debugging only
|
||||
Dds_Pot_Val[0] = 0; // address
|
||||
|
||||
@@ -563,11 +583,12 @@ void Update_Amp_Pot(void)
|
||||
|
||||
avalue = Dds_Pot_Val[1];
|
||||
SPI0_SendBytes(Dds_Pot_Val, 2, AMPLITUDE);
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
void Check_For_Clamp_On_Pwr_Up(void)
|
||||
{
|
||||
#if 0
|
||||
uint32_t idNumber1 = (uint32_t) ((sys.adc.V_ID2 * 3.3333) + 0.5);//multiply by 3.3333 and round to nearest integer
|
||||
uint32_t idNumber2 = (uint32_t) ((sys.adc.V_ID1 * 3.3333) + 0.5);//multiply by 3.3333 and round to nearest integer
|
||||
|
||||
@@ -590,6 +611,7 @@ void Check_For_Clamp_On_Pwr_Up(void)
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
bool Check_For_Clamp_New()
|
||||
@@ -701,6 +723,7 @@ bool Check_For_Clamp(void) // Assumes BROADCAST already checked for
|
||||
|
||||
void freq_key_process(void)
|
||||
{
|
||||
#if 0
|
||||
uint32_t tmp_frqx;
|
||||
|
||||
LD_Flag = false;
|
||||
@@ -738,10 +761,12 @@ void freq_key_process(void)
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void LD_key_process(void)
|
||||
{
|
||||
#if 0
|
||||
if(freqArray[frequency].frequency1 <= MAX_LD_FREQ && Cur_Mode != BROADCAST)
|
||||
{
|
||||
LD_Flag ^= 1;
|
||||
@@ -751,6 +776,7 @@ void LD_key_process(void)
|
||||
else
|
||||
Init_LD_Sync(); // clear the second freq
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
@@ -806,4 +832,4 @@ void Umag_Patch(void)
|
||||
void delayms(uint32_t msec)
|
||||
{
|
||||
stimer_delay(msec);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user