Working Component Management

This commit is contained in:
2025-04-14 15:12:02 +02:00
parent 133ee646d1
commit ca36cffd47
20 changed files with 138 additions and 170 deletions

View File

@ -9,16 +9,27 @@ public abstract class PICComponent {
IOPortInterface ioPorts;
TimerInterface timer;
InterruptInterface interrupts;
TableInterface table;
WindowManagement createWindow;
//TableInterface table;
//WindowManagement createWindow;
FrontendControllerInterface frontendController;
WatchdogTimerInterface watchdogTimer;
ProgramStackInterface programStack;
CommandInterface commands;
ToggleButtonInterface toggleButtonExt;
void initialize(PICComponents picComponents) {
toggleButtonExt = (ToggleButtonInterface) picComponents.getComponent(ToggleButtonInterface.class);
dataRegister = (DataRegisterInterface) picComponents.getComponent(DataRegisterInterface.class);
eeprom = (EEPROMInterface) picComponents.getComponent(EEPROMInterface.class);
ioPorts = (IOPortInterface) picComponents.getComponent(IOPortInterface.class);
System.out.print("Initializing PIC Component ");
preScaler = (PreScaler) picComponents.getComponent(PreScalerInterface.class);
timer = (TimerInterface) picComponents.getComponent(TimerInterface.class);
interrupts = (InterruptInterface) picComponents.getComponent(InterruptInterface.class);
//table = (TableInterface) picComponents.getComponent(TableInterface.class);
//createWindow = (WindowManagement) picComponents.getComponent(WindowManagement.class);
frontendController = (FrontendControllerInterface) picComponents.getComponent(FrontendControllerInterface.class);
watchdogTimer = (WatchdogTimerInterface) picComponents.getComponent(WatchdogTimerInterface.class);
programStack = (ProgramStackInterface) picComponents.getComponent(ProgramStackInterface.class);
commands = (CommandInterface) picComponents.getComponent(CommandInterface.class);
}
}