site  contact  subhomenews

Tentative first step framebuffer with LittleVGL

August 19, 2018 — BarryK

As posted earlier today, I have started to evaluate LittlevGL:

the "PC simulator" does look like a good starting point, though it is setup to create a binary named "demo" that is linked against SDL2. That's OK for learning, but I am aiming to talk directly to the Linux framebuffer.

For EasyOS, SDL2 packages are available here (libsdl2-*):

Download the pc-simulator zip file:
Direct link to version 5.1.1:

Expand the zip file, and this is what you see:


Open a terminal, and type "make". That's it, a binary named "demo" will be created. Run it "# ./demo", and you get a GUI:


There is another tutorial web page that explains how to create a simple "Hello World" app using the Linux framebuffere, so onto that...

Hello World with Linux framebuffer

There is an introduction and tutorial here:

I fiddled around for awhile. Like the "PC Simulator" tutorial page, there is a conceptual-gap in the instructions. Here:

2. Compile the code and go back to character terminal mode, how to compile it? For a beginner, this is an awkward step. A Makefile is needed. These are the steps that I followed:

  1. Run "make clean"
  2. In the 'pc-simulator' folder, I moved 'lv-conf.h', 'lv_drv_conf.h', 'lv_ex_conf.h', 'main.c' and 'Makefile' elsewhere.
  3. I then created new 'lv_drv.h', 'lv_conf.h' and 'main.c' as per instructions in the above URL.
  4. I copied-back the 'Makefile' that I had previously moved away, and edited it. Snapshot of the files, 'hide1' is where I moved the original files to:


Here is my edited Makefile:

# Makefile
CC = gcc
CFLAGS = -Wall -Wshadow -Wundef -Wmaybe-uninitialized
CFLAGS += -O3 -g3 -I./
#LDFLAGS += -lSDL2 -lm
BIN = demo

LVGL_DIR = ${shell pwd}

MAINSRC = main.c

include ./lvgl/lv_core/
include ./lvgl/lv_hal/
include ./lvgl/lv_objx/
include ./lvgl/lv_misc/lv_fonts/
include ./lvgl/lv_misc/
include ./lvgl/lv_themes/
include ./lvgl/lv_draw/

include ./lv_drivers/display/
include ./lv_drivers/indev/

OBJEXT ?= .o





all: clean default

%.o: %.c
@$(CC) $(CFLAGS) -c $< -o $@
@echo "CC $<"

default: $(AOBJS) $(COBJS) $(MAINOBJ)

rm -f $(BIN) $(AOBJS) $(COBJS) $(MAINOBJ)

I do realise that more modules than are needed, are being included in the build, but that's OK, as I plan to play with adding more widgets. Notice that SDL2 is not being linked.

Run "make", it creates 'demo'. This will not run on the Xorg desktop, though I vaguely recall a method of doing it in a terminal. Anyway, the way to test 'demo' is to exit from X, via the Shutdown menu in EasyOS (and most pups). Then, on the commandline, as long as a framebuffer has command of the screen, which is likely (there are some caveats), just execute 'demo', where-ever it is.

On the commandline, here is what it looks like:


That's as far as I've got. Next, need to investigate mouse support...

Tags: linux, easy

EasyShare supports Android phone via USB

August 13, 2018 — BarryK

I posted recently about Android utilities being included in future EasyOS and Quirky releases:

EasyShare is now using these utilities and supports file sharing via an Android phone connected by USB cable.

The main GUI now has a checkbox "Android USB", and it is very simple to use. Here is a snapshot:


The only slight difficulty, very slight, is that Developer mode and USB debugging have to be turned-on on the phone. The phone is automatically discovered, and it is just a matter of clicking the "Mount" button. 

I have updated the EasyShare tutorial page:   

Tags: easy, quirky

adb connection to phone over wifi

August 09, 2018 — BarryK

I posted yesterday about using 'adb' and 'adbfs' over usb to browse files on my Android phone:

Briefly mentioned that it could be done over wifi as well. Yes, this site has a nice explanation:

It does require a one-time usb connection to enable the phone to listen on port 5555. With usb-debugging enabled on the phone and usb cable connected to PC, on the PC:

# adb devices
...this will confirm the connection
# adb shell "ip route" dev wlan0  proto kernel  scope link  src
... is the ip-address of the phone.
# adb tcpip 5555
...starts the phone listening on port 5555

Then unplug the usb cable, and on the PC:

# adb connect
# adb shell "ls /sdcard"
...will list folders and files on phone
# adbfs /mnt/phone
...can browse the files
# fusermount -u /mnt/phone

Yeah it works, but not very secure. Port 5555 stays open until the phone is rebooted. adbfs is a simple method, but reckon will restrict to only doing it via usb cable.

Tags: easy, quirky, linux

EasyShare now using fakeidentd

August 07, 2018 — BarryK

I posted about the rewrite of EasyShare a few days ago:

