looking for a light weighted library/tool to write simple GUI abovethe text based application

P

petr.jakes.tpc

Hi,
I am working with the Python 2.5 running on the command line version
of Linux Ubuntu 7.04. This means NO X-windows, NO GTK/Gnome, NO
computer mouse, on my machine (AMD Geode 500MHz CPU, VGA output).

I would like to write some really light weighted GU interface. My
concept is to have just few user screens (about 10) controlled via 4
or 5 HW buttons connected to the GPIO pins they are available on the
motherboard (the HW design and the SW concept of reading this buttons
is already solved).

After some googling, I have found below mentioned can be usable, but
first, I would like to ask here for your opinions/experiences/advices.

Best regards

Petr Jakes

http://www.libsdl.org/
http://pyfltk.sourceforge.net/
http://www.pygame.org/news.html
http://pyui.sourceforge.net/
http://pyglet.org/
 
R

rndblnch

This means NO X-windows, NO GTK/Gnome, NO
computer mouse, on my machine (AMD Geode 500MHz CPU, VGA output).

I would like to write some really light weighted GU interface. My
concept is to have just few user screens (about 10) controlled via 4
or 5 HW buttons connected to the GPIO pins they are available on the
motherboard (the HW design and the SW concept of reading this buttons
is already solved).

what you are looking for is curse :)
http://docs.python.org/lib/module-curses.html
http://www.ibm.com/developerworks/linux/library/l-python6.html

renaud
 
P

petr.jakes.tpc

is already solved).

Renaud, thanks for your reply.

