Added CPU related stuff.

- Added CPU stuff (src/devices/cpu.cc)
- Fixed some weird things on console driver (src/devices/console.cc)