11 * @brief Static ram inside the AVR chip.
13 * The static ram inside the chip, provides an interface
14 * for reading and writing. This interface is used by the MMU.
16 class SRam
: public Memory
{
18 SRam(unsigned int size
);
22 * Reads a single bytes of raw data from memory at
25 * \exception AccessViolation { When the data requested is
26 * not available, this exception is thrown }
28 void writeByte(unsigned int offset
, byte val
);
31 * Reads a word of raw data from memory starting at
34 * \exception AccessViolation { When the data requested is
35 * not available, this exception is thrown }
37 void writeWord(unsigned int offset
, word val
);
40 inline SRam::SRam(unsigned int size
) : Memory(size
) {
44 inline void SRam::writeByte(unsigned int offset
, byte val
) {
45 write(offset
, &val
, 1);
48 inline void SRam::writeWord(unsigned int offset
, word val
) {
49 write(offset
, (unsigned char *)&val
, 2);