How to display bootscreen until userspace is loaded in yocto - splash-screen

I'm currently developing a custom image for an embedded system with Yocto. My current boot process (on the display) is: Kernel logo -> Black/empty screen (Kernel loaded, now loading userspace) -> Userspace Application.
For a better user experience i want to get rid of the black screen between kernel and userspace (custom logo is shown from kernel start until userspace is loaded). I tried using pslpash, but it basically just replaces the kernel logo.
How can i show a single boot logo from kernel start to userspace?

Related

Run splashscreen at Raspberry Pi boot before running Qt App

I am trying to run two services at RPi 4 startup:
one is my Qt App which I made executable and which has to wait for the graphical.target before running, which makes it start only after the raspberry loads the desktop.
the second is a simple splash screen which I would like to start from the very early boot of the RPi (thus hiding the console log) and ending just before the Qt app starts, therefore hiding everything, including the desktop frame, till the full-screen app appears.
Following several different guides, I tried various combination of parameters in the systemd files, such as:
[Unit]
Description= My Qt App Service
After=graphical.target
[Service]
Type=simple
User=pi
Environment=DISPLAY=:0
WorkingDirectory=/home/pi
ExecStart=/home/pi/myqtApp
[Install]
WantedBy=multi-user.target
for the Qt app (starting after the desktop loaded)
and:
[Unit]
Description=Splash Screen Service
DefaultDependencies=no
After=local-fs.target
Before=graphical.target
[Service]
ExecStart=/usr/bin/fbi -d /dev/fb0 --once --noverbose -a /opt/splashscreen.jpg
StandardInput=tty
StandardOutput=tty
[Install]
WantedBy=sysinit.target
I also modified the /boot/config.txt with display_splash=1 and /boot/cmdline.txt with
console=serial0,115200 console=tty1 root=PARTUUID=c8e5bf6e-02
rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait logo.nologo
consoleblank=0 loglevel=1 quiet vt.global_cursor_default=0
Now, two things happen depending on whether I set console=tty1 or tty3 (a guide suggested doing this) in the cmdline.txt file,
if tty1 is set, then the splash screen page is only briefly shown during startup, and then the desktop loads, and finally, my qt app starts. But I would like the splash screen to persist till the app starts without showing the desktop loading.
if tty3 is set, then the splash screen page is shown immediately at startup, but then the boot is stuck on it and nothing else is shown. In this case, I can see that my Qt app service started (no errors appear in its status) however somehow the splash screen service does not stop and therefore my qt app is not shown.
I would like everything to work as in this second case, with only the splash screen appearing since the beginning, but, of course, being replaced by the qt app as soon as the graphics allow it to run properly. I tried many other combinations of parameters in the service files but nothing seems to work.
edit: Forgot to mention that I am connected through an HDMI micro port to an external LCD display.

QWebView and embedded YouTube player - not working properly

My system:
OS: Debian Jessie 64bit
GPU: ATI Mobility Radeon HD 5650 (with proprietary video drivers)
I'm working with PyQt5 and want to embed a QWebView with a YouTube tutorial video inside a QWizardPage. However what I'm getting is the following is really strange:
Video doesn't load at all if I use the embedded link for the video (that is - the embedded YouTube player) which is basically what I want to use and not load the complete YouTube website
If I use the normal link (not embedded) I get not image but there is sound
The playback time is always messed up - I get -Nan:Nan when I however the player's playback trackbar and `
In the terminal (where I start my PyQt5 application from) always gives me the following errors:
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
Especially the last error really baffles me since yes, there is not JACK server running because I don't use JACK (I use PulseAudio and ALSA depending on the case). Does QWebView require JACK on Linux systems?
Here is a screenshot of my QWizard and the respective QWizardPage:
The code I use is as follows (the URL is just an example (video is mine) for the purpose of this post):
class CalibrationPageWelcome(QWizardPage):
'''
Gives an overviewo of the calibration procedure including some external URLs to tutorials
'''
def __init__(self, parent):
super(CalibrationPageWelcome, self).__init__(parent)
self.setTitle('Calibration Wizard')
self.setSubTitle('The wizard will guide you through the process of calibrating your camera device.')
layout = QVBoxLayout()
label = QLabel('''
Before you continue make sure you are familiar with the process of calibration.
The video below will give a brief explanation what the calibration process is for
and how it will be done using this wizard
''')
label.setWordWrap(True)
layout.addWidget(label)
view = QWebView()
# TODO Add link to tutorial about calibrating a camera using patterns and OpenCV
view.load(QUrl('https://www.youtube.com/embed/5sOiGJRyoBI'))
layout.addWidget(view)
self.setLayout(layout)
Any idea what is going on here?
Make sure you have the appropriate GStreamer dependencies installed - on Debian Jessie this should be:
apt-get install gstreamer1.0-plugins-{bad,base,good,ugly}

