Simple Terminal Emulator for embedded Linux handhelds, migrated from SDL1.2 to SDL2 (by haoict)
For generic linux:
sudo apt install build-essential libsdl2-dev libsdl2-ttf-dev
make./simple-terminal
./simple-terminal -font 2 # with alternative embedded font
./simple-terminal -scale 1 -font /path/to/font.ttf -fontsize 12 -fontshade 1 # with a ttf font
# rotate content inside the window (0|90|180|270)
./simple-terminal -rotate 90
./simple-terminal -rotate 270
# run commands when open
./simple-terminal -r "ls -la" "uname -a" whoami- -scale: scale factor for window sizing (e.g.,
-scale 2.0). - -font: embedded font id (
1..5) or path to a TTF file. - -fontsize: TTF font size when using
-font /path/to.ttf. - -fontshade: TTF render mode (
0solid,1blended,2shaded). - -rotate: rotate the rendered content only (
0|90|180|270). For90and270, characters and on-screen keyboard are rotated while window size stays the same. - -r: run one or more commands in the terminal on start.
- -q: quiet mode.
Simple Terminal supports scrollback history to review previous output:
- Buffer size: 256 lines by default (configurable in
src/config.hviascrollback_lines) - Scroll up: Press
F8(PC) orL2(handhelds, with OSK deactivated) to scroll up - Scroll down: Press
F7(PC) orR2(handhelds, with OSK deactivated) to scroll down - Scroll indicator: When scrolled, a
[offset]^indicator appears in the top-right corner - Auto-reset: Any key press (except scroll keys) returns to the bottom of the buffer
you can build everything for the target device with buildroot:
https://github.com/haoict/TiniLinux/blob/master/README.md#build
or build the toolchain only and build simple-terminal separately
# build toolchain
cd TiniLinux
./make-board-build.sh configs/toolchain_x86_64_aarch64_defconfig
cd output.toolchain_x86_64_aarch64
make -j $(nproc)
# build simple-terminal
cd SimpleTerminal
export CROSS_COMPILE=/home/haoict/TiniLinux/output.toolchain_x86_64_aarch64/host/bin/aarch64-none-linux-gnu-
makehttps://simple-terminal-psi.vercel.app
MIT License
Based on Aurélien APTEL bt source code.
https://github.com/benob/rs97_st-sdl



