Skip to content
This repository has been archived by the owner on Dec 12, 2023. It is now read-only.

enable miracast on vegetahd #1141

Open
Fuseteam opened this issue May 13, 2019 · 6 comments
Open

enable miracast on vegetahd #1141

Fuseteam opened this issue May 13, 2019 · 6 comments

Comments

@Fuseteam
Copy link

Fuseteam commented May 13, 2019

as the title says miracast is disabled on the BQ aquaris E5 while it supposely works under android.
There is an bug report about this on launch from a while back as well https://bugs.launchpad.net/aethercast/+bug/1598559
in aethercastctl i get the following output for show after using enable

Enabled: true
State: idle
Scanning: false
Capabilities:
  source

i have now tried to connect to an android device with a miracast sink app
i appear to run into this issue https://bugs.launchpad.net/aethercast/+bug/1590135
it appears related to apparmor as also noted in that issue
lines that i have also found in syslog

May 13 15:59:00 ubuntu-phablet dhclient[25317]: can't create /run/aethercast/dhclient-46d0-3e6d-03fa-a588-p2p0.leases: Permission denied
May 13 15:59:00 ubuntu-phablet kernel: [ 6426.898210]type=1400 audit(1557773940.350:234): apparmor="DENIED" operation="open" profile="/sbin/dhclient" name="/run/aethercast/dhclient-46d0-3e6d-03fa-a588-p2p0.leases" pid=25317 comm="dhclient" requested_mask="wc" denied_mask="wc" fsuid=0 ouid=0

and aethercast.log

can't create /run/aethercast/dhclient-e15c-0dba-2cae-6e65-p2p0.leases: Permission denied
@dark-eye
Copy link

It seems that I have the same issue on Meizu PRO 5 i think this is device independent

@dobey
Copy link
Member

dobey commented May 14, 2019

The apparmor issue is the same as described in #781 (comment)

If you perform this workaround, the apparmor issue will go away.

@Fuseteam
Copy link
Author

Fuseteam commented May 14, 2019

can confirm it successfully makes the connection
afterwards it restarts unity 🤣
a look at top appears to show that the cpu usage is high while memory usage seems to drop....weirdly enough
the high cpu usage seems to come from unity
during the connection both screens are black
right before unity restarts the connection is lost
attached a dmesg after the connection is lost
dmesg_aftermiracast.txt
the commands line looks like this (mac address screen commented out)

aethercastctl> connect screen
[CHG] Manager State changed: association
[CHG] Manager Scanning changed: false
[CHG] Manager State changed: configuration
[CHG] Manager State changed: connected
[CHG] Manager Enabled changed: true
[CHG] Manager Capabilities changed: 

hmm now i check my simulated sink with 'info' and it doesn't list 'sink' as one of the capabilities

@Fuseteam
Copy link
Author

Fuseteam commented May 15, 2019

the unity8.log after aethercast connect and before unity crash

