mpf-mc to execute a system command upon receipt of an event

64 views
Skip to first unread message

Marc Rechté

unread,
Jul 26, 2025, 11:32:21 AMJul 26
to MPF Users
Hi. What would be the appropriate way to make mpf-mc execute a system command upon the receipt of an event sent from mpf ?

Alex L

unread,
Aug 7, 2025, 4:35:30 PMAug 7
to MPF Users
Does the MC have to be the command executor, or would shelling out from the mpf game engine work instead?

Marc Rechté

unread,
Aug 15, 2025, 12:37:42 PMAug 15
to MPF Users
It seems my answer did not reach the group.

I finally wrote a new config player (mc_system_player).

Would such player be useful to the community (hence integrated into mpf-mc) ?

Ben Tripoli

unread,
Aug 16, 2025, 12:00:57 AMAug 16
to MPF Users
Nice work! If I understand what you are doing is correct, then I would use it to shutdown linux with a button combo when in attract mode. Im currently having to shutdown linux with a button behind the coin door before switching off power.

Marc Rechté

unread,
Aug 20, 2025, 11:30:18 AMAug 20
to MPF Users
The work is not complete to be pushed upstream (need to be reviewed by expert and need tests), but it does the job. It's on my fork https://github.com/mrechte/mpf-mc
Reply all
Reply to author
Forward
0 new messages