added all heater switches
This commit is contained in:
parent
c45e2a71d9
commit
375995e562
@ -108,9 +108,37 @@ void ObjectFactory::produce(){
|
||||
GpioConfig_t gpioConfigHeater0(std::string("gpiochip7"), 18,
|
||||
std::string("Heater0"), Gpio::OUT);
|
||||
gpioCookie->addGpio(gpioIds::HEATER_0, gpioConfigHeater0);
|
||||
|
||||
/* Pin H2-12 on stack connector */
|
||||
GpioConfig_t gpioConfigHeater1(std::string("gpiochip7"), 14,
|
||||
std::string("Heater1"), Gpio::OUT);
|
||||
gpioCookie->addGpio(gpioIds::HEATER_1, gpioConfigHeater1);
|
||||
|
||||
/* Pin H2-13 on stack connector */
|
||||
GpioConfig_t gpioConfigHeater2(std::string("gpiochip7"), 20,
|
||||
std::string("Heater2"), Gpio::OUT);
|
||||
gpioCookie->addGpio(gpioIds::HEATER_2, gpioConfigHeater2);
|
||||
|
||||
GpioConfig_t gpioConfigHeater3(std::string("gpiochip7"), 16,
|
||||
std::string("Heater3"), Gpio::OUT);
|
||||
gpioCookie->addGpio(gpioIds::HEATER_3, gpioConfigHeater3);
|
||||
|
||||
GpioConfig_t gpioConfigHeater4(std::string("gpiochip7"), 24,
|
||||
std::string("Heater4"), Gpio::OUT);
|
||||
gpioCookie->addGpio(gpioIds::HEATER_4, gpioConfigHeater4);
|
||||
|
||||
GpioConfig_t gpioConfigHeater5(std::string("gpiochip7"), 26,
|
||||
std::string("Heater5"), Gpio::OUT);
|
||||
gpioCookie->addGpio(gpioIds::HEATER_5, gpioConfigHeater5);
|
||||
|
||||
GpioConfig_t gpioConfigHeater6(std::string("gpiochip7"), 22,
|
||||
std::string("Heater6"), Gpio::OUT);
|
||||
gpioCookie->addGpio(gpioIds::HEATER_6, gpioConfigHeater6);
|
||||
|
||||
GpioConfig_t gpioConfigHeater7(std::string("gpiochip7"), 28,
|
||||
std::string("Heater7"), Gpio::OUT);
|
||||
gpioCookie->addGpio(gpioIds::HEATER_7, gpioConfigHeater7);
|
||||
|
||||
#endif
|
||||
new LinuxLibgpioIF(objects::GPIO_IF);
|
||||
new HeaterHandler(objects::HEATER_HANDLER, objects::GPIO_IF, gpioCookie, objects::PCDU_HANDLER,
|
||||
|
@ -311,6 +311,24 @@ gpioId_t HeaterHandler::getGpioIdFromSwitchNr(int switchNr) {
|
||||
case heaterSwitches::HEATER_1:
|
||||
gpioId = gpioIds::HEATER_1;
|
||||
break;
|
||||
case heaterSwitches::HEATER_2:
|
||||
gpioId = gpioIds::HEATER_2;
|
||||
break;
|
||||
case heaterSwitches::HEATER_3:
|
||||
gpioId = gpioIds::HEATER_3;
|
||||
break;
|
||||
case heaterSwitches::HEATER_4:
|
||||
gpioId = gpioIds::HEATER_4;
|
||||
break;
|
||||
case heaterSwitches::HEATER_5:
|
||||
gpioId = gpioIds::HEATER_5;
|
||||
break;
|
||||
case heaterSwitches::HEATER_6:
|
||||
gpioId = gpioIds::HEATER_6;
|
||||
break;
|
||||
case heaterSwitches::HEATER_7:
|
||||
gpioId = gpioIds::HEATER_7;
|
||||
break;
|
||||
default:
|
||||
sif::error << "HeaterHandler::getGpioIdFromSwitchNr: Unknown heater switch number"
|
||||
<< std::endl;
|
||||
|
Loading…
Reference in New Issue
Block a user