I think I was not specific/clear enough in my first posting. I know
the curses library ( http://pyncurses.sourceforge.net ). It AFIK
provides TUI (short for: Text User Interface or Textual User
Interface). My needs are GUI, I mean "a nice VGA pictures" on the VGA
LCD 10" display.

Petr
 
L

Lorenzo E. Danielsson

Renaud, thanks for your reply.

I think I was not specific/clear enough in my first posting. I know
the curses library ( http://pyncurses.sourceforge.net ). It AFIK
provides TUI (short for: Text User Interface or Textual User
Interface). My needs are GUI, I mean "a nice VGA pictures" on the VGA
LCD 10" display.

Petr

What you need then is something like SVGAlib (http;//svgalib.org). Only
really old people like myself know that it exists. I've never heard of
any Python bindings for it, but that might be where you come in. I
haven't looked at SVGAlib for years, and I'm not sure about the state of
the video drivers. I suggest you look at that first.

You could also look at GGI (http://ggi-project.org). GGI has different
output targets. IIRC, one of them is directfb. To tell you the truth
I've never really used GGI. There seems to be a python wrapper for GGI,
although it is fairly old. Maybe you could look at the code for some ideas.

You should also be able to compile SDL to be able to use directfb as a
target. If your libSDL handles it, then that should apply to wrapper
libraries as well, including pygame. I've never tried running SDL apps
this way, but if it works well, that would probably be your 'best' option.

Lorenzo
 
H

Hexamorph

Lorenzo said:
(e-mail address removed) wrote:

What you need then is something like SVGAlib (http;//svgalib.org). Only
really old people like myself know that it exists. I've never heard of
any Python bindings for it, but that might be where you come in. I
haven't looked at SVGAlib for years, and I'm not sure about the state of
the video drivers.

I don't think that there's a Python binding for it. Svgalib never
has gained enough popularity for anybody to write such bindings.
However, as long as the video card supports VGA or VESA it should work.

Another possibility might be using Xvesa (KDrive) which is a really
tiny self-containing X server for VGA/SVGA/FBdev. With this you can
atleast use simple GUI toolkits like Athena or TK or even use Xlib
directly (if you don't fear that adventure)

See:
http://www.xfree86.org/current/Xvesa.1.html
http://www.pps.jussieu.fr/~jch/software/kdrive.html


HTH
 
D

Diez B. Roggisch

Hi,
I am working with the Python 2.5 running on the command line version
of Linux Ubuntu 7.04. This means NO X-windows, NO GTK/Gnome, NO
computer mouse, on my machine (AMD Geode 500MHz CPU, VGA output).

I would like to write some really light weighted GU interface. My
concept is to have just few user screens (about 10) controlled via 4
or 5 HW buttons connected to the GPIO pins they are available on the
motherboard (the HW design and the SW concept of reading this buttons
is already solved).

After some googling, I have found below mentioned can be usable, but
first, I would like to ask here for your opinions/experiences/advices.

Best regards

Petr Jakes

http://www.libsdl.org/
http://pyfltk.sourceforge.net/
http://www.pygame.org/news.html
http://pyui.sourceforge.net/
http://pyglet.org/


pygame is based on sdl, pyui can render to pygame. So if you use that
stack, it's a question of SDL being capable of directly rendering to
something like SVGALib.

Pyglet is OpenGL, and fltk seems to need X.

But WHY aren't you just installing X? You don't need to run a
full-fledged Desktop like gnome or kde on top of it - just use ratpoison
or anything else as desktop manager & be happy.

After all, my first PC had 16MB of RAM and 133MHz - and ran X w/o any
problems.

Diez
 
P

Paul Boddie

What you need then is something like SVGAlib (http;//svgalib.org). Only
really old people like myself know that it exists. I've never heard of
any Python bindings for it, but that might be where you come in. I
haven't looked at SVGAlib for years, and I'm not sure about the state of
the video drivers. I suggest you look at that first.

I believe that SVGAlib was superseded by GGI and other projects, and I
recall that SVGAlib was considered to be something of a nightware with
respect to how it handles various resources. Certainly, I haven't been
very impressed by the behaviour of software using it.
You could also look at GGI (http://ggi-project.org). GGI has different
output targets. IIRC, one of them is directfb. To tell you the truth
I've never really used GGI. There seems to be a python wrapper for GGI,
although it is fairly old. Maybe you could look at the code for some ideas.

I've had to build software using GGI, and the biggest problem has been
getting packages for it. That said, it seemed to work fairly
acceptably once built and installed. Meanwhile, some people favour
Allegro [1] for this kind of work, and I've been confronted with newly
developed software which uses Allegro, so it's arguably in a different
maintenance state than something like SVGAlib or GGI.
You should also be able to compile SDL to be able to use directfb as a
target. If your libSDL handles it, then that should apply to wrapper
libraries as well, including pygame. I've never tried running SDL apps
this way, but if it works well, that would probably be your 'best' option.

I'd agree with these sentiments; SDL seems to be the best supported
technology of this kind in the Python universe, and one of the most
widely deployed in general; I've felt quite comfortable building
software against it. It would be very interesting to see whether a
framebuffer-based SDL could support Pygame, and I imagine that the
Pygame mailing list might already have some answers in its archives on
this topic.

Paul

[1] http://www.talula.demon.co.uk/allegro/
 
C

Chris Mellon

What you need then is something like SVGAlib (http;//svgalib.org). Only
really old people like myself know that it exists. I've never heard of
any Python bindings for it, but that might be where you come in. I
haven't looked at SVGAlib for years, and I'm not sure about the state of
the video drivers. I suggest you look at that first.

I believe that SVGAlib was superseded by GGI and other projects, and I
recall that SVGAlib was considered to be something of a nightware with
respect to how it handles various resources. Certainly, I haven't been
very impressed by the behaviour of software using it.
You could also look at GGI (http://ggi-project.org). GGI has different
output targets. IIRC, one of them is directfb. To tell you the truth
I've never really used GGI. There seems to be a python wrapper for GGI,
although it is fairly old. Maybe you could look at the code for some ideas.

I've had to build software using GGI, and the biggest problem has been
getting packages for it. That said, it seemed to work fairly
acceptably once built and installed. Meanwhile, some people favour
Allegro [1] for this kind of work, and I've been confronted with newly
developed software which uses Allegro, so it's arguably in a different
maintenance state than something like SVGAlib or GGI.
You should also be able to compile SDL to be able to use directfb as a
target. If your libSDL handles it, then that should apply to wrapper
libraries as well, including pygame. I've never tried running SDL apps
this way, but if it works well, that would probably be your 'best' option.

I'd agree with these sentiments; SDL seems to be the best supported
technology of this kind in the Python universe, and one of the most
widely deployed in general; I've felt quite comfortable building
software against it. It would be very interesting to see whether a
framebuffer-based SDL could support Pygame, and I imagine that the
Pygame mailing list might already have some answers in its archives on
this topic.


I agree that SDL is probably the best choice but for the sake of
completeness, Gtk can (at least in theory - I've never tried it) be
built against directfb and run without X.
 
P

petr.jakes.tpc

I agree that SDL is probably the best choice but for the sake of
completeness, Gtk can (at least in theory - I've never tried it) be
built against directfb and run without X.

from the Pygame Introduction: Pygame is a Python extension library
that wraps the SDL library and it's helpers. So you mean, Pygame can
run without X?

BTW I have nothing against X, I just have not experiences on the GUI
field, so my feeling was it can run faster without X on the 500MHz AMD
Geode CPU.

Petr
 
T

Tim Rau

from the Pygame Introduction: Pygame is a Python extension library
that wraps the SDL library and it's helpers. So you mean, Pygame can
run without X?

BTW I have nothing against X, I just have not experiences on the GUI
field, so my feeling was it can run faster without X on the 500MHz AMD
Geode CPU.

Petr

The problem is not with x: you should be able to run x just fine with
only 133MHZ and a few megs of ram. The performance issues on such a
machine come from things like kde and gnome. use one of the simpler
window managers.
 
P

petr.jakes.tpc

Finaly, after few experiments, I am using pygame.
It comunicates directly with the framebuffer and the performance is
excellent.

Thanks for your help.

Petr Jakes
 

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,058
Latest member
QQXCharlot

Latest Threads

Top