BBB Mouse not available for 1 minute.

13 views
Skip to first unread message

jwvande...@gmail.com

unread,
Jun 13, 2020, 8:13:29 PM6/13/20
to BeagleBoard
Hi All

This problem has been occupying me on or off for weeks.
What the object of the exercise is:
To start the BBB in console and use a .service file to start Xorg and my applications
without starting openbox or a Window Manager.

The environment:
Beaglebone Black Rev:c
Debian 9 Image 2018-10-07
Console only no gui.
Then installed Xorg ,openbox

Created a smartplug.service file in /lib/systemd/system
which contains the following.
-------------------------------
[Unit]
Description=Starts SmartPlug
After=getty@.service

[Service]
Type=simple
ExecStart=/usr/bin/xinit /home/debian/.xinitrc

[Install]
WantedBy=getty@.service
-------------------------------
Then edited the.xinitrc file in /home/debian
which contains the following.
-------------------------------
#!/bin/sh

sudo -u debian /usr/bin/xscreensaver &

sleep 60    #if any lower my app will fail (Allegro4)

sudo -u debian /home/debian/SmartPlug

sudo -u debian openbox-session
-------------------------------
When booting the xscreensaver splash screen shows up and stays active in the background.
In fact with 1 minute inactive time the screensaver already activates before the mouse can be used.
So, I sleep for 60 seconds.
The mouse cursor is inactive for at least 56 seconds, so if I run my application
before that time, it gets to some unknown point where it fails and exits.
I have tried to run the debugger to detect the point where it fails, BUT when the
debugger is on the screen, the mouse is not available yet and by the time it is, the problem is gone.

I have the same problem with Deb10 image, although the time to wait is less.
Have read many posts about "update the kernel" to solve slow boot, but I would assume
that the latest images have this kernel patch already included.

So although this installation will only boot up once and stay up for months, I would still like to solve this problem.
Have also tried to see the systemd-bootchart, but as it stops at about 20 seconds it does not show the culprit.

So, I am now officially out of my depth.

Would appreciate any suggestions towards solving this.
Regards

jwvande...@gmail.com

unread,
Jun 13, 2020, 8:53:04 PM6/13/20
to BeagleBoard
Hi All

In addition to my previous post.(Can't seem to edit my original post)

The onboard Flash disk has been erased and I am booting on a uSD.
Running systemd-analyze blame  shows these two very high numbers.
56.5 s generic-board-startup.service
54.3 s dev-mmcblk0p1.device

Using the board in the application with no cape's.

Regards
Reply all
Reply to author
Forward
0 new messages