>Ciao Stefano, >di che tipo di indirizzi parli, esattamente? > >Luca Beh, pensavo alle porte parallele.. l'output è facile, abbiamo a disposizione tutto un byte più qualcos'altro, Ma anche l'input, almeno parziale, è disponibile: PC parallel port has 5 input pins. Those inputs can accept TTL level signals (0-0.7V = logic 0, 2.4-5V = logic 1). You can connect a TTL level output signal to it directly (remeber to attach the signal source ground to parallel port ground). You can connect siple switches to the inputs by connecting the switch bbetween parallel port ground and input pin, and then adding a 10 kohm pull-up resistor from the pin to +5V. When the switch is activated, the pin goes to logic state 0. Usually it is a good idea to isolate the PC from the signal source, and in this case it is usually a good idea to use a relay or optocoupler (the relay/optocoupler output is wired in the place of the switch, otherwise works in the same way as the switch connection). TIP: You can avoid using external +5V power source by using one of the parallel port output pins as one. So set one free output pin to logic 1 and wire the 10 kohm pull-up resistors to it instead of dedicated extra +5V source. For other ideas how to get that +5V power take a look at How to get power from PC to your circuits and Simple 5V power supply for digital circuits. The input pins can be read from the I/O address LPT port base address + 1. The meaning of the buts in byte you read from that I/O port: D0: state not specified D1: state not specified D2: state not specified D3: state of pin 15 (ERROR) inverted D4: state of pin 13 (SELECTED) D5: state of pin 12 (PAPER OUT) D6: state of pin 10 (ACK) D7: state of pin 11 (BUSY) inverted Si tratta di soli 5 bit, però forse li si potrebbe mappare 1-contro-1. La libreria inpout32.dll sembra permettere l'accesso diretto alle porte anche con XP & company, semplicemente caricando al volo un virtual device driver. Ora, potendo 'girare' le istruzioni di IN e OUT dello Z80 emulato sulle porte esterne dovrebbe essere possibile ad esempio: - girare l'output della SpecDrum su un "ponte di resistenze" collegato alla parallela - rimappare i bit di ingresso/uscita del registratore a cassette sulla parallela come si faceva con gli emulatori ai vecchi tempi - costruire cavi "seriali" sulla parallela, controllati in software dall'emulazione dell'Interface 1 - Girare l'ingresso della parallela sulla porta $31 (kempston) e attaccarci un Joystick originale. - Usare due parallele (5+5 bit) e collegare una tastiera "spectrumosa" esterna - Interfacciarsi a un controller FDC e importare dati In generale... sarebbe bello poter riciclare l'hardware (autocostruito o meno) e attaccarlo a un PC moderno. E poi.. vuoi mettere il trip ? _________________________________________________________________ Scatta, ritocca e condividi le tue foto online. Gratis per te http://www.windowslive.it/foto.aspx