x48ng, a x48 « restomod » - gwh - 10-29-2023 10:02 AM
Hi everyone,
Let me present to you x48ng
I've been working on a fork of x48 for some time now. This fork aims at modernizing the code and the user interface.
I think I have arrived at a state where I've made significant changes (which I think of as improvements) and departed enough from legacy x48 that a proper introduction here makes sense.
The main changes are:
-
a text mode interface. Using ncurses and unicode the LCD can be displayed in the terminal, in three sizes.
- an complete rethink of the command-line options and configuration file
- …many more small things
The Readme has more details and screenshots.
This is for me a pure hobby project, on which I work mainly in bursts of inspiration for the pleasure of it.
Hopefully it's useful to some of you. Have a good day.
EDIT: a « screenshot »:
Code:
┌─[ | ↱ | | | | ]────────────────────────────────────────┐
│⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⢀⡀⠀⠀⡀⡀⣀⡀⡀⠀⡀⣀⡀⠀⠀⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⢺⡀⠀⠀⡗⡇⣇⡇⡏⠊⡇⣗⡂⠀⠀⣸⠂⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠤⠄│
│⡠⢺⠀⢠⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⠉⢹⠁⠰⠆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⡠⠬⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⠠⠤⡃⢘⡃⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⠢⠤⠃⠈⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⠎⢉⠆⢠⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⡔⠁⠀⠰⠆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⢉⡍⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⠀⡇⠀⢘⡃⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⠠⠧⠀⠈⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀│
│⣶⡖⡒⡖⡒⡶⡲⡖⡲⣶⡆⡶⣒⡖⡒⡖⢶⢲⢒⣲⢲⡆⣶⢲⢒⢲⢒⢲⢖⢶⢒⢶⡆⣶⠲⡶⢲⢲⠲⡖⡖⣒⣶⡆⣶⣶⣶⣶⣶⣶⣶⣶⣶⣶⡆⣶⣶⣶⣶⣶⣶⣶⣶⣶⣶⡆│
│⣿⣇⣶⣇⣶⣇⣆⣇⣎⣿⡇⣧⣛⣇⣃⣇⣦⣸⣰⣾⣸⡇⣿⣸⣘⣸⣰⣾⣰⣸⣰⣹⡇⣿⣸⣾⣸⣸⣰⣄⣇⣒⣿⡇⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡇⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣇│
└─[ wire: /dev/pts/3 ]-[ IR: (null) ]──────────────────────────────┘
RE: x48ng, a x48 « restomod » - cruff - 10-29-2023 11:46 AM
Glad to see x48 being worked on, I kept installing it over the years on my Linux systems as I upgraded them. Thanks!
RE: x48ng, a x48 « restomod » - EugeneNine - 10-29-2023 06:03 PM
I've been using x48 for forever also.
I like the idea of a terminal mode
something with lua, what version of lua do you have/use?
Code:
bash-5.1$ make WITH_X11=no WITH_SDL=no
cc -g -O2 -I./src/ -D_GNU_SOURCE=1 -DVERSION_MAJOR=0 -DVERSION_MINOR=33 -DPATCHLEVEL=0 -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=600 -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=600 -DNCURSES_WIDECHAR=1 -c -o src/runtime_options.o src/runtime_options.c
src/runtime_options.c: In function ‘config_read’:
src/runtime_options.c:118:10: warning: implicit declaration of function ‘luaL_loadfilex’; did you mean ‘luaL_loadfile’? [-Wimplicit-function-declaration]
118 | rc = luaL_loadfilex( config_lua_values, filename, "t" );
| ^~~~~~~~~~~~~~
| luaL_loadfile
src/runtime_options.c:119:16: error: ‘LUA_OK’ undeclared (first use in this function); did you mean ‘LUA_QL’?
119 | if ( rc != LUA_OK ) {
| ^~~~~~
| LUA_QL
src/runtime_options.c:119:16: note: each undeclared identifier is reported only once for each function it appears in
make: *** [<builtin>: src/runtime_options.o] Error 1
bash-5.1$
RE: x48ng, a x48 « restomod » - gwh - 10-29-2023 07:22 PM
(10-29-2023 06:03 PM)EugeneNine Wrote: I've been using x48 for forever also.
I like the idea of a terminal mode
something with lua, what version of lua do you have/use?
Code:
bash-5.1$ make WITH_X11=no WITH_SDL=no
cc -g -O2 -I./src/ -D_GNU_SOURCE=1 -DVERSION_MAJOR=0 -DVERSION_MINOR=33 -DPATCHLEVEL=0 -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=600 -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=600 -DNCURSES_WIDECHAR=1 -c -o src/runtime_options.o src/runtime_options.c
src/runtime_options.c: In function ‘config_read’:
src/runtime_options.c:118:10: warning: implicit declaration of function ‘luaL_loadfilex’; did you mean ‘luaL_loadfile’? [-Wimplicit-function-declaration]
118 | rc = luaL_loadfilex( config_lua_values, filename, "t" );
| ^~~~~~~~~~~~~~
| luaL_loadfile
src/runtime_options.c:119:16: error: ‘LUA_OK’ undeclared (first use in this function); did you mean ‘LUA_QL’?
119 | if ( rc != LUA_OK ) {
| ^~~~~~
| LUA_QL
src/runtime_options.c:119:16: note: each undeclared identifier is reported only once for each function it appears in
make: *** [<builtin>: src/runtime_options.o] Error 1
bash-5.1$
Here I have lua 5.4.6
EDIT: I just pushed a commit to the main branch that might solve your two errors. I can't really test quickly with an older lua (I suspect you have 5.1.x) but I hope it works for you.
RE: x48ng, a x48 « restomod » - EugeneNine - 10-31-2023 07:00 PM
Yes, I have the old 5.1
I miss the old C64 ACSII (petscii) where we had characters that were 1/4 size so we could make tui smaller
here is a pic of old and new side by side
RE: x48ng, a x48 « restomod » - gwh - 11-02-2023 09:16 AM
(10-31-2023 07:00 PM)EugeneNine Wrote: Yes, I have the old 5.1
I miss the old C64 ACSII (petscii) where we had characters that were 1/4 size so we could make tui smaller
here is a pic of old and new side by side
Thank you for your helpful feedback.
Have you tried x48ng --tui --small or x48ng --tui --tiny --mono ?
Both variants use unicode characters to display multiple pixels per character.
RE: x48ng, a x48 « restomod » - EugeneNine - 11-03-2023 12:30 AM
Ahh yes, I failed to RTFM.
Works on arm, this is on a BeagleBone Black
RE: x48ng, a x48 « restomod » - raprism - 06-09-2024 01:01 PM
To get some more experience on historic 48+ calcs I tried to use Emu48 and x49gp.
But finally I was glad to have found x48ng, because e.g. I have tinkered around how to get a proper resolution of the X application x49gp on wayland compositor running PCs (although for Emu48 and wine not a problem ...)
With x48ng it worked to get a usable emulator with easy setup of roms, and readability on a high res screen. (FYI on arch I had to install sdl_gfx for compilation.)
This call works to get a scaled window:
Code:
SDL_VIDEODRIVER=wayland x48ng --sdl
RE: x48ng, a x48 « restomod » - gwh - 06-12-2024 09:02 AM
(06-09-2024 01:01 PM)raprism Wrote: To get some more experience on historic 48+ calcs I tried to use Emu48 and x49gp.
But finally I was glad to have found x48ng, because e.g. I have tinkered around how to get a proper resolution of the X application x49gp on wayland compositor running PCs (although for Emu48 and wine not a problem ...)
With x48ng it worked to get a usable emulator with easy setup of roms, and readability on a high res screen. (FYI on arch I had to install sdl_gfx for compilation.)
This call works to get a scaled window:
Code:
SDL_VIDEODRIVER=wayland x48ng --sdl
It's encouraging to see my project be useful out there, thank you.
Regarding Arch, another kind user is maintaining packages https://aur.archlinux.org/packages/x48ng (and bleeding edge https://aur.archlinux.org/packages/x48ng-git too)
I'm very glad you find it useful!
|