arm,qml,qtwebkit,yocto,qt5.4 , Qt application trying to load platform plugin “xcb” instead of “eglfs”


Qt application trying to load platform plugin “xcb” instead of “eglfs”

Question:

Tag: arm,qml,qtwebkit,yocto,qt5.4

Built Raspberry Pi 2 linux distro including Qt5.4 + QtWebKit + QML plugin using Yocto on fido branch See tutorial

Testing with the following QML script

[email protected]:~# more webkit3.qml 
import QtQuick 2.0
import QtQuick.Controls 1.0
import QtWebKit 3.0

ScrollView {
    width: 640
    height: 480
    WebView {
        id: webview
        url: "http://qt-project.org"
        anchors.fill: parent
        onNavigationRequested: {
            // detect URL scheme prefix, most likely an external link
            var schemaRE = /^\w+:/;
            if (schemaRE.test(request.url)) {
                request.action = WebView.AcceptRequest;
            } else {
                request.action = WebView.IgnoreRequest;
                // delegate request.url here
            }
        }
    }
}

The ERROR message

This application failed to start because it could not find or load the Qt platform plugin "xcb"

Looks like it's still try to start with XCB plugin which relates to X11 whereas I specified EGLFS (??)

[email protected]:~# /usr/bin/qt5/qmlscene  webkit3.qml -platform eglfs
Unable to query physical screen size, defaulting to 100 dpi.
To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters).
This application failed to start because it could not find or load the Qt platform plugin "xcb".

Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen.

Reinstalling the application may fix this problem.

Any ideas why I am getting this issue?

QT5 plugins platforms installed

[email protected]:/usr/lib/qt5/plugins/platforms# ls -al
drwxr-xr-x    2 root     root          4096 Jun 12 12:59 .
drwxr-xr-x   18 root     root          4096 Jun 12 13:03 ..
-rwxr-xr-x    1 root     root        601864 Jun 11 15:19 libqeglfs.so
-rwxr-xr-x    1 root     root        499564 Jun 11 15:19 libqlinuxfb.so
-rwxr-xr-x    1 root     root         20576 Jun 11 15:19 libqminimal.so
-rwxr-xr-x    1 root     root        478500 Jun 11 15:19 libqminimalegl.so
-rwxr-xr-x    1 root     root        465740 Jun 11 15:19 libqoffscreen.so

Please do not refer me to the this or this issues. The message is the same but not I don't think it is the same cause.


Answer:

Maybe qmlscene is eating the arguments -- pass the -platform option BEFORE the name of the qml file, or set the QT_QPA_PLATFORM environment variable to eglfs instead of the command line parameter.

For the future, you might want to make eglfs the default choice by configuring Qt with -qpa eglfs.


Related:


Installing libraries for arm-gcc-compiler


linux,gcc,arm,cross-compiling,embedded-linux
I have a functional arm cross compiler that I can use with arm-linux-gnueabi-gcc command. This works for simple programs but I run into problems when I have to compile bigger programs requiring libraries like x11, opengl as the required headers/files are not present in arm-linux-gnuebi directory but in normal gcc...

How to divide the L2 cache between the cores on a ARM Cortex-A7?


caching,linux-kernel,arm,cortex-a,l2-cache
Context and goal I'd like to run two fully standalone applications on my Olimex A20 Lime platform that run a ARM Cortex-A7. The goal is to dedicate one core to each application. So far so good. Now I'd like to divide the L2 cache between the cores in the following...

Repeat state on mouse click QML


qt,qml,qtquick2
Within the code I have a State, a Transition and a RotationAnimation defined. After the property change takes place, i.e. after the rotation is set to 360, the onClicked handler is rendered mute and the animation will never be played again after subsequent MouseArea clicks. Here is my current code:...

what's ARM TCM memory


memory,arm
what is TCM memory on ARM processors, is it a dedicated memory which resides next to the processor or just a region of RAM which is configured as TCM??. if it's a dedicated memory, why can we configure it's location and size?....

