Read current core name from HPS side?

Kernel, Main, Utilities & Applications, Miscellaneous Devices.
eflanery
Posts: 4
Joined: Mon Aug 17, 2020 7:56 pm
Been thanked: 1 time

Read current core name from HPS side?

Unread post by eflanery »

Is it possible to somehow get the name of the running core via Linux on the HPS side?

I'm contemplating an arcade cabinet with button illumination and marquee artwork controlled by an additional device some kind (Pi-whatever probably), but it would need something to key off of.

It appears possible to externally cause a core to load via /dev/MiSTer_cmd, but I'd rather stick to the menu system for user interaction; and keep the cabinet management system non-interactive.
eflanery
Posts: 4
Joined: Mon Aug 17, 2020 7:56 pm
Been thanked: 1 time

Re: Read current core name from HPS side?

Unread post by eflanery »

FWIW, I found a way:

enable "bootcore=lastcore" in MiSTer.ini, so that the core name shows up in /media/fat/config/lastcore.dat, and periodically check that file.

Then, to work around the actual bootcore=lastcore functionality, on startup execute: "echo load_core /media/fat/menu.rbf > /dev/MiSTer_cmd"
bbond007
Top Contributor
Posts: 531
Joined: Tue May 26, 2020 5:06 am
Has thanked: 87 times
Been thanked: 211 times

Re: Read current core name from HPS side?

Unread post by bbond007 »

eflanery wrote: Wed Sep 09, 2020 8:32 pm Is it possible to somehow get the name of the running core via Linux on the HPS side?
eflanery wrote: Thu Sep 10, 2020 6:20 pm FWIW, I found a way:

enable "bootcore=lastcore" in MiSTer.ini, so that the core name shows up in /media/fat/config/lastcore.dat, and periodically check that file.

Then, to work around the actual bootcore=lastcore functionality, on startup execute: "echo load_core /media/fat/menu.rbf > /dev/MiSTer_cmd"
check file "/tmp/CORENAME" is simpler and less writes to the the SD card for a feature you are disabling....
eflanery
Posts: 4
Joined: Mon Aug 17, 2020 7:56 pm
Been thanked: 1 time

Re: Read current core name from HPS side?

Unread post by eflanery »

Perfect, that's even better.

I didn't even think to look in arguably the most obvious place. :-/

Thank you. :-)
Post Reply