Beaglebone Black, Qt Application, and startup procedure

I have a BBB running Debian 3.18.13-bone70. I have made a Qt application that works great. I would like this application to run on startup.
Currently, I have made a script, placed it in /etc/init.d and made a symbolic link to it in /etc/rc5.d/S05application. This all functions correctly.
The issue that I'm having is when my system boots up, I see my application briefly (<1 second) before the CLI login screen appears and hides my application.
I've tried playing around with the startup script location (moving it to rc2.d, but the same issue persists.
I have a splash screen that times out after 10 seconds, and it moves on to the next screen. After moving to the next screen the application is never hidden again. I would like to see the splash screen the entire time and hide the CLI login screen entirely. How could I go about doing this?
EDIT:
#!/bin/bash
export QWS_MOUSE_PROTO=tslib:/dev/input/event1
export TSLIB_CALIBFILE=/etc/pointercal
export TSLIB_CONFFILE=/etc/ts.conf
export TSLIB_PLUGINDIR=/usr/lib/ts
export TSLIB_TSDEVICE=/dev/input/event1
/home/root/./Scanscale -qws
This is the script that I use to start the application. The Qt window service is used when I start the program.
EDIT 2:
I'm running Debian 7 using the Debian 7 image from http://elinux.org/Beagleboard:BeagleBoneBlack_Debian from March 1, 2015. This is maintained by Robert Nelson, I'm not sure if it's a yocto build or something else.
Furthermore, it doesn't appear to be an X issue. I've stopped loading X, I no longer boot into the application and just sit on the command line waiting to log in. The system flickers at about the same point in time. Any thoughts?
I should probably also mention that I'm running it on a 4.3" LCD cape, not on the HDMI interface.
You weren't specific about your system and what else is running on it. For example, is it a yocto build and does it run the sato user interface, or is it more traditional X server with a display manager, window manager, etc? Either way, there is a session-specific file which directs what programs get launched when the Xserver starts up. Using matchbox, that file is .matchbox/session. With X, it's usually xinit, which is driven by .xinitrc or .xserverrc. Also, look at startx as another poster mentioned. The latter can either be in your home directory or /etc/X11. Depending on your system and configuration, likely one of those methods, customized, is what you're looking for. See man xinit for more info.

Raspberry Pi Custom SD Card Image

I have a project uses Qt GUI which works on raspberry-pi2; however I don't want users to interact with the operating system. I just want that the only application appears on the screen (from boot to shutdown) to be is my application. Actually the retropie project has done what I actually want. So I want to prepare an minimal SD Card image like that. Is there any tool or way to do that?
You can use openembedded http://www.openembedded.org/wiki/Main_Page for this.
Creat file that describe packages for your image, at your case base system + qt,
plus create description of package of your program, that include .service file for run you program at start with systemd. The command MACHINE=raspberry-something bitbake your-image
I'd just use the init scripts to run your application as soon as possible and make it handle all user inputs (keyboard and mouse) properly, without giving any way to the user to close it.

Always launching flash player in secondary monitor and full screen mode

I am trying to set the location of Flash Player launch location to my secondary monitor connected using a VGA cable and I want to launch it always in FullScreen mode. After couple of searches, I found one link which relates to this topic:
http://www.flashdevelop.org/community/viewtopic.php?f=7&t=6658
But it doesn't seem to work for me. How do I set the x,y co-ordinates of flash player when it is launching as a new process ?
Adobe air has a Screen class to handle this. To help you out, there is an open source project on Google code that wraps this and handles some of the basics:
http://code.google.com/p/airscreenmanageras3/

Resources