2018-08-31 18:42:12 +02:00
|
|
|
|
#!/usr/bin/python
|
|
|
|
|
|
|
|
|
|
from components.microprogram import Microprogram
|
|
|
|
|
from components.ram import Ram
|
|
|
|
|
from components.caretaker import Caretaker
|
|
|
|
|
|
|
|
|
|
c=Caretaker() # Init components
|
|
|
|
|
RAM=Ram(c,5000) # Init ram
|
|
|
|
|
RAM.loadRamFile("./ram.txt") # Load Ram from file
|
|
|
|
|
c["RAM"]=RAM # Add ram to components
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
mic=Microprogram(c) # Create micro program
|
|
|
|
|
mic.run() # Run the micro program
|
|
|
|
|
mic.dump() # Dump ram
|
|
|
|
|
|
2018-09-01 10:19:06 +02:00
|
|
|
|
c["MBR"]=-1
|
|
|
|
|
print(c["MBR"])
|
2018-08-31 18:42:12 +02:00
|
|
|
|
|