Page 1 of 1

Arcade Marquee Collaboration?

Posted: Wed Feb 10, 2021 2:56 am
by alinke
hey there, I'm the creator of a line of dynamic LED and LCD marquees that change to match the current game called Pixelcade, http://pixelcade.org. If there is any interest is doing an integration with MiSTer, do let me know and we can explore.

Thanks,

Al

Re: Arcade Marquee Collaboration?

Posted: Wed Feb 10, 2021 12:33 pm
by LamerDeluxe
I'd expect lots of people who have MiSTer powered arcade cabinets to be interested in this.

Re: Arcade Marquee Collaboration?

Posted: Wed Feb 10, 2021 2:04 pm
by redsteakraw
There may be some interest, you should talk to porkchop / mister addons, he has a storefront and will be selling JAMMA IO boards this would make a nice bundle. Is any of the controller software open source so it can be integrated into the project? https://twitter.com/MisterAddons

Re: Arcade Marquee Collaboration?

Posted: Thu Feb 11, 2021 7:44 am
by alinke
thanks much, I'll do that. Parts of Pixelcade are open source, yes. The easiest way to integrate though would be through the Pixelcade API http://pixelcade.org/api but this assumes MiSTer can make REST API calls. I am a newbie to MiSTer so not sure if that is a possibility or not. Anyhow, will look into further and thanks for the guidance.

Re: Arcade Marquee Collaboration?

Posted: Thu Feb 11, 2021 10:16 pm
by alanswx
alinke wrote: Thu Feb 11, 2021 7:44 am thanks much, I'll do that. Parts of Pixelcade are open source, yes. The easiest way to integrate though would be through the Pixelcade API http://pixelcade.org/api but this assumes MiSTer can make REST API calls. I am a newbie to MiSTer so not sure if that is a possibility or not. Anyhow, will look into further and thanks for the guidance.
When a new arcade game (or core starts) we need to hit the rest API with some kind of identifier to switch the marquee?

How do we know where the API lives? Or is it the java app running on MiSTer? I am not sure it would be a great idea to run the java app on a mister, we could try it though.

Re: Arcade Marquee Collaboration?

Posted: Fri Feb 12, 2021 5:18 am
by alinke
thanks for the reply. yes, that's correct, pass the rom name to Pixelcade's API and then it'll change. And you're correct, the API is part of the java console app that would run as a daemon on the MiSTer. It's a pretty low profile Java console app/ no GUI and have it running on pretty low powered hardware but I'm also not familiar with the MiSTer architecture. The .jar itself is around 20 MB, JRE is 100 MB or so, and then a matter of how much of the artwork to load. The artwork is 128x32 PNG file per game so doesn't take much space. And then the Pixelcade hardware itself would connect via USB and would need to be recognized by the OS as a virtual serial port device (ex. /dev/ttyACM0) for the LED version of Pixelcade or for the LCD version of Pixelcade, no USB is needed and instead it would just make a REST API call over WiFi to the LCD which has its own single board computer. Let me know what you think, thanks again.

Re: Arcade Marquee Collaboration?

Posted: Fri Feb 12, 2021 9:08 am
by zakk4223
Mister writes the current corename/setname to /tmp/CORENAME. You could probably just watch for changes in that file via the linux inotify API or use the command line /bin/inotifywait command to do it in a shell script. For arcade games that file will usually contain the rom name (assuming the MRA has the setname correctly set).

This should be doable with zero changes to Mister code

edit: NEOGEO is going to be a problem since it doesn't change the core name like arcade MRAs do

Re: Arcade Marquee Collaboration?

Posted: Sat Feb 13, 2021 9:22 am
by alinke
ah very nice , that may work, I will check that out, thanks for the direction

Re: Arcade Marquee Collaboration?

Posted: Sun Feb 14, 2021 9:41 am
by venice
zakk4223 wrote: Fri Feb 12, 2021 9:08 am edit: NEOGEO is going to be a problem since it doesn't change the core name like arcade MRAs do
I can't confim this as i found NEOGEO written in /tmp/CORENAME.
Or am I missing the point?

Re: Arcade Marquee Collaboration?

Posted: Sun Feb 14, 2021 5:35 pm
by zakk4223
venice wrote: Sun Feb 14, 2021 9:41 am
zakk4223 wrote: Fri Feb 12, 2021 9:08 am edit: NEOGEO is going to be a problem since it doesn't change the core name like arcade MRAs do
I can't confim this as i found NEOGEO written in /tmp/CORENAME.
Or am I missing the point?
You'll never get the actual game names in /tmp/CORENAME, is what I meant. So you can't determine if say, metal slug is being played, only that NEOGEO is the current core.

Re: Arcade Marquee Collaboration?

Posted: Mon Feb 15, 2021 9:18 pm
by NegentropicMan
I am currently trying to use inotifywait to see which rom is loaded by a core on the linux side. This is generally working fine, but shows a strange effect I described here: https://misterfpga.org/viewtopic.php?f=27&t=2058.

I have not looked at Pixelcade in deep yet, but I think one possible scenario avoiding running the Pixelcade application would be a shell script on the MiSTer side, reading core/rom information via /tmp/CORENAME and inotifywait and then acessing the pixelcade HTTP/REST API (via curl) running on a separete pi (zero, if cost is an issue) which in turn controls pixelcade. This would mean minor modifications on MiSTer side and very few additional computing overhead.

EDIT: added curl for the REST API call to clarify that I wanted to avoid running the pixelcade application

EDIT 2: Issue was solved, I can continue with my inotify experiments.

Re: Arcade Marquee Collaboration?

Posted: Mon Feb 15, 2021 9:46 pm
by zakk4223
One thing to be aware of: a lot of the rom packs people are using do not separate every rom into a single zip file. The roms are in one huge zip file. MiSTer is agnostic to how you package roms, so there are basically infinite possibilities and naming. Without actual changes to Main_Mister you're going to be blind to the actual name of games selected rom inside of zip files

Re: Arcade Marquee Collaboration?

Posted: Mon Feb 15, 2021 9:50 pm
by alanswx
you should be able to use the "setname" parameter inside the mra. This generally maps to the correct mame name.

Re: Arcade Marquee Collaboration?

Posted: Mon Feb 15, 2021 10:24 pm
by zakk4223
the setname gets written to /tmp/CORENAME for arcade games, so those are covered fairly easily. If they're trying to figure out which rom was loaded for consoles that's a huge mess of rom packaging on the internet...

Re: Arcade Marquee Collaboration?

Posted: Sat Feb 20, 2021 3:06 am
by alinke
NegentropicMan wrote: Mon Feb 15, 2021 9:18 pm I am currently trying to use inotifywait to see which rom is loaded by a core on the linux side. This is generally working fine, but shows a strange effect I described here: https://misterfpga.org/viewtopic.php?f=27&t=2058.

I have not looked at Pixelcade in deep yet, but I think one possible scenario avoiding running the Pixelcade application would be a shell script on the MiSTer side, reading core/rom information via /tmp/CORENAME and inotifywait and then acessing the pixelcade HTTP/REST API (via curl) running on a separete pi (zero, if cost is an issue) which in turn controls pixelcade. This would mean minor modifications on MiSTer side and very few additional computing overhead.

EDIT: added curl for the REST API call to clarify that I wanted to avoid running the pixelcade application

EDIT 2: Issue was solved, I can continue with my inotify experiments.
Pixelcade has two flavors, for the LED version, MiSTER would need to run the console java app locally. For the LCD version of Pixelcade, there is a separate Orange Pi that drives the LCD that accepts the REST API calls so on LCD, your suggestion would work as is. That said, the Java console app is pretty lightweight and should not cause a performance issue unless MiSTER is very sensitive there (I'm a MiSTER newbie so don't know the underlyings there). Thanks for the suggestions , this is all very helpful. I'll report back my findings after my board comes in.

Re: Arcade Marquee Collaboration?

Posted: Sat Feb 20, 2021 3:07 am
by alinke
zakk4223 wrote: Mon Feb 15, 2021 9:46 pm One thing to be aware of: a lot of the rom packs people are using do not separate every rom into a single zip file. The roms are in one huge zip file. MiSTer is agnostic to how you package roms, so there are basically infinite possibilities and naming. Without actual changes to Main_Mister you're going to be blind to the actual name of games selected rom inside of zip files
that's good to know and would be an issue as Pixelcade does need the ROM name of the current game in order to work. I'll play around with it and report back what I find as soon as my hardware comes in, thanks for the help!

Re: Arcade Marquee Collaboration?

Posted: Sat Feb 20, 2021 11:33 pm
by alinke
cool, thanks much for your help!

Re: Arcade Marquee Collaboration?

Posted: Sun Feb 21, 2021 5:48 pm
by venice
I have something similar running using zakk4223's "inotifywait" Idea in a script.
The display is just a bit smaller :D
https://misterfpga.org/viewtopic.php?f=9&t=1887

Re: Arcade Marquee Collaboration?

Posted: Mon Feb 22, 2021 9:13 am
by alinke
venice wrote: Sun Feb 21, 2021 5:48 pm I have something similar running using zakk4223's "inotifywait" Idea in a script.
The display is just a bit smaller :D
https://misterfpga.org/viewtopic.php?f=9&t=1887
small but might! very nice, looks like you've got the console marquee artwrok, were you able to get game names also?

Re: Arcade Marquee Collaboration?

Posted: Tue Feb 23, 2021 6:58 am
by venice
alinke wrote: Mon Feb 22, 2021 9:13 am .. were you able to get game names also?
...not really.
Most times you need to translate a bit the content of /temp/CORENAME (mooncrgx = Moon Cresta, tgfx16 = TurboGrafX16).
But as stated in some comments before Arcades are OK.
Games running on Computers or Consoles are actually not to identify, as I understand it.

Re: Arcade Marquee Collaboration?

Posted: Tue Mar 02, 2021 7:41 am
by alinke
gotcha, thanks, will do some experimentation here

Re: Arcade Marquee Collaboration?

Posted: Wed Jun 23, 2021 12:54 am
by alinke
Hey All, thanks for all the advice and guidance here. We ended up getting this working and have MiSTer support for both the Pixelcade LED and LCD line of marquees. Here's a video of it in action https://youtu.be/hhrPBrxSyRQ .

My partner who did the actual MiSTer integration also designed a pretty cool case for MiSTer which you'll see in that video too.

Welcome any feedback.

Re: Arcade Marquee Collaboration?

Posted: Wed Jun 23, 2021 6:09 am
by venice
alinke wrote: Wed Jun 23, 2021 12:54 am Hey All, thanks for all the advice and guidance here. We ended up getting this working and have MiSTer support for both the Pixelcade LED and LCD line of marquees. Here's a video of it in action https://youtu.be/hhrPBrxSyRQ .

My partner who did the actual MiSTer integration also designed a pretty cool case for MiSTer which you'll see in that video too.

Welcome any feedback.
Very very cool :D
How did you get the Core/Game information out of the MiSTer Menu?
PM me if you like.

Re: Arcade Marquee Collaboration?

Posted: Wed Jun 23, 2021 8:04 am
by alinke
thanks, it turned out to be a combination of a small MiSTer mod (will post a GitHub link to the change a bit later) and then monitoring these files. With those in hand, the mod then makes a call to the Pixelcade REST API http://pixelcade.org/api to update the marquee.

/root# more /tmp/FULLPATH
_Arcade/_Organized/_2 Core/_Capcom - Black Tiger
/root# more /tmp/CURRENTPATH
Black Tiger
/root# more /tmp/CORENAME
NEOGEO

Re: Arcade Marquee Collaboration?

Posted: Wed Jun 23, 2021 6:19 pm
by MrKai
...specifically, it is a small "5-liner" patch in menu.cpp that does this. The code is in my fork, here: https://github.com/kaicherry/Main_MiSTer

Hi :)

Re: Arcade Marquee Collaboration?

Posted: Wed Jun 23, 2021 8:06 pm
by MrKai
alinke wrote: Wed Jun 23, 2021 8:04 am ...then makes a call to the Pixelcade REST API http://pixelcade.org/api to update the marquee.
To be clear, that link is to the API docs. The software doesn't make outbound calls to the internet for any purpose :)

-K

Re: Arcade Marquee Collaboration?

Posted: Thu Jul 15, 2021 2:35 am
by alinke
looks like a recent release broke things here, really what needs to happen to keep the Pixelcade integration working with MiSTer is that this PR gets accepted https://github.com/MiSTer-devel/Main_MiSTer/pull/416 . The only thing this change does is add the select game to /tmp/FULLPATH which Pixelcade then picks up so we know what game marquee to display. If anyone has any influence over a developer who can accept this PR, that would be much appreciated. Thanks much

Re: Arcade Marquee Collaboration?

Posted: Sat Sep 11, 2021 10:44 pm
by alinke
Update, massive, big thanks to @sorgelig for making the code mod needed for Pixelcade marquees to work with MiSTer , now in the main code base https://pixelcade.org/mister/