8085 Simulator IDE
External Modules Manual


Table Of Contents:

General info
i8085simulatoride.server,

Functions and procedures
getmem, setmem, getio, setio, i8085trap, i8085rst75, i8085rst65, i8085rst55, i8085intr, i8085reset, gethalt, getinst, getcrystal, getclockcycles, geta, getf, getb, getc, getd, gete, geth, getl, getsp, getpc,

External client/servers
objectinit, objectrefresh, writeio, readio, objectterm, External modules interface,


General info
8085 Simulator IDE is an automation (ActiveX) server/client application. This feature enables communication with external simulation modules that can be developed by home developers and third parties using various Development Systems for Windows.

i8085simulatoride.server
External client application can access 8085 Simulator IDE server services by creating an ActiveX object using i8085simulatoride.server class.

Functions and procedures
Here is the list of functions and procedures available for external client applications:
- getmem
getmem(address) function will return the value in the memory location specified by 'address' argument [0-65535].
- setmem
setmem(address,value) procedure will put the 'value' argument [0-255] in the memory location specified by 'address' argument [0-65535].
- getio
getio(address) function will return the value on the I/O port specified by 'address' argument [0-255].
- setio
setio(address,value) procedure will put the 'value' argument [0-255] on the I/O port specified by 'address' argument [0-255].
- i8085trap
i8085trap() procedure with no arguments will generate TRAP interrupt signal.
- i8085rst75
i8085rst75() procedure with no arguments will generate RST 7.5 interrupt signal.
- i8085rst65
i8085rst65() procedure with no arguments will generate RST 6.5 interrupt signal.
- i8085rst55
i8085rst55() procedure with no arguments will generate RST 5.5 interrupt signal.
- i8085intr
i8085intr() procedure with no arguments will generate INTR interrupt signal.
- i8085reset
i8085reset() procedure with no arguments will generate RESET signal.
- gethalt
gethalt() function with no arguments will return the HALT state [0-1].
- getinst
getinst() function with no arguments will return the mnemonics of last executed instruction [string].
- getcrystal
getcrystal() function with no arguments will return the clock frequency parameter [string].
- getclockcycles
getclockcycles() function with no arguments will return the number of clock cycles passed after the start of the simulation. The last two functions will enable the external client application to develop a real time behavior if needed.
- geta
geta() function will return the value in A register.
- getf
getf() function will return the value in F (flag) register.
- getb
getb() function will return the value in B register.
- getc
getc() function will return the value in C register.
- getd
getd() function will return the value in D register.
- gete
gete() function will return the value in E register.
- geth
geth() function will return the value in H register.
- getl
getl() function will return the value in L register.
- getsp
getsp() function will return the value in SP register.
- getpc
getpc() function will return the value in PC register.

External client/servers
Full support and full synchronization is available for external applications with client/server capabilities. External server module should provide the following procedures:

- objectinit
objectinit() procedure will be called at the beginning of the simulation in 8085 Simulator IDE. With this procedure external module should be initialized to a known initial state.
- objectrefresh
objectrefresh() procedure will be called after every simulated instruction.
- writeio
writeio(port,data) procedure will be called after every simulated OUT instruction and its arguments will be available for the external module.
- readio
readio(port,data) procedure will be called during the simulation of every IN instruction and the external module should assign the non-negative value [0-255] to the second argument (that should be addressed by reference and not by value) only if it is assigned to the specified port argument.
- objectterm
objectterm() procedure needs to contain the code to terminate external module application (typically End statement).

External modules interface
The class name should be set using External Modules interface available from Tools menu of 8085 Simulator IDE. External client/server applications will be started and terminated automatically with 8085 Simulator IDE.