Unofficial Guide To Expanding Your Numworks/Using the simulator

From Wikibooks, open books for an open world
Jump to navigation Jump to search

Windows (Author wanted)[edit | edit source]

OS X (Author wanted)[edit | edit source]

Linux[edit | edit source]

To use the simulator, you'll need a system with X Windows support for the GUI, so before starting have a working Linux system setup with X Windows. You also should have already successfully built the firmware for the calculator itself and this guide assumes you have installed the tools to do so.

Building the simulator[edit | edit source]

  1. Your have first to install clang
    1. On Gentoo and Gentoo based (funtoo, calculate, ...): emerge -v clang
    2. On Debian and Debian based (Ubuntu, ...) apt-get install clang
    3. On Arch Linux sudo pacman -S clang
    4. Others ...
  2. Change to the epsilon directory cd epsilon
  3. make PLATFORM=simulator clean
  4. make PLATFORM=simulator

Using the simulator[edit | edit source]

Once you have finished your build, you will have an executable app.elf. Just run this with ./app.elf You should see an ugly (but functional) version of the Numworks calculator appear on your screen (most likely in French). You can quit by closing the window.

So now that it's running, what to do with it? The great thing about the simulator is that you can debug your applications in it without special hardware. To do this you'll need to rebuild with the debug data:

  1. make PLATFORM=simulator clean
  2. make PLATFORM=simulator DEBUG=1

You can now debug with GDB, or any IDE that supports GDB. gdb ./app.elf will start a command line session of GDB.

For a more intuitive interface, you can try out GDBGUI. This is a python app that gives you a browser based GUI for GDB.