Prevent and catch access to secure memory from normal code


arm,embedded,bare-metal,trust-zone
I am exploring the ARM trustzone on my imx53-QSB and I have a question. I shared the memory between the normal and the secure world. But when I try to access to read from a secure memory adress from the normal (like that : cprintf("Secure Data SD0: 0x%x\n", *R32 SD0);)...

Code using indirect assignment not working


c,pointers,arm
On an embedded ARM system I have implemented a register system: Each register is an array of uint8_T The host system can set either one register or more registers at the same time, by issuing a specific command on the serial port of the CPU. This is the code, stripped...

QML is not recognising C++ functions


c++,qml,integration
I am trying to implement my c++ class into QML, the class is recognised by setting the context property and I can successfully call the class and see all the functions but on runtime they are not recognised and returns the error: TypeError: Property 'getSrcImage' of object Wrapper(0x7b211cbf10) is not...

setting wrapMode property of Text in ScrollView


qt,qml,qt5,qtquick2
I wrote QML like this: import QtQuick 2.2 import QtQuick.Controls 1.1 import QtQuick.Layouts 1.1 import App 0.1 ApplicationWindow { id: appWindow visible: true width: 300 height: 500 ColumnLayout { ScrollView { ColumnLayout { Text { width: 250 text: "Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor...

How to convert unsigned char to signed integer by neon


arm,simd,neon,cortex-a
How to convert a variable of data type uint8_t to int32_t using Neon? I could not find any intrinsic for doing this.

Why Device Tree Structure (DTS) file is needed both in bootloader and kernel source code?


linux-kernel,arm,embedded-linux,u-boot,device-tree
Bootloaders like U-Boot that do not implement the Open Firmware API, are expected to pass to the kernel a binary form of the flattened device tree - LinuxFDTBlob Why are the DTS files present in the kernel as well? Isn't that redundant? As an example, U-boot source code has...

How to connect a destroyed signal of C++ object from QML?


javascript,qt,qml,qtquick2
I want to connect a destroyed signal of C++ QObject from QML so I did this: Rectangle { id: root width: 128 height: 128 Button { anchors.centerIn: parent text: "Click me" onClicked: { qobj.Component.onDestruction.connect(function(){console.log("It destroy")}) // qobj is set from c++ qobj.destroy() // should output "It destroy" } } But...

QML ScrollView with ColumnLayout


c++,layout,qml,qt5
I am trying to create a scroll view around a ColumnLayout, unfortunately my current code doesn't work. I know about ListView, but in my case I need to create scrollable Layout, because it will contain heterogeneous elements. ApplicationWindow { id: mainwindow title: qsTr("Hello World") width: 300 height: 300 visible: true...

How to rotate an element on both axes with different angle values


qt,qml
If you need to rotate an element in QML in order to achieve a sort of 3d flip effect then you can do transform: Rotation { origin.x: 30; origin.y: 30; axis { x: 0; y: 1; z: 0 } angle: 24 } How can I achieve the same thing but...

Flashing a C program to ARM


c,arm,embedded
I just started programming for an ARM Processor and I have never been this clueless. There are a couple of example projects that came with the board (ADucm350) and I wanted to upload one of them. I downloaded Keil (or I think it's just the project management software part of...

Qt application trying to load platform plugin “xcb” instead of “eglfs”


arm,qml,qtwebkit,yocto,qt5.4
Built Raspberry Pi 2 linux distro including Qt5.4 + QtWebKit + QML plugin using Yocto on fido branch See tutorial Testing with the following QML script [email protected]:~# more webkit3.qml import QtQuick 2.0 import QtQuick.Controls 1.0 import QtWebKit 3.0 ScrollView { width: 640 height: 480 WebView { id: webview url: "http://qt-project.org"...

Did anyone compiled GSL for androind?


android,arm,gsl
I am trying to compile gsl for android but it is giving error. I checked on their website and they said that It has been reported to compile on the following other platforms, SunOS 4.1.3 & Solaris 2.x (Sparc) Alpha GNU/Linux, gcc HP-UX 9/10/11, PA-RISC, gcc/cc IRIX 6.5, gcc m68k...

Align horizontalcenter in Column


qt,qml,qtquick2,qt-quick
Column documentation explains how to achieve this: However, I would like to achieve this: That is, all items inside the Column should be horizontally aligned to the center. anchors.horizontalCenter: parent.Center does not work. How can I obtain the desired result?...

ARM assembly cannot use immediate values and ADDS/ADCS together


gcc,assembly,arm,instructions
I am currently trying to speed up some of my C functions on a Cortex-M0 (Freescale KL25Z) using assembly. I get a problem with this minimal test program: @.syntax unified .cpu cortex-m0 .text .global test .code 16 test: mov r0, #0 adds r0, r0, #1 bx lr When I try...

Share array or list between C++ and QML via property


c++,list,properties,qml
There's a list of unsigned ints in C++ class. The list can be modified inside the class in some way. There's a QML object that has to use this list. How should I declare the list to make the object able to use the values from the list and after...

ARM conditional instruction setting flags


arm,arm64
As I read about conditional execution in ARM, I can see why instructions in ARM do not set the flags by default. They seem to set flags only when the S suffix is added in. I was wondering if it would be possible to have an ARM instruction that executes...

Prelink Error: prelink-cross: simple hello world example


c++,compilation,arm,cross-compiling,prelink
I am trying to cross-prelink a simple hello world program. I use the cross-compile toolchain arm-2012.03-57-arm-none-linux-gnueabi-i686-pc-linux-gnu and I am not sure if I have used the prelink-cross options correclty. I'll be glad if someone could point me to the right direction. More details about the source code on github. Thank...

Can't use DropShadow in Column?


qt,qml,qtquick2
I was developing a small application using QML, and i need a small drop shadow on the text component, to make it more readable, but when I add the DropShadow to the Label in the Column, it throws an error: "QML Column: Cannot specify top, bottom, verticalCenter, fill or centerIn...

Cmake errors: The CXX Compiler identification is unknown, The C compiler identification is unknown


c++,opencv,cmake,arm,cmake-gui
I'm trying to install OpenCV on Fedora 21 with a cross compiler for ARM processor. However, when i try to configure using Cmake 3.03, it gives the error: *The CXX compiler identification is unknown The C compiler identification is unknown Check for working CXX compiler: /opt/FriendlyARM/toolschain/4.5.1/bin/arm-linux-g++ Check for working CXX...

QML: Using a Canvas in a RadioButtonStyle


qt,qml,qt-quick
Using a Canvas inside a RadioButtonStyle doesn't seem to work. Consider this simple example: // MyRadioButton.qml import QtQuick 2.4 import QtQuick.Controls 1.3 import QtQuick.Controls.Styles 1.3 RadioButton { id: base implicitHeight: 24 style: RadioButtonStyle { spacing: 4 indicator: Canvas { id: circle anchors { left: parent.left verticalCenter: parent.verticalCenter } height: 16...

C Global declared in ISR


c,arm,embedded,cortex-m,codewarrior
I am evaluating Freescale's Kinetis Design Studio for their ARM series microcontrollers. I was looking at an example as a basis to do my first "blink an LED" project. When using variables shared between my main program and an ISR such as a counter, I would typically define a volatile...

where and what to learn to use Qt5? [closed]


c++,qt,qml
I tried to use Qt5 but I find it very confusing. I have good knowledge of c++(I would say between intermediate-expert level) but no knowledge of javascript or QML(only basic HTML) When I go through the examples and tutorials provided with Qt, I find then more to be reference material...

Eclipse CDT shows … not resolved errors for ARM neon intrinsics, but produces the binary


c++,eclipse,arm,neon
I develop ARM-Neon based embedded software for Cortex A8 and A9 processors. I use Eclipse CDT Luna for development environment. I opened a project and added #include "arm_neon.h" at the beginning of my main code, and the following flags to both C++ compiler and linker miscellaneous flags part in project...

What is the use of the ui.qml files in Qt5 (QML)?


qt,qml
As far as I can see the .qml files can be used to define the UI, which seems to override whatever is written in ui.qml file. So, what exactly is the use of the ui.qml file? I'm using Qt5 with Qt Creator....

QtQuick2 - QML reusable item focus changes when selecting/clicking outside/inside of root item


javascript,qt,focus,qml,qtquick2
How can I implement focus changing state into reusable QML component when I clicked or selected another item outside component body to call any event (highlight text, show/hide rectangle and etc). There is code I trying to implement highlight line under CheckBox text when item have focus, and hide that...

Text as parameter in inline assembly (ARM)?


gcc,arm,inline-assembly
Is there a way to put plain text in inline assembly (ARM)? My problem is reading banked registers. The syntax is (r11 of user mode): mrs r0, r11_usr The problem is the "usr"-part. I tried: #define READ_REG_MODE(retvar, rg, mode) \ asm volatile (\ "mrs %[reg], r%c[rn]_%c[mod]\n\t"\ :[reg] "=r" (retvar)\ :[rn]"I"(rg),...

Editing a TextInput in a ScrollView


qt,scrollview,qml,qtquick2,qtquickcontrols
I have an issue with my QML. I'd like to edit a TextInput based on an action, setting the focus attribute to true. It works when the TextInput is located in a Rectangle, but not in a ScrollView. Here is an example: Item { id: main width: 640 height: 480...

JTag Debugging with Eclipse Mars CDT : “Program file does not exist”


arm,eclipse-cdt,cortex-m3,jtag,jlink
I have successfully compiled an ARM embedded project, next files has been created: MyProject.elf MyProject.bin MyProject.hex MyProject.map MyProjectmd5.bin Then I am going to Run -> Debug Configurations -> GDB SEGGER J-Link Debugging -> New -> Debug and I get the error: Program file does not exist The GCC Compiler for...

Passing 2-dimensional QVariantList from C++ to QML


c++,qt,qml
I am really confused on how to pass a 2-dimensional QVariantList from C++ to QML, I basically want to pass a value from C++ which will do the same as assigning it in QML like this: property var twoDim: [["1-1", "1-2"],["2-1", "2-2"]] So that I can use the array as...

Deploying to Android results in file not found after adding QtQuick Controls


android,qt,deployment,qml,qt5.4
After importing QtQuick.Controls 1.2 and using StackedWidget component, I now get an error when deploying to Android as seen below. The missing file AnimationDrawable.qml is not missing from the Android build directory so I do not understand why it is not packaged with the APK. It deploys fine when I...

Even width of Text and Textfield


qt,qml,qt5,qtquick2
I have a simple login form written in QML with a custom component, MediumText, and two TextFields. Unfortunately, I'm not able to properly align the elements, as shown by the following picture: I want the labels to the left (MediumText type), as well as the TextField instances on the right,...

Cache and scratchpad memories


caching,arm,computer-architecture
Could someone explain what is the difference between cache memory and scratchpad memory? I'm currently learning about computer architecture.

QtQuick2 - QML - create infinite moving line animation


javascript,animation,qml,infinite-scroll,qtquick2
Does anyone know how to implement linear animation, for example like in progress bars, where few of lines moving infinite in the bar from left to right or any other way? I'm going to use only QtQuick2 primitives and without any additional C++ components, glad to see any answers that...

QML: Can I draw a rectangle from its center, not from its corner?


qml
If I want to visualize a point in qml i could do something like this: import QtQuick 2.4 import QtQuick.Window 2.2 import QtQuick.Controls 1.2 import QtQuick.Layouts 1.0 ApplicationWindow{ width: 1024 height: 256 visible: true ColumnLayout { anchors.fill: parent Rectangle { x: 10 y: 10 width: 5 height: 5 color: "white"...

What are the steps to setup an RTOS application on STM32 using Linux and Makefiles instead of using Windows based IDEs?


makefile,arm,embedded-linux,stm32,rtos
I am using STM32F4 Discovery board to develop a simple application to on-board accelerometer while simultaneously lighting respective LEDs mounted around the accelerometer device. I want to use any RTOS but I am unable to decide which one since I am new to using RTOS. If anyone could elaborate the...

DPI-independent constant size in QML


qt,qml,qt5,qtquick2,qt-quick
I have a visual component in my app written in QML, Qt5. I want it to always have the width of 5 cm on the screen, no matter what device is used. If I set width: somevalue, then the DPI might differ among the devices which will result in different...

How to set User Agent in QtWebEngine QML application


qt,qml,qt5,user-agent,qtwebengine
NOTE: I was able to do that on QtWebKit QML using the QtWebView extension. Here I am interested in using QtWebEngine. My simple test application import QtQuick 2.1 import QtQuick.Controls 1.1 import QtWebEngine 1.0 ApplicationWindow { width: 800 height: 600 color: "lightgray" visible: true WebEngineView { id: webview url:...

Update bindings to var properties in QML


qt,qml
If you take a look at this page it notes that bindings to var properties are not automatically updated when the object changes: Item { property var car: new Object({wheels: 4}) Text { text: "The car has " + car.wheels + " wheels"; } Component.onCompleted: { car.wheels = 6; }...

Program Runs Fine for Hours and Eventually Seg Faults with Memory Address 0x10 [closed]


c++,c,memory,arm
So I've been tracking some memory issue for the longest time. I'm coding in C++ and I can see that my program mostly works. I am monitoring my resources and I dont think I have a memory leak because my memory used stays below 12% (I'm on a system with...

How to close Pyqt5 program from QML?


qt,python-3.x,qml,signals-slots,pyqt5
I started a project in Qt Creator initially with a C++ backend, but then switched it to use PyQt5. I have a main.qml, where when I press a button called Exit, I call Qt.quit(). However, I get a General Message stating: Signal QQmlEngine::quit() emitted, but no receivers connected to handle...

QTimer::singleShot equivalent for QML


qt,qml
Consider this C++ statement (example from docs): QTimer::singleShot(600000, &app, SLOT(quit())); How to do the same in .qml JavaScript, something like this QML: Rectangle { property int counter: 0 onCounterChanged: { if (counter > 42) { // do equivalent of above C++ statement here } } // more code, which actually...

Qt Creator doesn't display QML folder


qt,qml,qt-creator,qtquick2,qt-quick
I have a Qt project in Qt Creator. I have a qrc file with the QMLs registered and everything works. However for some reason the "projects" view of Qt Creator doesn't show the QML folder (screenshot attached) like it does for any example project. I'm just curious. Why does QML...

What does QByteArray get converted to in QML?


javascript,qt,qml,qbytearray
If I have a signal: void foo(QByteArray data); And in QML I handle it: onFoo: { console.log(data.toString()); } What is the type of data in QML? What methods does it have? It doesn't seem to be a javascript string - it doesn't even have a .length, and no .charCodeAt(). But...

Swap the two middle bytes of a word using 4 ARM instructions


algorithm,assembly,arm
The task is to write code in arm assembler using no more than 4 instructions that swaps the two middle bytes in a given 32-bit word. For example if the word is 0xAABBCCDD the result should be 0xAACCBBDD. You may use at most 4 arm instructions from the set AND,...

Traversing a string using arm assembly inside V8 source


arm,v8
I am trying to implement a fastpath for regular expressions in arm/code-stubs-arm.cc in the RegExpExecStub::Generate function. The subject string is stored in the register 'r4'. I need to traverse character by character in the string but I can't seem to be able to do it. I have tried things like:...