Adafruit Looper won't let me exit program - Rasp Pi 4

General project help for Adafruit customers

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
Galmo1
 
Posts: 5
Joined: Tue Nov 09, 2021 8:09 pm

Adafruit Looper won't let me exit program - Rasp Pi 4

Post by Galmo1 »

So I installed the Adafruit video looper on my Raspberry Pi 4 model B using these steps from a Youtube video: "Make a USB Video Looper with a Raspberry Pi 4 Model B - YouTube
Video Looper with Raspberry Pi 4 Model B - Tutorial Australia".

It worked great at first. Would plug in the USB, it played the videos, then when I wanted to exit the program I would hit ESC and get back to the main screen.

Now when I hit ESC, nothing happens. It remains on the black screen that says 'Hit ESC to exit'. The program still runs videos when I plug in the USB.

Luckily (I hope), the command screen still is accessible. I've tried a bunch of commands to kill the specific program but it still leaves me with the 'Hit ESC to exit' screen. If someone has any other options to try and help exit this program, please share! Thanks!

User avatar
mikeysklar
 
Posts: 13936
Joined: Mon Aug 01, 2016 8:10 pm

Re: Adafruit Looper won't let me exit program - Rasp Pi 4

Post by mikeysklar »

If you remotely login are you able to stop | start | restart the looper:

Code: Select all

sudo supervisorctl stop video_looper

Code: Select all

sudo supervisorctl start video_looper

Code: Select all

sudo supervisorctl restart video_looper

User avatar
Galmo1
 
Posts: 5
Joined: Tue Nov 09, 2021 8:09 pm

Re: Adafruit Looper won't let me exit program - Rasp Pi 4

Post by Galmo1 »

So it worked at first, but now I'm constantly stuck in the command prompt screen.

I tried $ sudo reboot, but it still starts up the video_looper program and will not let me ESC. Now somehow my videos don't even play. I see a cursor in the middle of the screen where I can type in the prompt. The program says it detects a video, but after the countdown ends it goes right to showing that cursor.

I typed in $ sudo exit, and that only brought me to a black screen where I can type anything, but no commands worked anymore. I was forced to then use CTRL+ALT+DEL to reboot.

Do you think this error can be from the coding in the video looper program?

User avatar
mikeysklar
 
Posts: 13936
Joined: Mon Aug 01, 2016 8:10 pm

Re: Adafruit Looper won't let me exit program - Rasp Pi 4

Post by mikeysklar »

If you can remotely login (via ssh) you can shutoff the program via command line.

Code: Select all

