public TestSystemWithInterruptingDevice(byte portAddress, byte initialValue, int waitCycles, int[][] startInterruptAfterTStatesAndDuringTStates, byte valueForDataBusAfterInterrupt)
        {
            // Initialize components
            clock = new __Clock(3500000L);
            cpu = new __Z80CPU();
            memory = new _TestMemory(65536, 0);
            device = new _TestInterruptingDevice(portAddress, initialValue, waitCycles, startInterruptAfterTStatesAndDuringTStates, valueForDataBusAfterInterrupt);

            // Connect buses
            cpu.Address.ConnectTo(addressBus);
            cpu.Data.ConnectTo(dataBus);
            memory.Address.ConnectTo(addressBus);
            memory.Data.ConnectTo(dataBus);
            device.Address.ConnectTo(addressBus);
            device.Data.ConnectTo(dataBus);

            // Connect individual PINs
            ((__Clock)clock).ConnectTo(cpu, (TestMemory)memory, device);
            ((__Z80CPU)cpu).ConnectTo(clock, (TestMemory)memory, device);
            ((_TestMemory)memory).ConnectTo(clock, cpu);
            ((_TestInterruptingDevice)device).ConnectTo(clock, cpu);
        }
        public TestSystemWithInterruptingDevice(byte portAddress, byte initialValue, int waitCycles, int[][] startInterruptAfterTStatesAndDuringTStates, byte valueForDataBusAfterInterrupt)
        {
            // Initialize components
            clock  = new __Clock(3500000L);
            cpu    = new __Z80CPU();
            memory = new _TestMemory(65536, 0);
            device = new _TestInterruptingDevice(portAddress, initialValue, waitCycles, startInterruptAfterTStatesAndDuringTStates, valueForDataBusAfterInterrupt);

            // Connect buses
            cpu.Address.ConnectTo(addressBus);
            cpu.Data.ConnectTo(dataBus);
            memory.Address.ConnectTo(addressBus);
            memory.Data.ConnectTo(dataBus);
            device.Address.ConnectTo(addressBus);
            device.Data.ConnectTo(dataBus);

            // Connect individual PINs
            ((__Clock)clock).ConnectTo(cpu, (TestMemory)memory, device);
            ((__Z80CPU)cpu).ConnectTo(clock, (TestMemory)memory, device);
            ((_TestMemory)memory).ConnectTo(clock, cpu);
            ((_TestInterruptingDevice)device).ConnectTo(clock, cpu);
        }
 public void ConnectTo(Clock clock, TestMemory memory, TestInterruptingDevice device)
 {
     base.ConnectTo(clock, memory);
     this.device = device;
 }
 public void ConnectTo(Z80CPU cpu, TestMemory memory, TestInterruptingDevice device)
 {
     base.ConnectTo(cpu, memory);
     this.device = device;
 }
 public void ConnectTo(Clock clock, TestMemory memory, TestInterruptingDevice device)
 {
     base.ConnectTo(clock, memory);
     this.device = device;
 }
 public void ConnectTo(Z80CPU cpu, TestMemory memory, TestInterruptingDevice device)
 {
     base.ConnectTo(cpu, memory);
     this.device = device;
 }