Which appeared in EasyOS 0.9.6 released a couple of days ago.

Then yesterday, examined using fakeidentd server for network discovery:

Puppy Forum member 'step', a longtime contributor on the forum, sent me a pm about another way to query fakeidentd, using 'telnet'. Like this:

# { printf \\n; sleep 1; } | telnet 113

Busybox has a telnet applet, though my current configuration of busybox does not have it.

Very nice, thanks very much for that info. As I have the '' perl script working, staying with that for now. EasyShare is now modified to use fakeidentd, and I have tested, works great.

Running 'easyshare' from a terminal, noticed an error message, although the sshfs connection worked:

do_known_hosts: hostkeys_foreach failed: No such file or directory

It was a one-off message, I discovered because folder /root/.ssh did not exist. Fixed.

Tags: easy, quirky

Kernel 4.14.61 and SeaMonkey 2.49.4

August 07, 2018 — BarryK

I have compiled the Linux kernel, version 4.14.61, on EasyOS 0.9.6 Pyro64. The source, with patches and build scripts, is here:

There is a PET package, that will be used in the next builds of EasyOS and Quirky. There is a SFS file of the source:

I also compiled the latest SeaMonkey, version 2.49.4. The PET is here (45MB):

...this is for EasyOS 0.9.5 and later. Do not try and use it in any other distro, as it is linked against specific libraries, such as 'icu', that likely won't be present, or mis-configured.

Tags: easy, quirky

EasyShare probing computers to obtain hostnames

August 07, 2018 — BarryK

EasyShare has automatic discovery of shared folders and printers on the local network. To achieve this, it has to discover the hostnames of the computers, and in the case of Windows computers, the netbios-name.

EasyShare has two ways of doing this, by probing for SMB servers and then using the 'nbtscan' utility to retrieve the hostname or netbios-name, or by probing a modified dnsmasq server and using the 'nmap' utility to retrieve the hostname.

In the latter case, EasyOS (and Quirky) runs the dnsmasq server in a special configuration such that it will return the hostname upon receiving a query from nmap. A problem is that this is a corruption of how dnsmasq is normally used, so if someone wanted to use dnsmasq in the normal way, they can't.

What I want is a lightweight server that upon receiving a request, will return an arbitrary string. It would be nice if I could write such a server, but I don't know how. Instead, looking for something ready-made...

After googling, I discovered the 'identd' server. Busybox has a very cutdown version, name 'fakeidentd'. On one of the computers, run it, with any arbitrary string:

# fakeidentd HITHERE

fakeidentd listens on port 113, so we need some way to query this port, from another computer on the network. I could not see how to use 'nmap', however, found a perl script:

EasyOS and Quirky have a cut-down perl named "perl_tiny", and with the devx sfs, the full perl. I tried this script first with the devx loaded, so had the full perl, and it required just one more module, Net::Ident. This was easy to install:

# perl -MCPAN -e shell
> install Net::Ident
> quit

...which I made into a PET package. I then tested without the devx, and Net::Ident was missing some dependencies. Those missing deps are now included in perl_tiny.

Now, on another computer on my network, with Net::Ident and ident-user-enum installed, where is the computer running fakeidentd:

# 113
ident-user-enum v1.0 ( )    HITHERE


So, we have a simple mechanism to broadcast the hostname. My intention is to use this instead of dnsmasq. 'perl-net-ident' will be a PET package, in the noarch repo, and '' will be builtin at /usr/sbin in woofQ.

Of course, this discovery mechanism will apply to computers running EasyOS and Quirky only. For other computers, they must be running the SMB server ('smbd' daemon in the case of Samba). EasyShare probes for both.

Tags: easy, quirky

EasyOS version 0.9.6 released

August 06, 2018 — BarryK

Version 0.9.5 has changes to Easy Containers, however that work work has been on hold, as I "jumped tracks" to work on EasyShare, super-easy network file and printer sharing. EasyShare has been re-written, bugs fixed, improvements, and is the main feature of EasyOS 0.9.6.

Between 0.9.5 and 0.9.6, various bugs have been fixed. Just today, at the 12th hour before releasing 0.9.6, fixed a bug in the Xorg Wizard.

One curious thing, Xorg is now defaulting to using the 'modesetting' driver for Intel video hardware. You need to run the Xorg Wizard to explicitly choose the Intel driver.

Some issues regarding 0.9.5 posted to the Puppy Forum, have not yet been resolved, as my attention has been on EasyShare. Will get onto them soon.

There is a new app in 0.9.6, Vovchik's Gxlat language translator, that I posted about recently (look in the Document category in the menu):


The download is an image file to be written to a USB-stick. There are many utilities for doing that. If you need some instruction, read this:

If you wish to read-up on what EasyOS is all about, look here:

Read about 0.9.5 here:

Discussion on EasyOS is happening at this thread of the Puppy Forum, for 0.9.5 start reading from here:

Have fun!

Tags: easy