[2019-05-15:12:25:58.257] qtmir.sensor: Screen::toggleSensors - enable= true
[2019-05-15 12:26:03.928184] mirserver: New display configuration:
[2019-05-15 12:26:03.954582] mirserver:   0.1: LVDS 4.6" 57x101mm
[2019-05-15 12:26:03.954840] mirserver:        Current mode 720x1280 56.25Hz
[2019-05-15 12:26:03.954960] mirserver:        Preferred mode 720x1280 56.25Hz
[2019-05-15 12:26:03.955063] mirserver:        Logical position +0+0
[2019-05-15 12:26:03.955191] mirserver:   0.2: unused DisplayPort
[2019-05-15 12:26:03.974744] mirserver:   0.3: Virtual 29.8" 660x370mm
[2019-05-15 12:26:03.974968] mirserver:        Current mode 1280x720 60.00Hz
[2019-05-15 12:26:03.975092] mirserver:        Preferred mode 1280x720 60.00Hz
[2019-05-15 12:26:03.975208] mirserver:        Logical position +720+0
[2019-05-15:12:26:03.977] qtmir.screens: QtCompositor::stop
[2019-05-15:12:26:03.978] qtmir.screens: ScreensModel::onCompositorStopping
[2019-05-15:12:26:03.979] qtmir.screens: ScreenWindow::setExposed 0x1a482a0 false 0x16a7ea8
[2019-05-15:12:26:04.036] qtmir.screens: ScreensModel::update
[2019-05-15:12:26:04.667] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.669] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.680] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.681] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.693] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.693] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.701] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.702] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.710] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.710] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.716] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.717] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.723] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.723] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.730] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.730] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.737] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.738] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.745] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.746] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.753] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.753] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.761] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:04.762] file:///usr/share/unity8//Panel/IndicatorItem.qml:107:21: QML Icon: Binding loop detected for property "width"
[2019-05-15:12:26:05.364] qtmir.sensor: Screen - identifier is: ""
[2019-05-15:12:26:05.364] qtmir.sensor: Screen - nativeOrientation is: Qt::ScreenOrientation(LandscapeOrientation)
[2019-05-15:12:26:05.365] qtmir.sensor: Screen - initial currentOrientation is: Qt::ScreenOrientation(LandscapeOrientation)
[2019-05-15:12:26:05.367] qtmir.screens: Added Screen with id 3 and geometry QRect(720,0 1280x720)
[2019-05-15:12:26:05.369] qtmir.screens: Destroying ScreenWindow 0x1a482a0
[2019-05-15:12:26:05.369] qtmir.screens: Screen::setWindow - new geometry for shell surface ShellView(0x16f9bb8) QRect(720,0 1280x720)
[2019-05-15:12:26:05.369] qtmir.screens: ScreenWindow 0x1a482a0 with window ID 2 backed by Screen(0x25c8a00) with ID 3
[2019-05-15:12:26:05.371] qml: Calculating new usage mode. Pointer devices: 0 current mode: Staged old device count 0 root width: 160 height: 160
[2019-05-15:12:26:05.408] qtmir.surfaces: MirSurface[0x2350e58,"unity8-dash"]::updateVisibility(true)
[2019-05-15:12:26:05.409] qtmir.surfaces: MirSurface[0x2930568,"com.ubuntu.terminal_terminal"]::updateVisibility(true)
[2019-05-15:12:26:05.538] qtmir.screens: QWindow ShellView(0x16f9bb8) with geom QRect(720,0 1280x720) is backed by a Screen(0x25c8a00) with geometry QRect(720,0 1280x720)
[2019-05-15:12:26:05.982] file:///usr/share/unity8//Components/WallpaperResolver.qml:41:19: QML QQuickImage: Cannot open: file:///usr/share/unity8/graphics/phone_background.jpg
[2019-05-15:12:26:07.189] This backend doesn't support multiple users
[2019-05-15:12:26:07.280] qml: EdgeBarrierSettings: min=12gu(96px), max=17gu(136px), sensitivity=0.35, threshold=15.25gu(122px)
[2019-05-15:12:26:07.431] qtmir.surfaces: MirSurface[0x2350e58,"unity8-dash"]::updateVisibility(false)
[2019-05-15:12:26:07.433] qtmir.surfaces: MirSurface[0x2930568,"com.ubuntu.terminal_terminal"]::updateVisibility(false)
[2019-05-15:12:26:07.434] This backend doesn't support multiple users
[2019-05-15:12:26:07.715] Using "/etc/ubuntu/devices.conf" as device configuration file
[2019-05-15:12:26:07.720] qtmir.surfaces: MirSurface[0x2007c30,"-"]::registerView(45480600) after=2
[2019-05-15:12:26:07.720] qtmir.surfaces: MirSurface[0x2007c30,"-"]::updateVisibility(true)
[2019-05-15:12:26:07.721] qtmir.surfaces: MirSurface[0x2007c30,"-"]::updateVisibility(false)
[2019-05-15:12:26:07.740] Virtual uinput mouse device created.
[2019-05-15:12:26:07.741] qtmir.screens: Screen::setWindow - new geometry for shell surface SecondaryWindow(0x270e368) QRect(0,0 720x1280)
[2019-05-15:12:26:07.743] qtmir.screens: ScreenWindow 0x299fb28 with window ID 3 backed by Screen(0x16a7ea0) with ID 1
[2019-05-15:12:26:07.743] qtmir.screens: QWindow SecondaryWindow(0x270e368) with geom QRect(0,0 720x1280) is backed by a Screen(0x16a7ea0) with geometry QRect(0,0 720x1280)
[2019-05-15:12:26:07.748] qtmir.screens: Screen::setMirDisplayBuffer Screen(0x16a7ea0) 0xb071af8c 0xb0748024
[2019-05-15:12:26:07.748] qtmir.screens: =======================================
[2019-05-15:12:26:07.748] qtmir.screens: Screen(0x16a7ea0) - id: 1 geometry: QRect(0,0 720x1280) window: 0x299fb28 type: "LVDS" scale: 1
[2019-05-15:12:26:07.750] qtmir.screens: Screen(0x25c8a00) - id: 3 geometry: QRect(720,0 1280x720) window: 0x1a482a0 type: "Unknown" scale: 1
[2019-05-15:12:26:07.750] qtmir.screens: =======================================
[2019-05-15:12:26:07.777] qtmir.screens: QtCompositor::start
[2019-05-15 12:26:07.779459] mirserver: New display configuration:
[2019-05-15 12:26:07.801068] mirserver:   0.1: LVDS 4.6" 57x101mm
[2019-05-15 12:26:07.801302] mirserver:        Current mode 720x1280 56.25Hz
[2019-05-15 12:26:07.801421] mirserver:        Preferred mode 720x1280 56.25Hz
[2019-05-15 12:26:07.801559] mirserver:        Logical position +0+0
[2019-05-15 12:26:07.801672] mirserver:   0.2: unused DisplayPort
[2019-05-15 12:26:07.801775] mirserver:   0.3: unused Virtual
[2019-05-15:12:26:07.801] qtmir.screens: QtCompositor::stop
[2019-05-15:12:26:07.930] qtmir.screens: ScreensModel::onCompositorStarting
[2019-05-15:12:26:07.931] qtmir.screens: ScreensModel::update
[2019-05-15:12:26:07.931] qtmir.screens: Screen::setMirDisplayBuffer Screen(0x25c8a00) 0xb075918c 0xb076abb4
[2019-05-15:12:26:07.932] qtmir.screens: Screen::setMirDisplayBuffer Screen(0x16a7ea0) 0xb071af8c 0xb0748024
[2019-05-15:12:26:07.932] qtmir.screens: =======================================
[2019-05-15:12:26:07.932] qtmir.screens: Screen(0x16a7ea0) - id: 1 geometry: QRect(0,0 720x1280) window: 0x299fb28 type: "LVDS" scale: 1.875
[2019-05-15:12:26:07.936] qtmir.screens: Screen(0x25c8a00) - id: 3 geometry: QRect(720,0 1280x720) window: 0x1a482a0 type: "Unknown" scale: 1
[2019-05-15:12:26:07.937] qtmir.screens: =======================================
[2019-05-15:12:26:07.937] qtmir.screens: ScreenWindow::setExposed 0x299fb28 true 0x16a7ea8
[2019-05-15:12:26:07.937] qtmir.screens: ScreenWindow::setExposed 0x1a482a0 true 0x25c8a08
[2019-05-15:12:26:07.938] qtmir.screens: ScreensModel::onCompositorStopping
[2019-05-15:12:26:07.938] qtmir.screens: ScreenWindow::setExposed 0x299fb28 false 0x16a7ea8
[2019-05-15:12:26:07.939] qtmir.screens: ScreenWindow::setExposed 0x1a482a0 false 0x25c8a08
[2019-05-15:12:26:07.939] qtmir.screens: ScreensModel::update
[2019-05-15:12:26:07.940] qtmir.screens: Screen::setMirDisplayBuffer Screen(0x25c8a00) 0xb075918c 0xb076abb4
[2019-05-15:12:26:07.940] qtmir.screens: Screen::setMirDisplayBuffer Screen(0x16a7ea0) 0xb071af8c 0xb0748024
[2019-05-15:12:26:07.940] qtmir.screens: =======================================
[2019-05-15:12:26:07.941] qtmir.screens: Screen(0x16a7ea0) - id: 1 geometry: QRect(0,0 720x1280) window: 0x299fb28 type: "LVDS" scale: 1.875
[2019-05-15:12:26:07.942] qtmir.screens: Screen(0x25c8a00) - id: 3 geometry: QRect(720,0 1280x720) window: 0x1a482a0 type: "Unknown" scale: 1
[2019-05-15:12:26:07.942] qtmir.screens: =======================================
[2019-05-15:12:26:07.945] qtmir.screens: QtCompositor::start
[2019-05-15:12:26:07.980] Input device added: "unity8-simulated-mouse" "/dev/input/event5" QFlags(0x2)
[2019-05-15:12:26:08.034] qml: Calculating new usage mode. Pointer devices: 1 current mode: Staged old device count 0 root width: 160 height: 90
[2019-05-15:12:26:08.128] qtmir.surfaces: MirSurface[0x27d3cc8,"logviewer.neothethird_logviewer"]::updateVisibility(false)
[2019-05-15:12:26:08.131] qtmir.applications: Application["unity8-dash"]::setRequestedState(requestedState=running)
[2019-05-15:12:26:08.134] qtmir.applications: Application["com.ubuntu.terminal_terminal"]::setRequestedState(requestedState=running)
[2019-05-15:12:26:08.136] qtmir.applications: Application["com.ubuntu.terminal_terminal"]::resume()
[2019-05-15:12:26:08.136] qtmir.applications: Application["com.ubuntu.terminal_terminal"]::setInternalState(state=Running)
[2019-05-15:12:26:08.154] qtmir.applications: Application["logviewer.neothethird_logviewer"]::setRequestedState(requestedState=running)
[2019-05-15:12:26:08.155] qtmir.applications: Application["logviewer.neothethird_logviewer"]::resume()

