4 #include "SimulationObject.h"
10 typedef unsigned long long ClockFrequency
;
20 class HardwareSettings
;
23 class Device
: public SimulationObject
{
25 Device(SimulationClock
& clock
, const char *devicename
= 0);
29 void load(const Program
& program
);
30 void addAnalyzers(ScriptEngine
*vm
,
31 const std::list
<const char *> & analyzers
);
34 void setClockFrequency(ClockFrequency frq
);
35 void reset(unsigned int type
);
38 DebugInterface
*debugInterface();
41 // Construction methods for DeviceSettings
42 void buildCore(unsigned int ioSpaceSize
, unsigned int ramSize
,
43 unsigned int flashSize
, unsigned int stackMask
,
44 int pcBytes
= 2, ERam
*eram
= 0);
45 void buildHardware(const char *hwname
, HardwareSettings
& hws
);
46 void addIOReg(unsigned int address
, const std::string
& name
,
47 unsigned char initial
= 0);
48 void addInterrupt(unsigned int vector
, unsigned int address
,
52 static const ClockFrequency defaultFrequency
= 8000000;
62 IntVect(unsigned int addr
, const std::string
& name
)
63 : address(addr
), name(name
) {}
67 std::vector
< IntVect
> intVectors
;
69 friend class DeviceSettings
;