Bootable Qt-Linux Application

QT application Autostart --- in linux

1) You can simply create a script to start your application and add it to /etc/init.d folder, for example: /etc/init.d/S30myapp, which includes:

#!/bin/sh
/etc/my_qt_app -qws &

Of course, do not forget to chmod +x them.

2-3) The most simple solution is to use Qt Windowing System (QWS). Check here for more technical details.

4) Taken from tags from superuser:

Desktop-environments: Software that provides a graphical user
interface, with elements like icons, windows, toolbars, as well as
additional features. Popular examples include Gnome and KDE.

A window manager takes care of the placement and appearance of windows
in a GUI-driven operating system. Sometimes, the term also refers to
plugins that extend this basic functionality.

I don't know your requirements, but usually only windows manger is used in embedded devices. But as I mentioned before, Qt has its own windows manager - QWS. Another widespread option is X Server.

5) In case you use QWS (or any other windows manager), you can start your initial application and maximize it to full screen, so it will be the only application visible. However, check this discussion for multiple concurrent applications using QWS.

How to create bootable GUI programs?

The story behind a comprehensive GUI + bootable program is somewhat like this:

  • Develop the program in a linux GUI toolkit
  • On boot, load a linux kernel (without any desktop environment)
  • Hand over the control to the program GUI

more info: Bootable Qt-Linux Application

Building Qt apps for Windows Phone on Linux

Well there is Wine. This is what wikipedia says about it;

Wine (short for Wine Is Not an Emulator) is a free and open source compatibility layer software application that aims to allow applications designed for Microsoft Windows to run on Unix-like operating systems. Wine also provides a software library, known as Winelib, against which developers can compile Windows applications to help port them to Unix-like systems.

You can find more info about Wine here; https://www.winehq.org/

I haven't tried it before but since it says "allow applications designed for Microsoft Windows to run on Unix-like operating systems," I'm thinking it should work.

This is your only option. If it doesn't work, then i guess you should think about running windows on virtual machine or dual booting with windows. Good luck!

Qt GUI instance autostarted with systemd does not respond to input

Thanks for the input above. It actually was not a working directory or timing issue. The problem was that my Qt GUI was not getting the proper environment variables that it needed for communicating with the touchscreen. Sourcing /etc/profile worked for me:

[Unit]
Description=The Qt Gui
After=dropbear.service
ConditionFileIsExecutable=/home/user/gui

[Service]
Type=simple
TimeoutStartSec=60
WorkingDirectory=/home/user
ExecStartPre=/bin/sh -c 'echo 127 > /sys/class/backlight/generic-bl/brightness'
ExecStart=/bin/sh -c 'source /etc/profile ; /home/user/gui -qws'
Restart=always

[Install]
WantedBy=multi-user.target


Related Topics



Leave a reply



Submit