Skip to content

Commit 8d134ae

Browse files
committed
build
1 parent 9f1d4b1 commit 8d134ae

File tree

7 files changed

+44
-28
lines changed

7 files changed

+44
-28
lines changed

README.md

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -3,25 +3,3 @@ This is a **modified** version of the Casio emulator developed by [qiufuyu](http
33
Files are modified so that they can work on windows.
44

55
Note that ROMs are **not** included in the `models` folder (for copyright reasons), you have to obtain one from somewhere else or dump it from a real calculator or emulator. (note that models labeled with `_emu` are for ROMs dumped from official emulators)
6-
7-
8-
# CasioEmuX-win
9-
10-
An emulator and disassembler for the CASIO calculator series using the nX-U8/100 core.
11-
With debuggers.
12-
13-
To build it, install tdm-gcc and run build.bat
14-
15-
syntax:
16-
17-
`casioemu key1=value1 key2=value2 ...`
18-
19-
`model=<directory>` model directory, which should contain interface.png, model.lua, rom.bin(you can find it elsewhere) and _disas.txt(use disas-cpp on rom.bin to obtain this file)
20-
21-
these arguments are optional:
22-
23-
`script=<xxx.lua>` the supplied lua script will run on startup
24-
25-
`exit_on_console_shutdown=true/false` pretty self-evident, default to false
26-
27-
`history=<history file path>` input history

emulator/README.md

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,22 @@
11
# Emulator
2-
a version ported to windows
3-
run build.bat to build it, if you are using 32-bit system, then you need to change the libraries in build.bat to the correspoding 32 bit versions
4-
the dlls needed by the program is in the dlls directory
2+
3+
An emulator and disassembler for the CASIO calculator series using the nX-U8/100 core ported to windows.
4+
With debuggers.
5+
6+
To build it, install tdm-gcc and run build32.bat or build64.bat (depending on your machine's architecture).
7+
8+
The dlls needed by the program (SDL2.dll, SDL2_image.dll) are in the `dlls` directory.
9+
10+
## Syntax
11+
12+
`casioemu <key1>=<value1> <key2>=<value2> ...`
13+
14+
`model=<directory>` model directory, which should contain interface.png, model.lua, rom.bin(you can find it elsewhere) and _disas.txt(use disas-cpp on rom.bin to obtain this file)
15+
16+
these arguments are optional:
17+
18+
`script=<xxx.lua>` the supplied lua script will run on startup
19+
20+
`exit_on_console_shutdown=true/false` pretty self-evident, default to false
21+
22+
`history=<history file path>` the file that stores your input history

emulator/build32.bat

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
@pushd %~dp0%
2+
3+
@set include=-I"libs\SDL2-2.26.4\i686-w64-mingw32\include\SDL2" -I"libs\SDL2_image-2.6.3\i686-w64-mingw32\include\SDL2" -I"libs\lua-5.3.6\include" -I"libs\wineditline-2.206\include"
4+
5+
@set compiler=%include% -Wall -pedantic -std=c++2a -O2
6+
7+
@set linker=-L"libs\SDL2-2.26.4\i686-w64-mingw32\lib" -L"libs\SDL2_image-2.6.3\i686-w64-mingw32\lib" -L"libs\lua-5.3.6" -L"libs\wineditline-2.206\lib32"
8+
@set linker=%linker% -lmingw32 -lSDL2main -lSDL2 -lSDL2_image -llua53_32bit -ledit_static
9+
10+
@set files=src\casioemu.cpp src\Emulator.cpp src\Logger.cpp
11+
@set files=%files% src\Chipset\CPU.cpp src\Chipset\CPUPushPop.cpp src\Chipset\MMURegion.cpp src\Chipset\CPUControl.cpp src\Chipset\CPUArithmetic.cpp src\Chipset\CPULoadStore.cpp src\Chipset\Chipset.cpp src\Chipset\MMU.cpp src\Chipset\InterruptSource.cpp
12+
@set files=%files% src\Peripheral\BatteryBackedRAM.cpp src\Peripheral\Peripheral.cpp src\Peripheral\Keyboard.cpp src\Peripheral\Screen.cpp src\Peripheral\Timer.cpp src\Peripheral\StandbyControl.cpp src\Peripheral\ROMWindow.cpp src\Peripheral\Miscellaneous.cpp
13+
@set files=%files% src\Gui\CodeViewer.cpp src\Gui\Command.cpp src\Data\ModelInfo.cpp
14+
@set files=%files% src\Gui\imgui\imgui_impl_sdl2.cpp src\Gui\imgui\imgui_impl_sdlrenderer2.cpp src\Gui\imgui\imgui.cpp src\Gui\imgui\imgui_widgets.cpp src\Gui\imgui\imgui_tables.cpp src\Gui\imgui\imgui_draw.cpp
15+
16+
@set output_exe=casioemu32.exe
17+
18+
g++ %compiler% %files% %linker% -m32 -o %output_exe%
19+
20+
@popd

emulator/build.bat renamed to emulator/build64.bat

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
@set include=-I"libs\SDL2-2.26.4\x86_64-w64-mingw32\include\SDL2" -I"libs\SDL2_image-2.6.3\x86_64-w64-mingw32\include\SDL2" -I"libs\lua-5.3.6\include" -I"libs\wineditline-2.206\include"
44

5-
@set compiler=%include% -Wall -pedantic -std=c++2a
5+
@set compiler=%include% -Wall -pedantic -std=c++2a -O2
66

77
@set linker=-L"libs\SDL2-2.26.4\x86_64-w64-mingw32\lib" -L"libs\SDL2_image-2.6.3\x86_64-w64-mingw32\lib" -L"libs\lua-5.3.6" -L"libs\wineditline-2.206\lib64"
88
@set linker=%linker% -lmingw32 -lSDL2main -lSDL2 -lSDL2_image -llua53 -ledit_static
@@ -13,8 +13,8 @@
1313
@set files=%files% src\Gui\CodeViewer.cpp src\Gui\Command.cpp src\Data\ModelInfo.cpp
1414
@set files=%files% src\Gui\imgui\imgui_impl_sdl2.cpp src\Gui\imgui\imgui_impl_sdlrenderer2.cpp src\Gui\imgui\imgui.cpp src\Gui\imgui\imgui_widgets.cpp src\Gui\imgui\imgui_tables.cpp src\Gui\imgui\imgui_draw.cpp
1515

16-
@set output_exe=casioemu.exe
16+
@set output_exe=casioemu64.exe
1717

18-
g++ %compiler% %files% %linker% -O2 -o %output_exe%
18+
g++ %compiler% %files% %linker% -m64 -o %output_exe%
1919

2020
@popd

emulator/dlls/32bit/SDL2.dll

2.19 MB
Binary file not shown.

emulator/dlls/32bit/SDL2_image.dll

854 KB
Binary file not shown.
322 KB
Binary file not shown.

0 commit comments

Comments
 (0)