mirror of
https://github.com/trholding/llama2.c.git
synced 2026-02-06 11:26:53 +00:00
L2E OS v0.1 "Temple DOS" Release + Various Improvements
L2E OS v0.1 "Temple DOS" Release. Various Improvements. Major Makefile overhaul.
This commit is contained in:
parent
733a625b29
commit
ae8ea66eda
14
.gitignore
vendored
14
.gitignore
vendored
@ -12,3 +12,17 @@ model.h
|
||||
UNIK/
|
||||
build/
|
||||
stories15M.bin
|
||||
l2e_boot/linux/
|
||||
l2e_boot/musl/
|
||||
l2e_boot/musl_build/
|
||||
l2e_boot/toybox/
|
||||
l2e_boot/kernel_headers/
|
||||
l2e_boot/busybox/
|
||||
l2e_boot/ISO/
|
||||
l2e_boot/l2eos.iso
|
||||
l2e_boot/limine/
|
||||
l2e_boot/fbDOOM/
|
||||
l2e_boot/l2e_sources/l2eterm/lvgl/
|
||||
l2e_boot/l2e_sources/l2eterm/lv_drivers/
|
||||
assets/l2ebg.svg
|
||||
assets/LAIRS.svg
|
||||
|
||||
11
CITATION.cff
Normal file
11
CITATION.cff
Normal file
@ -0,0 +1,11 @@
|
||||
cff-version: 1.2.0
|
||||
message: "If you use this software, please cite it as below."
|
||||
authors:
|
||||
- family-names: "Ignis"
|
||||
given-names: "Vulcan"
|
||||
orcid: "https://orcid.org/0009-0006-6872-9262"
|
||||
title: "L2E OS"
|
||||
version: v0.1
|
||||
doi: 10.5281/zenodo.8330450
|
||||
date-released: 2017-12-18
|
||||
url: "https://github.com/trholding/llama2.c"
|
||||
@ -1,8 +1,8 @@
|
||||
#
|
||||
# Automatically generated file; DO NOT EDIT.
|
||||
# Unikraft/0.14.0~245a6829 Configuration
|
||||
# Unikraft/0.14.0~70bc0af0 Configuration
|
||||
#
|
||||
CONFIG_UK_FULLVERSION="0.14.0~245a6829"
|
||||
CONFIG_UK_FULLVERSION="0.14.0~70bc0af0"
|
||||
CONFIG_UK_CODENAME="Prometheus"
|
||||
CONFIG_UK_ARCH="x86_64"
|
||||
CONFIG_UK_DEFNAME="L2E"
|
||||
@ -78,6 +78,7 @@ CONFIG_KVM_MAX_IRQ_HANDLER_ENTRIES=8
|
||||
#
|
||||
# end of Virtio
|
||||
|
||||
CONFIG_UKPLAT_ALLOW_GIC=y
|
||||
# CONFIG_PLAT_LINUXU is not set
|
||||
# CONFIG_PLAT_XEN is not set
|
||||
|
||||
@ -95,16 +96,6 @@ CONFIG_UKPLAT_LCPU_MAXCOUNT=1
|
||||
CONFIG_HZ=100
|
||||
# end of Platform Configuration
|
||||
|
||||
#
|
||||
# Device Drivers
|
||||
#
|
||||
|
||||
#
|
||||
# Interrupt controller
|
||||
#
|
||||
# end of Interrupt controller
|
||||
# end of Device Drivers
|
||||
|
||||
#
|
||||
# Library Configuration
|
||||
#
|
||||
@ -216,7 +207,6 @@ CONFIG_LIBUKDEBUG_PRINT_SRCNAME=y
|
||||
# CONFIG_LIBUKDEBUG_TRACEPOINTS is not set
|
||||
# CONFIG_LIBUKFALLOC is not set
|
||||
# CONFIG_LIBUKFALLOCBUDDY is not set
|
||||
CONFIG_LIBUKINTCTLR=y
|
||||
CONFIG_LIBUKLIBID=y
|
||||
# CONFIG_LIBUKLIBPARAM is not set
|
||||
CONFIG_LIBUKLOCK=y
|
||||
|
||||
439
Makefile
439
Makefile
@ -4,6 +4,11 @@ BLIS_PREFIX = /usr/local
|
||||
BLIS_INC = $(BLIS_PREFIX)/include/blis
|
||||
BLIS_LIB = $(BLIS_PREFIX)/lib/libblis.a
|
||||
|
||||
|
||||
#OpenBLAS
|
||||
OPENBLAS_PREFIX = /usr/include
|
||||
OPENBLAS_INC = $(OPENBLAS_PREFIX)/openblas
|
||||
|
||||
# Model / Tokenizer Paths
|
||||
MOD_PATH = out/model.bin
|
||||
TOK_PATH = tokenizer.bin
|
||||
@ -17,15 +22,16 @@ TOK_PATH = tokenizer.bin
|
||||
|
||||
CC = gcc
|
||||
|
||||
# the most basic way of building that is most likely to work on most systems
|
||||
.PHONY: run
|
||||
run: run.c
|
||||
$(CC) -O3 -o run run.c -lm
|
||||
##@ Simple Builds
|
||||
|
||||
# useful for a debug build, can then e.g. analyze with valgrind, example:
|
||||
# $ valgrind --leak-check=full ./run out/model.bin -n 3
|
||||
rundebug: run.c
|
||||
$(CC) -g -o run run.c -lm
|
||||
# the most basic way of building that is most likely to work on most systems
|
||||
|
||||
.PHONY: run
|
||||
run: run_cc
|
||||
|
||||
.PHONY: run_cc
|
||||
run_cc: ## - Standard build with basic optimizations
|
||||
$(CC) -O3 -o run run.c -lm
|
||||
|
||||
# https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html
|
||||
# https://simonbyrne.github.io/notes/fastmath/
|
||||
@ -36,99 +42,120 @@ rundebug: run.c
|
||||
# -fstack-arrays, unless -fmax-stack-var-size is specified, and -fno-protect-parens.
|
||||
# It turns off -fsemantic-interposition.
|
||||
# In our specific application this is *probably* okay to use
|
||||
.PHONY: runfast
|
||||
runfast: run.c
|
||||
.PHONY: run_cc_fast
|
||||
run_cc_fast: ## - More Optimized build. Disregards strict standards compliance
|
||||
$(CC) -Ofast -o run run.c -lm
|
||||
|
||||
# compiles with gnu99 standard flags for amazon linux, coreos, etc. compatibility
|
||||
.PHONY: run_cc_gnu
|
||||
run_cc_gnu: ## - Optimized Generic linux distro build
|
||||
$(CC) -Ofast -std=gnu11 -o run run.c -lm
|
||||
|
||||
##@ Accelerated Builds
|
||||
|
||||
# additionally compiles with OpenMP, allowing multithreaded runs
|
||||
# make sure to also enable multiple threads when running, e.g.:
|
||||
# OMP_NUM_THREADS=4 ./run out/model.bin
|
||||
.PHONY: run_cc_openmp
|
||||
run_cc_openmp: run.c
|
||||
$(CC) -D OPENMP -Ofast -fopenmp -foffload-options="-Ofast -lm" -march=native run.c -lm -o run
|
||||
run_cc_openmp: ## - OpenMP accelerated build
|
||||
$(CC) -D OPENMP -Ofast -fopenmp -march=native run.c -lm -o run
|
||||
|
||||
.PHONY: run_cc_openacc
|
||||
run_cc_openacc: run.c
|
||||
$(CC) -D OPENACC -Ofast -fopenacc -foffload-options="-Ofast -lm" -march=native run.c -lm -o run
|
||||
run_cc_openacc: ## - OpenACC accelerated build
|
||||
$(CC) -D OPENACC -Ofast -fopenacc -march=native run.c -lm -o run
|
||||
|
||||
.PHONY: win64
|
||||
win64:
|
||||
x86_64-w64-mingw32-gcc -Ofast -D_WIN32 -o run.exe -I. run.c win.c
|
||||
|
||||
# compiles with gnu99 standard flags for amazon linux, coreos, etc. compatibility
|
||||
.PHONY: rungnu
|
||||
rungnu:
|
||||
$(CC) -Ofast -std=gnu11 -o run run.c -lm
|
||||
|
||||
.PHONY: runompgnu
|
||||
runompgnu:
|
||||
$(CC) -Ofast -fopenmp -std=gnu11 run.c -lm -o run
|
||||
.PHONY: run_cc_omp_gnu
|
||||
run_cc_omp_gnu: ## - Generic linux distro + OpenMP build
|
||||
$(CC) -D OPENMP -Ofast -fopenmp -std=gnu11 run.c -lm -o run
|
||||
|
||||
.PHONY: run_cc_clblast
|
||||
run_cc_clblast: run.c
|
||||
$(CC) -D CLBLAST -Ofast -fopenmp -march=native run.c -lm -lclblast -o run
|
||||
run_cc_clblast: ## - CLBlast OpenCL CBLAS GPU accelerated build
|
||||
$(CC) -D OPENMP -D CLBLAST -Ofast -fopenmp -march=native run.c -lm -lclblast -o run
|
||||
|
||||
.PHONY: run_cc_openblas
|
||||
run_cc_openblas: run.c
|
||||
$(CC) -D OPENBLAS -Ofast -fopenmp -march=native run.c -lm -lopenblas -o run
|
||||
run_cc_openblas: ## - Openblas CBLAS accelerated build
|
||||
$(CC) -D OPENMP -D OPENBLAS -Ofast -fopenmp -march=native -I$(OPENBLAS_INC) run.c -lm -lopenblas -o run
|
||||
|
||||
.PHONY: run_cc_cblas
|
||||
run_cc_cblas: run.c
|
||||
run_cc_cblas: ## - Generic CBLAS accelerated build
|
||||
$(CC) -D CBLAS -Ofast -fopenmp -march=native run.c -lm -lcblas -o run
|
||||
|
||||
.PHONY: run_cc_blis
|
||||
run_cc_blis: run.c
|
||||
run_cc_blis: ## - BLIS accelerated build
|
||||
$(CC) -D BLIS -Ofast -fopenmp -march=native -I$(BLIS_INC) run.c -lm -lblis -o run
|
||||
|
||||
.PHONY: run_cc_armpl
|
||||
run_cc_armpl: run.c
|
||||
$(CC) -D ARMPL -Ofast -fopenmp -march=native run.c -lm -larmpl_lp64_mp -o run
|
||||
|
||||
# amd64 (x86_64) / intel mac (WIP) Do not use!
|
||||
##@ Special Builds
|
||||
|
||||
##@ ---> x86_64
|
||||
|
||||
# amd64 (x86_64) / Intel Mac (WIP) Do not use!
|
||||
|
||||
.PHONY: run_cc_mkl
|
||||
run_cc_mkl: run.c
|
||||
$(CC) -D MKL -Ofast -fopenmp -march=native run.c -lm -lblis -o run
|
||||
run_cc_mkl: ## - OpenMP + Intel MKL CBLAS build (x86_64 / intel Mac) (WIP)
|
||||
$(CC) -D MKL -D OPENMP -Ofast -fopenmp -march=native run.c -lm -lblis -o run
|
||||
|
||||
##@ ---> ARM64 / aarch64
|
||||
|
||||
.PHONY: run_cc_armpl
|
||||
run_cc_armpl: ## - ARM PL BLAS accelerated build (ARM64 & Mac) (WIP)
|
||||
$(CC) -D ARMPL -D OPENMP -Ofast -fopenmp -march=native run.c -lm -larmpl_lp64_mp -o run
|
||||
|
||||
##@ ---> Macintosh
|
||||
|
||||
.PHONY: run_cc_mac_accel
|
||||
runaccel: run.c
|
||||
$(CC) -D AAF -Ofast -fopenmp -march=native run.c -lm -framework Accelerate -o run
|
||||
run_cc_mac_accel: ## - Mac OS OPENMP + CBLAS via Accelerate Framework build (WIP/TEST)
|
||||
$(CC) -D AAF -D OPENMP -Ofast -fopenmp -march=native run.c -lm -framework Accelerate -o run
|
||||
|
||||
##@ ---> Windows
|
||||
|
||||
.PHONY: run_win64
|
||||
run_win: ## - Optimized Windows build with MinGW-w64 toolchain
|
||||
x86_64-w64-mingw32-gcc -Ofast -D_WIN32 -o run.exe -I. run.c win.c
|
||||
|
||||
.PHONY: run_win_msvc
|
||||
run_win_msvc: ## - OpenMP accelerated Windows build with MSVC toolchain (Untested)
|
||||
cl.exe /fp:fast /Ox /DOPENMP /openmp /I. run.c win.c
|
||||
|
||||
##@ ---> MultiOS Builds (using cosmopolitan libc + toolchain)
|
||||
|
||||
# Cosmocc
|
||||
|
||||
.PHONY: run_cosmocc
|
||||
run_cosmocc: run.c
|
||||
run_cosmocc: ## - Optimized Portable + cosmocc (runs on all OSes)
|
||||
cosmocc -Ofast -D COSMO_BLINK -D COSMO_METAL run.c -lm -o run.com
|
||||
|
||||
##@ ---> MultiOS Builds ---> with Embedded Models
|
||||
|
||||
# Cosmocc + embedded model & tokenizer
|
||||
|
||||
.PHONY: run_cosmocc_zipos
|
||||
run_cosmocc_zipos: run.c
|
||||
run_cosmocc_zipos: ## - Optimized Portable + cosmocc + embedded zip model build (runs on all OSes)
|
||||
cosmocc -Ofast -D COSMO_BLINK -D COSMO_METAL -D COSMO_ZIP run.c -lm -o run.com
|
||||
zip run.com $(MOD_PATH)
|
||||
zip run.com $(TOK_PATH)
|
||||
|
||||
.PHONY: run_cosmocc_incbin
|
||||
run_cosmocc_incbin:
|
||||
run_cosmocc_incbin: ## - Optimized Portable + cosmocc + embedded model fast build (runs on all OSes)
|
||||
cosmocc -Ofast -D COSMO_BLINK -D COSMO_METAL -D INC_BIN -D MODPATH=$(MOD_PATH) -D TOKPATH=$(TOK_PATH) -D LLOOP run.c -lm -o run.com
|
||||
|
||||
.PHONY: run_cosmocc_strlit
|
||||
run_cosmocc_strlit: run.c
|
||||
# Uses https://github.com/mortie/strliteral to embed files
|
||||
run_cosmocc_strlit: ## - Optimized Portable + cosmocc + embedded model build (runs on all OSes)
|
||||
gcc -Ofast strliteral.c -o strlit
|
||||
./strlit -i emb_Model_data $(MOD_PATH) model.h
|
||||
./strlit -i emb_Tokenizer_data $(TOK_PATH) tokenizer.h
|
||||
cosmocc -Ofast -D COSMO_BLINK -D COSMO_METAL -D STRLIT -D LLOOP run.c -lm -o run.com
|
||||
|
||||
##@ ---> GCC/Clang Embedded Model Builds
|
||||
|
||||
# GCC OpenMP + embedded model & tokenizer
|
||||
|
||||
.PHONY: run_gcc_openmp_incbin
|
||||
run_gcc_openmp_incbin: run.c
|
||||
run_gcc_openmp_incbin: ## - Gcc + OpenMP + embedded model fast build
|
||||
gcc -D OPENMP -Ofast -fopenmp -foffload-options="-Ofast -lm" -march=native -D INC_BIN -D MODPATH=$(MOD_PATH) -D TOKPATH=$(TOK_PATH) -D LLOOP run.c -lm -o run
|
||||
|
||||
.PHONY: run_gcc_openmp_strlit
|
||||
run_gcc_openmp_strlit: run.c
|
||||
# Uses https://github.com/mortie/strliteral to embed files
|
||||
run_gcc_openmp_strlit: ## - Gcc + OpenMP + embedded model build
|
||||
gcc -Ofast strliteral.c -o strlit
|
||||
./strlit -i emb_Model_data $(MOD_PATH) model.h
|
||||
./strlit -i emb_Tokenizer_data $(TOK_PATH) tokenizer.h
|
||||
@ -137,26 +164,26 @@ run_gcc_openmp_strlit: run.c
|
||||
# Clang OpenMP + embedded model & tokenizer
|
||||
|
||||
.PHONY: run_clang_openmp_incbin
|
||||
run_clang_openmp_incbin: run.c
|
||||
run_clang_openmp_incbin: ## - Clang + OpenMP + embedded model fast build
|
||||
clang -D OPENMP -Ofast -fopenmp -march=native -D INC_BIN -D MODPATH=$(MOD_PATH) -D TOKPATH=$(TOK_PATH) -D LLOOP run.c -lm -o run
|
||||
|
||||
.PHONY: run_clang_openmp_strlit
|
||||
run_clang_openmp_strlit: run.c
|
||||
# Uses https://github.com/mortie/strliteral to embed files
|
||||
run_clang_openmp_strlit: ## - Clang + OpenMP + embedded model build
|
||||
clang -Ofast strliteral.c -o strlit
|
||||
./strlit -i emb_Model_data $(MOD_PATH) model.h
|
||||
./strlit -i emb_Tokenizer_data $(TOK_PATH) tokenizer.h
|
||||
clang -D OPENMP -Ofast -fopenmp -march=native -D STRLIT -D LLOOP run.c -lm -o run
|
||||
|
||||
##@ ---> GCC/Clang Embedded Model Builds ---> Statically Linked
|
||||
|
||||
# GCC static + embedded model & tokenizer
|
||||
|
||||
.PHONY: run_gcc_static_incbin
|
||||
run_gcc_static_incbin: run.c
|
||||
run_gcc_static_incbin: ## - Optimized Static gcc + embedded model fast build
|
||||
gcc -Ofast -static -march=native -D INC_BIN -D MODPATH=$(MOD_PATH) -D TOKPATH=$(TOK_PATH) -D LLOOP run.c -lm -o run
|
||||
|
||||
.PHONY: run_gcc_static_strlit
|
||||
run_gcc_static_strlit: run.c
|
||||
# Uses https://github.com/mortie/strliteral to embed files
|
||||
run_gcc_static_strlit: ## - Optimized Static gcc + embedded model build
|
||||
gcc -Ofast strliteral.c -o strlit
|
||||
./strlit -i emb_Model_data $(MOD_PATH) model.h
|
||||
./strlit -i emb_Tokenizer_data $(TOK_PATH) tokenizer.h
|
||||
@ -165,68 +192,306 @@ run_gcc_static_strlit: run.c
|
||||
# Clang static + embedded model & tokenizer
|
||||
|
||||
.PHONY: run_clang_static_incbin
|
||||
run_clang_static_incbin: run.c
|
||||
run_clang_static_incbin: ## - Optimized Static clang + embedded model fast build
|
||||
clang -Ofast -static -march=native -D INC_BIN -D MODPATH=$(MOD_PATH) -D TOKPATH=$(TOK_PATH) -D LLOOP run.c -lm -o run
|
||||
|
||||
.PHONY: run_clang_static_strlit
|
||||
run_clang_static_strlit: run.c
|
||||
# Uses https://github.com/mortie/strliteral to embed files
|
||||
run_clang_static_strlit: ## - Optimized Static clang + embedded model build
|
||||
clang -Ofast strliteral.c -o strlit
|
||||
./strlit -i emb_Model_data $(MOD_PATH) model.h
|
||||
./strlit -i emb_Tokenizer_data $(TOK_PATH) tokenizer.h
|
||||
clang -Ofast -static -march=native -D STRLIT -D LLOOP run.c -lm -o run
|
||||
|
||||
# Unikraft Unikernel build
|
||||
|
||||
.PHONY: run_unik_qemu_x86_64
|
||||
run_unik_qemu_x86_64: run.c
|
||||
[ ! -d "UNIK" ] && echo "Cloning unikraft and musl sources..." || true
|
||||
[ ! -d "UNIK/unikraft" ] && git clone https://github.com/unikraft/unikraft UNIK/unikraft || true
|
||||
[ ! -d "UNIK/libs/musl" ] && git clone https://github.com/unikraft/lib-musl UNIK/libs/musl || true
|
||||
make -f Makefile.unikernel
|
||||
|
||||
# Build for termux on Android
|
||||
##@ ---> Android
|
||||
|
||||
.PHONY: run_incbin
|
||||
run_incbin: run.c
|
||||
[ ! -d "out/" ] && echo "Downloading model..." || true
|
||||
[ ! -d "out/" ] && wget https://huggingface.co/karpathy/tinyllamas/resolve/main/stories15M.bin || true
|
||||
[ ! -d "out/" ] && mkdir out || true
|
||||
[ -f "stories15M.bin" ] && mv stories15M.bin out/model.bin || true
|
||||
.PHONY: run_incbin_tmux
|
||||
run_incbin_tmux: get_model ## - Optimized build + Embedded Model for Termux on Android
|
||||
$(CC) -Ofast -D INC_BIN -D MODPATH=$(MOD_PATH) -D TOKPATH=$(TOK_PATH) -o run run.c -lm
|
||||
|
||||
# run all tests
|
||||
##@ ---> L2E Unikernel (Asteroid)
|
||||
# Unikraft Unikernel build
|
||||
|
||||
.PHONY: l2e_unik_qemu
|
||||
l2e_unik_qemu: get_model ## - L2E Unikernel (Asteroid) for kvm / qemu x86_64
|
||||
if [ ! -d "UNIK" ]; then echo "Cloning unikraft 0.14.0 and musl sources..." ; fi
|
||||
if [ ! -d "UNIK/unikraft" ]; then git clone -b RELEASE-0.14.0 --single-branch https://github.com/unikraft/unikraft UNIK/unikraft ; fi
|
||||
if [ ! -d "UNIK/libs/musl" ]; then git clone -b RELEASE-0.14.0 --single-branch https://github.com/unikraft/lib-musl UNIK/libs/musl ; fi
|
||||
make -f Makefile.unikernel
|
||||
|
||||
##@ ---> L2E Unikernel (Asteroid) ---> Boot in qemu
|
||||
.PHONY: boot_l2e_unik
|
||||
boot_l2e_unik: ## - Boot L2E Unikernel (Asteroid) in qemu
|
||||
qemu-system-x86_64 -m 512m --accel kvm --kernel build/L2E_qemu-x86_64 --serial stdio
|
||||
|
||||
##@ ---> L2E OS (Humanoid)
|
||||
# L2E OS - OS based on linux kernel
|
||||
.PHONY: l2e_os
|
||||
l2e_os: get_model tempclean ## - L2E OS, kernel module and userspace build
|
||||
if [ ! -d "l2e_boot/linux" ]; then echo "Cloning linux v6.5 sources..." ;\
|
||||
git clone -b v6.5 --single-branch https://github.com/torvalds/linux.git l2e_boot/linux ;\
|
||||
fi
|
||||
|
||||
if [ ! -d "l2e_boot/musl" ]; then echo "Cloning musl v1.2.4 sources..." ;\
|
||||
git clone -b v1.2.4 --single-branch git://git.musl-libc.org/musl l2e_boot/musl ;\
|
||||
fi
|
||||
|
||||
if [ ! -d "l2e_boot/toybox" ]; then echo "Cloning toybox 0.8.10 sources..." ;\
|
||||
git clone -b 0.8.10 --single-branch https://github.com/landley/toybox.git l2e_boot/toybox ;\
|
||||
fi
|
||||
|
||||
if [ ! -d "l2e_boot/busybox" ]; then echo "Cloning busybox 1_36_stable (1.36.1) sources..." ;\
|
||||
git clone -b 1_36_stable --depth 1 https://git.busybox.net/busybox l2e_boot/busybox ;\
|
||||
fi
|
||||
|
||||
if [ ! -d "l2e_boot/fbDOOM" ]; then echo "Cloning fbDOOM..." ;\
|
||||
git clone --depth 1 https://github.com/maximevince/fbDOOM.git l2e_boot/fbDOOM ;\
|
||||
echo "Downloading Freedoom 0.12.1 WADs" ;\
|
||||
cd l2e_boot/fbDOOM ;\
|
||||
if [ -x "`which jar 2>/dev/null`" ]; then curl -L https://github.com/freedoom/freedoom/releases/download/v0.12.1/freedm-0.12.1.zip --output - | jar -xv freedm-0.12.1/freedm.wad ;\
|
||||
curl -L https://github.com/freedoom/freedoom/releases/download/v0.12.1/freedoom-0.12.1.zip --output - | jar -xv freedoom-0.12.1/freedoom1.wad freedoom-0.12.1/freedoom2.wad ;\
|
||||
mv freedm-0.12.1/*.wad ./ ;\
|
||||
mv freedoom-0.12.1/*.wad ./ ;\
|
||||
rm -rf freedm-0.12.1 freedoom-0.12.1 ;\
|
||||
else wget https://github.com/freedoom/freedoom/releases/download/v0.12.1/freedm-0.12.1.zip ;\
|
||||
wget https://github.com/freedoom/freedoom/releases/download/v0.12.1/freedoom-0.12.1.zip ;\
|
||||
unzip -p freedm-0.12.1.zip freedm-0.12.1/freedm.wad > freedm.wad ;\
|
||||
unzip -p freedoom-0.12.1.zip freedoom-0.12.1/freedoom1.wad > freedoom1.wad ;\
|
||||
unzip -p freedoom-0.12.1.zip freedoom-0.12.1/freedoom2.wad > freedoom2.wad ;\
|
||||
rm freedm-0.12.1.zip freedoom-0.12.1.zip ;\
|
||||
fi;\
|
||||
fi
|
||||
|
||||
if [ ! -d "l2e_boot/l2e_sources/l2eterm/lvgl" ]; then echo "Cloning LVGL: lvgl v8.3.9 sources..." ;\
|
||||
cd l2e_boot/l2e_sources/l2eterm ;\
|
||||
git clone -b v8.3.9 --depth 1 https://github.com/lvgl/lvgl.git ;\
|
||||
echo "Cloning LVGL: lv_drivers v8.3.0 sources..." ;\
|
||||
git clone -b v8.3.0 --depth 1 https://github.com/lvgl/lv_drivers.git ;\
|
||||
fi
|
||||
|
||||
if [ ! -d "l2e_boot/limine" ]; then echo "Downloading & extracting limine v5.20230830.0 (tar.xz) sources..." ;\
|
||||
mkdir l2e_boot/limine ;\
|
||||
curl -L https://github.com/limine-bootloader/limine/releases/download/v5.20230830.0/limine-5.20230830.0.tar.xz --output - | tar -xvf - -J -C l2e_boot/limine --strip-components 1 ;\
|
||||
fi
|
||||
|
||||
cp -R l2e_boot/l2e_sources/l2e l2e_boot/linux/
|
||||
cp -R l2e_boot/l2e_sources/l2e_os l2e_boot/linux/drivers/misc/
|
||||
cp l2e_boot/l2e_sources/Kconfig l2e_boot/linux/drivers/misc/
|
||||
cp l2e_boot/l2e_sources/Makefile l2e_boot/linux/drivers/misc/
|
||||
cp l2e_boot/l2e_sources/L2E.gcc.config l2e_boot/linux/.config
|
||||
cp run.c l2e_boot/linux/l2e/
|
||||
cp incbin.h l2e_boot/linux/l2e/
|
||||
cp tokenizer.bin l2e_boot/linux/l2e/
|
||||
cp out/model.bin l2e_boot/linux/l2e/
|
||||
|
||||
if [ ! -d "l2e_boot/musl_build" ]; then cd l2e_boot/musl ;\
|
||||
./configure --disable-shared --prefix=../musl_build --syslibdir=../musl_build/lib ;\
|
||||
make ;\
|
||||
make install ;\
|
||||
cd ../musl_build ;\
|
||||
sed -i s@../musl_build@`pwd`@g bin/musl-gcc ;\
|
||||
sed -i s@../musl_build@`pwd`@g lib/musl-gcc.specs ;\
|
||||
cd ../linux ;\
|
||||
make headers_install INSTALL_HDR_PATH=../kernel_headers;\
|
||||
cp -r ../kernel_headers/include/linux ../musl_build/include/;\
|
||||
cp -r ../kernel_headers/include/asm ../musl_build/include/;\
|
||||
cp -r ../kernel_headers/include/asm-generic ../musl_build/include/;\
|
||||
cp -r ../kernel_headers/include/mtd ../musl_build/include/;\
|
||||
fi
|
||||
|
||||
if [ ! -f "l2e_boot/linux/l2e/toybox" ]; then cd l2e_boot/toybox ;\
|
||||
cp ../l2e_sources/L2E.toybox.config .config ;\
|
||||
make CC=../musl_build/bin/musl-gcc CFLAGS="-static" ;\
|
||||
cp toybox ../linux/l2e/ ;\
|
||||
fi
|
||||
|
||||
if [ ! -f "l2e_boot/linux/l2e/busybox" ]; then cd l2e_boot/busybox ;\
|
||||
cp ../l2e_sources/L2E.busybox.config .config ;\
|
||||
KCONFIG_NOTIMESTAMP=1 make CC=../musl_build/bin/musl-gcc CFLAGS="-static" ;\
|
||||
cp busybox ../linux/l2e/ ;\
|
||||
fi
|
||||
|
||||
if [ ! -f "l2e_boot/linux/l2e/fbdoom" ]; then cd l2e_boot/fbDOOM ;\
|
||||
cd fbdoom;\
|
||||
make clean ;\
|
||||
make CC=../../musl_build/bin/musl-gcc CFLAGS="-static" NOSDL=1 ;\
|
||||
strip -s fbdoom ;\
|
||||
cp fbdoom ../../linux/l2e/ ;\
|
||||
cp ../*.wad ../../linux/l2e/ ;\
|
||||
fi
|
||||
|
||||
if [ ! -f "l2e_boot/linux/l2e/l2eterm" ]; then cd l2e_boot/l2e_sources/l2eterm ;\
|
||||
make clean ;\
|
||||
make CC=../../musl_build/bin/musl-gcc CFLAGS="-static" ;\
|
||||
cp l2eterm ../../linux/l2e/ ;\
|
||||
cp LAIRS.png ../../linux/l2e/ ;\
|
||||
fi
|
||||
|
||||
if [ ! -d "l2e_boot/limine/bin" ]; then cd l2e_boot/limine ;\
|
||||
./configure --enable-bios-cd --enable-bios-pxe --enable-bios --enable-uefi-x86-64 --enable-uefi-cd ;\
|
||||
make ;\
|
||||
rm -r ../ISO ;\
|
||||
cp -R ../l2e_sources/ISO ../ ;\
|
||||
cp bin/limine-bios-cd.bin ../ISO/ ;\
|
||||
cp bin/limine-bios.sys ../ISO/ ;\
|
||||
cp bin/limine-uefi-cd.bin ../ISO/ ;\
|
||||
cp bin/BOOTX64.EFI ../ISO/EFI/BOOT/ ;\
|
||||
fi
|
||||
|
||||
cd l2e_boot/linux/l2e ; make l2e_bin_cc
|
||||
cd l2e_boot/linux ; SOURCE_DATE_EPOCH=1696185000 KBUILD_BUILD_TIMESTAMP="Oct 2 00:00:00 UTC 2023" KBUILD_BUILD_USER=Vulcan KBUILD_BUILD_HOST=amica.board make LOCALVERSION="- TEMPLE DOS"
|
||||
cp l2e_boot/linux/arch/x86/boot/bzImage l2e_boot/ISO/L2E_Exec
|
||||
|
||||
|
||||
##@ ---> L2E OS (Humanoid) ---> Make Bootable ISO
|
||||
.PHONY: l2e_os_iso
|
||||
l2e_os_iso: l2e_os ## - Make Bootable L2E OS Hybrid UEFI/BIOS ISO Image
|
||||
if [ -d 'l2e_boot/ISO' ]; then cd l2e_boot/ ;\
|
||||
ls ;\
|
||||
rm *.iso ;\
|
||||
xorriso -volume_date uuid '2023100200000000' \
|
||||
-volume_date all_file_dates '2023100200000000' \
|
||||
-charset 'UTF-8' \
|
||||
-volid "L2E OS" \
|
||||
-volset_id "L2E OS v0.1 TEMPLE DOS" \
|
||||
-publisher "L2E OS @Vulcan Ignis @TRHolding @AMICA Board" \
|
||||
-application_id "L2E OS Live Boot Disk" \
|
||||
-copyright_file "COPYRIGHT.TXT" \
|
||||
-abstract_file "ABSTRACT.TXT" \
|
||||
-biblio_file 'BIBLIO.MARCXML' \
|
||||
-as mkisofs -b /limine-bios-cd.bin \
|
||||
-no-emul-boot -boot-load-size 4 -boot-info-table \
|
||||
--efi-boot /limine-uefi-cd.bin \
|
||||
-efi-boot-part --efi-boot-image --protective-msdos-label \
|
||||
-preparer "L2E Build v0.1 + xorriso 1.5.6" \
|
||||
-sysid "L2E OS x86_64 UEFI/BIOS BOOT ISO" \
|
||||
./ISO -o l2eos.iso ;\
|
||||
./limine/bin/limine bios-install l2eos.iso ;\
|
||||
fi
|
||||
|
||||
|
||||
|
||||
##@ ---> L2E OS (Humanoid) ---> Boot in qemu
|
||||
.PHONY: boot_l2e_os
|
||||
boot_l2e_os: ## - Boot L2E OS (Humanoid) in qemu
|
||||
qemu-system-x86_64 -display gtk,zoom-to-fit=off -m 512m -accel kvm --kernel l2e_boot/ISO/L2E_Exec -vga virtio --append "loglevel=1 vga=0x392"
|
||||
|
||||
##@ ---> L2E OS (Humanoid) ---> Boot ISO in qemu
|
||||
.PHONY: boot_l2e_iso
|
||||
boot_l2e_iso: ## - Boot L2E OS ISO Image in qemu
|
||||
qemu-system-x86_64 -display gtk,zoom-to-fit=off -m 512 -accel kvm -vga virtio -cdrom l2e_boot/l2eos.iso
|
||||
|
||||
##@ ---> L2E OS (Humanoid) ---> Boot ISO with UEFI in qemu
|
||||
.PHONY: boot_l2e_iso_uefi
|
||||
boot_l2e_iso_uefi: ## - Boot L2E OS ISO Image with UEFI in qemu
|
||||
qemu-system-x86_64 -display gtk,zoom-to-fit=off -bios /usr/share/ovmf/x64/OVMF.fd -m 512 -accel kvm -vga virtio -cdrom l2e_boot/l2eos.iso
|
||||
|
||||
##@ Debug Build
|
||||
|
||||
# useful for a debug build, can then e.g. analyze with valgrind, example:
|
||||
# $ valgrind --leak-check=full ./run out/model.bin -n 3
|
||||
.PHONY: run_debug
|
||||
run_debug: ## - Debug build which can be analyzed with tools like valgrind.
|
||||
$(CC) -g -o run run.c -lm
|
||||
|
||||
##@ Testing
|
||||
.PHONY: test
|
||||
test:
|
||||
test: ## - run all tests (inclusive python code, needs python)
|
||||
pytest
|
||||
|
||||
# run only tests for run.c C implementation (is a bit faster if only C code changed)
|
||||
.PHONY: testc
|
||||
testc:
|
||||
testc: ## - run only tests for run.c C implementation (needs python)
|
||||
pytest -k runc
|
||||
|
||||
# run the C tests, without touching pytest / python
|
||||
# to increase verbosity level run e.g. as `make testcc VERBOSITY=1`
|
||||
VERBOSITY ?= 0
|
||||
.PHONY: testcc
|
||||
testcc:
|
||||
testcc: ## - run the C tests, without touching pytest / python
|
||||
$(CC) -DVERBOSITY=$(VERBOSITY) -O3 -o testc test.c -lm
|
||||
./testc
|
||||
|
||||
##@ Clean/ Purge
|
||||
.PHONY: tempclean
|
||||
tempclean: ## - Find and delete all temporary files left by editors
|
||||
find . -name '*~'
|
||||
find . -name '*~' -delete
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -f run run.com model.h tokenizer.h strlit run.com.dbg .config.old .config *~
|
||||
make -f Makefile.unikernel clean
|
||||
clean: ## - Simple cleaning
|
||||
rm -f run run.com model.h tokenizer.h strlit run.com.dbg *~ l2e_boot/linux/l2e/toybox l2e_boot/toybox/toybox l2e_boot/l2eos.iso
|
||||
cd l2e_boot/l2e_sources/l2e ; make clean
|
||||
if [ -d "l2e_boot/linux/l2e" ]; then cd l2e_boot/linux/l2e ; make clean ; fi
|
||||
if [ -d "l2e_boot/linux" ]; then cd l2e_boot/linux ; make clean ; fi
|
||||
if [ -d "l2e_boot/toybox" ]; then cd l2e_boot/toybox ; make clean ; fi
|
||||
if [ -d "l2e_boot/busybox" ]; then cd l2e_boot/busybox ; make clean ; fi
|
||||
if [ -d "l2e_boot/l2e_sources/l2eterm/lvgl" ]; then cd l2e_boot/l2e_sources/l2eterm ; make clean ; fi
|
||||
if [ -d "l2e_boot/musl" ]; then cd l2e_boot/musl ; make clean ; fi
|
||||
if [ -d "l2e_boot/limine" ]; then cd l2e_boot/limine ; make clean ; fi
|
||||
if [ -d "l2e_boot/ISO" ]; then rm -r l2e_boot/ISO ; fi
|
||||
if [ -d "build" ]; then make -f Makefile.unikernel clean ; fi
|
||||
|
||||
.PHONY: distclean
|
||||
distclean:
|
||||
rm -f run run.com model.h tokenizer.h strlit run.com.dbg .config.old .config *~
|
||||
make -f Makefile.unikernel distclean
|
||||
rm -rf UNIK
|
||||
distclean: ## - Deep cleaning (distclean sub projects)
|
||||
rm -f run run.com model.h tokenizer.h strlit run.com.dbg .config.old .config *~ l2e_boot/l2eos.iso
|
||||
cd l2e_boot/l2e_sources/l2e ; make clean
|
||||
if [ -d "l2e_boot/linux/l2e" ]; then cd l2e_boot/linux/l2e ; make clean ; fi
|
||||
if [ -d "l2e_boot/linux" ]; then cd l2e_boot/linux ; make distclean ; fi
|
||||
if [ -d "l2e_boot/toybox" ]; then cd l2e_boot/toybox ; make distclean ; fi
|
||||
if [ -d "l2e_boot/busybox" ]; then cd l2e_boot/busybox ; make distclean ; fi
|
||||
if [ -d "l2e_boot/l2e_sources/l2eterm/lvgl" ]; then cd l2e_boot/l2e_sources/l2eterm ; make clean ; fi
|
||||
if [ -d "l2e_boot/musl" ]; then cd l2e_boot/musl ; make distclean ; fi
|
||||
if [ -d "l2e_boot/limine" ]; then cd l2e_boot/limine ; make distclean ; fi
|
||||
if [ -d "l2e_boot/ISO" ]; then rm -r l2e_boot/ISO ; fi
|
||||
if [ -d "build" ]; then make -f Makefile.unikernel distclean ; fi
|
||||
rm -rf build
|
||||
rm -rf l2e_boot/musl_build
|
||||
rm -rf l2e_boot/kernel_headers
|
||||
|
||||
.PHONY: mintclean
|
||||
mintclean: ## - Revert to mint condition (remove sub projects)
|
||||
rm -f run run.com model.h tokenizer.h strlit run.com.dbg .config.old .config *~ l2e_boot/l2eos.iso
|
||||
cd l2e_boot/l2e_sources/l2e ; make clean
|
||||
if [ -d "l2e_boot/linux/l2e" ]; then cd l2e_boot/linux/l2e ; make clean ; fi
|
||||
if [ -d "l2e_boot/linux" ]; then cd l2e_boot/linux ; make distclean ; fi
|
||||
if [ -d "l2e_boot/toybox" ]; then cd l2e_boot/toybox ; make distclean ; fi
|
||||
if [ -d "l2e_boot/busybox" ]; then cd l2e_boot/busybox ; make distclean ; fi
|
||||
if [ -d "l2e_boot/l2e_sources/l2eterm/lvgl" ]; then cd l2e_boot/l2e_sources/l2eterm ; make clean ; fi
|
||||
if [ -d "l2e_boot/musl" ]; then cd l2e_boot/musl ; make distclean ; fi
|
||||
if [ -d "l2e_boot/limine" ]; then cd l2e_boot/limine ; make distclean ; fi
|
||||
if [ -d "l2e_boot/ISO" ]; then rm -r l2e_boot/ISO ; fi
|
||||
if [ -d "build" ]; then make -f Makefile.unikernel distclean ; fi
|
||||
rm -rf build
|
||||
rm -rf l2e_boot/musl_build
|
||||
rm -rf l2e_boot/kernel_headers
|
||||
#rm -rf UNIK
|
||||
#rm -rf l2e_boot/musl
|
||||
#rm -rf l2e_boot/toybox
|
||||
#rm -rf l2e_boot/busybox
|
||||
#rm -rf l2e_boot/l2e_sources/l2eterm/lvgl
|
||||
#rm -rf l2e_boot/l2e_sources/l2eterm/lv_drivers
|
||||
#rm -rf l2e_boot/limine
|
||||
#rm -rf l2e_boot/linux
|
||||
|
||||
##@ Misc
|
||||
|
||||
.PHONY: get_model
|
||||
get_model: ## - Get stories15M model
|
||||
if [ ! -d "out/" ]; then echo "Downloading model..." ; fi
|
||||
if [ ! -d "out/" ]; then wget https://huggingface.co/karpathy/tinyllamas/resolve/main/stories15M.bin ; fi
|
||||
if [ ! -d "out/" ]; then mkdir out ; fi
|
||||
if [ -f "stories15M.bin" ]; then mv stories15M.bin out/model.bin ; fi
|
||||
|
||||
.PHONY: list
|
||||
list:
|
||||
# Uses: https://stackoverflow.com/a/26339924
|
||||
.PHONY: list
|
||||
list: ## - Display sorted list of all targets
|
||||
@LC_ALL=C $(MAKE) -pRrq -f $(firstword $(MAKEFILE_LIST)) : 2>/dev/null | awk -v RS= -F: '/(^|\n)# Files(\n|$$)/,/(^|\n) / {if ($$1 !~ "^[#.]") {print $$1}}' | sort | grep -E -v -e '^[^[:alnum:]]' -e '^$@$$'
|
||||
|
||||
##@ Help
|
||||
# Credits:
|
||||
# https://www.thapaliya.com/en/writings/well-documented-makefiles/
|
||||
# https://gist.github.com/prwhite/8168133
|
||||
# https://www.client9.com/self-documenting-makefiles/
|
||||
.DEFAULT_GOAL=help
|
||||
.PHONY=help
|
||||
help: ## - Display this help. Make without target also displays this help.
|
||||
@awk 'BEGIN {FS = ":.*##"; printf "\nUsage:\n make \033[36m<target>\033[0m\n"} /^[a-zA-Z0-9_-]+:.*?##/ { printf " \033[36m%-15s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST)
|
||||
|
||||
100
README.md
100
README.md
@ -432,41 +432,89 @@ Example:
|
||||
make run_cc_openmp
|
||||
```
|
||||
|
||||
Targets:
|
||||
|
||||
NEW:
|
||||
Usage & Targets:
|
||||
|
||||
```
|
||||
run_unik_qemu_x86_64 - Unikernel + embedded model Build (QEMU/x86_64)
|
||||
```
|
||||
Usage:
|
||||
make <target>
|
||||
|
||||
```
|
||||
run - Default build
|
||||
rungnu - Generic linux distro build
|
||||
runompgnu - Generic linux distro + OpenMP build
|
||||
runfast - Optimized build
|
||||
run_cc_armpl - ARM PL BLAS accelerated build (ARM64) (WIP)
|
||||
run_cc_blis - BLIS accelerated build
|
||||
run_cc_cblas - Generic CBLAS accelerated build
|
||||
run_cc_clblast - CLBlast OpenCL CBLAS GPU accelerated build
|
||||
run_cc_mac_accel - Mac OS CBLAS via Accelerate Framework (WIP/TEST)
|
||||
run_cc_mkl - Intel MKL CBLAS build (x86_64 / intel Mac)(WIP)
|
||||
run_cc_openacc - OpenACC accelerated build
|
||||
run_cc_openblas - Openblas CBLAS accelerated build
|
||||
Simple Builds
|
||||
run_cc - Standard build with basic optimizations
|
||||
run_cc_fast - More Optimized build. Disregards strict standards compliance
|
||||
run_cc_gnu - Optimized Generic linux distro build
|
||||
|
||||
Accelerated Builds
|
||||
run_cc_openmp - OpenMP accelerated build
|
||||
run_cc_openacc - OpenACC accelerated build
|
||||
run_cc_omp_gnu - Generic linux distro + OpenMP build
|
||||
run_cc_clblast - CLBlast OpenCL CBLAS GPU accelerated build
|
||||
run_cc_openblas - Openblas CBLAS accelerated build
|
||||
run_cc_cblas - Generic CBLAS accelerated build
|
||||
run_cc_blis - BLIS accelerated build
|
||||
|
||||
Special Builds
|
||||
|
||||
---> x86_64
|
||||
run_cc_mkl - OpenMP + Intel MKL CBLAS build (x86_64 / intel Mac) (WIP)
|
||||
|
||||
---> ARM64 / aarch64
|
||||
run_cc_armpl - ARM PL BLAS accelerated build (ARM64 & Mac) (WIP)
|
||||
|
||||
---> Macintosh
|
||||
run_cc_mac_accel - Mac OS OPENMP + CBLAS via Accelerate Framework build (WIP/TEST)
|
||||
|
||||
---> Windows
|
||||
run_win - Optimized Windows build with MinGW-w64 toolchain
|
||||
run_win_msvc - OpenMP accelerated Windows build with MSVC toolchain (Untested)
|
||||
|
||||
---> MultiOS Builds (using cosmopolitan libc + toolchain)
|
||||
run_cosmocc - Optimized Portable + cosmocc (runs on all OSes)
|
||||
|
||||
---> MultiOS Builds ---> with Embedded Models
|
||||
run_cosmocc_zipos - Optimized Portable + cosmocc + embedded zip model build (runs on all OSes)
|
||||
run_cosmocc_incbin - Optimized Portable + cosmocc + embedded model fast build (runs on all OSes)
|
||||
run_cosmocc_strlit - Optimized Portable + cosmocc + embedded model build (runs on all OSes)
|
||||
|
||||
---> GCC/Clang Embedded Model Builds
|
||||
run_gcc_openmp_incbin - Gcc + OpenMP + embedded model fast build
|
||||
run_gcc_openmp_strlit - Gcc + OpenMP + embedded model build
|
||||
run_clang_openmp_incbin - Clang + OpenMP + embedded model fast build
|
||||
run_clang_openmp_strlit - Clang + OpenMP + embedded model build
|
||||
run_gcc_static_incbin - Static gcc + OpenMP + embedded model fast build
|
||||
run_gcc_static_strlit - Static gcc + OpenMP + embedded model build
|
||||
run_clang_static_incbin - Static clang + OpenMP + embedded model fast build
|
||||
run_clang_static_strlit - Static clang + OpenMP + embedded model build
|
||||
run_cosmocc - Portable + cosmocc
|
||||
run_cosmocc_incbin - Portable + cosmocc + embedded model fast build (All OSes)
|
||||
run_cosmocc_strlit - Portable + cosmocc + embedded model build (All OSes)
|
||||
run_cosmocc_zipos - Portable + cosmocc + embedded zip model build(All OSes)
|
||||
|
||||
---> GCC/Clang Embedded Model Builds ---> Statically Linked
|
||||
run_gcc_static_incbin - Optimized Static gcc + embedded model fast build
|
||||
run_gcc_static_strlit - Optimized Static gcc + embedded model build
|
||||
run_clang_static_incbin - Optimized Static clang + embedded model fast build
|
||||
run_clang_static_strlit - Optimized Static clang + embedded model build
|
||||
|
||||
---> Android
|
||||
run_incbin_tmux - Optimized build + Embedded Model for Termux on Android
|
||||
|
||||
---> Unikernel
|
||||
run_unik_qemu - L2E Unikernel for kvm / qemu x86_64
|
||||
|
||||
---> L2E OS (Humanoid)
|
||||
l2e_os - L2E OS, kernel module and userspace build
|
||||
|
||||
Debug Build
|
||||
run_debug - Debug build which can be analyzed with tools like valgrind.
|
||||
|
||||
Testing
|
||||
test - run all tests (inclusive python code, needs python)
|
||||
testc - run only tests for run.c C implementation (needs python)
|
||||
testcc - run the C tests, without touching pytest / python
|
||||
|
||||
Clean/ Purge
|
||||
clean - Simple cleaning
|
||||
distclean - Revert to mint condition. Warning: Deletes cloned subprojects.
|
||||
|
||||
Misc
|
||||
list - Display sorted list of all targets
|
||||
|
||||
Help
|
||||
help - Display this help. Make without target also displays this help.
|
||||
```
|
||||
|
||||
All builds with embedded models need the model to be in ``out/`` directory and the model name has to be ``model.bin``
|
||||
|
||||
Example:
|
||||
|
||||
2
l2e_boot/l2e_sources/ISO/ABSTRACT.TXT
Normal file
2
l2e_boot/l2e_sources/ISO/ABSTRACT.TXT
Normal file
@ -0,0 +1,2 @@
|
||||
L2E OS v0.1 "TEMPLE DOS" UEFI/BIOS Hybrid Live Boot Disk
|
||||
|
||||
54
l2e_boot/l2e_sources/ISO/BIBLIO.MARCXML
Normal file
54
l2e_boot/l2e_sources/ISO/BIBLIO.MARCXML
Normal file
@ -0,0 +1,54 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<record
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://www.loc.gov/MARC21/slim http://www.loc.gov/standards/marcxml/schema/MARC21slim.xsd"
|
||||
xmlns="http://www.loc.gov/MARC21/slim">
|
||||
|
||||
<leader>00928nmmaa22001697 4500</leader>
|
||||
<controlfield tag="005">20230909170024.0</controlfield>
|
||||
<controlfield tag="008">230909b |||||||gq||b| 00| 0 eng d</controlfield>
|
||||
<datafield tag="040" ind1=" " ind2=" ">
|
||||
<subfield code="c">Vulcan Ignis @L2E</subfield>
|
||||
<subfield code="a">Vulcan Ignis @L2E</subfield>
|
||||
</datafield>
|
||||
<datafield tag="210" ind1=" " ind2=" ">
|
||||
<subfield code="a">L2E OS </subfield>
|
||||
</datafield>
|
||||
<datafield tag="222" ind1=" " ind2=" ">
|
||||
<subfield code="a">L2E OS v0.1 "TEMPLE DOS"</subfield>
|
||||
</datafield>
|
||||
<datafield tag="245" ind1=" " ind2=" ">
|
||||
<subfield code="a">L2E OS v0.1</subfield>
|
||||
<subfield code="h">ISO Image / CDROM</subfield>
|
||||
<subfield code="b">L2E OS v0.1 "TEMPLE DOS" UEFI/BIOS Hybrid Live Boot Disk</subfield>
|
||||
<subfield code="c">Copyright (C) 2023 L2E OS - Vulcan Ignis @TRHolding @Amica Board. Contains code whose copyright is owned by their respective project owners.</subfield>
|
||||
</datafield>
|
||||
<datafield tag="260" ind1=" " ind2=" ">
|
||||
<subfield code="a">International / Web / Internet</subfield>
|
||||
<subfield code="b">Vulcan Ignis @L2E @TRHolding @Amica Board</subfield>
|
||||
<subfield code="c">2023</subfield>
|
||||
</datafield>
|
||||
<datafield tag="270" ind1=" " ind2=" ">
|
||||
<subfield code="m">1ohm@proton.me</subfield>
|
||||
<subfield code="p">Vulcan Ignis</subfield>
|
||||
<subfield code="q">Founder @L2E</subfield>
|
||||
</datafield>
|
||||
<datafield tag="365" ind1=" " ind2=" ">
|
||||
<subfield code="b">99.99</subfield>
|
||||
<subfield code="c">USD</subfield>
|
||||
<subfield code="e">Price is valid only for libraries that offer non free access.</subfield>
|
||||
<subfield code="m">Vulcan Ignis @L2E</subfield>
|
||||
</datafield>
|
||||
<datafield tag="856" ind1=" " ind2=" ">
|
||||
<subfield code="q">application/vnd.efi.iso</subfield>
|
||||
<subfield code="u">https://github.com/trholding/llama2.c</subfield>
|
||||
<subfield code="y">Llama 2 Everywhere OS (L2E OS)</subfield>
|
||||
<subfield code="z">L2E OS Github Repository</subfield>
|
||||
</datafield>
|
||||
<datafield tag="942" ind1=" " ind2=" ">
|
||||
<subfield code="2">z</subfield>
|
||||
<subfield code="n">0</subfield>
|
||||
<subfield code="c">CF</subfield>
|
||||
</datafield>
|
||||
</record>
|
||||
|
||||
2
l2e_boot/l2e_sources/ISO/COPYRIGHT.TXT
Normal file
2
l2e_boot/l2e_sources/ISO/COPYRIGHT.TXT
Normal file
@ -0,0 +1,2 @@
|
||||
Copyright (C) 2023 L2E OS - Vulcan Ignis @TRHolding @Amica Board
|
||||
Contains code whose copyright is owned by their respective project owners.
|
||||
BIN
l2e_boot/l2e_sources/ISO/l2ebg.png
Normal file
BIN
l2e_boot/l2e_sources/ISO/l2ebg.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 769 KiB |
30
l2e_boot/l2e_sources/ISO/limine.cfg
Normal file
30
l2e_boot/l2e_sources/ISO/limine.cfg
Normal file
@ -0,0 +1,30 @@
|
||||
TIMEOUT=5
|
||||
TERM_WALLPAPER=boot:///l2ebg.png
|
||||
INTERFACE_BRANDING=
|
||||
TERM_PALETTE=FF0000,FFFFFF,FF0000,FFFFFF,FF0000,000000,FFFFFF,FFFFFF
|
||||
TERM_PALETTE_BRIGHT=FFFFFF,FF0000,FF0000,FFFFFF,000000,000000,FFFFFF,FFFFFF
|
||||
INTERFACE_BRANDING_COLOR=1
|
||||
TERM_BACKGROUND=FF000000
|
||||
TERM_FOREGROUND=000000
|
||||
TERM_BACKGROUND_BRIGHT=FFFFFF
|
||||
TERM_FOREGROUND_BRIGHT=FFFFFF
|
||||
TERM_BACKDROP=000000
|
||||
INTERFACE_HELP_HIDDEN=yes
|
||||
TERM_MARGIN=200
|
||||
TERM_MARGIN_GRADIENT=30
|
||||
TERM_FONT_SCALE=1X1
|
||||
INTERFACE_RESOLUTION=1920x1080
|
||||
: L2E OS
|
||||
PROTOCOL=linux
|
||||
KERNEL_PATH=boot:///L2E_Exec
|
||||
KERNEL_CMDLINE="loglevel=1"
|
||||
RESOLUTION=1920x1080
|
||||
COMMENT= >>> TEMPLE DOS
|
||||
|
||||
:L2E OS KMOD
|
||||
PROTOCOL=linux
|
||||
KERNEL_PATH=boot:///L2E_Exec
|
||||
KERNEL_CMDLINE="loglevel=2"
|
||||
RESOLUTION=1920x1080
|
||||
COMMENT= >>> LLM IN KERNEL
|
||||
|
||||
582
l2e_boot/l2e_sources/Kconfig
Normal file
582
l2e_boot/l2e_sources/Kconfig
Normal file
@ -0,0 +1,582 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-only
|
||||
#
|
||||
# Misc strange devices
|
||||
#
|
||||
|
||||
menu "Misc devices"
|
||||
|
||||
config SENSORS_LIS3LV02D
|
||||
tristate
|
||||
depends on INPUT
|
||||
|
||||
config AD525X_DPOT
|
||||
tristate "Analog Devices Digital Potentiometers"
|
||||
depends on (I2C || SPI) && SYSFS
|
||||
help
|
||||
If you say yes here, you get support for the Analog Devices
|
||||
AD5258, AD5259, AD5251, AD5252, AD5253, AD5254, AD5255
|
||||
AD5160, AD5161, AD5162, AD5165, AD5200, AD5201, AD5203,
|
||||
AD5204, AD5206, AD5207, AD5231, AD5232, AD5233, AD5235,
|
||||
AD5260, AD5262, AD5263, AD5290, AD5291, AD5292, AD5293,
|
||||
AD7376, AD8400, AD8402, AD8403, ADN2850, AD5241, AD5242,
|
||||
AD5243, AD5245, AD5246, AD5247, AD5248, AD5280, AD5282,
|
||||
ADN2860, AD5273, AD5171, AD5170, AD5172, AD5173, AD5270,
|
||||
AD5271, AD5272, AD5274
|
||||
digital potentiometer chips.
|
||||
|
||||
See Documentation/misc-devices/ad525x_dpot.rst for the
|
||||
userspace interface.
|
||||
|
||||
This driver can also be built as a module. If so, the module
|
||||
will be called ad525x_dpot.
|
||||
|
||||
config AD525X_DPOT_I2C
|
||||
tristate "support I2C bus connection"
|
||||
depends on AD525X_DPOT && I2C
|
||||
help
|
||||
Say Y here if you have a digital potentiometers hooked to an I2C bus.
|
||||
|
||||
To compile this driver as a module, choose M here: the
|
||||
module will be called ad525x_dpot-i2c.
|
||||
|
||||
config AD525X_DPOT_SPI
|
||||
tristate "support SPI bus connection"
|
||||
depends on AD525X_DPOT && SPI_MASTER
|
||||
help
|
||||
Say Y here if you have a digital potentiometers hooked to an SPI bus.
|
||||
|
||||
If unsure, say N (but it's safe to say "Y").
|
||||
|
||||
To compile this driver as a module, choose M here: the
|
||||
module will be called ad525x_dpot-spi.
|
||||
|
||||
config DUMMY_IRQ
|
||||
tristate "Dummy IRQ handler"
|
||||
help
|
||||
This module accepts a single 'irq' parameter, which it should register for.
|
||||
The sole purpose of this module is to help with debugging of systems on
|
||||
which spurious IRQs would happen on disabled IRQ vector.
|
||||
|
||||
config IBM_ASM
|
||||
tristate "Device driver for IBM RSA service processor"
|
||||
depends on X86 && PCI && INPUT
|
||||
depends on SERIAL_8250 || SERIAL_8250=n
|
||||
help
|
||||
This option enables device driver support for in-band access to the
|
||||
IBM RSA (Condor) service processor in eServer xSeries systems.
|
||||
The ibmasm device driver allows user space application to access
|
||||
ASM (Advanced Systems Management) functions on the service
|
||||
processor. The driver is meant to be used in conjunction with
|
||||
a user space API.
|
||||
The ibmasm driver also enables the OS to use the UART on the
|
||||
service processor board as a regular serial port. To make use of
|
||||
this feature serial driver support (CONFIG_SERIAL_8250) must be
|
||||
enabled.
|
||||
|
||||
WARNING: This software may not be supported or function
|
||||
correctly on your IBM server. Please consult the IBM ServerProven
|
||||
website <https://www-03.ibm.com/systems/info/x86servers/serverproven/compat/us/>
|
||||
for information on the specific driver level and support statement
|
||||
for your IBM server.
|
||||
|
||||
config IBMVMC
|
||||
tristate "IBM Virtual Management Channel support"
|
||||
depends on PPC_PSERIES
|
||||
help
|
||||
This is the IBM POWER Virtual Management Channel
|
||||
|
||||
This driver is to be used for the POWER Virtual
|
||||
Management Channel virtual adapter on the PowerVM
|
||||
platform. It provides both request/response and
|
||||
async message support through the /dev/ibmvmc node.
|
||||
|
||||
To compile this driver as a module, choose M here: the
|
||||
module will be called ibmvmc.
|
||||
|
||||
config PHANTOM
|
||||
tristate "Sensable PHANToM (PCI)"
|
||||
depends on PCI
|
||||
help
|
||||
Say Y here if you want to build a driver for Sensable PHANToM device.
|
||||
|
||||
This driver is only for PCI PHANToMs.
|
||||
|
||||
If you choose to build module, its name will be phantom. If unsure,
|
||||
say N here.
|
||||
|
||||
config TIFM_CORE
|
||||
tristate "TI Flash Media interface support"
|
||||
depends on PCI
|
||||
help
|
||||
If you want support for Texas Instruments(R) Flash Media adapters
|
||||
you should select this option and then also choose an appropriate
|
||||
host adapter, such as 'TI Flash Media PCI74xx/PCI76xx host adapter
|
||||
support', if you have a TI PCI74xx compatible card reader, for
|
||||
example.
|
||||
You will also have to select some flash card format drivers. MMC/SD
|
||||
cards are supported via 'MMC/SD Card support: TI Flash Media MMC/SD
|
||||
Interface support (MMC_TIFM_SD)'.
|
||||
|
||||
To compile this driver as a module, choose M here: the module will
|
||||
be called tifm_core.
|
||||
|
||||
config TIFM_7XX1
|
||||
tristate "TI Flash Media PCI74xx/PCI76xx host adapter support"
|
||||
depends on PCI && TIFM_CORE
|
||||
default TIFM_CORE
|
||||
help
|
||||
This option enables support for Texas Instruments(R) PCI74xx and
|
||||
PCI76xx families of Flash Media adapters, found in many laptops.
|
||||
To make actual use of the device, you will have to select some
|
||||
flash card format drivers, as outlined in the TIFM_CORE Help.
|
||||
|
||||
To compile this driver as a module, choose M here: the module will
|
||||
be called tifm_7xx1.
|
||||
|
||||
config ICS932S401
|
||||
tristate "Integrated Circuits ICS932S401"
|
||||
depends on I2C
|
||||
help
|
||||
If you say yes here you get support for the Integrated Circuits
|
||||
ICS932S401 clock control chips.
|
||||
|
||||
This driver can also be built as a module. If so, the module
|
||||
will be called ics932s401.
|
||||
|
||||
config ATMEL_SSC
|
||||
tristate "Device driver for Atmel SSC peripheral"
|
||||
depends on HAS_IOMEM && (ARCH_AT91 || COMPILE_TEST)
|
||||
help
|
||||
This option enables device driver support for Atmel Synchronized
|
||||
Serial Communication peripheral (SSC).
|
||||
|
||||
The SSC peripheral supports a wide variety of serial frame based
|
||||
communications, i.e. I2S, SPI, etc.
|
||||
|
||||
If unsure, say N.
|
||||
|
||||
config ENCLOSURE_SERVICES
|
||||
tristate "Enclosure Services"
|
||||
help
|
||||
Provides support for intelligent enclosures (bays which
|
||||
contain storage devices). You also need either a host
|
||||
driver (SCSI/ATA) which supports enclosures
|
||||
or a SCSI enclosure device (SES) to use these services.
|
||||
|
||||
config SGI_XP
|
||||
tristate "Support communication between SGI SSIs"
|
||||
depends on NET
|
||||
depends on (IA64_SGI_UV || X86_UV) && SMP
|
||||
depends on X86_64 || BROKEN
|
||||
select SGI_GRU if X86_64 && SMP
|
||||
help
|
||||
An SGI machine can be divided into multiple Single System
|
||||
Images which act independently of each other and have
|
||||
hardware based memory protection from the others. Enabling
|
||||
this feature will allow for direct communication between SSIs
|
||||
based on a network adapter and DMA messaging.
|
||||
|
||||
config SMPRO_ERRMON
|
||||
tristate "Ampere Computing SMPro error monitor driver"
|
||||
depends on MFD_SMPRO || COMPILE_TEST
|
||||
help
|
||||
Say Y here to get support for the SMpro error monitor function
|
||||
provided by Ampere Computing's Altra and Altra Max SoCs. Upon
|
||||
loading, the driver creates sysfs files which can be use to gather
|
||||
multiple HW error data reported via read and write system calls.
|
||||
|
||||
To compile this driver as a module, say M here. The driver will be
|
||||
called smpro-errmon.
|
||||
|
||||
config SMPRO_MISC
|
||||
tristate "Ampere Computing SMPro miscellaneous driver"
|
||||
depends on MFD_SMPRO || COMPILE_TEST
|
||||
help
|
||||
Say Y here to get support for the SMpro error miscellalenous function
|
||||
provided by Ampere Computing's Altra and Altra Max SoCs.
|
||||
|
||||
To compile this driver as a module, say M here. The driver will be
|
||||
called smpro-misc.
|
||||
|
||||
config CS5535_MFGPT
|
||||
tristate "CS5535/CS5536 Geode Multi-Function General Purpose Timer (MFGPT) support"
|
||||
depends on MFD_CS5535
|
||||
help
|
||||
This driver provides access to MFGPT functionality for other
|
||||
drivers that need timers. MFGPTs are available in the CS5535 and
|
||||
CS5536 companion chips that are found in AMD Geode and several
|
||||
other platforms. They have a better resolution and max interval
|
||||
than the generic PIT, and are suitable for use as high-res timers.
|
||||
You probably don't want to enable this manually; other drivers that
|
||||
make use of it should enable it.
|
||||
|
||||
config CS5535_MFGPT_DEFAULT_IRQ
|
||||
int
|
||||
depends on CS5535_MFGPT
|
||||
default 7
|
||||
help
|
||||
MFGPTs on the CS5535 require an interrupt. The selected IRQ
|
||||
can be overridden as a module option as well as by driver that
|
||||
use the cs5535_mfgpt_ API; however, different architectures might
|
||||
want to use a different IRQ by default. This is here for
|
||||
architectures to set as necessary.
|
||||
|
||||
config CS5535_CLOCK_EVENT_SRC
|
||||
tristate "CS5535/CS5536 high-res timer (MFGPT) events"
|
||||
depends on GENERIC_CLOCKEVENTS && CS5535_MFGPT
|
||||
help
|
||||
This driver provides a clock event source based on the MFGPT
|
||||
timer(s) in the CS5535 and CS5536 companion chips.
|
||||
MFGPTs have a better resolution and max interval than the
|
||||
generic PIT, and are suitable for use as high-res timers.
|
||||
|
||||
config GEHC_ACHC
|
||||
tristate "GEHC ACHC support"
|
||||
depends on SPI && SYSFS
|
||||
depends on SOC_IMX53 || COMPILE_TEST
|
||||
select FW_LOADER
|
||||
help
|
||||
Support for GE ACHC microcontroller, that is part of the GE
|
||||
PPD device.
|
||||
|
||||
To compile this driver as a module, choose M here: the
|
||||
module will be called gehc-achc.
|
||||
|
||||
config HI6421V600_IRQ
|
||||
tristate "HiSilicon Hi6421v600 IRQ and powerkey"
|
||||
depends on OF
|
||||
depends on SPMI
|
||||
depends on HAS_IOMEM
|
||||
select MFD_CORE
|
||||
select REGMAP_SPMI
|
||||
help
|
||||
This driver provides IRQ handling for Hi6421v600, used on
|
||||
some Kirin chipsets, like the one at Hikey 970.
|
||||
|
||||
config HP_ILO
|
||||
tristate "Channel interface driver for the HP iLO processor"
|
||||
depends on PCI
|
||||
help
|
||||
The channel interface driver allows applications to communicate
|
||||
with iLO management processors present on HP ProLiant servers.
|
||||
Upon loading, the driver creates /dev/hpilo/dXccbN files, which
|
||||
can be used to gather data from the management processor, via
|
||||
read and write system calls.
|
||||
|
||||
To compile this driver as a module, choose M here: the
|
||||
module will be called hpilo.
|
||||
|
||||
config QCOM_COINCELL
|
||||
tristate "Qualcomm coincell charger support"
|
||||
depends on MFD_SPMI_PMIC || COMPILE_TEST
|
||||
help
|
||||
This driver supports the coincell block found inside of
|
||||
Qualcomm PMICs. The coincell charger provides a means to
|
||||
charge a coincell battery or backup capacitor which is used
|
||||
to maintain PMIC register and RTC state in the absence of
|
||||
external power.
|
||||
|
||||
config QCOM_FASTRPC
|
||||
tristate "Qualcomm FastRPC"
|
||||
depends on ARCH_QCOM || COMPILE_TEST
|
||||
depends on RPMSG
|
||||
select DMA_SHARED_BUFFER
|
||||
select QCOM_SCM
|
||||
help
|
||||
Provides a communication mechanism that allows for clients to
|
||||
make remote method invocations across processor boundary to
|
||||
applications DSP processor. Say M if you want to enable this
|
||||
module.
|
||||
|
||||
config SGI_GRU
|
||||
tristate "SGI GRU driver"
|
||||
depends on X86_UV && SMP
|
||||
select MMU_NOTIFIER
|
||||
help
|
||||
The GRU is a hardware resource located in the system chipset. The GRU
|
||||
contains memory that can be mmapped into the user address space. This memory is
|
||||
used to communicate with the GRU to perform functions such as load/store,
|
||||
scatter/gather, bcopy, AMOs, etc. The GRU is directly accessed by user
|
||||
instructions using user virtual addresses. GRU instructions (ex., bcopy) use
|
||||
user virtual addresses for operands.
|
||||
|
||||
If you are not running on a SGI UV system, say N.
|
||||
|
||||
config SGI_GRU_DEBUG
|
||||
bool "SGI GRU driver debug"
|
||||
depends on SGI_GRU
|
||||
help
|
||||
This option enables additional debugging code for the SGI GRU driver.
|
||||
If you are unsure, say N.
|
||||
|
||||
config APDS9802ALS
|
||||
tristate "Medfield Avago APDS9802 ALS Sensor module"
|
||||
depends on I2C
|
||||
help
|
||||
If you say yes here you get support for the ALS APDS9802 ambient
|
||||
light sensor.
|
||||
|
||||
This driver can also be built as a module. If so, the module
|
||||
will be called apds9802als.
|
||||
|
||||
config ISL29003
|
||||
tristate "Intersil ISL29003 ambient light sensor"
|
||||
depends on I2C && SYSFS
|
||||
help
|
||||
If you say yes here you get support for the Intersil ISL29003
|
||||
ambient light sensor.
|
||||
|
||||
This driver can also be built as a module. If so, the module
|
||||
will be called isl29003.
|
||||
|
||||
config ISL29020
|
||||
tristate "Intersil ISL29020 ambient light sensor"
|
||||
depends on I2C
|
||||
help
|
||||
If you say yes here you get support for the Intersil ISL29020
|
||||
ambient light sensor.
|
||||
|
||||
This driver can also be built as a module. If so, the module
|
||||
will be called isl29020.
|
||||
|
||||
config SENSORS_TSL2550
|
||||
tristate "Taos TSL2550 ambient light sensor"
|
||||
depends on I2C && SYSFS
|
||||
help
|
||||
If you say yes here you get support for the Taos TSL2550
|
||||
ambient light sensor.
|
||||
|
||||
This driver can also be built as a module. If so, the module
|
||||
will be called tsl2550.
|
||||
|
||||
config SENSORS_BH1770
|
||||
tristate "BH1770GLC / SFH7770 combined ALS - Proximity sensor"
|
||||
depends on I2C
|
||||
help
|
||||
Say Y here if you want to build a driver for BH1770GLC (ROHM) or
|
||||
SFH7770 (Osram) combined ambient light and proximity sensor chip.
|
||||
|
||||
To compile this driver as a module, choose M here: the
|
||||
module will be called bh1770glc. If unsure, say N here.
|
||||
|
||||
config SENSORS_APDS990X
|
||||
tristate "APDS990X combined als and proximity sensors"
|
||||
depends on I2C
|
||||
help
|
||||
Say Y here if you want to build a driver for Avago APDS990x
|
||||
combined ambient light and proximity sensor chip.
|
||||
|
||||
To compile this driver as a module, choose M here: the
|
||||
module will be called apds990x. If unsure, say N here.
|
||||
|
||||
config HMC6352
|
||||
tristate "Honeywell HMC6352 compass"
|
||||
depends on I2C
|
||||
help
|
||||
This driver provides support for the Honeywell HMC6352 compass,
|
||||
providing configuration and heading data via sysfs.
|
||||
|
||||
config DS1682
|
||||
tristate "Dallas DS1682 Total Elapsed Time Recorder with Alarm"
|
||||
depends on I2C
|
||||
help
|
||||
If you say yes here you get support for Dallas Semiconductor
|
||||
DS1682 Total Elapsed Time Recorder.
|
||||
|
||||
This driver can also be built as a module. If so, the module
|
||||
will be called ds1682.
|
||||
|
||||
config VMWARE_BALLOON
|
||||
tristate "VMware Balloon Driver"
|
||||
depends on VMWARE_VMCI && X86 && HYPERVISOR_GUEST
|
||||
select MEMORY_BALLOON
|
||||
help
|
||||
This is VMware physical memory management driver which acts
|
||||
like a "balloon" that can be inflated to reclaim physical pages
|
||||
by reserving them in the guest and invalidating them in the
|
||||
monitor, freeing up the underlying machine pages so they can
|
||||
be allocated to other guests. The balloon can also be deflated
|
||||
to allow the guest to use more physical memory.
|
||||
|
||||
If unsure, say N.
|
||||
|
||||
To compile this driver as a module, choose M here: the
|
||||
module will be called vmw_balloon.
|
||||
|
||||
config PCH_PHUB
|
||||
tristate "Intel EG20T PCH/LAPIS Semicon IOH(ML7213/ML7223/ML7831) PHUB"
|
||||
select GENERIC_NET_UTILS
|
||||
depends on PCI && (X86_32 || MIPS || COMPILE_TEST)
|
||||
help
|
||||
This driver is for PCH(Platform controller Hub) PHUB(Packet Hub) of
|
||||
Intel Topcliff which is an IOH(Input/Output Hub) for x86 embedded
|
||||
processor. The Topcliff has MAC address and Option ROM data in SROM.
|
||||
This driver can access MAC address and Option ROM data in SROM.
|
||||
|
||||
This driver also can be used for LAPIS Semiconductor's IOH,
|
||||
ML7213/ML7223/ML7831.
|
||||
ML7213 which is for IVI(In-Vehicle Infotainment) use.
|
||||
ML7223 IOH is for MP(Media Phone) use.
|
||||
ML7831 IOH is for general purpose use.
|
||||
ML7213/ML7223/ML7831 is companion chip for Intel Atom E6xx series.
|
||||
ML7213/ML7223/ML7831 is completely compatible for Intel EG20T PCH.
|
||||
|
||||
To compile this driver as a module, choose M here: the module will
|
||||
be called pch_phub.
|
||||
|
||||
config LATTICE_ECP3_CONFIG
|
||||
tristate "Lattice ECP3 FPGA bitstream configuration via SPI"
|
||||
depends on SPI && SYSFS
|
||||
select FW_LOADER
|
||||
default n
|
||||
help
|
||||
This option enables support for bitstream configuration (programming
|
||||
or loading) of the Lattice ECP3 FPGA family via SPI.
|
||||
|
||||
If unsure, say N.
|
||||
|
||||
config SRAM
|
||||
bool "Generic on-chip SRAM driver"
|
||||
depends on HAS_IOMEM
|
||||
select GENERIC_ALLOCATOR
|
||||
select SRAM_EXEC if ARM
|
||||
help
|
||||
This driver allows you to declare a memory region to be managed by
|
||||
the genalloc API. It is supposed to be used for small on-chip SRAM
|
||||
areas found on many SoCs.
|
||||
|
||||
config SRAM_EXEC
|
||||
bool
|
||||
|
||||
config DW_XDATA_PCIE
|
||||
depends on PCI
|
||||
tristate "Synopsys DesignWare xData PCIe driver"
|
||||
help
|
||||
This driver allows controlling Synopsys DesignWare PCIe traffic
|
||||
generator IP also known as xData, present in Synopsys DesignWare
|
||||
PCIe Endpoint prototype.
|
||||
|
||||
If unsure, say N.
|
||||
|
||||
config PCI_ENDPOINT_TEST
|
||||
depends on PCI
|
||||
select CRC32
|
||||
tristate "PCI Endpoint Test driver"
|
||||
help
|
||||
Enable this configuration option to enable the host side test driver
|
||||
for PCI Endpoint.
|
||||
|
||||
config XILINX_SDFEC
|
||||
tristate "Xilinx SDFEC 16"
|
||||
depends on HAS_IOMEM
|
||||
help
|
||||
This option enables support for the Xilinx SDFEC (Soft Decision
|
||||
Forward Error Correction) driver. This enables a char driver
|
||||
for the SDFEC.
|
||||
|
||||
You may select this driver if your design instantiates the
|
||||
SDFEC(16nm) hardened block. To compile this as a module choose M.
|
||||
|
||||
If unsure, say N.
|
||||
|
||||
config MISC_RTSX
|
||||
tristate
|
||||
default MISC_RTSX_PCI || MISC_RTSX_USB
|
||||
|
||||
config HISI_HIKEY_USB
|
||||
tristate "USB GPIO Hub on HiSilicon Hikey 960/970 Platform"
|
||||
depends on (OF && GPIOLIB) || COMPILE_TEST
|
||||
depends on USB_ROLE_SWITCH
|
||||
help
|
||||
If you say yes here this adds support for the on-board USB GPIO hub
|
||||
found on HiKey 960/970 boards, which is necessary to support
|
||||
switching between the dual-role USB-C port and the USB-A host ports
|
||||
using only one USB controller.
|
||||
|
||||
config OPEN_DICE
|
||||
tristate "Open Profile for DICE driver"
|
||||
depends on OF_RESERVED_MEM
|
||||
help
|
||||
This driver exposes a DICE reserved memory region to userspace via
|
||||
a character device. The memory region contains Compound Device
|
||||
Identifiers (CDIs) generated by firmware as an output of DICE
|
||||
measured boot flow. Userspace can use CDIs for remote attestation
|
||||
and sealing.
|
||||
|
||||
If unsure, say N.
|
||||
|
||||
config VCPU_STALL_DETECTOR
|
||||
tristate "Guest vCPU stall detector"
|
||||
depends on OF && HAS_IOMEM
|
||||
help
|
||||
When this driver is bound inside a KVM guest, it will
|
||||
periodically "pet" an MMIO stall detector device from each vCPU
|
||||
and allow the host to detect vCPU stalls.
|
||||
|
||||
To compile this driver as a module, choose M here: the module
|
||||
will be called vcpu_stall_detector.
|
||||
|
||||
If you do not intend to run this kernel as a guest, say N.
|
||||
|
||||
config TMR_MANAGER
|
||||
tristate "Select TMR Manager"
|
||||
depends on MICROBLAZE && MB_MANAGER
|
||||
help
|
||||
This option enables the driver developed for TMR Manager.
|
||||
The Triple Modular Redundancy(TMR) manager provides support for
|
||||
fault detection.
|
||||
|
||||
Say N here unless you know what you are doing.
|
||||
|
||||
config TMR_INJECT
|
||||
tristate "Select TMR Inject"
|
||||
depends on TMR_MANAGER && FAULT_INJECTION_DEBUG_FS
|
||||
help
|
||||
This option enables the driver developed for TMR Inject.
|
||||
The Triple Modular Redundancy(TMR) Inject provides
|
||||
fault injection.
|
||||
|
||||
Say N here unless you know what you are doing.
|
||||
|
||||
config TPS6594_ESM
|
||||
tristate "TI TPS6594 Error Signal Monitor support"
|
||||
depends on MFD_TPS6594
|
||||
default MFD_TPS6594
|
||||
help
|
||||
Support ESM (Error Signal Monitor) on TPS6594 PMIC devices.
|
||||
ESM is used typically to reboot the board in error condition.
|
||||
|
||||
This driver can also be built as a module. If so, the module
|
||||
will be called tps6594-esm.
|
||||
|
||||
config TPS6594_PFSM
|
||||
tristate "TI TPS6594 Pre-configurable Finite State Machine support"
|
||||
depends on MFD_TPS6594
|
||||
default MFD_TPS6594
|
||||
help
|
||||
Support PFSM (Pre-configurable Finite State Machine) on TPS6594 PMIC devices.
|
||||
These devices integrate a finite state machine engine, which manages the state
|
||||
of the device during operating state transition.
|
||||
|
||||
This driver can also be built as a module. If so, the module
|
||||
will be called tps6594-pfsm.
|
||||
|
||||
source "drivers/misc/c2port/Kconfig"
|
||||
source "drivers/misc/eeprom/Kconfig"
|
||||
source "drivers/misc/cb710/Kconfig"
|
||||
source "drivers/misc/ti-st/Kconfig"
|
||||
source "drivers/misc/lis3lv02d/Kconfig"
|
||||
source "drivers/misc/altera-stapl/Kconfig"
|
||||
source "drivers/misc/mei/Kconfig"
|
||||
source "drivers/misc/vmw_vmci/Kconfig"
|
||||
source "drivers/misc/genwqe/Kconfig"
|
||||
source "drivers/misc/echo/Kconfig"
|
||||
source "drivers/misc/cxl/Kconfig"
|
||||
source "drivers/misc/ocxl/Kconfig"
|
||||
source "drivers/misc/bcm-vk/Kconfig"
|
||||
source "drivers/misc/cardreader/Kconfig"
|
||||
source "drivers/misc/uacce/Kconfig"
|
||||
source "drivers/misc/pvpanic/Kconfig"
|
||||
source "drivers/misc/mchp_pci1xxxx/Kconfig"
|
||||
source "drivers/misc/l2e_os/Kconfig"
|
||||
endmenu
|
||||
1231
l2e_boot/l2e_sources/L2E.busybox.config
Normal file
1231
l2e_boot/l2e_sources/L2E.busybox.config
Normal file
File diff suppressed because it is too large
Load Diff
2948
l2e_boot/l2e_sources/L2E.gcc.config
Normal file
2948
l2e_boot/l2e_sources/L2E.gcc.config
Normal file
File diff suppressed because it is too large
Load Diff
390
l2e_boot/l2e_sources/L2E.toybox.config
Normal file
390
l2e_boot/l2e_sources/L2E.toybox.config
Normal file
@ -0,0 +1,390 @@
|
||||
#
|
||||
# Automatically generated make config: don't edit
|
||||
# ToyBox version: KCONFIG_VERSION
|
||||
# Wed Sep 6 09:52:02 2023
|
||||
#
|
||||
# CONFIG_TOYBOX_ON_ANDROID is not set
|
||||
CONFIG_TOYBOX_FORK=y
|
||||
|
||||
#
|
||||
# Posix commands
|
||||
#
|
||||
CONFIG_BASENAME=y
|
||||
CONFIG_CAL=y
|
||||
CONFIG_CAT=y
|
||||
CONFIG_CHGRP=y
|
||||
CONFIG_CHOWN=y
|
||||
CONFIG_CHMOD=y
|
||||
CONFIG_CKSUM=y
|
||||
CONFIG_CRC32=y
|
||||
CONFIG_CMP=y
|
||||
CONFIG_COMM=y
|
||||
CONFIG_CP=y
|
||||
CONFIG_MV=y
|
||||
CONFIG_INSTALL=y
|
||||
CONFIG_CPIO=y
|
||||
CONFIG_CUT=y
|
||||
CONFIG_DATE=y
|
||||
CONFIG_DD=y
|
||||
CONFIG_DF=y
|
||||
CONFIG_DIRNAME=y
|
||||
CONFIG_DU=y
|
||||
CONFIG_ECHO=y
|
||||
CONFIG_ENV=y
|
||||
CONFIG_EXPAND=y
|
||||
CONFIG_FALSE=y
|
||||
CONFIG_FILE=y
|
||||
CONFIG_FIND=y
|
||||
CONFIG_GETCONF=y
|
||||
CONFIG_GREP=y
|
||||
CONFIG_EGREP=y
|
||||
CONFIG_FGREP=y
|
||||
CONFIG_HEAD=y
|
||||
CONFIG_ICONV=y
|
||||
CONFIG_ID=y
|
||||
# CONFIG_ID_Z is not set
|
||||
CONFIG_GROUPS=y
|
||||
CONFIG_LOGNAME=y
|
||||
CONFIG_WHOAMI=y
|
||||
CONFIG_KILL=y
|
||||
CONFIG_KILLALL5=y
|
||||
CONFIG_LINK=y
|
||||
CONFIG_LN=y
|
||||
CONFIG_LOGGER=y
|
||||
CONFIG_LS=y
|
||||
CONFIG_MKDIR=y
|
||||
# CONFIG_MKDIR_Z is not set
|
||||
CONFIG_MKFIFO=y
|
||||
# CONFIG_MKFIFO_Z is not set
|
||||
CONFIG_NICE=y
|
||||
CONFIG_NL=y
|
||||
CONFIG_NOHUP=y
|
||||
CONFIG_OD=y
|
||||
CONFIG_PASTE=y
|
||||
CONFIG_PATCH=y
|
||||
CONFIG_PRINTF=y
|
||||
CONFIG_PS=y
|
||||
CONFIG_TOP=y
|
||||
CONFIG_IOTOP=y
|
||||
CONFIG_PGREP=y
|
||||
CONFIG_PKILL=y
|
||||
CONFIG_PWD=y
|
||||
CONFIG_RENICE=y
|
||||
CONFIG_RM=y
|
||||
CONFIG_RMDIR=y
|
||||
CONFIG_SED=y
|
||||
CONFIG_SLEEP=y
|
||||
CONFIG_SORT=y
|
||||
CONFIG_SORT_FLOAT=y
|
||||
CONFIG_SPLIT=y
|
||||
CONFIG_STRINGS=y
|
||||
CONFIG_TAIL=y
|
||||
CONFIG_TAR=y
|
||||
CONFIG_TEE=y
|
||||
CONFIG_TEST=y
|
||||
CONFIG_TEST_GLUE=y
|
||||
CONFIG_TIME=y
|
||||
CONFIG_TOUCH=y
|
||||
CONFIG_TRUE=y
|
||||
CONFIG_TTY=y
|
||||
CONFIG_ULIMIT=y
|
||||
CONFIG_ARCH=y
|
||||
CONFIG_LINUX32=y
|
||||
CONFIG_UNAME=y
|
||||
CONFIG_UNIQ=y
|
||||
CONFIG_UNLINK=y
|
||||
CONFIG_UUDECODE=y
|
||||
CONFIG_UUENCODE=y
|
||||
CONFIG_WC=y
|
||||
CONFIG_WHO=y
|
||||
CONFIG_XARGS=y
|
||||
|
||||
#
|
||||
# Pending (unfinished) commands
|
||||
#
|
||||
# CONFIG_ARP is not set
|
||||
# CONFIG_ARPING is not set
|
||||
# CONFIG_BC is not set
|
||||
# CONFIG_BOOTCHARTD is not set
|
||||
# CONFIG_BRCTL is not set
|
||||
# CONFIG_CHSH is not set
|
||||
# CONFIG_CROND is not set
|
||||
# CONFIG_CRONTAB is not set
|
||||
# CONFIG_DHCP is not set
|
||||
# CONFIG_DHCP6 is not set
|
||||
# CONFIG_DHCPD is not set
|
||||
# CONFIG_DEBUG_DHCP is not set
|
||||
# CONFIG_DIFF is not set
|
||||
# CONFIG_DUMPLEASES is not set
|
||||
# CONFIG_EXPR is not set
|
||||
# CONFIG_FDISK is not set
|
||||
# CONFIG_FOLD is not set
|
||||
# CONFIG_FSCK is not set
|
||||
# CONFIG_GETFATTR is not set
|
||||
# CONFIG_GETOPT is not set
|
||||
# CONFIG_GETTY is not set
|
||||
# CONFIG_GITCOMPAT is not set
|
||||
# CONFIG_GITCLONE is not set
|
||||
# CONFIG_GITINIT is not set
|
||||
# CONFIG_GITREMOTE is not set
|
||||
# CONFIG_GITFETCH is not set
|
||||
# CONFIG_GITCHECKOUT is not set
|
||||
# CONFIG_GROUPADD is not set
|
||||
# CONFIG_GROUPDEL is not set
|
||||
# CONFIG_HEXDUMP is not set
|
||||
# CONFIG_HD is not set
|
||||
# CONFIG_INIT is not set
|
||||
# CONFIG_IP is not set
|
||||
# CONFIG_IPCRM is not set
|
||||
# CONFIG_IPCS is not set
|
||||
# CONFIG_KLOGD is not set
|
||||
# CONFIG_KLOGD_SOURCE_RING_BUFFER is not set
|
||||
# CONFIG_LAST is not set
|
||||
# CONFIG_LSOF is not set
|
||||
# CONFIG_MAN is not set
|
||||
# CONFIG_MDEV is not set
|
||||
# CONFIG_MDEV_CONF is not set
|
||||
# CONFIG_MKE2FS is not set
|
||||
# CONFIG_MKE2FS_JOURNAL is not set
|
||||
# CONFIG_MKE2FS_GEN is not set
|
||||
# CONFIG_MKE2FS_LABEL is not set
|
||||
# CONFIG_MKE2FS_EXTENDED is not set
|
||||
# CONFIG_MODPROBE is not set
|
||||
# CONFIG_MORE is not set
|
||||
# CONFIG_ROUTE is not set
|
||||
CONFIG_SH=y
|
||||
# CONFIG_CD is not set
|
||||
# CONFIG_DECLARE is not set
|
||||
# CONFIG_EXIT is not set
|
||||
# CONFIG_SET is not set
|
||||
# CONFIG_UNSET is not set
|
||||
# CONFIG_EVAL is not set
|
||||
# CONFIG_EXEC is not set
|
||||
# CONFIG_EXPORT is not set
|
||||
# CONFIG_JOBS is not set
|
||||
# CONFIG_LOCAL is not set
|
||||
# CONFIG_SHIFT is not set
|
||||
# CONFIG_SOURCE is not set
|
||||
# CONFIG_WAIT is not set
|
||||
# CONFIG_STRACE is not set
|
||||
# CONFIG_STTY is not set
|
||||
# CONFIG_SULOGIN is not set
|
||||
# CONFIG_SYSLOGD is not set
|
||||
# CONFIG_TCPSVD is not set
|
||||
# CONFIG_TELNET is not set
|
||||
# CONFIG_TELNETD is not set
|
||||
# CONFIG_TFTP is not set
|
||||
# CONFIG_TFTPD is not set
|
||||
# CONFIG_TR is not set
|
||||
# CONFIG_TRACEROUTE is not set
|
||||
# CONFIG_USERADD is not set
|
||||
# CONFIG_USERDEL is not set
|
||||
# CONFIG_VI is not set
|
||||
# CONFIG_XZCAT is not set
|
||||
|
||||
#
|
||||
# Other commands
|
||||
#
|
||||
CONFIG_ACPI=y
|
||||
CONFIG_ASCII=y
|
||||
CONFIG_UNICODE=y
|
||||
CONFIG_BASE64=y
|
||||
CONFIG_BASE32=y
|
||||
CONFIG_BLKDISCARD=y
|
||||
CONFIG_BLKID=y
|
||||
CONFIG_FSTYPE=y
|
||||
CONFIG_BLOCKDEV=y
|
||||
CONFIG_BUNZIP2=y
|
||||
CONFIG_BZCAT=y
|
||||
# CONFIG_CHCON is not set
|
||||
CONFIG_CHROOT=y
|
||||
CONFIG_CHRT=y
|
||||
CONFIG_CLEAR=y
|
||||
CONFIG_COUNT=y
|
||||
CONFIG_DEVMEM=y
|
||||
CONFIG_DOS2UNIX=y
|
||||
CONFIG_UNIX2DOS=y
|
||||
CONFIG_EJECT=y
|
||||
CONFIG_FACTOR=y
|
||||
CONFIG_FALLOCATE=y
|
||||
CONFIG_FLOCK=y
|
||||
CONFIG_FMT=y
|
||||
CONFIG_FREE=y
|
||||
CONFIG_FREERAMDISK=y
|
||||
CONFIG_FSFREEZE=y
|
||||
CONFIG_FSYNC=y
|
||||
CONFIG_GPIODETECT=y
|
||||
CONFIG_GPIOFIND=y
|
||||
CONFIG_GPIOINFO=y
|
||||
CONFIG_GPIOGET=y
|
||||
CONFIG_GPIOSET=y
|
||||
CONFIG_HELP=y
|
||||
CONFIG_HEXEDIT=y
|
||||
CONFIG_HWCLOCK=y
|
||||
CONFIG_I2CDETECT=y
|
||||
CONFIG_I2CDUMP=y
|
||||
CONFIG_I2CGET=y
|
||||
CONFIG_I2CSET=y
|
||||
CONFIG_I2CTRANSFER=y
|
||||
CONFIG_INOTIFYD=y
|
||||
CONFIG_INSMOD=y
|
||||
CONFIG_IONICE=y
|
||||
CONFIG_IORENICE=y
|
||||
CONFIG_LOGIN=y
|
||||
CONFIG_LOSETUP=y
|
||||
CONFIG_LSATTR=y
|
||||
CONFIG_CHATTR=y
|
||||
CONFIG_LSMOD=y
|
||||
CONFIG_LSPCI=y
|
||||
CONFIG_LSUSB=y
|
||||
CONFIG_MAKEDEVS=y
|
||||
CONFIG_MCOOKIE=y
|
||||
CONFIG_MIX=y
|
||||
CONFIG_MKPASSWD=y
|
||||
CONFIG_MKSWAP=y
|
||||
CONFIG_MODINFO=y
|
||||
CONFIG_MOUNTPOINT=y
|
||||
CONFIG_NBD_CLIENT=y
|
||||
CONFIG_NBD_SERVER=y
|
||||
CONFIG_UNSHARE=y
|
||||
CONFIG_NSENTER=y
|
||||
CONFIG_ONEIT=y
|
||||
CONFIG_OPENVT=y
|
||||
CONFIG_CHVT=y
|
||||
CONFIG_DEALLOCVT=y
|
||||
CONFIG_PARTPROBE=y
|
||||
CONFIG_PIVOT_ROOT=y
|
||||
CONFIG_PMAP=y
|
||||
CONFIG_PRINTENV=y
|
||||
CONFIG_PWDX=y
|
||||
CONFIG_PWGEN=y
|
||||
CONFIG_READAHEAD=y
|
||||
CONFIG_READELF=y
|
||||
CONFIG_READLINK=y
|
||||
CONFIG_REALPATH=y
|
||||
CONFIG_REBOOT=y
|
||||
CONFIG_RESET=y
|
||||
CONFIG_REV=y
|
||||
CONFIG_RMMOD=y
|
||||
CONFIG_RTCWAKE=y
|
||||
CONFIG_SETFATTR=y
|
||||
CONFIG_SETSID=y
|
||||
CONFIG_SHA3SUM=y
|
||||
CONFIG_SHRED=y
|
||||
CONFIG_SHUF=y
|
||||
CONFIG_STAT=y
|
||||
CONFIG_SWAPOFF=y
|
||||
CONFIG_SWAPON=y
|
||||
CONFIG_SWITCH_ROOT=y
|
||||
CONFIG_SYSCTL=y
|
||||
CONFIG_TAC=y
|
||||
CONFIG_NPROC=y
|
||||
CONFIG_TASKSET=y
|
||||
CONFIG_TIMEOUT=y
|
||||
CONFIG_TRUNCATE=y
|
||||
CONFIG_UCLAMPSET=y
|
||||
CONFIG_UPTIME=y
|
||||
CONFIG_USLEEP=y
|
||||
CONFIG_UUIDGEN=y
|
||||
CONFIG_VCONFIG=y
|
||||
CONFIG_VMSTAT=y
|
||||
CONFIG_W=y
|
||||
CONFIG_WATCH=y
|
||||
CONFIG_WATCHDOG=y
|
||||
CONFIG_WHICH=y
|
||||
CONFIG_XXD=y
|
||||
CONFIG_YES=y
|
||||
|
||||
#
|
||||
# Networking commands
|
||||
#
|
||||
CONFIG_FTPGET=y
|
||||
CONFIG_FTPPUT=y
|
||||
CONFIG_HOST=y
|
||||
CONFIG_HTTPD=y
|
||||
CONFIG_IFCONFIG=y
|
||||
CONFIG_MICROCOM=y
|
||||
CONFIG_NETCAT=y
|
||||
CONFIG_NETSTAT=y
|
||||
CONFIG_PING=y
|
||||
CONFIG_RFKILL=y
|
||||
CONFIG_SNTP=y
|
||||
CONFIG_TUNCTL=y
|
||||
CONFIG_WGET=y
|
||||
# CONFIG_WGET_LIBTLS is not set
|
||||
|
||||
#
|
||||
# Linux Standard Base commands
|
||||
#
|
||||
CONFIG_DMESG=y
|
||||
# CONFIG_GZIP is not set
|
||||
CONFIG_GUNZIP=y
|
||||
CONFIG_ZCAT=y
|
||||
CONFIG_HOSTNAME=y
|
||||
CONFIG_DNSDOMAINNAME=y
|
||||
CONFIG_KILLALL=y
|
||||
CONFIG_MD5SUM=y
|
||||
CONFIG_SHA1SUM=y
|
||||
CONFIG_SHA224SUM=y
|
||||
CONFIG_SHA256SUM=y
|
||||
CONFIG_SHA384SUM=y
|
||||
CONFIG_SHA512SUM=y
|
||||
CONFIG_MKNOD=y
|
||||
# CONFIG_MKNOD_Z is not set
|
||||
CONFIG_MKTEMP=y
|
||||
CONFIG_MOUNT=y
|
||||
CONFIG_PASSWD=y
|
||||
# CONFIG_PASSWD_SAD is not set
|
||||
CONFIG_PIDOF=y
|
||||
CONFIG_SEQ=y
|
||||
CONFIG_SU=y
|
||||
CONFIG_SYNC=y
|
||||
CONFIG_UMOUNT=y
|
||||
|
||||
#
|
||||
# Example commands
|
||||
#
|
||||
# CONFIG_DEMO_MANY_OPTIONS is not set
|
||||
# CONFIG_DEMO_NUMBER is not set
|
||||
# CONFIG_DEMO_SCANKEY is not set
|
||||
# CONFIG_DEMO_UTF8TOWC is not set
|
||||
# CONFIG_HELLO is not set
|
||||
# CONFIG_HOSTID is not set
|
||||
# CONFIG_LOGPATH is not set
|
||||
# CONFIG_SKELETON is not set
|
||||
# CONFIG_SKELETON_ALIAS is not set
|
||||
|
||||
#
|
||||
# Android commands
|
||||
#
|
||||
# CONFIG_GETENFORCE is not set
|
||||
# CONFIG_LOAD_POLICY is not set
|
||||
# CONFIG_LOG is not set
|
||||
# CONFIG_RESTORECON is not set
|
||||
# CONFIG_RUNCON is not set
|
||||
# CONFIG_SENDEVENT is not set
|
||||
# CONFIG_SETENFORCE is not set
|
||||
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
#
|
||||
# Toybox global settings
|
||||
#
|
||||
CONFIG_TOYBOX=y
|
||||
CONFIG_TOYBOX_SUID=y
|
||||
CONFIG_TOYBOX_LSM_NONE=y
|
||||
# CONFIG_TOYBOX_SELINUX is not set
|
||||
# CONFIG_TOYBOX_SMACK is not set
|
||||
# CONFIG_TOYBOX_LIBCRYPTO is not set
|
||||
# CONFIG_TOYBOX_LIBZ is not set
|
||||
CONFIG_TOYBOX_FLOAT=y
|
||||
CONFIG_TOYBOX_HELP=y
|
||||
CONFIG_TOYBOX_HELP_DASHDASH=y
|
||||
# CONFIG_TOYBOX_FREE is not set
|
||||
# CONFIG_TOYBOX_NORECURSE is not set
|
||||
# CONFIG_TOYBOX_DEBUG is not set
|
||||
CONFIG_TOYBOX_UID_SYS=100
|
||||
CONFIG_TOYBOX_UID_USR=500
|
||||
# CONFIG_TOYBOX_FORCE_NOMMU is not set
|
||||
70
l2e_boot/l2e_sources/Makefile
Normal file
70
l2e_boot/l2e_sources/Makefile
Normal file
@ -0,0 +1,70 @@
|
||||
# SPDX-License-Identifier: GPL-2.0
|
||||
#
|
||||
# Makefile for misc devices that really don't fit anywhere else.
|
||||
#
|
||||
|
||||
obj-$(CONFIG_IBM_ASM) += ibmasm/
|
||||
obj-$(CONFIG_IBMVMC) += ibmvmc.o
|
||||
obj-$(CONFIG_AD525X_DPOT) += ad525x_dpot.o
|
||||
obj-$(CONFIG_AD525X_DPOT_I2C) += ad525x_dpot-i2c.o
|
||||
obj-$(CONFIG_AD525X_DPOT_SPI) += ad525x_dpot-spi.o
|
||||
obj-$(CONFIG_ATMEL_SSC) += atmel-ssc.o
|
||||
obj-$(CONFIG_DUMMY_IRQ) += dummy-irq.o
|
||||
obj-$(CONFIG_ICS932S401) += ics932s401.o
|
||||
obj-$(CONFIG_LKDTM) += lkdtm/
|
||||
obj-$(CONFIG_TIFM_CORE) += tifm_core.o
|
||||
obj-$(CONFIG_TIFM_7XX1) += tifm_7xx1.o
|
||||
obj-$(CONFIG_PHANTOM) += phantom.o
|
||||
obj-$(CONFIG_QCOM_COINCELL) += qcom-coincell.o
|
||||
obj-$(CONFIG_QCOM_FASTRPC) += fastrpc.o
|
||||
obj-$(CONFIG_SENSORS_BH1770) += bh1770glc.o
|
||||
obj-$(CONFIG_SENSORS_APDS990X) += apds990x.o
|
||||
obj-$(CONFIG_ENCLOSURE_SERVICES) += enclosure.o
|
||||
obj-$(CONFIG_KGDB_TESTS) += kgdbts.o
|
||||
obj-$(CONFIG_SGI_XP) += sgi-xp/
|
||||
obj-$(CONFIG_SGI_GRU) += sgi-gru/
|
||||
obj-$(CONFIG_SMPRO_ERRMON) += smpro-errmon.o
|
||||
obj-$(CONFIG_SMPRO_MISC) += smpro-misc.o
|
||||
obj-$(CONFIG_CS5535_MFGPT) += cs5535-mfgpt.o
|
||||
obj-$(CONFIG_GEHC_ACHC) += gehc-achc.o
|
||||
obj-$(CONFIG_HP_ILO) += hpilo.o
|
||||
obj-$(CONFIG_APDS9802ALS) += apds9802als.o
|
||||
obj-$(CONFIG_ISL29003) += isl29003.o
|
||||
obj-$(CONFIG_ISL29020) += isl29020.o
|
||||
obj-$(CONFIG_SENSORS_TSL2550) += tsl2550.o
|
||||
obj-$(CONFIG_DS1682) += ds1682.o
|
||||
obj-$(CONFIG_C2PORT) += c2port/
|
||||
obj-$(CONFIG_HMC6352) += hmc6352.o
|
||||
obj-y += eeprom/
|
||||
obj-y += cb710/
|
||||
obj-$(CONFIG_VMWARE_BALLOON) += vmw_balloon.o
|
||||
obj-$(CONFIG_PCH_PHUB) += pch_phub.o
|
||||
obj-y += ti-st/
|
||||
obj-y += lis3lv02d/
|
||||
obj-$(CONFIG_ALTERA_STAPL) +=altera-stapl/
|
||||
obj-$(CONFIG_INTEL_MEI) += mei/
|
||||
obj-$(CONFIG_VMWARE_VMCI) += vmw_vmci/
|
||||
obj-$(CONFIG_LATTICE_ECP3_CONFIG) += lattice-ecp3-config.o
|
||||
obj-$(CONFIG_SRAM) += sram.o
|
||||
obj-$(CONFIG_SRAM_EXEC) += sram-exec.o
|
||||
obj-$(CONFIG_GENWQE) += genwqe/
|
||||
obj-$(CONFIG_ECHO) += echo/
|
||||
obj-$(CONFIG_CXL_BASE) += cxl/
|
||||
obj-$(CONFIG_DW_XDATA_PCIE) += dw-xdata-pcie.o
|
||||
obj-$(CONFIG_PCI_ENDPOINT_TEST) += pci_endpoint_test.o
|
||||
obj-$(CONFIG_OCXL) += ocxl/
|
||||
obj-$(CONFIG_BCM_VK) += bcm-vk/
|
||||
obj-y += cardreader/
|
||||
obj-$(CONFIG_PVPANIC) += pvpanic/
|
||||
obj-$(CONFIG_UACCE) += uacce/
|
||||
obj-$(CONFIG_XILINX_SDFEC) += xilinx_sdfec.o
|
||||
obj-$(CONFIG_HISI_HIKEY_USB) += hisi_hikey_usb.o
|
||||
obj-$(CONFIG_HI6421V600_IRQ) += hi6421v600-irq.o
|
||||
obj-$(CONFIG_OPEN_DICE) += open-dice.o
|
||||
obj-$(CONFIG_GP_PCI1XXXX) += mchp_pci1xxxx/
|
||||
obj-$(CONFIG_VCPU_STALL_DETECTOR) += vcpu_stall_detector.o
|
||||
obj-$(CONFIG_TMR_MANAGER) += xilinx_tmr_manager.o
|
||||
obj-$(CONFIG_TMR_INJECT) += xilinx_tmr_inject.o
|
||||
obj-$(CONFIG_TPS6594_ESM) += tps6594-esm.o
|
||||
obj-$(CONFIG_TPS6594_PFSM) += tps6594-pfsm.o
|
||||
obj-y += l2e_os/
|
||||
65
l2e_boot/l2e_sources/l2e/Makefile
Normal file
65
l2e_boot/l2e_sources/l2e/Makefile
Normal file
@ -0,0 +1,65 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-only
|
||||
#
|
||||
# Makefile for L2E Init
|
||||
#
|
||||
|
||||
# choose your compiler, e.g. gcc/clang
|
||||
# example override to clang: make run CC=clang
|
||||
|
||||
CC = gcc
|
||||
|
||||
MOD_PATH = model.bin
|
||||
TOK_PATH = tokenizer.bin
|
||||
MUSL_SYSROOT = ../../musl_build
|
||||
MUSL_SYSINC = ../../musl_build/include
|
||||
MUSL_LIB = ../../musl_build/lib
|
||||
INITLINKER= lld
|
||||
INITLINKERGCC = lld
|
||||
INITLINKERCLANG = lld
|
||||
|
||||
|
||||
# Preprocessed $(CC) static + embedded model & tokenizer, init ; for debugging only
|
||||
|
||||
.PHONY: l2e_bin_pre_cc
|
||||
l2e_bin_pre_cc:
|
||||
$(CC) -E -Ofast -static -D LINUXK -D OSPROMPT="ORACLE$$" -D MODPATH=$(MOD_PATH) -D TOKPATH=$(TOK_PATH) run.c -lm -o l2e_bin
|
||||
$(CC) -E -Ofast -static -nostdinc --sysroot $(MUSL_SYSROOT) -isystem $(MUSL_SYSINC) -L$(MUSL_LIB) -fuse-ld=$(INITLINKER) init.c -o init
|
||||
|
||||
# $(CC) static + embedded model & tokenizer, init
|
||||
|
||||
.PHONY: l2e_bin_cc
|
||||
l2e_bin_cc:
|
||||
$(CC) -Ofast -static -D LINUXK -D OSPROMPT="ORACLE$$" -D MODPATH=$(MOD_PATH) -D TOKPATH=$(TOK_PATH) run.c -lm -o l2e_bin
|
||||
$(CC) -Ofast -static -nostdinc --sysroot $(MUSL_SYSROOT) -isystem $(MUSL_SYSINC) -L$(MUSL_LIB) -fuse-ld=$(INITLINKER) init.c -o init
|
||||
strip -s l2e_bin
|
||||
strip -s init
|
||||
|
||||
# GCC static + embedded model & tokenizer, init
|
||||
|
||||
.PHONY: l2e_bin_gcc
|
||||
l2e_bin_gcc:
|
||||
gcc -Ofast -static -D LINUXK -D OSPROMPT="ORACLE$$" -D MODPATH=$(MOD_PATH) -D TOKPATH=$(TOK_PATH) run.c -lm -o l2e_bin
|
||||
gcc -Ofast -static -nostdinc --sysroot $(MUSL_SYSROOT) -isystem $(MUSL_SYSINC) -L$(MUSL_LIB) -fuse-ld=$(INITLINKERGCC) init.c -o init
|
||||
strip -s l2e_bin
|
||||
strip -s init
|
||||
|
||||
# Clang static + embedded model & tokenizer, init
|
||||
|
||||
.PHONY: l2e_bin_clang
|
||||
l2e_bin_clang:
|
||||
clang -Ofast -static -flto=thin -D LINUXK -D OSPROMPT="ORACLE$$" -D MODPATH=$(MOD_PATH) -D TOKPATH=$(TOK_PATH) run.c -lm -o l2e_bin
|
||||
clang -Ofast -static -flto=thin -nostdinc --sysroot $(MUSL_SYSROOT) -isystem $(MUSL_SYSINC) -L$(MUSL_LIB) -fuse-ld=$(INITLINKERCLANG) init.c -o init
|
||||
llvm-strip -s l2e_bin
|
||||
llvm-strip -s init
|
||||
|
||||
# Clean
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -f l2e_bin init toybox busybox l2eterm fbdoom *.wad ../drivers/misc/l2e_os/*.o ../drivers/misc/l2e_os/*.a ../drivers/misc/l2e_os/l2e_bin
|
||||
find . -name '*~'
|
||||
find . -name '*~' -delete
|
||||
|
||||
.PHONY: list
|
||||
list:
|
||||
@LC_ALL=C $(MAKE) -pRrq -f $(firstword $(MAKEFILE_LIST)) : 2>/dev/null | awk -v RS= -F: '/(^|\n)# Files(\n|$$)/,/(^|\n) / {if ($$1 !~ "^[#.]") {print $$1}}' | sort | grep -E -v -e '^[^[:alnum:]]' -e '^$@$$'
|
||||
|
||||
498
l2e_boot/l2e_sources/l2e/init.c
Normal file
498
l2e_boot/l2e_sources/l2e/init.c
Normal file
@ -0,0 +1,498 @@
|
||||
#define _XOPEN_SOURCE 700
|
||||
|
||||
#include <math.h>
|
||||
#include <ctype.h>
|
||||
#include <err.h>
|
||||
#include <errno.h>
|
||||
#include <locale.h>
|
||||
#include <signal.h>
|
||||
#include <stdint.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <sys/sysinfo.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/wait.h>
|
||||
#include <time.h>
|
||||
#include <unistd.h>
|
||||
#include <wchar.h>
|
||||
|
||||
// PRINT LOGO TEXT
|
||||
static char *infotext =
|
||||
"\n"
|
||||
" ..**********************************************.. \n"
|
||||
" .*%%%%%%*******************************************%%%%%*. \n"
|
||||
" .*%%%*. .*%%%*. \n"
|
||||
" .%%%*. *%%% %%%%%%%%%%%%%%%%%%%%%%%%%* *%%%%%%%%%%%* *%%%* \n"
|
||||
" .%%%. %%%% *%%%%%%%%%%%%%%%%%%%%%%%% *%%%%%%%%%%%%%. .%%%. \n"
|
||||
" %%%* %%%% %%%% *%%% \n"
|
||||
" .%%%. %%%% ******%%%%%%%%% %%%%%%%%%%%%%*. .%%%.\n"
|
||||
" .%%%. %%%% %%%%%%%%%****** %%%%%%%%%%%***. .%%%.\n"
|
||||
" %%%* %%%%* %%%% *%%% \n"
|
||||
" .%%%*. %%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%. .%%%. \n"
|
||||
" .%%%* *%%%%%%%%%%%%* *%%%%%%%%%%%%%%%%%%%%%%%%%%%%* .*%%%. \n"
|
||||
" .*%%%*. .*%%%*. \n"
|
||||
" .*%%%%%%*******************************************%%%%%*. \n"
|
||||
" ..**********************************************.. \n"
|
||||
"\n"
|
||||
" so much depends glazed with rain \n"
|
||||
" upon water \n"
|
||||
"\n"
|
||||
" a red wheel beside the white \n"
|
||||
" barrow chickens \n"
|
||||
"\n"
|
||||
" *** The Red Wheelbarrow Init - L2E OS v0.1 \"TEMPLE DOS\" \n"
|
||||
" *** (c) 2023 Vulcan Ignis \n"
|
||||
"\n";
|
||||
|
||||
/* START RAINBOWCOLORS*/
|
||||
/* Contains Rainbow Color Codes from "lolcat" by jaseg
|
||||
* "lolcat" is Copyright (C) 2020 jaseg <github@jaseg.net>
|
||||
* and distributed under "DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
|
||||
* Version 2, December 2004"
|
||||
*/
|
||||
char *rainbowbuffer = "";
|
||||
#define ARRAY_SIZE(foo) (sizeof(foo) / sizeof(foo[0]))
|
||||
const unsigned char codes[] = {39, 38, 44, 43, 49, 48, 84, 83, 119, 118,
|
||||
154, 148, 184, 178, 214, 208, 209, 203, 204, 198,
|
||||
199, 163, 164, 128, 129, 93, 99, 63, 69, 33};
|
||||
|
||||
static void find_escape_sequences(wint_t c, int *state) {
|
||||
if (c == '\033') {
|
||||
*state = 1;
|
||||
} else if (*state == 1) {
|
||||
if (('a' <= c && c <= 'z') || ('A' <= c && c <= 'Z'))
|
||||
*state = 2;
|
||||
} else {
|
||||
*state = 0;
|
||||
}
|
||||
}
|
||||
|
||||
static wint_t color_hack(FILE *_ignored) {
|
||||
(void)_ignored;
|
||||
static size_t idx = 0;
|
||||
char c = rainbowbuffer[idx++];
|
||||
if (c)
|
||||
return c;
|
||||
idx = 0;
|
||||
return WEOF;
|
||||
}
|
||||
|
||||
int rainbow(double hf, double vf, int fc, int fl, int rd, int tc, int cs,
|
||||
double co, char *message) {
|
||||
rainbowbuffer = message;
|
||||
int cc = -1, i, l = 0;
|
||||
wint_t c;
|
||||
int colors = isatty(STDOUT_FILENO);
|
||||
int force_locale = 1;
|
||||
int random = 0;
|
||||
int start_color = 0;
|
||||
int rgb = 0;
|
||||
double freq_h = 0.23, freq_v = 0.1;
|
||||
int rand_offset = 0;
|
||||
struct timeval tv;
|
||||
gettimeofday(&tv, NULL);
|
||||
double offx = 0;
|
||||
|
||||
if (co >= 0) {
|
||||
offx = co;
|
||||
} else {
|
||||
offx = (tv.tv_sec % 300) / 300.0;
|
||||
}
|
||||
|
||||
if (hf >= 0) {
|
||||
freq_h = hf;
|
||||
}
|
||||
if (vf >= 0) {
|
||||
freq_v = vf;
|
||||
}
|
||||
if (fc == 1) {
|
||||
colors = 1;
|
||||
}
|
||||
if (fl == 1) {
|
||||
force_locale = 0;
|
||||
}
|
||||
if (rd == 1) {
|
||||
random = 1;
|
||||
}
|
||||
if (cs >= 0) {
|
||||
start_color = cs;
|
||||
}
|
||||
if (tc == 1) {
|
||||
rgb = 1;
|
||||
}
|
||||
|
||||
if (random) {
|
||||
srand(time(NULL));
|
||||
rand_offset = rand();
|
||||
}
|
||||
|
||||
char *env_lang = getenv("LANG");
|
||||
if (force_locale && env_lang && !strstr(env_lang, "UTF-8")) {
|
||||
if (!setlocale(LC_ALL, "C.UTF-8")) {
|
||||
/* C.UTF-8 may not be available on all platforms */
|
||||
setlocale(LC_ALL, "");
|
||||
/* Let's hope for the best */
|
||||
}
|
||||
} else {
|
||||
setlocale(LC_ALL, "");
|
||||
}
|
||||
|
||||
i = 0;
|
||||
|
||||
wint_t (*this_file_read_wchar)(FILE *);
|
||||
FILE *f;
|
||||
|
||||
int escape_state = 0;
|
||||
this_file_read_wchar = &color_hack;
|
||||
f = 0;
|
||||
|
||||
while ((c = this_file_read_wchar(f)) != WEOF) {
|
||||
if (colors) {
|
||||
find_escape_sequences(c, &escape_state);
|
||||
|
||||
if (!escape_state) {
|
||||
if (c == '\n') {
|
||||
l++;
|
||||
i = 0;
|
||||
|
||||
} else {
|
||||
if (rgb) {
|
||||
i += wcwidth(c);
|
||||
float theta =
|
||||
i * freq_h / 5.0f + l * freq_v +
|
||||
(offx + 2.0f * (rand_offset + start_color) / (float)RAND_MAX) *
|
||||
M_PI;
|
||||
float offset = 0.1;
|
||||
|
||||
uint8_t red = lrintf(
|
||||
(offset + (1.0f - offset) * (0.5f + 0.5f * sin(theta + 0))) *
|
||||
255.0f);
|
||||
uint8_t green = lrintf(
|
||||
(offset +
|
||||
(1.0f - offset) * (0.5f + 0.5f * sin(theta + 2 * M_PI / 3))) *
|
||||
255.0f);
|
||||
uint8_t blue = lrintf(
|
||||
(offset +
|
||||
(1.0f - offset) * (0.5f + 0.5f * sin(theta + 4 * M_PI / 3))) *
|
||||
255.0f);
|
||||
wprintf(L"\033[38;2;%d;%d;%dm", red, green, blue);
|
||||
|
||||
} else {
|
||||
int ncc = offx * ARRAY_SIZE(codes) +
|
||||
(int)((i += wcwidth(c)) * freq_h + l * freq_v);
|
||||
if (cc != ncc)
|
||||
wprintf(L"\033[38;5;%hhum",
|
||||
codes[(rand_offset + start_color + (cc = ncc)) %
|
||||
ARRAY_SIZE(codes)]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
putwchar(c);
|
||||
/* implies "colors" */
|
||||
if (escape_state == 2)
|
||||
wprintf(L"\033[38;5;%hhum",
|
||||
codes[(rand_offset + start_color + cc) % ARRAY_SIZE(codes)]);
|
||||
}
|
||||
|
||||
if (colors) {
|
||||
wprintf(L"\033[0m");
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int rainbowprint(char *message) {
|
||||
rainbow(-1, -1, -1, -1, -1, 1, -1, -1, message);
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* END RAINBOW COLORS*/
|
||||
|
||||
int main() {
|
||||
|
||||
struct sysinfo sys_info;
|
||||
if (sysinfo(&sys_info) != 0) {
|
||||
perror("sysinfo");
|
||||
}
|
||||
|
||||
sigset_t set;
|
||||
int status;
|
||||
if (getpid() != 1) {
|
||||
rainbowprint(infotext);
|
||||
fprintf(stderr, " *******************************************\n"
|
||||
" *** Guru Meditation >>> ERROR 01 <<< ***\n"
|
||||
" *** Not PID 1. You are not special! ***\n"
|
||||
" *******************************************\n");
|
||||
rainbowprint(" *** Reference >>> ");
|
||||
printf("%ld", sys_info.uptime %60);
|
||||
rainbowprint("s <<< into boot... ***\n");
|
||||
rainbowprint(" *******************************************\n");
|
||||
return 1;
|
||||
}
|
||||
|
||||
sigfillset(&set);
|
||||
sigprocmask(SIG_BLOCK, &set, 0);
|
||||
if (fork())
|
||||
for (;;)
|
||||
wait(&status);
|
||||
sigprocmask(SIG_UNBLOCK, &set, 0);
|
||||
setsid();
|
||||
setpgid(0, 0);
|
||||
|
||||
//char *argv[] = {"/bin/sh", NULL};
|
||||
char *argv[] = {"/bin/busybox", "setsid", "-c", "/bin/busybox", "ash", NULL};
|
||||
char *envp[] = {"HOME=/root/", "TERM=linux", "PATH=/:/bin", "TZ=UTC0", "USER=root",
|
||||
"LOGNAME=[l2e_init]", "ENV=/.fsociety/shellcode.sh", "PS1=TEMPLE DOS #| ", NULL};
|
||||
|
||||
pid_t child;
|
||||
|
||||
char *createuserspace[] = {"/bin/busybox", "--install", "-s", "/bin", NULL};
|
||||
char *mountrun[] = {"/bin/mount", "/run", NULL};
|
||||
char *mountdev[] = {"/bin/busybox", "mount", "devtmpfs", "-t", "devtmpfs", "-o", "mode=0755,nosuid", "/dev", NULL};
|
||||
char *mountproc[] = {"/bin/busybox", "mount", "proc", "-t", "proc", "-o", "nosuid,noexec,nodev", "/proc", NULL};
|
||||
char *mountsys[] = {"/bin/busybox", "mount", "sysfs", "-t", "sysfs", "-o", "nosuid,noexec,nodev", "/sys", NULL};
|
||||
//char *mklock[] = {"/bin/mkdir", "-p", "/run/lock", "/run/shm", NULL};
|
||||
//char *mkchmod[] = {"/bin/chmod", "1777", "/run/lock", "/run/shm", NULL};
|
||||
//char *mklinkshm[] = {"/bin/ln", "-sfn", "/run/shm", "/dev/shm", NULL};
|
||||
//char *mklinkrun[] = {"/bin/ln", "-sfv", "/run", "/var/run", NULL};
|
||||
//char *mklinklock[] = {"/bin/ln", "-sfv", "/run/lock", "/var/lock", NULL};
|
||||
//char *initscripts[] = {"/bin/ash", "-c", "/????.sh", NULL};
|
||||
|
||||
int childstatus;
|
||||
|
||||
rainbowprint(" *** Info: Kernel bro handed the castle to me...\n");
|
||||
rainbowprint(" *** Action: Transcending boot...\n");
|
||||
rainbowprint(" *** Info: The Guru awakened...\n");
|
||||
|
||||
// USERSPACE CREATION
|
||||
rainbowprint(" *** Info: Create Userspace\n");
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** Userspace creation failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Create Userspace...\n");
|
||||
if (execve(createuserspace[0], createuserspace, envp)) {
|
||||
fprintf(stderr, " *** Userspace creation failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
// USERSPACE CREATION END
|
||||
|
||||
/*
|
||||
// DO MOUNTS
|
||||
rainbowprint(" *** Info: Mounts\n");
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** Mounting failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Mounting run\n");
|
||||
if (execve(mountrun[0], mountrun, envp)) {
|
||||
fprintf(stderr, " *** Mounting run failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
|
||||
// DEVTEMPFS
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** Mounting failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Mounting devtmpfs");
|
||||
if (execve(mountdev[0], mountdev, envp)) {
|
||||
fprintf(stderr, " *** Mounting devtmpfs failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
// END DEVTEMPFS
|
||||
*/
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** Mounting failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Mounting procfs\n");
|
||||
if (execve(mountproc[0], mountproc, envp)) {
|
||||
fprintf(stderr, " *** Mounting procfs failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** Mounting failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Mounting sysfs\n");
|
||||
if (execve(mountsys[0], mountsys, envp)) {
|
||||
fprintf(stderr, " *** Mounting sysfs failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
|
||||
if (child > 0) {
|
||||
while ((child = wait(&childstatus)) > 0)
|
||||
;
|
||||
if (childstatus == 0) {
|
||||
rainbowprint(" *** Success: All actions succeeded!\n");
|
||||
} else {
|
||||
fprintf(stderr, " *** Actions failed! ***\n");
|
||||
// return (childstatus);
|
||||
}
|
||||
}
|
||||
/*
|
||||
// CREATE LOCK DIR
|
||||
rainbowprint(" *** Info: Directories\n");
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** Directory creation failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Directory creation\n");
|
||||
if (execve(mklock[0], mklock, envp)) {
|
||||
fprintf(stderr, " *** Directory creation failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
|
||||
if (child > 0) {
|
||||
while ((child = wait(&childstatus)) > 0)
|
||||
;
|
||||
if (childstatus == 0) {
|
||||
rainbowprint(" *** Success: Directory creation succeeded!\n");
|
||||
} else {
|
||||
fprintf(stderr, " *** Directory creation failed! ***\n");
|
||||
// return (childstatus);
|
||||
}
|
||||
}
|
||||
|
||||
// CHANGE LOCK DIR PERM
|
||||
rainbowprint(" *** Action: Permissions\n");
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** Changing directory permissions failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Changing directory permissions\n");
|
||||
if (execve(mkchmod[0], mkchmod, envp)) {
|
||||
fprintf(stderr, " *** Changing directory permissions failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
|
||||
if (child > 0) {
|
||||
while ((child = wait(&childstatus)) > 0)
|
||||
;
|
||||
if (childstatus == 0) {
|
||||
rainbowprint(" *** Success: Permission change succeeded!\n");
|
||||
} else {
|
||||
fprintf(stderr, " *** Permission change failed! ***\n");
|
||||
// return (childstatus);
|
||||
}
|
||||
}
|
||||
|
||||
// LINKING
|
||||
rainbowprint(" *** Action: Links\n");
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** Linking shm failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Linking shm\n");
|
||||
if (execve(mklinkshm[0], mklinkshm, envp)) {
|
||||
fprintf(stderr, " *** Linking shm failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** Linking run failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Linking run\n");
|
||||
if (execve(mklinkrun[0], mklinkrun, envp)) {
|
||||
fprintf(stderr, " *** Linking run failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** Linking lock failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Linking lock\n");
|
||||
if (execve(mklinklock[0], mklinklock, envp)) {
|
||||
fprintf(stderr, " *** Linking lock failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
|
||||
if (child > 0) {
|
||||
while ((child = wait(&childstatus)) > 0)
|
||||
;
|
||||
if (childstatus == 0) {
|
||||
rainbowprint(" *** Success: All links succeeded!\n");
|
||||
} else {
|
||||
fprintf(stderr, " *** Links failed! ***\n");
|
||||
// return (childstatus);
|
||||
}
|
||||
}
|
||||
|
||||
*/
|
||||
|
||||
/*
|
||||
// RUN INITSCRIPT
|
||||
rainbowprint(" *** Action: uInit Script");
|
||||
child = fork();
|
||||
if (child == -1) {
|
||||
fprintf(stderr, " *** uInit Script failed! ***\n");
|
||||
}
|
||||
if (child == 0) {
|
||||
rainbowprint(" *** Action: Running uInit Script");
|
||||
if (execve(initscripts[0], initscripts, envp)) {
|
||||
fprintf(stderr, " *** uInit Script failed! ***\n");
|
||||
return (-1);
|
||||
}
|
||||
}
|
||||
|
||||
if (child > 0) {
|
||||
while ((child = wait(&childstatus)) > 0)
|
||||
;
|
||||
if (childstatus == 0) {
|
||||
rainbowprint(" *** Success: uInit Script succeeded!");
|
||||
} else {
|
||||
fprintf(stderr, " *** Init uScript failed! ***\n");
|
||||
// return (childstatus);
|
||||
}
|
||||
}
|
||||
// RUN INITSCRIPT END
|
||||
*/
|
||||
|
||||
|
||||
// BOOT INFO
|
||||
rainbowprint(infotext);
|
||||
rainbowprint(" *** Booted in >>> ");
|
||||
printf("%ld", sys_info.uptime % 60);
|
||||
rainbowprint(" <<< seconds ***\n");
|
||||
rainbowprint(" *** Note: Trancended Boot. Dropping to Temple DOS Shell...\n");
|
||||
rainbowprint(" *** Info: Load High Speed Stopwatch CLI by typing l2e\n");
|
||||
rainbowprint(" *** Info: Load LAIRS After Egypt GUI by typing l2eterm\n");
|
||||
rainbowprint(" *** Note: We are not auto loading l2e/l2eterm as we are auto\n");
|
||||
rainbowprint(" *** killing the l2e process started by kernel module\n");
|
||||
rainbowprint(" *** See module status with \"astu call_trans_opt\" \n");
|
||||
rainbowprint(" *** Info: CTRL+F & CTRL+G get's you out if in qemu...\n\n");
|
||||
|
||||
// HAND OFF
|
||||
if (execve(argv[0], &argv[0], envp) == -1) {
|
||||
fprintf(stderr, " *** IF YOU ARE SEEING THIS, SOMETHING IS AWRY ***\n");
|
||||
fprintf(stderr, " *** GURU MEDITATION! YOGA MAT ON FIRE! GURU DEMOTED TO FAKIR... BED OF NAILS TOO HOT... PANIC! DRAMA! ***\n");
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
41
l2e_boot/l2e_sources/l2e/l2e_cpio_list
Normal file
41
l2e_boot/l2e_sources/l2e/l2e_cpio_list
Normal file
@ -0,0 +1,41 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-only
|
||||
# Minimal initramfs for L2E OS
|
||||
|
||||
dir /dev 0755 0 0
|
||||
nod /dev/console 0600 0 0 c 5 1
|
||||
nod /dev/fb0 0660 0 0 c 29 0
|
||||
nod /dev/null 0666 0 0 c 1 3
|
||||
nod /dev/zero 0660 0 0 c 1 5
|
||||
nod /dev/random 0660 0 0 c 1 8
|
||||
nod /dev/tty0 660 0 0 c 4 0
|
||||
nod /dev/tty1 660 0 0 c 4 1
|
||||
nod /dev/tty2 660 0 0 c 4 2
|
||||
nod /dev/tty3 660 0 0 c 4 3
|
||||
nod /dev/tty4 660 0 0 c 4 4
|
||||
nod /dev/tty5 660 0 0 c 4 5
|
||||
nod /dev/tty6 660 0 0 c 4 6
|
||||
nod /dev/tty7 660 0 0 c 4 7
|
||||
dir /dev/input 0755 0 0
|
||||
dir /dev/pts 0755 0 0
|
||||
nod /dev/input/event0 0660 0 0 c 13 64
|
||||
nod /dev/input/event1 0660 0 0 c 13 65
|
||||
nod /dev/input/event2 0660 0 0 c 13 66
|
||||
nod /dev/input/event3 0660 0 0 c 13 67
|
||||
dir /proc 0755 0 0
|
||||
dir /sys 0755 0 0
|
||||
dir /tmp 0755 0 0
|
||||
dir /bin 0755 0 0
|
||||
dir /root 0755 0 0
|
||||
dir /.fsociety 0755 0 0
|
||||
file /l2e l2e/l2e_bin 755 0 0
|
||||
file /init l2e/init 755 0 0
|
||||
file /bin/toybox l2e/toybox 755 0 0
|
||||
file /bin/busybox l2e/busybox 755 0 0
|
||||
file /l2eterm l2e/l2eterm 755 0 0
|
||||
file /tmp/LAIRS.png l2e/LAIRS.png 755 0 0
|
||||
file /.fsociety/astsu l2e/fbdoom 755 0 0
|
||||
file /.fsociety/fsociety00.dat l2e/freedm.wad 755 0 0
|
||||
file /.fsociety/fsociety01.dat l2e/freedoom1.wad 755 0 0
|
||||
file /.fsociety/fsociety02.dat l2e/freedoom2.wad 755 0 0
|
||||
file /.fsociety/readme.txt l2e/readme.txt 755 0 0
|
||||
file /.fsociety/shellcode.sh l2e/shellcode.sh 755 0 0
|
||||
7
l2e_boot/l2e_sources/l2e/readme.txt
Normal file
7
l2e_boot/l2e_sources/l2e/readme.txt
Normal file
@ -0,0 +1,7 @@
|
||||
--------- readme.txt----------
|
||||
|
||||
|
||||
LEAVE ME HERE
|
||||
|
||||
|
||||
------------------------------
|
||||
76
l2e_boot/l2e_sources/l2e/shellcode.sh
Executable file
76
l2e_boot/l2e_sources/l2e/shellcode.sh
Executable file
@ -0,0 +1,76 @@
|
||||
#!/bin/ash
|
||||
|
||||
# Mr Robot & Hotel California Easter Eggs
|
||||
alias astu=''
|
||||
alias reboot='printf "We are all just prisoners here \nOf our own device \nWe are programmed to receive \nYou can check-out any time you like \nBut you can never leave!\n"'
|
||||
shutdown() { printf "Hello, friend. \nHello, friend? That's lame. \nMaybe I should give you a name, but that's a slippery slope. \nYou're only in my head. We have to remember that. \nWelcome to the Hotel California!\n" ; }
|
||||
|
||||
#Amiga / AmigaDOS / TRIPOS Easter Eggs
|
||||
alias DISKCOPY='cp'
|
||||
alias FORMAT='mkfs'
|
||||
alias INSTALL='echo You must be a Amiga Guru and meditate a lot for that ...'
|
||||
alias RELABEL='echo You miss that A 500 so much? ...'
|
||||
alias INFO='du ; mount'
|
||||
alias DIR='ls'
|
||||
alias LIST='ls -l'
|
||||
alias CD='cd'
|
||||
alias MAKEDIR='mkdir'
|
||||
alias ASSIGN='set'
|
||||
alias COPY='cp'
|
||||
alias DELETE='rm'
|
||||
alias PROTECT='chmod +t'
|
||||
alias RENAME='mv'
|
||||
alias TYPE='cat'
|
||||
alias DATE='date'
|
||||
alias ECHO='echo'
|
||||
alias NEWCLI='ash'
|
||||
alias ENDCLI='exit'
|
||||
alias SEARCH='grep'
|
||||
alias SAY='echo Maybe in the next version? ...'
|
||||
|
||||
#Mr Robot & CCA & Doom Easter Eggs
|
||||
alias xyzzy='cd / ; ln -s .fsociety fsociety; echo LOUDER!; export PS1="<CS30://> TEMPLE DOS #| " '
|
||||
alias XYZZY='xyzzy ; cat /fsociety/shellcode.sh | rev'
|
||||
alias plugh='xyzzy ; cd /fsociety ; ls -l ; cat readme.txt'
|
||||
alias PLUGH='alias | sort'
|
||||
alias plover='plugh ; ln -s fsociety00.dat fsociety00.wad & ln -s fsociety01.dat fsociety01.wad & ln -s fsociety02.dat fsociety02.wad'
|
||||
alias doom='echo You need some MAGIC to make it happen ; /fsociety/astsu -iwad'
|
||||
alias doomer='doom fsociety00.wad'
|
||||
alias doomest='doom fsociety01.wad'
|
||||
alias doomerest='doom fsociety02.wad'
|
||||
alias magic='echo LOUDER!'
|
||||
alias MAGIC='echo MAGIC WORDS: p****, p*****, x****, X****, a****, d***** ... The spells must be in order! Use a MIRROR to revERT!'
|
||||
|
||||
#BBS
|
||||
|
||||
alias Zzzzzz='echo The Joke is on us!'
|
||||
|
||||
#Credits / Help / Info / Menu
|
||||
alias credits=''
|
||||
alias help=''
|
||||
alias info=''
|
||||
alias menu=''
|
||||
|
||||
#Display messages from l2e kernel module
|
||||
alias call_trans_opt='echo Transcript from L2E Kernel Module: ; dmesg | grep -i T25 ; echo Note: We had killed the L2E kernel module user space process 15 seconds after boot up due to its buggy nature now...'
|
||||
|
||||
#kill l2e userspace to prevent l2e kernel module from working in background as it is buggy now
|
||||
setsid ash -c "sleep 15; killall l2e" &>/dev/null
|
||||
|
||||
#Matrix Easter Egg
|
||||
setsid ash -c "sleep 4; echo "
|
||||
setsid ash -c "sleep 5; echo Wake up, Neo..."
|
||||
setsid ash -c "sleep 9; echo The Matrix has you..."
|
||||
setsid ash -c "sleep 12; echo Follow the white llama."
|
||||
setsid ash -c "sleep 13; echo Knock, knock."
|
||||
setsid ash -c "sleep 14; echo Knock, knock, who?"
|
||||
setsid ash -c "sleep 15; echo Knock, knock, Neo."
|
||||
|
||||
#alias cryptic
|
||||
alias alias='alias | rev'
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
9
l2e_boot/l2e_sources/l2e_os/Kconfig
Normal file
9
l2e_boot/l2e_sources/l2e_os/Kconfig
Normal file
@ -0,0 +1,9 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-only
|
||||
#
|
||||
# L2E OS Driver
|
||||
#
|
||||
|
||||
config L2E_OS_DRIVER
|
||||
tristate "L2E OS Driver: LLAMA2 Binary Loader"
|
||||
select USERMODE_DRIVER
|
||||
default y
|
||||
12
l2e_boot/l2e_sources/l2e_os/Makefile
Normal file
12
l2e_boot/l2e_sources/l2e_os/Makefile
Normal file
@ -0,0 +1,12 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-only
|
||||
#
|
||||
# Makefile for L2E OS Driver
|
||||
#
|
||||
|
||||
$(obj)/l2e_blob.o: $(obj)/l2e_bin
|
||||
$(obj)/l2e_bin: $(srctree)/l2e/run.c
|
||||
# We could also pass any static l2e build here without building it
|
||||
$(CC) -Ofast -static -D LINUXK -D OSPROMPT="KERNEL ORACLE$$" -D MODPATH=$(srctree)/l2e/model.bin -D TOKPATH=$(srctree)/l2e/tokenizer.bin $(srctree)/l2e/run.c -lm -o $(obj)/l2e_bin
|
||||
|
||||
obj-$(CONFIG_L2E_OS_DRIVER) += l2e.o
|
||||
l2e-objs += l2e_kern.o l2e_blob.o
|
||||
12
l2e_boot/l2e_sources/l2e_os/l2e_blob.S
Normal file
12
l2e_boot/l2e_sources/l2e_os/l2e_blob.S
Normal file
@ -0,0 +1,12 @@
|
||||
// SPDX-License-Identifier: GPL-2.0-only
|
||||
/*
|
||||
* Derived from eprog_user_blob.S by Richard Weinberger
|
||||
* Copyright (C) 2023 Richard Weinberger <richard@nod.at>
|
||||
* Copyright (C) 2023 Vulcan Ignis <1ohm@pm.me>
|
||||
*/
|
||||
.section .init.rodata, "a"
|
||||
.global embedded_umh_start
|
||||
embedded_umh_start:
|
||||
.incbin "drivers/misc/l2e_os/l2e_bin"
|
||||
.global embedded_umh_end
|
||||
embedded_umh_end:
|
||||
143
l2e_boot/l2e_sources/l2e_os/l2e_kern.c
Normal file
143
l2e_boot/l2e_sources/l2e_os/l2e_kern.c
Normal file
@ -0,0 +1,143 @@
|
||||
// SPDX-License-Identifier: GPL-2.0-only
|
||||
/*
|
||||
* L2E OS Driver
|
||||
* Derived from eprog_kern by Richard Weinberger
|
||||
* Copyright (C) 2023 Richard Weinberger <richard@nod.at>
|
||||
* Copyright (C) 2023 Vulcan Ignis <1ohm@pm.me>
|
||||
*/
|
||||
|
||||
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
|
||||
#include <linux/freezer.h>
|
||||
#include <linux/fs.h>
|
||||
#include <linux/init.h>
|
||||
#include <linux/kthread.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/sched/signal.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/umh.h>
|
||||
#include <linux/usermode_driver.h>
|
||||
|
||||
// Max 1024 chars
|
||||
static char *quest = "Sudo make me a";
|
||||
module_param(quest, charp, S_IRUGO);
|
||||
|
||||
extern char embedded_umh_start;
|
||||
extern char embedded_umh_end;
|
||||
|
||||
static struct umd_info l2e_ctx = {
|
||||
.driver_name = "l2e",
|
||||
};
|
||||
|
||||
static struct task_struct *l2e_thread_tsk;
|
||||
static char *read_buf;
|
||||
static char *write_buf;
|
||||
#define READ_BUFSZ 4096
|
||||
#define WRITE_BUFSZ 4096
|
||||
|
||||
|
||||
static int l2e_thread(void *data)
|
||||
{
|
||||
struct umd_info *l2e_ctx = data;
|
||||
loff_t pos = 0;
|
||||
ssize_t nread;
|
||||
ssize_t nwrite;
|
||||
|
||||
set_freezable();
|
||||
|
||||
pr_alert(">> GURU UNMEDITATION :: L2E :: LLAMA HAS AWAKENED <<");
|
||||
pr_alert("l2e.quest: %s\n", quest);
|
||||
for (;;) {
|
||||
if (kthread_should_stop())
|
||||
break;
|
||||
|
||||
if (try_to_freeze())
|
||||
continue;
|
||||
|
||||
nread = kernel_read(l2e_ctx->pipe_from_umh, read_buf, READ_BUFSZ - 1, &pos);
|
||||
if (nread > 0) {
|
||||
read_buf[nread] = '\0';
|
||||
pr_alert("%s", read_buf);
|
||||
write_buf=quest;
|
||||
nwrite = kernel_write(l2e_ctx->pipe_to_umh, write_buf, WRITE_BUFSZ , &pos);
|
||||
|
||||
} else if (nread == -ERESTARTSYS) {
|
||||
break;
|
||||
} else {
|
||||
pr_err("Fatal error while reading from userspace: %ld\n", nread);
|
||||
/*
|
||||
* Suspend ourself and wait for termination.
|
||||
*/
|
||||
set_current_state(TASK_INTERRUPTIBLE);
|
||||
schedule();
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void kill_umh(struct umd_info *l2e_ctx)
|
||||
{
|
||||
struct pid *l2e_tgid = l2e_ctx->tgid;
|
||||
|
||||
kill_pid(l2e_tgid, SIGKILL, 1);
|
||||
wait_event(l2e_tgid->wait_pidfd, thread_group_exited(l2e_tgid));
|
||||
umd_cleanup_helper(l2e_ctx);
|
||||
}
|
||||
|
||||
static int __init l2e_init(void)
|
||||
{
|
||||
int ret;
|
||||
|
||||
read_buf = kmalloc(READ_BUFSZ, GFP_KERNEL);
|
||||
if (!read_buf) {
|
||||
ret = -ENOMEM;
|
||||
goto out;
|
||||
}
|
||||
|
||||
ret = umd_load_blob(&l2e_ctx, &embedded_umh_start, &embedded_umh_end - &embedded_umh_start);
|
||||
if (ret) {
|
||||
pr_err("Unable to load embedded l2e blob: %i\n", ret);
|
||||
kfree(read_buf);
|
||||
goto out;
|
||||
}
|
||||
|
||||
ret = fork_usermode_driver(&l2e_ctx);
|
||||
if (ret) {
|
||||
pr_err("Unable to start embedded l2e: %i\n", ret);
|
||||
umd_unload_blob(&l2e_ctx);
|
||||
kfree(read_buf);
|
||||
goto out;
|
||||
}
|
||||
|
||||
l2e_thread_tsk = kthread_create(l2e_thread, &l2e_ctx, "l2e_thread");
|
||||
if (IS_ERR(l2e_thread_tsk)) {
|
||||
ret = PTR_ERR(l2e_thread_tsk);
|
||||
pr_err("Unable to start kernel thread: %i\n", ret);
|
||||
kill_umh(&l2e_ctx);
|
||||
umd_unload_blob(&l2e_ctx);
|
||||
kfree(read_buf);
|
||||
goto out;
|
||||
}
|
||||
|
||||
wake_up_process(l2e_thread_tsk);
|
||||
ret = 0;
|
||||
out:
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void __exit l2e_exit(void)
|
||||
{
|
||||
kthread_stop(l2e_thread_tsk);
|
||||
kill_umh(&l2e_ctx);
|
||||
kfree(read_buf);
|
||||
umd_unload_blob(&l2e_ctx);
|
||||
}
|
||||
|
||||
module_init(l2e_init);
|
||||
module_exit(l2e_exit);
|
||||
|
||||
MODULE_AUTHOR("Richard Weinberger <richard@nod.at>");
|
||||
MODULE_AUTHOR("Vulcan Ignis <1ohm@pm.me>");
|
||||
MODULE_DESCRIPTION("L2E OS Driver");
|
||||
MODULE_LICENSE("GPL");
|
||||
BIN
l2e_boot/l2e_sources/l2eterm/LAIRS.png
Normal file
BIN
l2e_boot/l2e_sources/l2eterm/LAIRS.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 173 KiB |
105
l2e_boot/l2e_sources/l2eterm/Makefile
Normal file
105
l2e_boot/l2e_sources/l2eterm/Makefile
Normal file
@ -0,0 +1,105 @@
|
||||
#
|
||||
# Makefile
|
||||
#
|
||||
CC ?= gcc
|
||||
LVGL_DIR_NAME ?= lvgl
|
||||
LVGL_DIR ?= ${shell pwd}
|
||||
CFLAGS ?= -O3 -D_DEFAULT_SOURCE -flto=auto -ffunction-sections -fdata-sections -I$(LVGL_DIR)/ -Wall -Wshadow -Wundef -Wmissing-prototypes -Wno-discarded-qualifiers -Wall -Wextra -Wno-unused-function -Wno-error=strict-prototypes -Wpointer-arith -fno-strict-aliasing -Wno-error=cpp -Wuninitialized -Wmaybe-uninitialized -Wno-unused-parameter -Wno-missing-field-initializers -Wtype-limits -Wsizeof-pointer-memaccess -Wno-format-nonliteral -Wno-cast-qual -Wunreachable-code -Wno-switch-default -Wreturn-type -Wmultichar -Wformat-security -Wno-ignored-qualifiers -Wno-error=pedantic -Wno-sign-compare -Wno-error=missing-prototypes -Wdouble-promotion -Wclobbered -Wdeprecated -Wempty-body -Wtype-limits -Wshift-negative-value -Wstack-usage=2048 -Wno-unused-value -Wno-unused-parameter -Wno-missing-field-initializers -Wuninitialized -Wmaybe-uninitialized -Wall -Wextra -Wno-unused-parameter -Wno-missing-field-initializers -Wtype-limits -Wsizeof-pointer-memaccess -Wno-format-nonliteral -Wpointer-arith -Wno-cast-qual -Wmissing-prototypes -Wunreachable-code -Wno-switch-default -Wreturn-type -Wmultichar -Wno-discarded-qualifiers -Wformat-security -Wno-ignored-qualifiers -Wno-sign-compare -std=c99
|
||||
LDFLAGS ?= -static -lm
|
||||
BIN = l2eterm
|
||||
|
||||
prefix ?= /usr
|
||||
bindir ?= $(prefix)/bin
|
||||
|
||||
#Collect the files to compile
|
||||
MAINSRC = ./l2eterm.c
|
||||
|
||||
#LVGL
|
||||
#include $(LVGL_DIR)/lvgl/lvgl.mk
|
||||
#include $(LVGL_DIR)/$(LVGL_DIR_NAME)/demos/lv_demos.mk
|
||||
#include $(LVGL_DIR)/$(LVGL_DIR_NAME)/examples/lv_examples.mk
|
||||
include $(LVGL_DIR)/$(LVGL_DIR_NAME)/src/core/lv_core.mk
|
||||
#include $(LVGL_DIR)/$(LVGL_DIR_NAME)/src/draw/lv_draw.mk
|
||||
###
|
||||
CSRCS += lv_draw_arc.c
|
||||
CSRCS += lv_draw.c
|
||||
CSRCS += lv_draw_img.c
|
||||
CSRCS += lv_draw_label.c
|
||||
CSRCS += lv_draw_line.c
|
||||
CSRCS += lv_draw_mask.c
|
||||
CSRCS += lv_draw_rect.c
|
||||
CSRCS += lv_draw_transform.c
|
||||
CSRCS += lv_draw_layer.c
|
||||
CSRCS += lv_draw_triangle.c
|
||||
CSRCS += lv_img_buf.c
|
||||
CSRCS += lv_img_cache.c
|
||||
CSRCS += lv_img_decoder.c
|
||||
##
|
||||
DEPPATH += --dep-path $(LVGL_DIR)/$(LVGL_DIR_NAME)/src/draw
|
||||
VPATH += :$(LVGL_DIR)/$(LVGL_DIR_NAME)/src/draw
|
||||
CFLAGS += "-I$(LVGL_DIR)/$(LVGL_DIR_NAME)/src/draw"
|
||||
##
|
||||
CSRCS += lv_draw_sw.c
|
||||
CSRCS += lv_draw_sw_arc.c
|
||||
CSRCS += lv_draw_sw_blend.c
|
||||
CSRCS += lv_draw_sw_dither.c
|
||||
CSRCS += lv_draw_sw_gradient.c
|
||||
CSRCS += lv_draw_sw_img.c
|
||||
CSRCS += lv_draw_sw_letter.c
|
||||
CSRCS += lv_draw_sw_line.c
|
||||
CSRCS += lv_draw_sw_polygon.c
|
||||
CSRCS += lv_draw_sw_rect.c
|
||||
CSRCS += lv_draw_sw_transform.c
|
||||
CSRCS += lv_draw_sw_layer.c
|
||||
#
|
||||
DEPPATH += --dep-path $(LVGL_DIR)/$(LVGL_DIR_NAME)/src/draw/sw
|
||||
VPATH += :$(LVGL_DIR)/$(LVGL_DIR_NAME)/src/draw/sw
|
||||
CFLAGS += "-I$(LVGL_DIR)/$(LVGL_DIR_NAME)/src/draw/sw"
|
||||
###
|
||||
include $(LVGL_DIR)/$(LVGL_DIR_NAME)/src/extra/lv_extra.mk
|
||||
include $(LVGL_DIR)/$(LVGL_DIR_NAME)/src/font/lv_font.mk
|
||||
include $(LVGL_DIR)/$(LVGL_DIR_NAME)/src/hal/lv_hal.mk
|
||||
include $(LVGL_DIR)/$(LVGL_DIR_NAME)/src/misc/lv_misc.mk
|
||||
include $(LVGL_DIR)/$(LVGL_DIR_NAME)/src/widgets/lv_widgets.mk
|
||||
|
||||
#LVGL Drivers
|
||||
#include $(LVGL_DIR)/lv_drivers/lv_drivers.mk
|
||||
###
|
||||
LV_DRIVERS_DIR_NAME ?= lv_drivers
|
||||
override CFLAGS := -I$(LVGL_DIR) $(CFLAGS)
|
||||
CSRCS += $(wildcard $(LVGL_DIR)/$(LV_DRIVERS_DIR_NAME)/*.c)
|
||||
CSRCS += $(wildcard $(LVGL_DIR)/$(LV_DRIVERS_DIR_NAME)/indev/*.c)
|
||||
CSRCS += $(wildcard $(LVGL_DIR)/$(LV_DRIVERS_DIR_NAME)/display/*.c)
|
||||
###
|
||||
|
||||
# Mouse Cursor
|
||||
CSRCS +=$(LVGL_DIR)/mouse_cursor_icon.c
|
||||
|
||||
OBJEXT ?= .o
|
||||
|
||||
AOBJS = $(ASRCS:.S=$(OBJEXT))
|
||||
COBJS = $(CSRCS:.c=$(OBJEXT))
|
||||
|
||||
MAINOBJ = $(MAINSRC:.c=$(OBJEXT))
|
||||
|
||||
SRCS = $(ASRCS) $(CSRCS) $(MAINSRC)
|
||||
OBJS = $(AOBJS) $(COBJS)
|
||||
|
||||
## MAINOBJ -> OBJFILES
|
||||
|
||||
all: default
|
||||
|
||||
%.o: %.c
|
||||
@$(CC) $(CFLAGS) -c $< -o $@
|
||||
@echo "CC $<"
|
||||
|
||||
default: $(AOBJS) $(COBJS) $(MAINOBJ)
|
||||
$(CC) -o $(BIN) $(MAINOBJ) $(AOBJS) $(COBJS) $(LDFLAGS)
|
||||
strip -s l2eterm
|
||||
|
||||
clean:
|
||||
rm -f $(BIN) $(AOBJS) $(COBJS) $(MAINOBJ)
|
||||
find . -name '*~'
|
||||
find . -name '*~' -delete
|
||||
|
||||
|
||||
498
l2e_boot/l2e_sources/l2eterm/l2eterm.c
Normal file
498
l2e_boot/l2e_sources/l2eterm/l2eterm.c
Normal file
@ -0,0 +1,498 @@
|
||||
// Credit: lvgl, https://github.com/lupyuen/lvglterm and me (Vulcan)
|
||||
|
||||
#include "lv_drivers/display/fbdev.h"
|
||||
#include "lv_drivers/indev/evdev.h"
|
||||
#include "lvgl/lvgl.h"
|
||||
#include <dirent.h>
|
||||
#include <poll.h>
|
||||
#include <pthread.h>
|
||||
#include <spawn.h>
|
||||
#include <stddef.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <sys/time.h>
|
||||
#include <termios.h>
|
||||
#include <time.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#define DISP_BUF_SIZE (1920 * 256)
|
||||
|
||||
#define TIMER_PERIOD_MS 100
|
||||
#define READ_PIPE 0
|
||||
#define WRITE_PIPE 1
|
||||
#define L2E_TASK "/l2e"
|
||||
|
||||
static int create_widgets(void);
|
||||
static void timer_callback(lv_timer_t *timer);
|
||||
static void input_callback(lv_event_t *e);
|
||||
static bool has_input(int fd);
|
||||
static void remove_escape_codes(char *buf, int len);
|
||||
|
||||
/* Pipes for L2E Shell: stdin, stdout, stderr */
|
||||
|
||||
static int l2e_stdin[2];
|
||||
static int l2e_stdout[2];
|
||||
static int l2e_stderr[2];
|
||||
|
||||
/* LVGL Column Container for L2E Widgets */
|
||||
|
||||
static lv_obj_t *g_col;
|
||||
|
||||
/* LVGL Text Area Widgets for L2E Input and Output */
|
||||
|
||||
static lv_obj_t *g_input;
|
||||
static lv_obj_t *g_output;
|
||||
|
||||
/* LVGL Keyboard Widget for L2E Terminal */
|
||||
|
||||
static lv_obj_t *g_kb;
|
||||
|
||||
/* LVGL Font Style for L2E Input and Output */
|
||||
|
||||
static lv_style_t g_terminal_style;
|
||||
|
||||
/* LVGL Timer for polling L2E Output */
|
||||
|
||||
static lv_timer_t *g_timer;
|
||||
|
||||
/* Arguments for L2E Task */
|
||||
|
||||
static char *const l2e_argv[] = {L2E_TASK, NULL};
|
||||
|
||||
// Creates a Terminal
|
||||
static int create_terminal(void) {
|
||||
int ret;
|
||||
pid_t pid;
|
||||
|
||||
/* Create the pipes for L2E Shell: stdin, stdout and stderr */
|
||||
|
||||
ret = pipe(l2e_stdin);
|
||||
if (ret < 0) {
|
||||
printf("stdin pipe failed: %d\n", ret);
|
||||
return -1;
|
||||
}
|
||||
|
||||
ret = pipe(l2e_stdout);
|
||||
if (ret < 0) {
|
||||
printf("stdout pipe failed: %d\n", ret);
|
||||
return -1;
|
||||
}
|
||||
|
||||
ret = pipe(l2e_stderr);
|
||||
if (ret < 0) {
|
||||
printf("stderr pipe failed: %d\n", ret);
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* Close default stdin, stdout and stderr */
|
||||
|
||||
close(0);
|
||||
close(1);
|
||||
close(2);
|
||||
|
||||
/* Assign the new pipes as stdin, stdout and stderr */
|
||||
|
||||
dup2(l2e_stdin[READ_PIPE], 0);
|
||||
dup2(l2e_stdout[WRITE_PIPE], 1);
|
||||
dup2(l2e_stderr[WRITE_PIPE], 2);
|
||||
|
||||
/* Start the L2E Shell and inherit stdin, stdout and stderr */
|
||||
|
||||
ret = posix_spawn(&pid, /* Returned Task ID */
|
||||
L2E_TASK, /* L2E Path */
|
||||
NULL, /* Inherit stdin, stdout and stderr */
|
||||
NULL, /* Default spawn attributes */
|
||||
l2e_argv, /* Arguments */
|
||||
NULL); /* No environment */
|
||||
if (ret < 0) {
|
||||
int errcode = ret;
|
||||
printf("posix_spawn failed: %d\n", errcode);
|
||||
return -errcode;
|
||||
}
|
||||
|
||||
/* Create an LVGL Timer to poll for output from L2E Shell */
|
||||
|
||||
g_timer = lv_timer_create(timer_callback, /* Callback Function */
|
||||
TIMER_PERIOD_MS, /* Timer Period (millisec) */
|
||||
NULL); /* Callback Argument */
|
||||
|
||||
/* Create the LVGL Terminal Widgets */
|
||||
|
||||
ret = create_widgets();
|
||||
if (ret < 0) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Wallpaper
|
||||
|
||||
void set_wall(void) {
|
||||
// LV_IMG_DECLARE(img_lcars_png);
|
||||
lv_obj_t *img;
|
||||
|
||||
img = lv_img_create(lv_scr_act());
|
||||
/* Assuming a File system is attached to letter 'A'
|
||||
* E.g. set LV_USE_FS_STDIO 'A' in lv_conf.h */
|
||||
lv_img_set_src(img, "A:/tmp/LAIRS.png");
|
||||
lv_obj_align(img, LV_ALIGN_TOP_LEFT, 0, 0);
|
||||
}
|
||||
|
||||
// L.I.T.T Animation
|
||||
|
||||
static void anim_x_cb(void *var, int32_t v) { lv_obj_set_x(var, v); }
|
||||
|
||||
static void anim_size_cb(void *var, int32_t v) { lv_obj_set_size(var, v, v); }
|
||||
|
||||
/**
|
||||
* Create a playback animation
|
||||
*/
|
||||
void litt_anim(void) {
|
||||
|
||||
lv_obj_t *obj = lv_obj_create(lv_scr_act());
|
||||
lv_obj_set_style_bg_color(obj, lv_palette_main(LV_PALETTE_RED), 0);
|
||||
lv_obj_set_size(obj, 60, 10);
|
||||
lv_obj_set_style_radius(obj, 0, 0);
|
||||
|
||||
lv_obj_align(obj, LV_ALIGN_BOTTOM_MID, 0, 0);
|
||||
|
||||
lv_anim_t a;
|
||||
lv_anim_init(&a);
|
||||
lv_anim_set_var(&a, obj);
|
||||
lv_anim_set_values(&a, 0, 0);
|
||||
lv_anim_set_time(&a, 2000);
|
||||
lv_anim_set_playback_delay(&a, 300);
|
||||
lv_anim_set_playback_time(&a, 1000);
|
||||
lv_anim_set_repeat_delay(&a, 300);
|
||||
lv_anim_set_repeat_count(&a, 3);
|
||||
lv_anim_set_path_cb(&a, lv_anim_path_ease_in_out);
|
||||
|
||||
// lv_anim_set_exec_cb(&a, anim_size_cb);
|
||||
// lv_anim_start(&a);
|
||||
lv_anim_set_exec_cb(&a, anim_x_cb);
|
||||
lv_anim_set_values(&a, 0, 500);
|
||||
lv_anim_start(&a);
|
||||
}
|
||||
// End Animation
|
||||
|
||||
// Creates widgets
|
||||
static int create_widgets(void) {
|
||||
/* Set the Font Style for L2E Input and Output to a Monospaced Font */
|
||||
|
||||
lv_style_init(&g_terminal_style);
|
||||
lv_style_set_text_font(&g_terminal_style, &lv_font_unscii_16);
|
||||
|
||||
/* Create an LVGL Container with Column Flex Direction */
|
||||
|
||||
// add wallpaper
|
||||
set_wall();
|
||||
|
||||
// LITT Anim
|
||||
|
||||
litt_anim();
|
||||
|
||||
g_col = lv_obj_create(lv_scr_act());
|
||||
|
||||
lv_obj_set_size(g_col, 1425, 525);
|
||||
lv_obj_align(g_col, LV_ALIGN_TOP_LEFT, 353, 432);
|
||||
|
||||
lv_obj_set_flex_flow(g_col, LV_FLEX_FLOW_COLUMN);
|
||||
lv_obj_set_style_pad_all(g_col, 0, 0); /* No padding */
|
||||
|
||||
/* Create an LVGL Text Area Widget for L2E Output */
|
||||
|
||||
g_output = lv_textarea_create(g_col);
|
||||
|
||||
lv_obj_add_style(g_output, &g_terminal_style, 0);
|
||||
lv_obj_set_width(g_output, LV_PCT(100));
|
||||
lv_obj_set_flex_grow(g_output, 1); /* Fill the column */
|
||||
|
||||
/* Create an LVGL Text Area Widget for L2E Input */
|
||||
|
||||
g_input = lv_textarea_create(g_col);
|
||||
|
||||
lv_obj_add_style(g_input, &g_terminal_style, 0);
|
||||
lv_obj_set_size(g_input, LV_PCT(100), LV_SIZE_CONTENT);
|
||||
|
||||
/* Create an LVGL Keyboard Widget */
|
||||
|
||||
g_kb = lv_keyboard_create(g_col);
|
||||
|
||||
lv_obj_set_style_pad_all(g_kb, 0, 0); /* No padding */
|
||||
|
||||
/* Register the Callback Function for L2E Input */
|
||||
|
||||
lv_obj_add_event_cb(g_input, input_callback, LV_EVENT_ALL, NULL);
|
||||
|
||||
/* Set the Keyboard to populate the L2E Input Text Area */
|
||||
|
||||
lv_keyboard_set_textarea(g_kb, g_input);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Time Callback makes sure pipes are in sync
|
||||
static void timer_callback(lv_timer_t *timer) {
|
||||
int ret;
|
||||
static char buf[64];
|
||||
|
||||
/* Poll L2E stdout to check if there's output to be processed */
|
||||
|
||||
if (has_input(l2e_stdout[READ_PIPE])) {
|
||||
/* Read the output from L2E stdout */
|
||||
|
||||
ret = read(l2e_stdout[READ_PIPE], buf, sizeof(buf) - 1);
|
||||
if (ret > 0) {
|
||||
/* Add to L2E Output Text Area */
|
||||
|
||||
buf[ret] = 0;
|
||||
remove_escape_codes(buf, ret);
|
||||
lv_textarea_add_text(g_output, buf);
|
||||
}
|
||||
}
|
||||
|
||||
/* Poll L2E stderr to check if there's output to be processed */
|
||||
|
||||
if (has_input(l2e_stderr[READ_PIPE])) {
|
||||
/* Read the output from L2E stderr */
|
||||
|
||||
ret = read(l2e_stderr[READ_PIPE], buf, sizeof(buf) - 1);
|
||||
if (ret > 0) {
|
||||
/* Add to L2E Output Text Area */
|
||||
|
||||
buf[ret] = 0;
|
||||
remove_escape_codes(buf, ret);
|
||||
lv_textarea_add_text(g_output, buf);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// If Enter Key was pressed, send the L2E Input Command to L2E stdin.
|
||||
|
||||
static void input_callback(lv_event_t *e) {
|
||||
int ret;
|
||||
|
||||
/* Decode the LVGL Event */
|
||||
|
||||
const lv_event_code_t code = lv_event_get_code(e);
|
||||
|
||||
// Auto hide keyboard
|
||||
|
||||
if (code == LV_EVENT_FOCUSED) {
|
||||
if (lv_indev_get_type(lv_indev_get_act()) != LV_INDEV_TYPE_KEYPAD) {
|
||||
lv_keyboard_set_textarea(g_kb, g_input);
|
||||
lv_obj_update_layout(g_col); /*Be sure the sizes are recalculated*/
|
||||
lv_obj_clear_flag(g_kb, LV_OBJ_FLAG_HIDDEN);
|
||||
lv_obj_scroll_to_view_recursive(g_input, LV_ANIM_OFF);
|
||||
lv_indev_wait_release(lv_event_get_param(e));
|
||||
}
|
||||
} else if (code == LV_EVENT_DEFOCUSED) {
|
||||
lv_keyboard_set_textarea(g_kb, NULL);
|
||||
lv_obj_add_flag(g_kb, LV_OBJ_FLAG_HIDDEN);
|
||||
lv_indev_reset(NULL, g_input);
|
||||
litt_anim();
|
||||
}
|
||||
|
||||
/* If L2E Input Text Area has changed, get the Key Pressed */
|
||||
|
||||
if (code == LV_EVENT_VALUE_CHANGED) {
|
||||
/* Get the Button Index of the Keyboard Button Pressed */
|
||||
|
||||
const uint16_t id = lv_keyboard_get_selected_btn(g_kb);
|
||||
|
||||
/* Get the Text of the Keyboard Button */
|
||||
|
||||
const char *key = lv_keyboard_get_btn_text(g_kb, id);
|
||||
if (key == NULL) {
|
||||
return;
|
||||
}
|
||||
|
||||
/* If Key Pressed is Enter, send the Command to L2E stdin */
|
||||
|
||||
if (code == LV_EVENT_VALUE_CHANGED) {
|
||||
/* Read the L2E Input */
|
||||
|
||||
const char *cmd;
|
||||
|
||||
cmd = lv_textarea_get_text(g_input);
|
||||
if (cmd == NULL || cmd[0] == 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
/* Send the Command to L2E stdin */
|
||||
if (strchr(cmd, '\n')) {
|
||||
ret = write(l2e_stdin[WRITE_PIPE], cmd, strlen(cmd));
|
||||
/* Erase the L2E Input */
|
||||
lv_textarea_set_text(g_input, "");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Return true if the File Descriptor has data to be read.
|
||||
static bool has_input(int fd) {
|
||||
int ret;
|
||||
|
||||
/* Poll the File Descriptor for input */
|
||||
|
||||
struct pollfd fdp;
|
||||
fdp.fd = fd;
|
||||
fdp.events = POLLIN;
|
||||
ret = poll(&fdp, /* File Descriptors */
|
||||
1, /* Number of File Descriptors */
|
||||
0); /* Poll Timeout (Milliseconds) */
|
||||
|
||||
if (ret > 0) {
|
||||
/* If poll is OK and there is input */
|
||||
|
||||
if ((fdp.revents & POLLIN) != 0) {
|
||||
/* Report that there is input */
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/* Else report no input */
|
||||
|
||||
return false;
|
||||
} else if (ret == 0) {
|
||||
/* If timeout, report no input */
|
||||
|
||||
return false;
|
||||
} else if (ret < 0) {
|
||||
/* Handle error */
|
||||
|
||||
printf("poll failed: %d, fd=%d\n", ret, fd);
|
||||
return false;
|
||||
}
|
||||
|
||||
/* Never comes here */
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
// Remove ANSI Escape Codes from the string. Assumes that buf[len] is 0.
|
||||
static void remove_escape_codes(char *buf, int len) {
|
||||
int i;
|
||||
int j;
|
||||
|
||||
for (i = 0; i < len; i++) {
|
||||
/* Escape Code looks like 0x1b 0x5b 0x4b */
|
||||
|
||||
if (buf[i] == 0x1b) {
|
||||
/* Remove 3 bytes */
|
||||
|
||||
for (j = i; j + 2 < len; j++) {
|
||||
buf[j] = buf[j + 3];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Hide cursor
|
||||
static void hidecursor(bool setting) {
|
||||
// hide "\033[?25l" / show "\033[?25h"
|
||||
system(setting ? "echo -e \"\033[?25l\"" : "echo -e \"\033[?25h\"");
|
||||
}
|
||||
|
||||
// Make terminal silent
|
||||
// Credit: // https://stackoverflow.com/a/73204172
|
||||
void termprep() {
|
||||
struct termios tc;
|
||||
tcgetattr(0, &tc);
|
||||
tc.c_lflag &= ~(ICANON | ECHO);
|
||||
tc.c_cc[VMIN] = 0;
|
||||
tc.c_cc[VTIME] = 0;
|
||||
tcsetattr(0, TCSANOW, &tc);
|
||||
}
|
||||
|
||||
int main(void) {
|
||||
int ret;
|
||||
|
||||
hidecursor(true);
|
||||
|
||||
/* Prepare terminal */
|
||||
|
||||
static struct termios oterm;
|
||||
// Get current terminal parameters
|
||||
tcgetattr(0, &oterm);
|
||||
termprep();
|
||||
|
||||
/* LVGL initialization */
|
||||
|
||||
lv_init();
|
||||
|
||||
/* LVGL port initialization */
|
||||
|
||||
/*Linux frame buffer device init*/
|
||||
fbdev_init();
|
||||
|
||||
/*A small buffer for LittlevGL to draw the screen's content*/
|
||||
static lv_color_t buf[DISP_BUF_SIZE];
|
||||
|
||||
/*Initialize a descriptor for the buffer*/
|
||||
static lv_disp_draw_buf_t disp_buf;
|
||||
lv_disp_draw_buf_init(&disp_buf, buf, NULL, DISP_BUF_SIZE);
|
||||
|
||||
/*Initialize and register a display driver*/
|
||||
static lv_disp_drv_t disp_drv;
|
||||
lv_disp_drv_init(&disp_drv);
|
||||
disp_drv.draw_buf = &disp_buf;
|
||||
disp_drv.flush_cb = fbdev_flush;
|
||||
disp_drv.hor_res = 1920;
|
||||
disp_drv.ver_res = 1080;
|
||||
lv_disp_drv_register(&disp_drv);
|
||||
|
||||
evdev_init();
|
||||
static lv_indev_drv_t indev_drv_1;
|
||||
lv_indev_drv_init(&indev_drv_1); /*Basic initialization*/
|
||||
indev_drv_1.type = LV_INDEV_TYPE_POINTER;
|
||||
|
||||
/*This function will be called periodically (by the library) to get the mouse
|
||||
* position and state*/
|
||||
indev_drv_1.read_cb = evdev_read;
|
||||
lv_indev_t *mouse_indev = lv_indev_drv_register(&indev_drv_1);
|
||||
|
||||
/*Set a cursor for the mouse*/
|
||||
LV_IMG_DECLARE(mouse_cursor_icon)
|
||||
lv_obj_t *cursor_obj =
|
||||
lv_img_create(lv_scr_act()); /*Create an image object for the cursor */
|
||||
lv_img_set_src(cursor_obj, &mouse_cursor_icon); /*Set the image source*/
|
||||
lv_indev_set_cursor(mouse_indev,
|
||||
cursor_obj); /*Connect the image object to the driver*/
|
||||
|
||||
/* Create the LVGL Widgets */
|
||||
|
||||
ret = create_terminal();
|
||||
if (ret < 0) {
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
|
||||
/*Handle LitlevGL tasks (tickless mode)*/
|
||||
while (1) {
|
||||
lv_timer_handler();
|
||||
usleep(5000);
|
||||
}
|
||||
|
||||
// Restore terminal
|
||||
tcsetattr(STDIN_FILENO, TCSANOW, &oterm);
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
|
||||
/*Set in lv_conf.h as `LV_TICK_CUSTOM_SYS_TIME_EXPR`*/
|
||||
uint32_t custom_tick_get(void) {
|
||||
static uint64_t start_ms = 0;
|
||||
if (start_ms == 0) {
|
||||
struct timeval tv_start;
|
||||
gettimeofday(&tv_start, NULL);
|
||||
start_ms = (tv_start.tv_sec * 1000000 + tv_start.tv_usec) / 1000;
|
||||
}
|
||||
|
||||
struct timeval tv_now;
|
||||
gettimeofday(&tv_now, NULL);
|
||||
uint64_t now_ms;
|
||||
now_ms = (tv_now.tv_sec * 1000000 + tv_now.tv_usec) / 1000;
|
||||
uint32_t time_ms = now_ms - start_ms;
|
||||
return time_ms;
|
||||
}
|
||||
773
l2e_boot/l2e_sources/l2eterm/lv_conf.h
Normal file
773
l2e_boot/l2e_sources/l2eterm/lv_conf.h
Normal file
@ -0,0 +1,773 @@
|
||||
/**
|
||||
* @file lv_conf.h
|
||||
* Configuration file for v8.3.9
|
||||
*/
|
||||
|
||||
/*
|
||||
* Copy this file as `lv_conf.h`
|
||||
* 1. simply next to the `lvgl` folder
|
||||
* 2. or any other places and
|
||||
* - define `LV_CONF_INCLUDE_SIMPLE`
|
||||
* - add the path as include path
|
||||
*/
|
||||
|
||||
/* clang-format off */
|
||||
#if 1 /*Set it to "1" to enable content*/
|
||||
|
||||
#ifndef LV_CONF_H
|
||||
#define LV_CONF_H
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
/*=======================
|
||||
FUNCTION PROTOTYPES
|
||||
*=======================*/
|
||||
|
||||
extern uint32_t custom_tick_get(void);
|
||||
|
||||
/*====================
|
||||
COLOR SETTINGS
|
||||
*====================*/
|
||||
|
||||
/*Color depth: 1 (1 byte per pixel), 8 (RGB332), 16 (RGB565), 32 (ARGB8888)*/
|
||||
#define LV_COLOR_DEPTH 32
|
||||
|
||||
/*Swap the 2 bytes of RGB565 color. Useful if the display has an 8-bit interface (e.g. SPI)*/
|
||||
#define LV_COLOR_16_SWAP 0
|
||||
|
||||
/*Enable features to draw on transparent background.
|
||||
*It's required if opa, and transform_* style properties are used.
|
||||
*Can be also used if the UI is above another layer, e.g. an OSD menu or video player.*/
|
||||
#define LV_COLOR_SCREEN_TRANSP 0
|
||||
|
||||
/* Adjust color mix functions rounding. GPUs might calculate color mix (blending) differently.
|
||||
* 0: round down, 64: round up from x.75, 128: round up from half, 192: round up from x.25, 254: round up */
|
||||
#define LV_COLOR_MIX_ROUND_OFS 0
|
||||
|
||||
/*Images pixels with this color will not be drawn if they are chroma keyed)*/
|
||||
#define LV_COLOR_CHROMA_KEY lv_color_hex(0x00ff00) /*pure green*/
|
||||
|
||||
/*=========================
|
||||
MEMORY SETTINGS
|
||||
*=========================*/
|
||||
|
||||
/*1: use custom malloc/free, 0: use the built-in `lv_mem_alloc()` and `lv_mem_free()`*/
|
||||
#define LV_MEM_CUSTOM 0
|
||||
#if LV_MEM_CUSTOM == 0
|
||||
/*Size of the memory available for `lv_mem_alloc()` in bytes (>= 2kB)*/
|
||||
#define LV_MEM_SIZE (16 * 1920U * 1080U) /*[bytes]*/
|
||||
|
||||
/*Set an address for the memory pool instead of allocating it as a normal array. Can be in external SRAM too.*/
|
||||
#define LV_MEM_ADR 0 /*0: unused*/
|
||||
/*Instead of an address give a memory allocator that will be called to get a memory pool for LVGL. E.g. my_malloc*/
|
||||
#if LV_MEM_ADR == 0
|
||||
#undef LV_MEM_POOL_INCLUDE
|
||||
#undef LV_MEM_POOL_ALLOC
|
||||
#endif
|
||||
|
||||
#else /*LV_MEM_CUSTOM*/
|
||||
#define LV_MEM_CUSTOM_INCLUDE <stdlib.h> /*Header for the dynamic memory function*/
|
||||
#define LV_MEM_CUSTOM_ALLOC malloc
|
||||
#define LV_MEM_CUSTOM_FREE free
|
||||
#define LV_MEM_CUSTOM_REALLOC realloc
|
||||
#endif /*LV_MEM_CUSTOM*/
|
||||
|
||||
/*Number of the intermediate memory buffer used during rendering and other internal processing mechanisms.
|
||||
*You will see an error log message if there wasn't enough buffers. */
|
||||
#define LV_MEM_BUF_MAX_NUM 16
|
||||
|
||||
/*Use the standard `memcpy` and `memset` instead of LVGL's own functions. (Might or might not be faster).*/
|
||||
#define LV_MEMCPY_MEMSET_STD 0
|
||||
|
||||
/*====================
|
||||
HAL SETTINGS
|
||||
*====================*/
|
||||
|
||||
/*Default display refresh period. LVG will redraw changed areas with this period time*/
|
||||
#define LV_DISP_DEF_REFR_PERIOD 30 /*[ms]*/
|
||||
|
||||
/*Input device read period in milliseconds*/
|
||||
#define LV_INDEV_DEF_READ_PERIOD 30 /*[ms]*/
|
||||
|
||||
/*Use a custom tick source that tells the elapsed time in milliseconds.
|
||||
*It removes the need to manually update the tick with `lv_tick_inc()`)*/
|
||||
#define LV_TICK_CUSTOM 1
|
||||
#if LV_TICK_CUSTOM
|
||||
#define LV_TICK_CUSTOM_INCLUDE <stdint.h> /*Header for the system time function*/
|
||||
#define LV_TICK_CUSTOM_SYS_TIME_EXPR (custom_tick_get()) /*Expression evaluating to current system time in ms*/
|
||||
#endif /*LV_TICK_CUSTOM*/
|
||||
|
||||
/*Default Dot Per Inch. Used to initialize default sizes such as widgets sized, style paddings.
|
||||
*(Not so important, you can adjust it to modify default sizes and spaces)*/
|
||||
#define LV_DPI_DEF 130 /*[px/inch]*/
|
||||
|
||||
/*=======================
|
||||
* FEATURE CONFIGURATION
|
||||
*=======================*/
|
||||
|
||||
/*-------------
|
||||
* Drawing
|
||||
*-----------*/
|
||||
|
||||
/*Enable complex draw engine.
|
||||
*Required to draw shadow, gradient, rounded corners, circles, arc, skew lines, image transformations or any masks*/
|
||||
#define LV_DRAW_COMPLEX 1
|
||||
#if LV_DRAW_COMPLEX != 0
|
||||
|
||||
/*Allow buffering some shadow calculation.
|
||||
*LV_SHADOW_CACHE_SIZE is the max. shadow size to buffer, where shadow size is `shadow_width + radius`
|
||||
*Caching has LV_SHADOW_CACHE_SIZE^2 RAM cost*/
|
||||
#define LV_SHADOW_CACHE_SIZE 0
|
||||
|
||||
/* Set number of maximally cached circle data.
|
||||
* The circumference of 1/4 circle are saved for anti-aliasing
|
||||
* radius * 4 bytes are used per circle (the most often used radiuses are saved)
|
||||
* 0: to disable caching */
|
||||
#define LV_CIRCLE_CACHE_SIZE 4
|
||||
#endif /*LV_DRAW_COMPLEX*/
|
||||
|
||||
/**
|
||||
* "Simple layers" are used when a widget has `style_opa < 255` to buffer the widget into a layer
|
||||
* and blend it as an image with the given opacity.
|
||||
* Note that `bg_opa`, `text_opa` etc don't require buffering into layer)
|
||||
* The widget can be buffered in smaller chunks to avoid using large buffers.
|
||||
*
|
||||
* - LV_LAYER_SIMPLE_BUF_SIZE: [bytes] the optimal target buffer size. LVGL will try to allocate it
|
||||
* - LV_LAYER_SIMPLE_FALLBACK_BUF_SIZE: [bytes] used if `LV_LAYER_SIMPLE_BUF_SIZE` couldn't be allocated.
|
||||
*
|
||||
* Both buffer sizes are in bytes.
|
||||
* "Transformed layers" (where transform_angle/zoom properties are used) use larger buffers
|
||||
* and can't be drawn in chunks. So these settings affects only widgets with opacity.
|
||||
*/
|
||||
#define LV_LAYER_SIMPLE_BUF_SIZE (24 * 1024)
|
||||
#define LV_LAYER_SIMPLE_FALLBACK_BUF_SIZE (3 * 1024)
|
||||
|
||||
/*Default image cache size. Image caching keeps the images opened.
|
||||
*If only the built-in image formats are used there is no real advantage of caching. (I.e. if no new image decoder is added)
|
||||
*With complex image decoders (e.g. PNG or JPG) caching can save the continuous open/decode of images.
|
||||
*However the opened images might consume additional RAM.
|
||||
*0: to disable caching*/
|
||||
#define LV_IMG_CACHE_DEF_SIZE 0
|
||||
|
||||
/*Number of stops allowed per gradient. Increase this to allow more stops.
|
||||
*This adds (sizeof(lv_color_t) + 1) bytes per additional stop*/
|
||||
#define LV_GRADIENT_MAX_STOPS 2
|
||||
|
||||
/*Default gradient buffer size.
|
||||
*When LVGL calculates the gradient "maps" it can save them into a cache to avoid calculating them again.
|
||||
*LV_GRAD_CACHE_DEF_SIZE sets the size of this cache in bytes.
|
||||
*If the cache is too small the map will be allocated only while it's required for the drawing.
|
||||
*0 mean no caching.*/
|
||||
#define LV_GRAD_CACHE_DEF_SIZE 0
|
||||
|
||||
/*Allow dithering the gradients (to achieve visual smooth color gradients on limited color depth display)
|
||||
*LV_DITHER_GRADIENT implies allocating one or two more lines of the object's rendering surface
|
||||
*The increase in memory consumption is (32 bits * object width) plus 24 bits * object width if using error diffusion */
|
||||
#define LV_DITHER_GRADIENT 0
|
||||
#if LV_DITHER_GRADIENT
|
||||
/*Add support for error diffusion dithering.
|
||||
*Error diffusion dithering gets a much better visual result, but implies more CPU consumption and memory when drawing.
|
||||
*The increase in memory consumption is (24 bits * object's width)*/
|
||||
#define LV_DITHER_ERROR_DIFFUSION 0
|
||||
#endif
|
||||
|
||||
/*Maximum buffer size to allocate for rotation.
|
||||
*Only used if software rotation is enabled in the display driver.*/
|
||||
#define LV_DISP_ROT_MAX_BUF (10*1024)
|
||||
|
||||
/*-------------
|
||||
* GPU
|
||||
*-----------*/
|
||||
|
||||
/*Use Arm's 2D acceleration library Arm-2D */
|
||||
#define LV_USE_GPU_ARM2D 0
|
||||
|
||||
/*Use STM32's DMA2D (aka Chrom Art) GPU*/
|
||||
#define LV_USE_GPU_STM32_DMA2D 0
|
||||
#if LV_USE_GPU_STM32_DMA2D
|
||||
/*Must be defined to include path of CMSIS header of target processor
|
||||
e.g. "stm32f7xx.h" or "stm32f4xx.h"*/
|
||||
#define LV_GPU_DMA2D_CMSIS_INCLUDE
|
||||
#endif
|
||||
|
||||
/*Enable RA6M3 G2D GPU*/
|
||||
#define LV_USE_GPU_RA6M3_G2D 0
|
||||
#if LV_USE_GPU_RA6M3_G2D
|
||||
/*include path of target processor
|
||||
e.g. "hal_data.h"*/
|
||||
#define LV_GPU_RA6M3_G2D_INCLUDE "hal_data.h"
|
||||
#endif
|
||||
|
||||
/*Use SWM341's DMA2D GPU*/
|
||||
#define LV_USE_GPU_SWM341_DMA2D 0
|
||||
#if LV_USE_GPU_SWM341_DMA2D
|
||||
#define LV_GPU_SWM341_DMA2D_INCLUDE "SWM341.h"
|
||||
#endif
|
||||
|
||||
/*Use NXP's PXP GPU iMX RTxxx platforms*/
|
||||
#define LV_USE_GPU_NXP_PXP 0
|
||||
#if LV_USE_GPU_NXP_PXP
|
||||
/*1: Add default bare metal and FreeRTOS interrupt handling routines for PXP (lv_gpu_nxp_pxp_osa.c)
|
||||
* and call lv_gpu_nxp_pxp_init() automatically during lv_init(). Note that symbol SDK_OS_FREE_RTOS
|
||||
* has to be defined in order to use FreeRTOS OSA, otherwise bare-metal implementation is selected.
|
||||
*0: lv_gpu_nxp_pxp_init() has to be called manually before lv_init()
|
||||
*/
|
||||
#define LV_USE_GPU_NXP_PXP_AUTO_INIT 0
|
||||
#endif
|
||||
|
||||
/*Use NXP's VG-Lite GPU iMX RTxxx platforms*/
|
||||
#define LV_USE_GPU_NXP_VG_LITE 0
|
||||
|
||||
/*Use SDL renderer API*/
|
||||
#define LV_USE_GPU_SDL 0
|
||||
#if LV_USE_GPU_SDL
|
||||
#define LV_GPU_SDL_INCLUDE_PATH <SDL2/SDL.h>
|
||||
/*Texture cache size, 8MB by default*/
|
||||
#define LV_GPU_SDL_LRU_SIZE (1024 * 1024 * 8)
|
||||
/*Custom blend mode for mask drawing, disable if you need to link with older SDL2 lib*/
|
||||
#define LV_GPU_SDL_CUSTOM_BLEND_MODE (SDL_VERSION_ATLEAST(2, 0, 6))
|
||||
#endif
|
||||
|
||||
/*-------------
|
||||
* Logging
|
||||
*-----------*/
|
||||
|
||||
/*Enable the log module*/
|
||||
#define LV_USE_LOG 0
|
||||
#if LV_USE_LOG
|
||||
|
||||
/*How important log should be added:
|
||||
*LV_LOG_LEVEL_TRACE A lot of logs to give detailed information
|
||||
*LV_LOG_LEVEL_INFO Log important events
|
||||
*LV_LOG_LEVEL_WARN Log if something unwanted happened but didn't cause a problem
|
||||
*LV_LOG_LEVEL_ERROR Only critical issue, when the system may fail
|
||||
*LV_LOG_LEVEL_USER Only logs added by the user
|
||||
*LV_LOG_LEVEL_NONE Do not log anything*/
|
||||
#define LV_LOG_LEVEL LV_LOG_LEVEL_WARN
|
||||
|
||||
/*1: Print the log with 'printf';
|
||||
*0: User need to register a callback with `lv_log_register_print_cb()`*/
|
||||
#define LV_LOG_PRINTF 0
|
||||
|
||||
/*Enable/disable LV_LOG_TRACE in modules that produces a huge number of logs*/
|
||||
#define LV_LOG_TRACE_MEM 1
|
||||
#define LV_LOG_TRACE_TIMER 1
|
||||
#define LV_LOG_TRACE_INDEV 1
|
||||
#define LV_LOG_TRACE_DISP_REFR 1
|
||||
#define LV_LOG_TRACE_EVENT 1
|
||||
#define LV_LOG_TRACE_OBJ_CREATE 1
|
||||
#define LV_LOG_TRACE_LAYOUT 1
|
||||
#define LV_LOG_TRACE_ANIM 1
|
||||
|
||||
#endif /*LV_USE_LOG*/
|
||||
|
||||
/*-------------
|
||||
* Asserts
|
||||
*-----------*/
|
||||
|
||||
/*Enable asserts if an operation is failed or an invalid data is found.
|
||||
*If LV_USE_LOG is enabled an error message will be printed on failure*/
|
||||
#define LV_USE_ASSERT_NULL 1 /*Check if the parameter is NULL. (Very fast, recommended)*/
|
||||
#define LV_USE_ASSERT_MALLOC 1 /*Checks is the memory is successfully allocated or no. (Very fast, recommended)*/
|
||||
#define LV_USE_ASSERT_STYLE 0 /*Check if the styles are properly initialized. (Very fast, recommended)*/
|
||||
#define LV_USE_ASSERT_MEM_INTEGRITY 0 /*Check the integrity of `lv_mem` after critical operations. (Slow)*/
|
||||
#define LV_USE_ASSERT_OBJ 0 /*Check the object's type and existence (e.g. not deleted). (Slow)*/
|
||||
|
||||
/*Add a custom handler when assert happens e.g. to restart the MCU*/
|
||||
#define LV_ASSERT_HANDLER_INCLUDE <stdint.h>
|
||||
#define LV_ASSERT_HANDLER while(1); /*Halt by default*/
|
||||
|
||||
/*-------------
|
||||
* Others
|
||||
*-----------*/
|
||||
|
||||
/*1: Show CPU usage and FPS count*/
|
||||
#define LV_USE_PERF_MONITOR 0
|
||||
#if LV_USE_PERF_MONITOR
|
||||
#define LV_USE_PERF_MONITOR_POS LV_ALIGN_BOTTOM_RIGHT
|
||||
#endif
|
||||
|
||||
/*1: Show the used memory and the memory fragmentation
|
||||
* Requires LV_MEM_CUSTOM = 0*/
|
||||
#define LV_USE_MEM_MONITOR 0
|
||||
#if LV_USE_MEM_MONITOR
|
||||
#define LV_USE_MEM_MONITOR_POS LV_ALIGN_BOTTOM_LEFT
|
||||
#endif
|
||||
|
||||
/*1: Draw random colored rectangles over the redrawn areas*/
|
||||
#define LV_USE_REFR_DEBUG 0
|
||||
|
||||
/*Change the built in (v)snprintf functions*/
|
||||
#define LV_SPRINTF_CUSTOM 0
|
||||
#if LV_SPRINTF_CUSTOM
|
||||
#define LV_SPRINTF_INCLUDE <stdio.h>
|
||||
#define lv_snprintf snprintf
|
||||
#define lv_vsnprintf vsnprintf
|
||||
#else /*LV_SPRINTF_CUSTOM*/
|
||||
#define LV_SPRINTF_USE_FLOAT 0
|
||||
#endif /*LV_SPRINTF_CUSTOM*/
|
||||
|
||||
#define LV_USE_USER_DATA 1
|
||||
|
||||
/*Garbage Collector settings
|
||||
*Used if lvgl is bound to higher level language and the memory is managed by that language*/
|
||||
#define LV_ENABLE_GC 0
|
||||
#if LV_ENABLE_GC != 0
|
||||
#define LV_GC_INCLUDE "gc.h" /*Include Garbage Collector related things*/
|
||||
#endif /*LV_ENABLE_GC*/
|
||||
|
||||
/*=====================
|
||||
* COMPILER SETTINGS
|
||||
*====================*/
|
||||
|
||||
/*For big endian systems set to 1*/
|
||||
#define LV_BIG_ENDIAN_SYSTEM 0
|
||||
|
||||
/*Define a custom attribute to `lv_tick_inc` function*/
|
||||
#define LV_ATTRIBUTE_TICK_INC
|
||||
|
||||
/*Define a custom attribute to `lv_timer_handler` function*/
|
||||
#define LV_ATTRIBUTE_TIMER_HANDLER
|
||||
|
||||
/*Define a custom attribute to `lv_disp_flush_ready` function*/
|
||||
#define LV_ATTRIBUTE_FLUSH_READY
|
||||
|
||||
/*Required alignment size for buffers*/
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN_SIZE 1
|
||||
|
||||
/*Will be added where memories needs to be aligned (with -Os data might not be aligned to boundary by default).
|
||||
* E.g. __attribute__((aligned(4)))*/
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
|
||||
/*Attribute to mark large constant arrays for example font's bitmaps*/
|
||||
#define LV_ATTRIBUTE_LARGE_CONST
|
||||
|
||||
/*Compiler prefix for a big array declaration in RAM*/
|
||||
#define LV_ATTRIBUTE_LARGE_RAM_ARRAY
|
||||
|
||||
/*Place performance critical functions into a faster memory (e.g RAM)*/
|
||||
#define LV_ATTRIBUTE_FAST_MEM
|
||||
|
||||
/*Prefix variables that are used in GPU accelerated operations, often these need to be placed in RAM sections that are DMA accessible*/
|
||||
#define LV_ATTRIBUTE_DMA
|
||||
|
||||
/*Export integer constant to binding. This macro is used with constants in the form of LV_<CONST> that
|
||||
*should also appear on LVGL binding API such as Micropython.*/
|
||||
#define LV_EXPORT_CONST_INT(int_value) struct _silence_gcc_warning /*The default value just prevents GCC warning*/
|
||||
|
||||
/*Extend the default -32k..32k coordinate range to -4M..4M by using int32_t for coordinates instead of int16_t*/
|
||||
#define LV_USE_LARGE_COORD 0
|
||||
|
||||
/*==================
|
||||
* FONT USAGE
|
||||
*===================*/
|
||||
|
||||
/*Montserrat fonts with ASCII range and some symbols using bpp = 4
|
||||
*https://fonts.google.com/specimen/Montserrat*/
|
||||
#define LV_FONT_MONTSERRAT_8 0
|
||||
#define LV_FONT_MONTSERRAT_10 0
|
||||
#define LV_FONT_MONTSERRAT_12 0
|
||||
#define LV_FONT_MONTSERRAT_14 1
|
||||
#define LV_FONT_MONTSERRAT_16 0
|
||||
#define LV_FONT_MONTSERRAT_18 0
|
||||
#define LV_FONT_MONTSERRAT_20 0
|
||||
#define LV_FONT_MONTSERRAT_22 0
|
||||
#define LV_FONT_MONTSERRAT_24 0
|
||||
#define LV_FONT_MONTSERRAT_26 0
|
||||
#define LV_FONT_MONTSERRAT_28 0
|
||||
#define LV_FONT_MONTSERRAT_30 0
|
||||
#define LV_FONT_MONTSERRAT_32 0
|
||||
#define LV_FONT_MONTSERRAT_34 0
|
||||
#define LV_FONT_MONTSERRAT_36 0
|
||||
#define LV_FONT_MONTSERRAT_38 0
|
||||
#define LV_FONT_MONTSERRAT_40 0
|
||||
#define LV_FONT_MONTSERRAT_42 0
|
||||
#define LV_FONT_MONTSERRAT_44 0
|
||||
#define LV_FONT_MONTSERRAT_46 0
|
||||
#define LV_FONT_MONTSERRAT_48 0
|
||||
|
||||
/*Demonstrate special features*/
|
||||
#define LV_FONT_MONTSERRAT_12_SUBPX 0
|
||||
#define LV_FONT_MONTSERRAT_28_COMPRESSED 0 /*bpp = 3*/
|
||||
#define LV_FONT_DEJAVU_16_PERSIAN_HEBREW 0 /*Hebrew, Arabic, Persian letters and all their forms*/
|
||||
#define LV_FONT_SIMSUN_16_CJK 0 /*1000 most common CJK radicals*/
|
||||
|
||||
/*Pixel perfect monospace fonts*/
|
||||
#define LV_FONT_UNSCII_8 0
|
||||
#define LV_FONT_UNSCII_16 1
|
||||
|
||||
/*Optionally declare custom fonts here.
|
||||
*You can use these fonts as default font too and they will be available globally.
|
||||
*E.g. #define LV_FONT_CUSTOM_DECLARE LV_FONT_DECLARE(my_font_1) LV_FONT_DECLARE(my_font_2)*/
|
||||
#define LV_FONT_CUSTOM_DECLARE
|
||||
|
||||
/*Always set a default font*/
|
||||
#define LV_FONT_DEFAULT &lv_font_montserrat_14
|
||||
|
||||
/*Enable handling large font and/or fonts with a lot of characters.
|
||||
*The limit depends on the font size, font face and bpp.
|
||||
*Compiler error will be triggered if a font needs it.*/
|
||||
#define LV_FONT_FMT_TXT_LARGE 0
|
||||
|
||||
/*Enables/disables support for compressed fonts.*/
|
||||
#define LV_USE_FONT_COMPRESSED 0
|
||||
|
||||
/*Enable subpixel rendering*/
|
||||
#define LV_USE_FONT_SUBPX 0
|
||||
#if LV_USE_FONT_SUBPX
|
||||
/*Set the pixel order of the display. Physical order of RGB channels. Doesn't matter with "normal" fonts.*/
|
||||
#define LV_FONT_SUBPX_BGR 0 /*0: RGB; 1:BGR order*/
|
||||
#endif
|
||||
|
||||
/*Enable drawing placeholders when glyph dsc is not found*/
|
||||
#define LV_USE_FONT_PLACEHOLDER 1
|
||||
|
||||
/*=================
|
||||
* TEXT SETTINGS
|
||||
*=================*/
|
||||
|
||||
/**
|
||||
* Select a character encoding for strings.
|
||||
* Your IDE or editor should have the same character encoding
|
||||
* - LV_TXT_ENC_UTF8
|
||||
* - LV_TXT_ENC_ASCII
|
||||
*/
|
||||
#define LV_TXT_ENC LV_TXT_ENC_UTF8
|
||||
|
||||
/*Can break (wrap) texts on these chars*/
|
||||
#define LV_TXT_BREAK_CHARS " ,.;:-_"
|
||||
|
||||
/*If a word is at least this long, will break wherever "prettiest"
|
||||
*To disable, set to a value <= 0*/
|
||||
#define LV_TXT_LINE_BREAK_LONG_LEN 0
|
||||
|
||||
/*Minimum number of characters in a long word to put on a line before a break.
|
||||
*Depends on LV_TXT_LINE_BREAK_LONG_LEN.*/
|
||||
#define LV_TXT_LINE_BREAK_LONG_PRE_MIN_LEN 3
|
||||
|
||||
/*Minimum number of characters in a long word to put on a line after a break.
|
||||
*Depends on LV_TXT_LINE_BREAK_LONG_LEN.*/
|
||||
#define LV_TXT_LINE_BREAK_LONG_POST_MIN_LEN 3
|
||||
|
||||
/*The control character to use for signalling text recoloring.*/
|
||||
#define LV_TXT_COLOR_CMD "#"
|
||||
|
||||
/*Support bidirectional texts. Allows mixing Left-to-Right and Right-to-Left texts.
|
||||
*The direction will be processed according to the Unicode Bidirectional Algorithm:
|
||||
*https://www.w3.org/International/articles/inline-bidi-markup/uba-basics*/
|
||||
#define LV_USE_BIDI 0
|
||||
#if LV_USE_BIDI
|
||||
/*Set the default direction. Supported values:
|
||||
*`LV_BASE_DIR_LTR` Left-to-Right
|
||||
*`LV_BASE_DIR_RTL` Right-to-Left
|
||||
*`LV_BASE_DIR_AUTO` detect texts base direction*/
|
||||
#define LV_BIDI_BASE_DIR_DEF LV_BASE_DIR_AUTO
|
||||
#endif
|
||||
|
||||
/*Enable Arabic/Persian processing
|
||||
*In these languages characters should be replaced with an other form based on their position in the text*/
|
||||
#define LV_USE_ARABIC_PERSIAN_CHARS 0
|
||||
|
||||
/*==================
|
||||
* WIDGET USAGE
|
||||
*================*/
|
||||
|
||||
/*Documentation of the widgets: https://docs.lvgl.io/latest/en/html/widgets/index.html*/
|
||||
|
||||
#define LV_USE_ARC 1
|
||||
|
||||
#define LV_USE_BAR 1
|
||||
|
||||
#define LV_USE_BTN 1
|
||||
|
||||
#define LV_USE_BTNMATRIX 1
|
||||
|
||||
#define LV_USE_CANVAS 1
|
||||
|
||||
#define LV_USE_CHECKBOX 1
|
||||
|
||||
#define LV_USE_DROPDOWN 1 /*Requires: lv_label*/
|
||||
|
||||
#define LV_USE_IMG 1 /*Requires: lv_label*/
|
||||
|
||||
#define LV_USE_LABEL 1
|
||||
#if LV_USE_LABEL
|
||||
#define LV_LABEL_TEXT_SELECTION 1 /*Enable selecting text of the label*/
|
||||
#define LV_LABEL_LONG_TXT_HINT 1 /*Store some extra info in labels to speed up drawing of very long texts*/
|
||||
#endif
|
||||
|
||||
#define LV_USE_LINE 1
|
||||
|
||||
#define LV_USE_ROLLER 1 /*Requires: lv_label*/
|
||||
#if LV_USE_ROLLER
|
||||
#define LV_ROLLER_INF_PAGES 7 /*Number of extra "pages" when the roller is infinite*/
|
||||
#endif
|
||||
|
||||
#define LV_USE_SLIDER 1 /*Requires: lv_bar*/
|
||||
|
||||
#define LV_USE_SWITCH 1
|
||||
|
||||
#define LV_USE_TEXTAREA 1 /*Requires: lv_label*/
|
||||
#if LV_USE_TEXTAREA != 0
|
||||
#define LV_TEXTAREA_DEF_PWD_SHOW_TIME 1500 /*ms*/
|
||||
#endif
|
||||
|
||||
#define LV_USE_TABLE 1
|
||||
|
||||
/*==================
|
||||
* EXTRA COMPONENTS
|
||||
*==================*/
|
||||
|
||||
/*-----------
|
||||
* Widgets
|
||||
*----------*/
|
||||
#define LV_USE_ANIMIMG 1
|
||||
|
||||
#define LV_USE_CALENDAR 1
|
||||
#if LV_USE_CALENDAR
|
||||
#define LV_CALENDAR_WEEK_STARTS_MONDAY 0
|
||||
#if LV_CALENDAR_WEEK_STARTS_MONDAY
|
||||
#define LV_CALENDAR_DEFAULT_DAY_NAMES {"Mo", "Tu", "We", "Th", "Fr", "Sa", "Su"}
|
||||
#else
|
||||
#define LV_CALENDAR_DEFAULT_DAY_NAMES {"Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"}
|
||||
#endif
|
||||
|
||||
#define LV_CALENDAR_DEFAULT_MONTH_NAMES {"January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"}
|
||||
#define LV_USE_CALENDAR_HEADER_ARROW 1
|
||||
#define LV_USE_CALENDAR_HEADER_DROPDOWN 1
|
||||
#endif /*LV_USE_CALENDAR*/
|
||||
|
||||
#define LV_USE_CHART 1
|
||||
|
||||
#define LV_USE_COLORWHEEL 1
|
||||
|
||||
#define LV_USE_IMGBTN 1
|
||||
|
||||
#define LV_USE_KEYBOARD 1
|
||||
|
||||
#define LV_USE_LED 1
|
||||
|
||||
#define LV_USE_LIST 1
|
||||
|
||||
#define LV_USE_MENU 1
|
||||
|
||||
#define LV_USE_METER 1
|
||||
|
||||
#define LV_USE_MSGBOX 1
|
||||
|
||||
#define LV_USE_SPAN 1
|
||||
#if LV_USE_SPAN
|
||||
/*A line text can contain maximum num of span descriptor */
|
||||
#define LV_SPAN_SNIPPET_STACK_SIZE 64
|
||||
#endif
|
||||
|
||||
#define LV_USE_SPINBOX 1
|
||||
|
||||
#define LV_USE_SPINNER 1
|
||||
|
||||
#define LV_USE_TABVIEW 1
|
||||
|
||||
#define LV_USE_TILEVIEW 1
|
||||
|
||||
#define LV_USE_WIN 1
|
||||
|
||||
/*-----------
|
||||
* Themes
|
||||
*----------*/
|
||||
|
||||
/*A simple, impressive and very complete theme*/
|
||||
#define LV_USE_THEME_DEFAULT 1
|
||||
#if LV_USE_THEME_DEFAULT
|
||||
|
||||
/*0: Light mode; 1: Dark mode*/
|
||||
#define LV_THEME_DEFAULT_DARK 1
|
||||
|
||||
/*1: Enable grow on press*/
|
||||
#define LV_THEME_DEFAULT_GROW 1
|
||||
|
||||
/*Default transition time in [ms]*/
|
||||
#define LV_THEME_DEFAULT_TRANSITION_TIME 80
|
||||
#endif /*LV_USE_THEME_DEFAULT*/
|
||||
|
||||
/*A very simple theme that is a good starting point for a custom theme*/
|
||||
#define LV_USE_THEME_BASIC 1
|
||||
|
||||
/*A theme designed for monochrome displays*/
|
||||
#define LV_USE_THEME_MONO 1
|
||||
|
||||
/*-----------
|
||||
* Layouts
|
||||
*----------*/
|
||||
|
||||
/*A layout similar to Flexbox in CSS.*/
|
||||
#define LV_USE_FLEX 1
|
||||
|
||||
/*A layout similar to Grid in CSS.*/
|
||||
#define LV_USE_GRID 1
|
||||
|
||||
/*---------------------
|
||||
* 3rd party libraries
|
||||
*--------------------*/
|
||||
|
||||
/*File system interfaces for common APIs */
|
||||
|
||||
/*API for fopen, fread, etc*/
|
||||
#define LV_USE_FS_STDIO 1
|
||||
#if LV_USE_FS_STDIO
|
||||
#define LV_FS_STDIO_LETTER 'A' /*Set an upper cased letter on which the drive will accessible (e.g. 'A')*/
|
||||
#define LV_FS_STDIO_PATH "" /*Set the working directory. File/directory paths will be appended to it.*/
|
||||
#define LV_FS_STDIO_CACHE_SIZE 0 /*>0 to cache this number of bytes in lv_fs_read()*/
|
||||
#endif
|
||||
|
||||
/*API for open, read, etc*/
|
||||
#define LV_USE_FS_POSIX 0
|
||||
#if LV_USE_FS_POSIX
|
||||
#define LV_FS_POSIX_LETTER '\0' /*Set an upper cased letter on which the drive will accessible (e.g. 'A')*/
|
||||
#define LV_FS_POSIX_PATH "" /*Set the working directory. File/directory paths will be appended to it.*/
|
||||
#define LV_FS_POSIX_CACHE_SIZE 0 /*>0 to cache this number of bytes in lv_fs_read()*/
|
||||
#endif
|
||||
|
||||
/*API for CreateFile, ReadFile, etc*/
|
||||
#define LV_USE_FS_WIN32 0
|
||||
#if LV_USE_FS_WIN32
|
||||
#define LV_FS_WIN32_LETTER '\0' /*Set an upper cased letter on which the drive will accessible (e.g. 'A')*/
|
||||
#define LV_FS_WIN32_PATH "" /*Set the working directory. File/directory paths will be appended to it.*/
|
||||
#define LV_FS_WIN32_CACHE_SIZE 0 /*>0 to cache this number of bytes in lv_fs_read()*/
|
||||
#endif
|
||||
|
||||
/*API for FATFS (needs to be added separately). Uses f_open, f_read, etc*/
|
||||
#define LV_USE_FS_FATFS 0
|
||||
#if LV_USE_FS_FATFS
|
||||
#define LV_FS_FATFS_LETTER '\0' /*Set an upper cased letter on which the drive will accessible (e.g. 'A')*/
|
||||
#define LV_FS_FATFS_CACHE_SIZE 0 /*>0 to cache this number of bytes in lv_fs_read()*/
|
||||
#endif
|
||||
|
||||
/*PNG decoder library*/
|
||||
#define LV_USE_PNG 1
|
||||
|
||||
/*BMP decoder library*/
|
||||
#define LV_USE_BMP 0
|
||||
|
||||
/* JPG + split JPG decoder library.
|
||||
* Split JPG is a custom format optimized for embedded systems. */
|
||||
#define LV_USE_SJPG 0
|
||||
|
||||
/*GIF decoder library*/
|
||||
#define LV_USE_GIF 0
|
||||
|
||||
/*QR code library*/
|
||||
#define LV_USE_QRCODE 0
|
||||
|
||||
/*FreeType library*/
|
||||
#define LV_USE_FREETYPE 0
|
||||
#if LV_USE_FREETYPE
|
||||
/*Memory used by FreeType to cache characters [bytes] (-1: no caching)*/
|
||||
#define LV_FREETYPE_CACHE_SIZE (16 * 1024)
|
||||
#if LV_FREETYPE_CACHE_SIZE >= 0
|
||||
/* 1: bitmap cache use the sbit cache, 0:bitmap cache use the image cache. */
|
||||
/* sbit cache:it is much more memory efficient for small bitmaps(font size < 256) */
|
||||
/* if font size >= 256, must be configured as image cache */
|
||||
#define LV_FREETYPE_SBIT_CACHE 0
|
||||
/* Maximum number of opened FT_Face/FT_Size objects managed by this cache instance. */
|
||||
/* (0:use system defaults) */
|
||||
#define LV_FREETYPE_CACHE_FT_FACES 0
|
||||
#define LV_FREETYPE_CACHE_FT_SIZES 0
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/*Rlottie library*/
|
||||
#define LV_USE_RLOTTIE 0
|
||||
|
||||
/*FFmpeg library for image decoding and playing videos
|
||||
*Supports all major image formats so do not enable other image decoder with it*/
|
||||
#define LV_USE_FFMPEG 0
|
||||
#if LV_USE_FFMPEG
|
||||
/*Dump input information to stderr*/
|
||||
#define LV_FFMPEG_DUMP_FORMAT 0
|
||||
#endif
|
||||
|
||||
/*-----------
|
||||
* Others
|
||||
*----------*/
|
||||
|
||||
/*1: Enable API to take snapshot for object*/
|
||||
#define LV_USE_SNAPSHOT 0
|
||||
|
||||
/*1: Enable Monkey test*/
|
||||
#define LV_USE_MONKEY 0
|
||||
|
||||
/*1: Enable grid navigation*/
|
||||
#define LV_USE_GRIDNAV 0
|
||||
|
||||
/*1: Enable lv_obj fragment*/
|
||||
#define LV_USE_FRAGMENT 0
|
||||
|
||||
/*1: Support using images as font in label or span widgets */
|
||||
#define LV_USE_IMGFONT 0
|
||||
|
||||
/*1: Enable a published subscriber based messaging system */
|
||||
#define LV_USE_MSG 0
|
||||
|
||||
/*1: Enable Pinyin input method*/
|
||||
/*Requires: lv_keyboard*/
|
||||
#define LV_USE_IME_PINYIN 0
|
||||
#if LV_USE_IME_PINYIN
|
||||
/*1: Use default thesaurus*/
|
||||
/*If you do not use the default thesaurus, be sure to use `lv_ime_pinyin` after setting the thesauruss*/
|
||||
#define LV_IME_PINYIN_USE_DEFAULT_DICT 1
|
||||
/*Set the maximum number of candidate panels that can be displayed*/
|
||||
/*This needs to be adjusted according to the size of the screen*/
|
||||
#define LV_IME_PINYIN_CAND_TEXT_NUM 6
|
||||
|
||||
/*Use 9 key input(k9)*/
|
||||
#define LV_IME_PINYIN_USE_K9_MODE 1
|
||||
#if LV_IME_PINYIN_USE_K9_MODE == 1
|
||||
#define LV_IME_PINYIN_K9_CAND_TEXT_NUM 3
|
||||
#endif // LV_IME_PINYIN_USE_K9_MODE
|
||||
#endif
|
||||
|
||||
/*==================
|
||||
* EXAMPLES
|
||||
*==================*/
|
||||
|
||||
/*Enable the examples to be built with the library*/
|
||||
#define LV_BUILD_EXAMPLES 0
|
||||
|
||||
/*===================
|
||||
* DEMO USAGE
|
||||
====================*/
|
||||
|
||||
/*Show some widget. It might be required to increase `LV_MEM_SIZE` */
|
||||
#define LV_USE_DEMO_WIDGETS 0
|
||||
#if LV_USE_DEMO_WIDGETS
|
||||
#define LV_DEMO_WIDGETS_SLIDESHOW 0
|
||||
#endif
|
||||
|
||||
/*Demonstrate the usage of encoder and keyboard*/
|
||||
#define LV_USE_DEMO_KEYPAD_AND_ENCODER 0
|
||||
|
||||
/*Benchmark your system*/
|
||||
#define LV_USE_DEMO_BENCHMARK 0
|
||||
#if LV_USE_DEMO_BENCHMARK
|
||||
/*Use RGB565A8 images with 16 bit color depth instead of ARGB8565*/
|
||||
#define LV_DEMO_BENCHMARK_RGB565A8 0
|
||||
#endif
|
||||
|
||||
/*Stress test for LVGL*/
|
||||
#define LV_USE_DEMO_STRESS 0
|
||||
|
||||
/*Music player demo*/
|
||||
#define LV_USE_DEMO_MUSIC 0
|
||||
#if LV_USE_DEMO_MUSIC
|
||||
#define LV_DEMO_MUSIC_SQUARE 0
|
||||
#define LV_DEMO_MUSIC_LANDSCAPE 0
|
||||
#define LV_DEMO_MUSIC_ROUND 0
|
||||
#define LV_DEMO_MUSIC_LARGE 0
|
||||
#define LV_DEMO_MUSIC_AUTO_PLAY 0
|
||||
#endif
|
||||
|
||||
/*--END OF LV_CONF_H--*/
|
||||
|
||||
#endif /*LV_CONF_H*/
|
||||
|
||||
#endif /*End of "Content enable"*/
|
||||
494
l2e_boot/l2e_sources/l2eterm/lv_drv_conf.h
Normal file
494
l2e_boot/l2e_sources/l2eterm/lv_drv_conf.h
Normal file
@ -0,0 +1,494 @@
|
||||
/**
|
||||
* @file lv_drv_conf.h
|
||||
* Configuration file for v8.3.0
|
||||
*/
|
||||
|
||||
/*
|
||||
* COPY THIS FILE AS lv_drv_conf.h
|
||||
*/
|
||||
|
||||
/* clang-format off */
|
||||
#if 1 /*Set it to "1" to enable the content*/
|
||||
|
||||
#ifndef LV_DRV_CONF_H
|
||||
#define LV_DRV_CONF_H
|
||||
|
||||
#include "lv_conf.h"
|
||||
|
||||
/*********************
|
||||
* DELAY INTERFACE
|
||||
*********************/
|
||||
#define LV_DRV_DELAY_INCLUDE <stdint.h> /*Dummy include by default*/
|
||||
#define LV_DRV_DELAY_US(us) /*delay_us(us)*/ /*Delay the given number of microseconds*/
|
||||
#define LV_DRV_DELAY_MS(ms) /*delay_ms(ms)*/ /*Delay the given number of milliseconds*/
|
||||
|
||||
/*********************
|
||||
* DISPLAY INTERFACE
|
||||
*********************/
|
||||
|
||||
/*------------
|
||||
* Common
|
||||
*------------*/
|
||||
#define LV_DRV_DISP_INCLUDE <stdint.h> /*Dummy include by default*/
|
||||
#define LV_DRV_DISP_CMD_DATA(val) /*pin_x_set(val)*/ /*Set the command/data pin to 'val'*/
|
||||
#define LV_DRV_DISP_RST(val) /*pin_x_set(val)*/ /*Set the reset pin to 'val'*/
|
||||
|
||||
/*---------
|
||||
* SPI
|
||||
*---------*/
|
||||
#define LV_DRV_DISP_SPI_CS(val) /*spi_cs_set(val)*/ /*Set the SPI's Chip select to 'val'*/
|
||||
#define LV_DRV_DISP_SPI_WR_BYTE(data) /*spi_wr(data)*/ /*Write a byte the SPI bus*/
|
||||
#define LV_DRV_DISP_SPI_WR_ARRAY(adr, n) /*spi_wr_mem(adr, n)*/ /*Write 'n' bytes to SPI bus from 'adr'*/
|
||||
|
||||
/*------------------
|
||||
* Parallel port
|
||||
*-----------------*/
|
||||
#define LV_DRV_DISP_PAR_CS(val) /*par_cs_set(val)*/ /*Set the Parallel port's Chip select to 'val'*/
|
||||
#define LV_DRV_DISP_PAR_SLOW /*par_slow()*/ /*Set low speed on the parallel port*/
|
||||
#define LV_DRV_DISP_PAR_FAST /*par_fast()*/ /*Set high speed on the parallel port*/
|
||||
#define LV_DRV_DISP_PAR_WR_WORD(data) /*par_wr(data)*/ /*Write a word to the parallel port*/
|
||||
#define LV_DRV_DISP_PAR_WR_ARRAY(adr, n) /*par_wr_mem(adr,n)*/ /*Write 'n' bytes to Parallel ports from 'adr'*/
|
||||
|
||||
/***************************
|
||||
* INPUT DEVICE INTERFACE
|
||||
***************************/
|
||||
|
||||
/*----------
|
||||
* Common
|
||||
*----------*/
|
||||
#define LV_DRV_INDEV_INCLUDE <stdint.h> /*Dummy include by default*/
|
||||
#define LV_DRV_INDEV_RST(val) /*pin_x_set(val)*/ /*Set the reset pin to 'val'*/
|
||||
#define LV_DRV_INDEV_IRQ_READ 0 /*pn_x_read()*/ /*Read the IRQ pin*/
|
||||
|
||||
/*---------
|
||||
* SPI
|
||||
*---------*/
|
||||
#define LV_DRV_INDEV_SPI_CS(val) /*spi_cs_set(val)*/ /*Set the SPI's Chip select to 'val'*/
|
||||
#define LV_DRV_INDEV_SPI_XCHG_BYTE(data) 0 /*spi_xchg(val)*/ /*Write 'val' to SPI and give the read value*/
|
||||
|
||||
/*---------
|
||||
* I2C
|
||||
*---------*/
|
||||
#define LV_DRV_INDEV_I2C_START /*i2c_start()*/ /*Make an I2C start*/
|
||||
#define LV_DRV_INDEV_I2C_STOP /*i2c_stop()*/ /*Make an I2C stop*/
|
||||
#define LV_DRV_INDEV_I2C_RESTART /*i2c_restart()*/ /*Make an I2C restart*/
|
||||
#define LV_DRV_INDEV_I2C_WR(data) /*i2c_wr(data)*/ /*Write a byte to the I1C bus*/
|
||||
#define LV_DRV_INDEV_I2C_READ(last_read) 0 /*i2c_rd()*/ /*Read a byte from the I2C bud*/
|
||||
|
||||
|
||||
/*********************
|
||||
* DISPLAY DRIVERS
|
||||
*********************/
|
||||
|
||||
/*-------------------
|
||||
* SDL
|
||||
*-------------------*/
|
||||
|
||||
/* SDL based drivers for display, mouse, mousewheel and keyboard*/
|
||||
#ifndef USE_SDL
|
||||
# define USE_SDL 0
|
||||
#endif
|
||||
|
||||
/* Hardware accelerated SDL driver */
|
||||
#ifndef USE_SDL_GPU
|
||||
# define USE_SDL_GPU 0
|
||||
#endif
|
||||
|
||||
#if USE_SDL || USE_SDL_GPU
|
||||
# define SDL_HOR_RES 480
|
||||
# define SDL_VER_RES 320
|
||||
|
||||
/* Scale window by this factor (useful when simulating small screens) */
|
||||
# define SDL_ZOOM 1
|
||||
|
||||
/* Used to test true double buffering with only address changing.
|
||||
* Use 2 draw buffers, bith with SDL_HOR_RES x SDL_VER_RES size*/
|
||||
# define SDL_DOUBLE_BUFFERED 0
|
||||
|
||||
/*Eclipse: <SDL2/SDL.h> Visual Studio: <SDL.h>*/
|
||||
# define SDL_INCLUDE_PATH <SDL2/SDL.h>
|
||||
|
||||
/*Open two windows to test multi display support*/
|
||||
# define SDL_DUAL_DISPLAY 0
|
||||
#endif
|
||||
|
||||
/*-------------------
|
||||
* Monitor of PC
|
||||
*-------------------*/
|
||||
|
||||
/*DEPRECATED: Use the SDL driver instead. */
|
||||
#ifndef USE_MONITOR
|
||||
# define USE_MONITOR 0
|
||||
#endif
|
||||
|
||||
#if USE_MONITOR
|
||||
# define MONITOR_HOR_RES 480
|
||||
# define MONITOR_VER_RES 320
|
||||
|
||||
/* Scale window by this factor (useful when simulating small screens) */
|
||||
# define MONITOR_ZOOM 1
|
||||
|
||||
/* Used to test true double buffering with only address changing.
|
||||
* Use 2 draw buffers, bith with MONITOR_HOR_RES x MONITOR_VER_RES size*/
|
||||
# define MONITOR_DOUBLE_BUFFERED 0
|
||||
|
||||
/*Eclipse: <SDL2/SDL.h> Visual Studio: <SDL.h>*/
|
||||
# define MONITOR_SDL_INCLUDE_PATH <SDL2/SDL.h>
|
||||
|
||||
/*Open two windows to test multi display support*/
|
||||
# define MONITOR_DUAL 0
|
||||
#endif
|
||||
|
||||
/*-----------------------------------
|
||||
* Native Windows (including mouse)
|
||||
*----------------------------------*/
|
||||
#ifndef USE_WINDOWS
|
||||
# define USE_WINDOWS 0
|
||||
#endif
|
||||
|
||||
#if USE_WINDOWS
|
||||
# define WINDOW_HOR_RES 480
|
||||
# define WINDOW_VER_RES 320
|
||||
#endif
|
||||
|
||||
/*----------------------------
|
||||
* Native Windows (win32drv)
|
||||
*---------------------------*/
|
||||
#ifndef USE_WIN32DRV
|
||||
# define USE_WIN32DRV 0
|
||||
#endif
|
||||
|
||||
#if USE_WIN32DRV
|
||||
/* Scale window by this factor (useful when simulating small screens) */
|
||||
# define WIN32DRV_MONITOR_ZOOM 1
|
||||
#endif
|
||||
|
||||
/*----------------------------------------
|
||||
* GTK drivers (monitor, mouse, keyboard
|
||||
*---------------------------------------*/
|
||||
#ifndef USE_GTK
|
||||
# define USE_GTK 0
|
||||
#endif
|
||||
|
||||
/*----------------------------------------
|
||||
* Wayland drivers (monitor, mouse, keyboard, touchscreen)
|
||||
*---------------------------------------*/
|
||||
#ifndef USE_WAYLAND
|
||||
# define USE_WAYLAND 0
|
||||
#endif
|
||||
|
||||
#if USE_WAYLAND
|
||||
/* Support for client-side decorations */
|
||||
# ifndef LV_WAYLAND_CLIENT_SIDE_DECORATIONS
|
||||
# define LV_WAYLAND_CLIENT_SIDE_DECORATIONS 1
|
||||
# endif
|
||||
/* Support for (deprecated) wl-shell protocol */
|
||||
# ifndef LV_WAYLAND_WL_SHELL
|
||||
# define LV_WAYLAND_WL_SHELL 1
|
||||
# endif
|
||||
/* Support for xdg-shell protocol */
|
||||
# ifndef LV_WAYLAND_XDG_SHELL
|
||||
# define LV_WAYLAND_XDG_SHELL 0
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/*----------------
|
||||
* SSD1963
|
||||
*--------------*/
|
||||
#ifndef USE_SSD1963
|
||||
# define USE_SSD1963 0
|
||||
#endif
|
||||
|
||||
#if USE_SSD1963
|
||||
# define SSD1963_HOR_RES LV_HOR_RES
|
||||
# define SSD1963_VER_RES LV_VER_RES
|
||||
# define SSD1963_HT 531
|
||||
# define SSD1963_HPS 43
|
||||
# define SSD1963_LPS 8
|
||||
# define SSD1963_HPW 10
|
||||
# define SSD1963_VT 288
|
||||
# define SSD1963_VPS 12
|
||||
# define SSD1963_FPS 4
|
||||
# define SSD1963_VPW 10
|
||||
# define SSD1963_HS_NEG 0 /*Negative hsync*/
|
||||
# define SSD1963_VS_NEG 0 /*Negative vsync*/
|
||||
# define SSD1963_ORI 0 /*0, 90, 180, 270*/
|
||||
# define SSD1963_COLOR_DEPTH 16
|
||||
#endif
|
||||
|
||||
/*----------------
|
||||
* R61581
|
||||
*--------------*/
|
||||
#ifndef USE_R61581
|
||||
# define USE_R61581 0
|
||||
#endif
|
||||
|
||||
#if USE_R61581
|
||||
# define R61581_HOR_RES LV_HOR_RES
|
||||
# define R61581_VER_RES LV_VER_RES
|
||||
# define R61581_HSPL 0 /*HSYNC signal polarity*/
|
||||
# define R61581_HSL 10 /*HSYNC length (Not Implemented)*/
|
||||
# define R61581_HFP 10 /*Horitontal Front poarch (Not Implemented)*/
|
||||
# define R61581_HBP 10 /*Horitontal Back poarch (Not Implemented */
|
||||
# define R61581_VSPL 0 /*VSYNC signal polarity*/
|
||||
# define R61581_VSL 10 /*VSYNC length (Not Implemented)*/
|
||||
# define R61581_VFP 8 /*Vertical Front poarch*/
|
||||
# define R61581_VBP 8 /*Vertical Back poarch */
|
||||
# define R61581_DPL 0 /*DCLK signal polarity*/
|
||||
# define R61581_EPL 1 /*ENABLE signal polarity*/
|
||||
# define R61581_ORI 0 /*0, 180*/
|
||||
# define R61581_LV_COLOR_DEPTH 16 /*Fix 16 bit*/
|
||||
#endif
|
||||
|
||||
/*------------------------------
|
||||
* ST7565 (Monochrome, low res.)
|
||||
*-----------------------------*/
|
||||
#ifndef USE_ST7565
|
||||
# define USE_ST7565 0
|
||||
#endif
|
||||
|
||||
#if USE_ST7565
|
||||
/*No settings*/
|
||||
#endif /*USE_ST7565*/
|
||||
|
||||
/*------------------------------
|
||||
* GC9A01 (color, low res.)
|
||||
*-----------------------------*/
|
||||
#ifndef USE_GC9A01
|
||||
# define USE_GC9A01 0
|
||||
#endif
|
||||
|
||||
#if USE_GC9A01
|
||||
/*No settings*/
|
||||
#endif /*USE_GC9A01*/
|
||||
|
||||
/*------------------------------------------
|
||||
* UC1610 (4 gray 160*[104|128])
|
||||
* (EA DOGXL160 160x104 tested)
|
||||
*-----------------------------------------*/
|
||||
#ifndef USE_UC1610
|
||||
# define USE_UC1610 0
|
||||
#endif
|
||||
|
||||
#if USE_UC1610
|
||||
# define UC1610_HOR_RES LV_HOR_RES
|
||||
# define UC1610_VER_RES LV_VER_RES
|
||||
# define UC1610_INIT_CONTRAST 33 /* init contrast, values in [%] */
|
||||
# define UC1610_INIT_HARD_RST 0 /* 1 : hardware reset at init, 0 : software reset */
|
||||
# define UC1610_TOP_VIEW 0 /* 0 : Bottom View, 1 : Top View */
|
||||
#endif /*USE_UC1610*/
|
||||
|
||||
/*-------------------------------------------------
|
||||
* SHARP memory in pixel monochrome display series
|
||||
* LS012B7DD01 (184x38 pixels.)
|
||||
* LS013B7DH03 (128x128 pixels.)
|
||||
* LS013B7DH05 (144x168 pixels.)
|
||||
* LS027B7DH01 (400x240 pixels.) (tested)
|
||||
* LS032B7DD02 (336x536 pixels.)
|
||||
* LS044Q7DH01 (320x240 pixels.)
|
||||
*------------------------------------------------*/
|
||||
#ifndef USE_SHARP_MIP
|
||||
# define USE_SHARP_MIP 0
|
||||
#endif
|
||||
|
||||
#if USE_SHARP_MIP
|
||||
# define SHARP_MIP_HOR_RES LV_HOR_RES
|
||||
# define SHARP_MIP_VER_RES LV_VER_RES
|
||||
# define SHARP_MIP_SOFT_COM_INVERSION 0
|
||||
# define SHARP_MIP_REV_BYTE(b) /*((uint8_t) __REV(__RBIT(b)))*/ /*Architecture / compiler dependent byte bits order reverse*/
|
||||
#endif /*USE_SHARP_MIP*/
|
||||
|
||||
/*-------------------------------------------------
|
||||
* ILI9341 240X320 TFT LCD
|
||||
*------------------------------------------------*/
|
||||
#ifndef USE_ILI9341
|
||||
# define USE_ILI9341 0
|
||||
#endif
|
||||
|
||||
#if USE_ILI9341
|
||||
# define ILI9341_HOR_RES LV_HOR_RES
|
||||
# define ILI9341_VER_RES LV_VER_RES
|
||||
# define ILI9341_GAMMA 1
|
||||
# define ILI9341_TEARING 0
|
||||
#endif /*USE_ILI9341*/
|
||||
|
||||
/*-----------------------------------------
|
||||
* Linux frame buffer device (/dev/fbx)
|
||||
*-----------------------------------------*/
|
||||
#ifndef USE_FBDEV
|
||||
# define USE_FBDEV 1
|
||||
#endif
|
||||
|
||||
#if USE_FBDEV
|
||||
# define FBDEV_PATH "/dev/fb0"
|
||||
#endif
|
||||
|
||||
/*-----------------------------------------
|
||||
* FreeBSD frame buffer device (/dev/fbx)
|
||||
*.........................................*/
|
||||
#ifndef USE_BSD_FBDEV
|
||||
# define USE_BSD_FBDEV 0
|
||||
#endif
|
||||
|
||||
#if USE_BSD_FBDEV
|
||||
# define FBDEV_PATH "/dev/fb0"
|
||||
#endif
|
||||
|
||||
/*-----------------------------------------
|
||||
* DRM/KMS device (/dev/dri/cardX)
|
||||
*-----------------------------------------*/
|
||||
#ifndef USE_DRM
|
||||
# define USE_DRM 0
|
||||
#endif
|
||||
|
||||
#if USE_DRM
|
||||
# define DRM_CARD "/dev/dri/card0"
|
||||
# define DRM_CONNECTOR_ID -1 /* -1 for the first connected one */
|
||||
#endif
|
||||
|
||||
/*********************
|
||||
* INPUT DEVICES
|
||||
*********************/
|
||||
|
||||
/*--------------
|
||||
* XPT2046
|
||||
*--------------*/
|
||||
#ifndef USE_XPT2046
|
||||
# define USE_XPT2046 0
|
||||
#endif
|
||||
|
||||
#if USE_XPT2046
|
||||
# define XPT2046_HOR_RES 480
|
||||
# define XPT2046_VER_RES 320
|
||||
# define XPT2046_X_MIN 200
|
||||
# define XPT2046_Y_MIN 200
|
||||
# define XPT2046_X_MAX 3800
|
||||
# define XPT2046_Y_MAX 3800
|
||||
# define XPT2046_AVG 4
|
||||
# define XPT2046_X_INV 0
|
||||
# define XPT2046_Y_INV 0
|
||||
# define XPT2046_XY_SWAP 0
|
||||
#endif
|
||||
|
||||
/*-----------------
|
||||
* FT5406EE8
|
||||
*-----------------*/
|
||||
#ifndef USE_FT5406EE8
|
||||
# define USE_FT5406EE8 0
|
||||
#endif
|
||||
|
||||
#if USE_FT5406EE8
|
||||
# define FT5406EE8_I2C_ADR 0x38 /*7 bit address*/
|
||||
#endif
|
||||
|
||||
/*---------------
|
||||
* AD TOUCH
|
||||
*--------------*/
|
||||
#ifndef USE_AD_TOUCH
|
||||
# define USE_AD_TOUCH 0
|
||||
#endif
|
||||
|
||||
#if USE_AD_TOUCH
|
||||
/*No settings*/
|
||||
#endif
|
||||
|
||||
|
||||
/*---------------------------------------
|
||||
* Mouse or touchpad on PC (using SDL)
|
||||
*-------------------------------------*/
|
||||
/*DEPRECATED: Use the SDL driver instead. */
|
||||
#ifndef USE_MOUSE
|
||||
# define USE_MOUSE 0
|
||||
#endif
|
||||
|
||||
#if USE_MOUSE
|
||||
/*No settings*/
|
||||
#endif
|
||||
|
||||
/*-------------------------------------------
|
||||
* Mousewheel as encoder on PC (using SDL)
|
||||
*------------------------------------------*/
|
||||
/*DEPRECATED: Use the SDL driver instead. */
|
||||
#ifndef USE_MOUSEWHEEL
|
||||
# define USE_MOUSEWHEEL 0
|
||||
#endif
|
||||
|
||||
#if USE_MOUSEWHEEL
|
||||
/*No settings*/
|
||||
#endif
|
||||
|
||||
/*-------------------------------------------------
|
||||
* Touchscreen, mouse/touchpad or keyboard as libinput interface (for Linux based systems)
|
||||
*------------------------------------------------*/
|
||||
#ifndef USE_LIBINPUT
|
||||
# define USE_LIBINPUT 0
|
||||
#endif
|
||||
|
||||
#ifndef USE_BSD_LIBINPUT
|
||||
# define USE_BSD_LIBINPUT 0
|
||||
#endif
|
||||
|
||||
#if USE_LIBINPUT || USE_BSD_LIBINPUT
|
||||
/*If only a single device of the same type is connected, you can also auto detect it, e.g.:
|
||||
*#define LIBINPUT_NAME libinput_find_dev(LIBINPUT_CAPABILITY_TOUCH, false)*/
|
||||
# define LIBINPUT_NAME "/dev/input/event0" /*You can use the "evtest" Linux tool to get the list of devices and test them*/
|
||||
|
||||
#endif /*USE_LIBINPUT || USE_BSD_LIBINPUT*/
|
||||
|
||||
/*-------------------------------------------------
|
||||
* Mouse or touchpad as evdev interface (for Linux based systems)
|
||||
*------------------------------------------------*/
|
||||
#ifndef USE_EVDEV
|
||||
# define USE_EVDEV 1
|
||||
#endif
|
||||
|
||||
#ifndef USE_BSD_EVDEV
|
||||
# define USE_BSD_EVDEV 0
|
||||
#endif
|
||||
|
||||
#if USE_EVDEV || USE_BSD_EVDEV
|
||||
# define EVDEV_NAME "/dev/input/event1" /*You can use the "evtest" Linux tool to get the list of devices and test them*/
|
||||
# define EVDEV_SWAP_AXES 0 /*Swap the x and y axes of the touchscreen*/
|
||||
|
||||
# define EVDEV_CALIBRATE 0 /*Scale and offset the touchscreen coordinates by using maximum and minimum values for each axis*/
|
||||
|
||||
# if EVDEV_CALIBRATE
|
||||
# define EVDEV_HOR_MIN 0 /*to invert axis swap EVDEV_XXX_MIN by EVDEV_XXX_MAX*/
|
||||
# define EVDEV_HOR_MAX 4096 /*"evtest" Linux tool can help to get the correct calibraion values>*/
|
||||
# define EVDEV_VER_MIN 0
|
||||
# define EVDEV_VER_MAX 4096
|
||||
# endif /*EVDEV_CALIBRATE*/
|
||||
#endif /*USE_EVDEV*/
|
||||
|
||||
/*-------------------------------------------------
|
||||
* Full keyboard support for evdev and libinput interface
|
||||
*------------------------------------------------*/
|
||||
# ifndef USE_XKB
|
||||
# define USE_XKB 0
|
||||
# endif
|
||||
|
||||
#if USE_LIBINPUT || USE_BSD_LIBINPUT || USE_EVDEV || USE_BSD_EVDEV
|
||||
# if USE_XKB
|
||||
# define XKB_KEY_MAP { .rules = NULL, \
|
||||
.model = "pc101", \
|
||||
.layout = "us", \
|
||||
.variant = NULL, \
|
||||
.options = NULL } /*"setxkbmap -query" can help find the right values for your keyboard*/
|
||||
# endif /*USE_XKB*/
|
||||
#endif /*USE_LIBINPUT || USE_BSD_LIBINPUT || USE_EVDEV || USE_BSD_EVDEV*/
|
||||
|
||||
/*-------------------------------
|
||||
* Keyboard of a PC (using SDL)
|
||||
*------------------------------*/
|
||||
/*DEPRECATED: Use the SDL driver instead. */
|
||||
#ifndef USE_KEYBOARD
|
||||
# define USE_KEYBOARD 0
|
||||
#endif
|
||||
|
||||
#if USE_KEYBOARD
|
||||
/*No settings*/
|
||||
#endif
|
||||
|
||||
#endif /*LV_DRV_CONF_H*/
|
||||
|
||||
#endif /*End of "Content enable"*/
|
||||
104
l2e_boot/l2e_sources/l2eterm/mouse_cursor_icon.c
Normal file
104
l2e_boot/l2e_sources/l2eterm/mouse_cursor_icon.c
Normal file
@ -0,0 +1,104 @@
|
||||
#include "lvgl/lvgl.h"
|
||||
|
||||
const uint8_t mouse_cursor_icon_map[] = {
|
||||
#if LV_COLOR_DEPTH == 1 || LV_COLOR_DEPTH == 8
|
||||
/*Pixel format: Alpha 8 bit, Red: 3 bit, Green: 3 bit, Blue: 2 bit*/
|
||||
0x24, 0xb8, 0x24, 0xc8, 0x00, 0x13, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0xcc, 0xdb, 0xff, 0x49, 0xcc, 0x00, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0xc8, 0xff, 0xff, 0xff, 0xff, 0x49, 0xe0, 0x00, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0xcb, 0xff, 0xff, 0xff, 0xfc, 0xff, 0xff, 0x6d, 0xf3, 0x00, 0x4f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0xcb, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x92, 0xff, 0x00, 0x73, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0xcb, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x92, 0xff, 0x00, 0x90, 0x00, 0x00, 0x00, 0x00, 0xb6, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0xcb, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xb7, 0xff, 0x24, 0xab, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0xcb, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xdb, 0xff, 0x24, 0xbb, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0xcc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xdb, 0xff, 0x49, 0xd8, 0x00, 0x37, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0xcc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x6d, 0xef, 0x00, 0x4f, 0x00, 0x00,
|
||||
0x49, 0xcc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x92, 0xff, 0x00, 0x6b,
|
||||
0x49, 0xcc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xdb, 0xff, 0x92, 0xf7, 0x92, 0xf8, 0x6e, 0xfb, 0x92, 0xf8, 0x6d, 0xff, 0x00, 0xb3,
|
||||
0x49, 0xcc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xdb, 0xff, 0x24, 0xb7, 0x00, 0x1b, 0x00, 0x14, 0x00, 0x13, 0x00, 0x0c, 0x25, 0x07,
|
||||
0x49, 0xcc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x6d, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x6e, 0xf0, 0x00, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0xcc, 0xff, 0xff, 0xff, 0xff, 0x49, 0xd8, 0x00, 0x78, 0x92, 0xfb, 0xff, 0xff, 0xff, 0xff, 0xdb, 0xff, 0x00, 0x8b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x6d, 0xd3, 0xff, 0xff, 0x6d, 0xef, 0x00, 0x34, 0x00, 0x00, 0x49, 0xc7, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x6d, 0xdc, 0x00, 0x14, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00,
|
||||
0x49, 0xe0, 0x6d, 0xff, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x57, 0x92, 0xff, 0xff, 0xff, 0xff, 0xff, 0xb7, 0xff, 0x00, 0x78, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00,
|
||||
0x00, 0x68, 0x00, 0x4f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x49, 0xd0, 0xff, 0xff, 0xff, 0xfc, 0xff, 0xff, 0x6d, 0xd8, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6f, 0xb7, 0xff, 0xff, 0xff, 0x92, 0xff, 0x49, 0xac, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x03, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x25, 0xd7, 0x49, 0xc7, 0x00, 0x47, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
#endif
|
||||
#if LV_COLOR_DEPTH == 16 && LV_COLOR_16_SWAP == 0
|
||||
/*Pixel format: Alpha 8 bit, Red: 5 bit, Green: 6 bit, Blue: 5 bit*/
|
||||
0xc3, 0x18, 0xb8, 0xe4, 0x20, 0xc8, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x49, 0x4a, 0xcc, 0x96, 0xb5, 0xff, 0xc7, 0x39, 0xcc, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x41, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0xe7, 0x39, 0xc8, 0xbf, 0xff, 0xff, 0xfb, 0xde, 0xff, 0x28, 0x42, 0xe0, 0x00, 0x00, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x41, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0xe7, 0x39, 0xcb, 0x3d, 0xef, 0xff, 0xff, 0xff, 0xfc, 0x3d, 0xef, 0xff, 0xcb, 0x5a, 0xf3, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0xe7, 0x39, 0xcb, 0x5d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xbf, 0xff, 0xff, 0x8e, 0x73, 0xff, 0x00, 0x00, 0x73, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0xe8, 0x41, 0xcb, 0x5d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x51, 0x8c, 0xff, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd3, 0x9c, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0xe8, 0x41, 0xcb, 0x5d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x14, 0xa5, 0xff, 0xa2, 0x10, 0xab, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x08, 0x42, 0xcb, 0x5d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xd7, 0xbd, 0xff, 0x04, 0x21, 0xbb, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x08, 0x42, 0xcc, 0x5d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x59, 0xce, 0xff, 0xe8, 0x41, 0xd8, 0x00, 0x00, 0x37, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x08, 0x42, 0xcc, 0x5d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfc, 0xe6, 0xff, 0xab, 0x5a, 0xef, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x00,
|
||||
0x08, 0x42, 0xcc, 0x5d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xbe, 0xf7, 0xff, 0xaf, 0x7b, 0xff, 0x00, 0x00, 0x6b,
|
||||
0x28, 0x42, 0xcc, 0x5d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7a, 0xd6, 0xff, 0x10, 0x84, 0xf7, 0xae, 0x73, 0xf8, 0x6e, 0x73, 0xfb, 0x8e, 0x73, 0xf8, 0xcb, 0x5a, 0xff, 0x61, 0x08, 0xb3,
|
||||
0x28, 0x42, 0xcc, 0x7d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x59, 0xce, 0xff, 0xa2, 0x10, 0xb7, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x14, 0x00, 0x00, 0x13, 0x00, 0x00, 0x0c, 0x45, 0x29, 0x07,
|
||||
0x29, 0x4a, 0xcc, 0x5d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xdb, 0xde, 0xff, 0xec, 0x62, 0xff, 0x1c, 0xe7, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0c, 0x63, 0xf0, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x29, 0x4a, 0xcc, 0xdf, 0xff, 0xff, 0x7d, 0xef, 0xff, 0x49, 0x4a, 0xd8, 0x00, 0x00, 0x78, 0x51, 0x8c, 0xfb, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x38, 0xc6, 0xff, 0x00, 0x00, 0x8b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0xcb, 0x5a, 0xd3, 0xdb, 0xde, 0xff, 0xec, 0x62, 0xef, 0x00, 0x00, 0x34, 0x00, 0x00, 0x00, 0xe7, 0x39, 0xc7, 0x5d, 0xef, 0xff, 0xff, 0xff, 0xff, 0xbe, 0xf7, 0xff, 0xaa, 0x52, 0xdc, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00,
|
||||
0xe8, 0x41, 0xe0, 0xaa, 0x52, 0xff, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x57, 0x72, 0x94, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x96, 0xb5, 0xff, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x61, 0x08, 0x04, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x68, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x69, 0x4a, 0xd0, 0x7d, 0xef, 0xff, 0xff, 0xff, 0xfc, 0xbe, 0xf7, 0xff, 0xaa, 0x52, 0xd8, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe4, 0x20, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6f, 0x75, 0xad, 0xff, 0xbf, 0xff, 0xff, 0x10, 0x84, 0xff, 0x86, 0x31, 0xac, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x41, 0x08, 0x03, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x66, 0x31, 0xd7, 0xc7, 0x39, 0xc7, 0x00, 0x00, 0x47, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
#endif
|
||||
#if LV_COLOR_DEPTH == 16 && LV_COLOR_16_SWAP != 0
|
||||
/*Pixel format: Alpha 8 bit, Red: 5 bit, Green: 6 bit, Blue: 5 bit BUT the 2 color bytes are swapped*/
|
||||
0x18, 0xc3, 0xb8, 0x20, 0xe4, 0xc8, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x4a, 0x49, 0xcc, 0xb5, 0x96, 0xff, 0x39, 0xc7, 0xcc, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x39, 0xe7, 0xc8, 0xff, 0xbf, 0xff, 0xde, 0xfb, 0xff, 0x42, 0x28, 0xe0, 0x00, 0x00, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x39, 0xe7, 0xcb, 0xef, 0x3d, 0xff, 0xff, 0xff, 0xfc, 0xef, 0x3d, 0xff, 0x5a, 0xcb, 0xf3, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x39, 0xe7, 0xcb, 0xef, 0x5d, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xbf, 0xff, 0x73, 0x8e, 0xff, 0x00, 0x00, 0x73, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x41, 0xe8, 0xcb, 0xef, 0x5d, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x8c, 0x51, 0xff, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9c, 0xd3, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x41, 0xe8, 0xcb, 0xef, 0x5d, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xa5, 0x14, 0xff, 0x10, 0xa2, 0xab, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x42, 0x08, 0xcb, 0xef, 0x5d, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xbd, 0xd7, 0xff, 0x21, 0x04, 0xbb, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x42, 0x08, 0xcc, 0xef, 0x5d, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xce, 0x59, 0xff, 0x41, 0xe8, 0xd8, 0x00, 0x00, 0x37, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x42, 0x08, 0xcc, 0xef, 0x5d, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xe6, 0xfc, 0xff, 0x5a, 0xab, 0xef, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x00,
|
||||
0x42, 0x08, 0xcc, 0xef, 0x5d, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf7, 0xbe, 0xff, 0x7b, 0xaf, 0xff, 0x00, 0x00, 0x6b,
|
||||
0x42, 0x28, 0xcc, 0xef, 0x5d, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xd6, 0x7a, 0xff, 0x84, 0x10, 0xf7, 0x73, 0xae, 0xf8, 0x73, 0x6e, 0xfb, 0x73, 0x8e, 0xf8, 0x5a, 0xcb, 0xff, 0x08, 0x61, 0xb3,
|
||||
0x42, 0x28, 0xcc, 0xef, 0x7d, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xce, 0x59, 0xff, 0x10, 0xa2, 0xb7, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x14, 0x00, 0x00, 0x13, 0x00, 0x00, 0x0c, 0x29, 0x45, 0x07,
|
||||
0x4a, 0x29, 0xcc, 0xef, 0x5d, 0xff, 0xff, 0xff, 0xff, 0xde, 0xdb, 0xff, 0x62, 0xec, 0xff, 0xe7, 0x1c, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x63, 0x0c, 0xf0, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x4a, 0x29, 0xcc, 0xff, 0xdf, 0xff, 0xef, 0x7d, 0xff, 0x4a, 0x49, 0xd8, 0x00, 0x00, 0x78, 0x8c, 0x51, 0xfb, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc6, 0x38, 0xff, 0x00, 0x00, 0x8b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x5a, 0xcb, 0xd3, 0xde, 0xdb, 0xff, 0x62, 0xec, 0xef, 0x00, 0x00, 0x34, 0x00, 0x00, 0x00, 0x39, 0xe7, 0xc7, 0xef, 0x5d, 0xff, 0xff, 0xff, 0xff, 0xf7, 0xbe, 0xff, 0x52, 0xaa, 0xdc, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00,
|
||||
0x41, 0xe8, 0xe0, 0x52, 0xaa, 0xff, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x57, 0x94, 0x72, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xb5, 0x96, 0xff, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x08, 0x61, 0x04, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x68, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x4a, 0x69, 0xd0, 0xef, 0x7d, 0xff, 0xff, 0xff, 0xfc, 0xf7, 0xbe, 0xff, 0x52, 0xaa, 0xd8, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0xe4, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6f, 0xad, 0x75, 0xff, 0xff, 0xbf, 0xff, 0x84, 0x10, 0xff, 0x31, 0x86, 0xac, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x08, 0x41, 0x03, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x31, 0x66, 0xd7, 0x39, 0xc7, 0xc7, 0x00, 0x00, 0x47, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
#endif
|
||||
#if LV_COLOR_DEPTH == 32
|
||||
0x19, 0x19, 0x19, 0xb8, 0x1e, 0x1e, 0x1e, 0xc8, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x48, 0x48, 0x48, 0xcc, 0xb2, 0xb2, 0xb2, 0xff, 0x3a, 0x3a, 0x3a, 0xcc, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x0a, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x3b, 0x3b, 0x3b, 0xc8, 0xf6, 0xf6, 0xf6, 0xff, 0xdc, 0xdc, 0xdc, 0xff, 0x43, 0x43, 0x43, 0xe0, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x0a, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x3b, 0x3b, 0x3b, 0xcb, 0xe6, 0xe6, 0xe6, 0xff, 0xff, 0xff, 0xff, 0xfc, 0xe5, 0xe5, 0xe5, 0xff, 0x59, 0x59, 0x59, 0xf3, 0x00, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x3c, 0x3c, 0x3c, 0xcb, 0xe9, 0xe9, 0xe9, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf5, 0xf5, 0xf5, 0xff, 0x72, 0x72, 0x72, 0xff, 0x00, 0x00, 0x00, 0x73, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x3d, 0x3d, 0x3d, 0xcb, 0xe9, 0xe9, 0xe9, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x8a, 0x8a, 0x8a, 0xff, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x99, 0x99, 0x99, 0x00, 0x04, 0x04, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x3e, 0x3e, 0x3e, 0xcb, 0xe9, 0xe9, 0xe9, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xfe, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xa2, 0xa2, 0xa2, 0xff, 0x13, 0x13, 0x13, 0xab, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x3f, 0x3f, 0x3f, 0xcb, 0xe9, 0xe9, 0xe9, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xfe, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xb7, 0xb7, 0xb7, 0xff, 0x1f, 0x1f, 0x1f, 0xbb, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x41, 0x41, 0x41, 0xcc, 0xea, 0xea, 0xea, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xfe, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xca, 0xca, 0xca, 0xff, 0x3d, 0x3d, 0x3d, 0xd8, 0x00, 0x00, 0x00, 0x37, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x41, 0x41, 0x41, 0xcc, 0xea, 0xea, 0xea, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xde, 0xde, 0xde, 0xff, 0x56, 0x56, 0x56, 0xef, 0x00, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x00, 0x00,
|
||||
0x42, 0x42, 0x42, 0xcc, 0xea, 0xea, 0xea, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xfe, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf3, 0xf3, 0xf3, 0xff, 0x76, 0x76, 0x76, 0xff, 0x00, 0x00, 0x00, 0x6b,
|
||||
0x43, 0x43, 0x43, 0xcc, 0xea, 0xea, 0xea, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xce, 0xce, 0xce, 0xff, 0x80, 0x80, 0x80, 0xf7, 0x74, 0x74, 0x74, 0xf8, 0x6d, 0x6d, 0x6d, 0xfb, 0x72, 0x72, 0x72, 0xf8, 0x57, 0x57, 0x57, 0xff, 0x0c, 0x0c, 0x0c, 0xb3,
|
||||
0x44, 0x44, 0x44, 0xcc, 0xeb, 0xeb, 0xeb, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfc, 0xfb, 0xfb, 0xfb, 0xff, 0xfe, 0xfe, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc9, 0xc9, 0xc9, 0xff, 0x13, 0x13, 0x13, 0xb7, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, 0x0c, 0x29, 0x29, 0x29, 0x07,
|
||||
0x45, 0x45, 0x45, 0xcc, 0xe8, 0xe8, 0xe8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xd9, 0xd9, 0xd9, 0xff, 0x5e, 0x5e, 0x5e, 0xff, 0xe2, 0xe2, 0xe2, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x62, 0x62, 0x62, 0xf0, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x45, 0x45, 0x45, 0xcc, 0xf9, 0xf9, 0xf9, 0xff, 0xec, 0xec, 0xec, 0xff, 0x4a, 0x4a, 0x4a, 0xd8, 0x00, 0x00, 0x00, 0x78, 0x8a, 0x8a, 0x8a, 0xfb, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc3, 0xc3, 0xc3, 0xff, 0x00, 0x00, 0x00, 0x8b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x58, 0x58, 0x58, 0xd3, 0xd9, 0xd9, 0xd9, 0xff, 0x5e, 0x5e, 0x5e, 0xef, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x00, 0x00, 0x3b, 0x3b, 0x3b, 0xc7, 0xe9, 0xe9, 0xe9, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf4, 0xf4, 0xf4, 0xff, 0x54, 0x54, 0x54, 0xdc, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
|
||||
0x3e, 0x3e, 0x3e, 0xe0, 0x54, 0x54, 0x54, 0xff, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x57, 0x8e, 0x8e, 0x8e, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xb0, 0xb0, 0xb0, 0xff, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x0c, 0x0c, 0x04, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x68, 0x00, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x4c, 0x4c, 0x4c, 0xd0, 0xec, 0xec, 0xec, 0xff, 0xff, 0xff, 0xff, 0xfc, 0xf4, 0xf4, 0xf4, 0xff, 0x53, 0x53, 0x53, 0xd8, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x1e, 0x1e, 0x00, 0x04, 0x04, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6f, 0xab, 0xab, 0xab, 0xff, 0xf6, 0xf6, 0xf6, 0xff, 0x80, 0x80, 0x80, 0xff, 0x31, 0x31, 0x31, 0xac, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x09, 0x09, 0x09, 0x03, 0x02, 0x02, 0x02, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x2e, 0x2e, 0x2e, 0xd7, 0x38, 0x38, 0x38, 0xc7, 0x00, 0x00, 0x00, 0x47, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
#endif
|
||||
};
|
||||
|
||||
lv_img_dsc_t mouse_cursor_icon = {
|
||||
.header.always_zero = 0,
|
||||
.header.w = 14,
|
||||
.header.h = 20,
|
||||
.data_size = 280 * LV_IMG_PX_SIZE_ALPHA_BYTE,
|
||||
.header.cf = LV_IMG_CF_TRUE_COLOR_ALPHA,
|
||||
.data = mouse_cursor_icon_map,
|
||||
};
|
||||
29
run.c
29
run.c
@ -3,15 +3,32 @@
|
||||
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// Unikraft Unikernel Support Directives
|
||||
// L2E Humanoid : Linux Kernel Support Directives
|
||||
//
|
||||
|
||||
#define _DEFTOSTR(LSTR) #LSTR
|
||||
#define DEFTOSTR(LSTR) _DEFTOSTR(LSTR)
|
||||
|
||||
#define LOOPSTATUS 0 // Status off
|
||||
|
||||
#ifndef LINUXK
|
||||
#define OSPROMPT L2E$
|
||||
#endif
|
||||
|
||||
#ifdef LINUXK
|
||||
#define INC_BIN
|
||||
#define LLOOP
|
||||
#define LOOPSTATUS 1 // Status on
|
||||
#endif
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// L2E Asteroid : Unikraft Unikernel Support Directives
|
||||
//
|
||||
|
||||
#ifdef UNIK
|
||||
#define STRLIT
|
||||
#define LLOOP
|
||||
#define LOOPSTATUS 1 // Status on
|
||||
#else
|
||||
#define LOOPSTATUS 0 // Status off
|
||||
#endif
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
@ -83,7 +100,9 @@ __static_yoink("zipos");
|
||||
#include <armpl.h>
|
||||
#elif defined(AAF)
|
||||
#include <Accelerate/Accelerate.h>
|
||||
#elif defined(OPENBLAS) || defined(CBLAS)
|
||||
#elif defined(OPENBLAS)
|
||||
#include "cblas.h"
|
||||
#elif defined(CBLAS)
|
||||
#include <cblas.h>
|
||||
#endif
|
||||
|
||||
@ -918,7 +937,7 @@ int main(int argc, char *argv[]) {
|
||||
while(1) { // start of loop
|
||||
#endif
|
||||
prompt=(char*)malloc(1024);
|
||||
printf("\nL2E $ ");
|
||||
printf("\n" DEFTOSTR(OSPROMPT)" ");
|
||||
fflush(stdout);
|
||||
inprompt(prompt); // read prompt
|
||||
#else
|
||||
|
||||
Loading…
Reference in New Issue
Block a user