sudo supervisorctl stop video_looper
There are log files for what the looper is doing in /var/log/supervisor/*

There is another thread on video looper in our forums that sounds familiar to yours. The videos were sometimes being mounted from a different location. Instead of /media/pi instead of /mnt/usbdrive0. There user also created a script to enable / disable the looper.

viewtopic.php?f=8&t=138174&p=683592&hil ... tl#p683592

Code: Select all

#!/bin/sh

# Make sure script is run as root.
if [ "$(id -u)" != "0" ]; then
echo "Must be run as root with sudo! Try: sudo ./disable.sh"
exit 1
fi
# !!!Make sure that enable.sh has permission: sudo chmod +x enable.sh !!!!
# Enable supervisor process that start video looper.
rm /etc/supervisor/conf.d/video_looper.conf.disabled
cp /home/pi/pi_video_looper/video_looper.conf /etc/supervisor/conf.d/video_looper.conf
supervisorctl start video_looper

User avatar
Galmo1
 
Posts: 5
Joined: Tue Nov 09, 2021 8:09 pm

Re: Adafruit Looper won't let me exit program - Rasp Pi 4

Post by Galmo1 »

mikeysklar wrote:If you can remotely login (via ssh) you can shutoff the program via command line.

Code: Select all

sudo supervisorctl stop video_looper
I tried this, and it left me with a blank screen where I can only run commands.
mikeysklar wrote: There are log files for what the looper is doing in /var/log/supervisor/*

There is another thread on video looper in our forums that sounds familiar to yours. The videos were sometimes being mounted from a different location. Instead of /media/pi instead of /mnt/usbdrive0. There user also created a script to enable / disable the looper.

viewtopic.php?f=8&t=138174&p=683592&hil ... tl#p683592

Code: Select all

#!/bin/sh
[/quote]

Erik stated "The problem is while booting sometimes the usb-stick with videofiles was automounted on /media/pi/ so it was not mounted on /mnt/usbdrive0/.
So i [b]unchecked the first two lines in preferences[/b] regarding the automount possibility in Volume Management in the File Manager tree."

How do I uncheck those first two lines in preferences? I don't know how to even get to 'preferences'. 

Thanks for helping!

User avatar
mikeysklar
 
Posts: 13936
Joined: Mon Aug 01, 2016 8:10 pm

Re: Adafruit Looper won't let me exit program - Rasp Pi 4

Post by mikeysklar »

I think Erik's mention of disabling the first time lines in the Volume Management Tree is related to being in GUI mode (X-Windows) and running. You probably could enter this with the startx command.

Code: Select all

 Start file manager (pcmanfm) and go to Edit / Preferences / tab Volume Management and disable automount options..
Now I think the above is only relevant if you are running in GUI mode which I do not believe you are doing so this is turning into a tangent that is getting us off course.

I would focus on making sure your mounted filesystem is what you expect to see. When you running the follow command what is the output?

Code: Select all

df -H

Code: Select all

mount

User avatar
Galmo1
 
Posts: 5
Joined: Tue Nov 09, 2021 8:09 pm

Re: Adafruit Looper won't let me exit program - Rasp Pi 4

Post by Galmo1 »

Thank you for being patient with me! Lol

When I run "df -H" I got the following:

Filesystem Size Used Avail Use% Mounted on
/dev/root 32G 3.4G 27G 12% /
devtmpfs 1.9G 0 1.9G 0% /dev
tmpfs 2.1G 0 2.1G 0% /dev/shm
tmpfs 2.1G 9.0M 2.0G 1% /run
tmpfs 5.3M 4.1k 5.3M 1% /run/lock
tmpfs 2.1G 0 2.1G 0% /sys/fs/cgroup
/dev/mmcblk0p1 265M 50M 215M 19% /boot
tmpfs 402M 4.1k 402M 1% /run/user/1000

When I run "mount" I got a lot more info. I attached a photo.
Attachments
Mount
Mount
IMG-20211127-135903.jpg (702.43 KiB) Viewed 652 times

User avatar
mikeysklar
 
Posts: 13936
Joined: Mon Aug 01, 2016 8:10 pm

Re: Adafruit Looper won't let me exit program - Rasp Pi 4

Post by mikeysklar »

In your output from both the df and mount commands I cannot see your mounted filesystem for the video files you are playing. Are those files being stored on a USB drive? That drive should show up in the `df` output and the `mount` output. Your `mount` output is truncated due to the photo screenshot. If possible please paste in the full output from logging in remotely. You can run `mount | less` to get it to page one screen at a time and use space bar to continue.

User avatar
Galmo1
 
Posts: 5
Joined: Tue Nov 09, 2021 8:09 pm

Re: Adafruit Looper won't let me exit program - Rasp Pi 4

Post by Galmo1 »

Yes, the files are being stored on a USD drive. As soon as I plug in the USB, the video looper starts working and plays the videos.

Also... I found a command that seemed to help!

I simply typed in 'Startx' then hit Enter, and it seems to do a reboot to the main screen. Hopefully that's a safe way to do it?

User avatar
mikeysklar
 
Posts: 13936
Joined: Mon Aug 01, 2016 8:10 pm

Re: Adafruit Looper won't let me exit program - Rasp Pi 4

Post by mikeysklar »

Interesting that running X helps. In that case you can set your Pi to just boot into X-windows by using raspi-config.

Code: Select all

raspi-config
Boot Options --> Desktop / CLI --> Desktop Autologin

Locked
Please be positive and constructive with your questions and comments.

Return to “General Project help”