cancel
Showing results for 
Search instead for 
Did you mean: 

qt-wpe-simple-browser throws error : QQmlApplicationEngine failed to load components

darla14
Senior

Hello ,

I followed 1 qt-wpe-simple-browser

from here : https://wiki.st.com/stm32mpu/wiki/How_to_install_a_simple_web_browser

but getting the error in launching the browser on executing this command :

qt-wpe-simple-browser http://google.com

QQmlApplicationEngine failed to load components

qrc:/main.qml:3:1:module "org.wpewebkit.qtwpe" is not installed

which package i have to install?

I am already connecteed to network and I am on Ecosystem 3.0

regards,

D

1 ACCEPTED SOLUTION

Accepted Solutions
Jean-Marc B
ST Employee

Hello @darla14​ 

Thank you very much for your feeback.

I take your questions as they come.

1/ The web browser can not connect to the google URL.

Could you check the board has an IP address. The commands

root@stm32mp1:~# ifconfig eth0

or if you have a WIFI connection

root@stm32mp1:~# ifconfig wlan0

should show the field inet addr with an IP address.

If not, please check your RJ45 connection or refer to the wiki pages related to the WIFI setup here or there.

If your board has an IP address, perhaps your board is behind a proxy. In such a case, export these two environment variables:

root@stm32mp1:~# export HTTP_PROXY="http://<your proxy url>:<port>"
root@stm32mp1:~# export HTTPS_PROXY="http://<your proxy url>:<port>"

NB: there is no typo in the second expression: the URL is http and not https.

2/ The screen goes black after systemctl stop weston@root

That's the expected behaviour. With the qtwayland environment, you don't need to apply this command. I am sorry, I didn't see you were using only egls.

3/ ULR fetching error with apt-get install qtwayland

That may happen some time to time. I didn't succeed in identifying the underlying problem. However, it happens to be transient errors when I saw them (twice or three times since we put in production the OpenSTLinux repository). If these errors are not transient from your side, I would be glad if you could open a new topic related to these errors.

4/ Using qt-wpe-simple-browser with egls

By running the following commands:

root@stm32mp1:~# systemctl stop weston@root
root@stm32mp1:~# export QT_QPA_PLATFORM=eglfs
root@stm32mp1:~# export QML2_IMPORT_PATH='/usr/lib/qt5/qml/'
root@stm32mp1:~# export QT_QPA_EGLFS_ALWAYS_SET_MODE='1'
root@stm32mp1:~# qt-wpe-simple-browser http://google.com

I am able to see the web browser on the screen of my stm32mp157f-dk2 board.

Best regards,

--JM

View solution in original post

9 REPLIES 9
Javier1
Principal

this looks like a Qt issue and Qt forum dwelings are more likely to answer your question

https://forum.qt.io/

we dont need to firmware by ourselves, lets talk
Jean-Marc B
ST Employee

Hello @darla14​ 

I think the wiki page is a bit misleading.

The error you get comes from the missing declaration:

root@stm32mp1:~# export QML2_IMPORT_PATH='/usr/lib/qt5/qml/'

If the launch failed again, try to declare (assuming your in the qtwayland environment):

root@stm32mp1:~# export QT_QPA_PLATFORM=wayland-egl
root@stm32mp1:~# export QT_QPA_EGLFS_ALWAYS_SET_MODE="1"

Tell me if this works. If so, I will get in touch with the wiki author to fix the web page when coming back from my holidays.

Best regards,

--JM

thanks, i was able to load it after exporting the path but unfortunately the webpage could not load the url

it shows :

Host www.google.com not found

Failed to load URL : http://WWW.GOOGLE.COM

I will test more.

STrange thing after executing systemctl stop weston@root , screen goes black . I had to connect to HDMI to see the page.

Dont we have to execute systemctl start weston@root at some point?

there are 3 steps

1> using Qt

2.Using Python

3> using eglfs or wayland.(whats teh difference)

I used eglfs because i get some url fetching error with apt-get install qtwayland (pointing some error in the url at 5.10.10 location.

I think 3rd Step is in addition and a pre-requisite with Step 1 OR 2 .It appeas from wiki that 1 OR 2 alone are sufficient.

Regards,

Jean-Marc B
ST Employee

Hello @darla14​ 

Thank you very much for your feeback.

I take your questions as they come.

1/ The web browser can not connect to the google URL.

Could you check the board has an IP address. The commands

root@stm32mp1:~# ifconfig eth0

or if you have a WIFI connection

root@stm32mp1:~# ifconfig wlan0

should show the field inet addr with an IP address.

If not, please check your RJ45 connection or refer to the wiki pages related to the WIFI setup here or there.

If your board has an IP address, perhaps your board is behind a proxy. In such a case, export these two environment variables:

root@stm32mp1:~# export HTTP_PROXY="http://<your proxy url>:<port>"
root@stm32mp1:~# export HTTPS_PROXY="http://<your proxy url>:<port>"

NB: there is no typo in the second expression: the URL is http and not https.

2/ The screen goes black after systemctl stop weston@root

That's the expected behaviour. With the qtwayland environment, you don't need to apply this command. I am sorry, I didn't see you were using only egls.

3/ ULR fetching error with apt-get install qtwayland

That may happen some time to time. I didn't succeed in identifying the underlying problem. However, it happens to be transient errors when I saw them (twice or three times since we put in production the OpenSTLinux repository). If these errors are not transient from your side, I would be glad if you could open a new topic related to these errors.

4/ Using qt-wpe-simple-browser with egls

By running the following commands:

root@stm32mp1:~# systemctl stop weston@root
root@stm32mp1:~# export QT_QPA_PLATFORM=eglfs
root@stm32mp1:~# export QML2_IMPORT_PATH='/usr/lib/qt5/qml/'
root@stm32mp1:~# export QT_QPA_EGLFS_ALWAYS_SET_MODE='1'
root@stm32mp1:~# qt-wpe-simple-browser http://google.com

I am able to see the web browser on the screen of my stm32mp157f-dk2 board.

Best regards,

--JM

thanks a lot ! worked for me as well.

i see we have used eglfs.

will try with wayland .

Tx,

Regards,

D

Hi @darla14​ 

I am glad to see you fixed the issue.

Keep me posted with the wayland attempt if needed.

Best Regards.

--JM

"To help community to find solutions, please click on "Select as Best" for reply which solved your issue or answered your question."

MBeli.1
Associate III

@Jean-Marc B​ I've tried kirkstone branch and I cannot even build qt-wpe-simple-browser due cog build issue mentioned here: https://github.com/Igalia/meta-webkit/issues/446

Even when resolve it somehow starting browser just display white background but no webpage content is loaded. Did somebody check it on kirkstone branch? Thanks.

Hi @MBeli.1​ 

As this post is two years old and successfully resolved, could you open a new one please?

Best regards,

--JM

MBeli.1
Associate III