T32: Memory access.
Still not tested on real T32. git-svn-id: https://www4.informatik.uni-erlangen.de/i4svn/danceos/trunk/devel/fail@2105 8c4709b5-6ec9-48aa-a5cd-a96041d1645a
This commit is contained in:
@ -32,6 +32,18 @@ bool VEZSExperiment::run()
|
||||
m_log << "Register R1: 0x" << hex << simulator.getCPU(0).getRegisterContent(reg) << endl;
|
||||
|
||||
simulator.getCPU(0).setRegisterContent(reg, 0x23);
|
||||
|
||||
address_t targetaddress = 0x12345678;
|
||||
MemoryManager& mm = simulator.getMemoryManager();
|
||||
mm.setByte(targetaddress, 0x42);
|
||||
mm.getByte(targetaddress);
|
||||
|
||||
uint8_t tb[] = {0xaa, 0xbb, 0xcc, 0xdd};
|
||||
mm.setBytes(targetaddress, 4, tb);
|
||||
*((uint32_t*)(tb)) = 0; // clear array.
|
||||
// read back bytes
|
||||
mm.getBytes(targetaddress, 4, tb);
|
||||
|
||||
// Explicitly terminate, or the simulator will continue to run.
|
||||
simulator.terminate();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user