** (process:2663): WARNING **: Unable to get instances of job 'application-click': The connection is closed
[2019-05-15:12:26:08.543] qtmir.applications: Application["logviewer.neothethird_logviewer"]::setInternalState(state=Running)
[2019-05-15:12:26:08.550] qtmir.mir: SessionListener::destroying_surface - this= SessionListener(0xb0756a2c) session= 0xa658150c surface= 0xa65c1b28
[2019-05-15:12:26:08.550] qtmir.mir: SessionListener::stopping - this= SessionListener(0xb0756a2c) session= 0xa658150c
[2019-05-15:12:26:08.633] qtmir.mir: SessionListener::stopping - this= SessionListener(0xb0756a2c) session= 0xaac00f24
[2019-05-15:12:26:08.638] qtmir.mir: SessionListener::stopping - this= SessionListener(0xb0756a2c) session= 0xaac4dbfc
[2019-05-15:12:26:08.647] qtmir.mir: SessionListener::stopping - this= SessionListener(0xb0756a2c) session= 0xa68c302c
[2019-05-15:12:26:09.302] qtmir.mir: SessionListener::destroying_surface - this= SessionListener(0xb0756a2c) session= 0xa65afafc surface= 0xa65afe18
[2019-05-15:12:26:09.387] qtmir.screens: ScreensModel::onCompositorStarting
[2019-05-15:12:26:09.387] qtmir.screens: ScreensModel::update
[2019-05-15:12:26:09.388] qtmir.screens: Removed Screen with id 3 and geometry QRect(720,0 1280x720)
[2019-05-15:12:26:09.531] Virtual uinput mouse device removed.
[2019-05-15:12:26:09.533] qtmir.surfaces: MirSurface[0x2007c30,"-"]::updateVisibility(true)
[2019-05-15:12:26:09.535] qtmir.surfaces: MirSurface[0x2007c30,"-"]::unregisterView(45480600) after=1 live=true
[2019-05-15:12:26:09.535] qtmir.surfaces: MirSurface[0x2007c30,"-"]::updateVisibility(false)
terminate called after throwing an instance of 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<std::system_error> >'
  what():  Nested Mir Display Error: Failed to update EGL surface: EGL_BAD_CONTEXT (0x3006)
()

@Fuseteam
Copy link
Author

Fuseteam commented May 28, 2019

i'll extract lines that look like errors here

[2019-05-15:12:26:05.982] file:///usr/share/unity8//Components/WallpaperResolver.qml:41:19: QML QQuickImage: Cannot open: file:///usr/share/unity8/graphics/phone_background.jpg
[2019-05-15:12:26:07.189] This backend doesn't support multiple users

the guessing the one from 15:12:26:05.982 is de reason the screen is black :P
interesting enough after the following line it seems to be stopping the sessionlistener(?) and destroying the a surface(?) or otherwise undoing whatever "preparations" it did to cast.....

** (process:2663): WARNING **: Unable to get instances of job 'application-click': The connection is closed

after this line unity8 crashed and the connection is lost

terminate called after throwing an instance of 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<std::system_error> >'
  what():  Nested Mir Display Error: Failed to update EGL surface: EGL_BAD_CONTEXT (0x3006)
()

@Fuseteam
Copy link
Author

Fuseteam commented Dec 15, 2019

I have now retried it on the latest devel
it connected and unity didn't crash
i also did not get anything on the screen 🤣
maybe its time for me to test on one of those fancy ms display adapters xD

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants