Author
Topic: MAME Plugin Progress Thread (Read 35949 times)

I am starting this thread to detail my progress with the MAME Plugin/Player pair that I am coding for LinuxMCE (and perhaps PlutoHome too).

I have made the first bits of necessary database changes in order to make the File list and UpdateMedia daemon start to index and list the files inside the games/ directory in the LinuxMCE structure.

I currently have to manually set attributes for now, but it does index the filename as title currently, and I am able to add pictures, and it does display on a file list on all of my orbiters.

I have assigned a MediaType of 8 (because it was available...) I hope I haven't trampled on anyone's toes for this. I will need to figure out how to use sql2cpp effectively to get the proper media ID (because I know under sqlcvs the PK_ fields will most likely change, I can't assume that they will be constant!).

There is no plugin/player combination yet, so while the new games scenario, file list, and single file/attribute views work properly, it doesn't do anything after that except say, "I have no devices in this entertainment area capable of playing this file!", and the DCERouter file currently gives the message:

I need to finish putting together a stable dev environment now, so I can work on the plugin/player pairs.

I do figure out from the DCERouter logs, that I will need the Plugin AND the Player... the DCE router sends messages to the Plugin first, to determine how to route things... I suspected this, but I would like more information as to why it is separated in this manner...the source code is a little bit foggy in this area, and I am using Xine_Player/Plugin as a reference.... Does anyone know what is going on?

Very exciting. Not just for MAME players, but as an example of an entire architectural expansion. Personally, the only games I'm interested in are the ones that run under the atari800 emulator (I was an Atari geek in the early 1980s). Do you think you could explain how to add a different emulator, for others to follow your lead?

In fact, it would be very useful for developers to see just how you got to the point where you are now. Like setting up a dev env, tools/techniques for finding where the target code resides before you start editing it, tools/techniques for (eg.) finding an unused media type, etc. Maybe you could add a section->page to the Developers Guide wiki entry? That would help me (or someone else) add atari800, and then the next media type, like maybe documents or just arbitrary applications.

Very exciting. Not just for MAME players, but as an example of an entire architectural expansion. Personally, the only games I'm interested in are the ones that run under the atari800 emulator (I was an Atari geek in the early 1980s). Do you think you could explain how to add a different emulator, for others to follow your lead?

In fact, it would be very useful for developers to see just how you got to the point where you are now. Like setting up a dev env, tools/techniques for finding where the target code resides before you start editing it, tools/techniques for (eg.) finding an unused media type, etc. Maybe you could add a section->page to the Developers Guide wiki entry? That would help me (or someone else) add atari800, and then the next media type, like maybe documents or just arbitrary applications.

I am an old Atari800 hacker from the 1980s, myself.. still am (looking at my Ben Heckendorn Atari 800 Laptop).

As for doing a generalised emulation framework.... I can't say at this point how possible that will be.

Ideally I want to use a Game Plugin, which forwards messages to individual Game Players, keying off file extensions to do so. This however, may not be possible without looking very awkward for one reason, the parts of the code that determine menu items for a given player are defined IN the Plugin, not the Player (because the Plugin is part of the DCE router's address space), this is a limitation of C++, and would require some sort of IDL type system if we needed to do dynamic introspection of the emulator capabilities.

As it is right now, I am building for ONE emulator type per plugin pair, currently this is MAME, so that I can see where the issues are. It is important that this not be a half-baked integration project, so it's not as simple as just hanging an emulator executable off the system somewhere. I intend to implement ALL of the media plugin features, (follow me, state saving for moving an instance to another MD, etc.).

I will know more once I get my dev environment stabilized. But it is very early in the project.

There are also other scalability issues that this media type will inevitably expose, on a potential system, there will be tens of thousands of ROMs in the file list, before you start applying filters! This will undoubtedly stress test the whole system to find bottlenecks. I've already found some obnoxious ones in the media sync portion of the Web Admin site as a result! (and I've only added my MAME roms!)

Status update: still trying to get a stable development environment working on my VM. Will let you guys know how things get on. I'm trying to build using the current SVN sources in anticipation for the 0710 release.

Status update: still trying to get a stable development environment working on my VM. Will let you guys know how things get on. I'm trying to build using the current SVN sources in anticipation for the 0710 release.

Is the current version of 0710 that developers are working on the one that's in SVN? I'd love to see a HowTo for building it locally and trying to run it (as well as debugging a few issues that Mantis says haven't been touched in a while).

Status update: still trying to get a stable development environment working on my VM. Will let you guys know how things get on. I'm trying to build using the current SVN sources in anticipation for the 0710 release.

Is the current version of 0710 that developers are working on the one that's in SVN? I'd love to see a HowTo for building it locally and trying to run it (as well as debugging a few issues that Mantis says haven't been touched in a while).

Well it looks to me that the latest checkins at http://svn.charonmedia.org/ are from 2-3 days ago. Some of our work on vdr seems to be there (some have not been committed yet as we are working through some issues related to Myth & vdr coexisting happily without Myth breaking). So overall things are pretty much up to date - i think. But I can't be sure how complete the current version is or what happens to revisions made in the public SVN when the same files are next synced from the non-public SVN and have in intervening time been updated there too.

Okay, I've got a stable dev environment working now, and was able to build and launch both a plugin and player combination into my dev vm

I've also done much of the necessary database work to implement the file list, updatemedia etc work....

and I understand how the plugin and player pairs interact.....

but i seem to be missing one link, how does the system know to talk with the DCE router plugin? right now it says "I can't play this media type for this entertainment area" and the DCErouter log confirms this

however, I _know_ there is a database table I'm missing, probably in pluto_main, which maps what media types go to which entertainment areas etc... totallymaxed: what am I missing?

Okay, I've got a stable dev environment working now, and was able to build and launch both a plugin and player combination into my dev vm

I've also done much of the necessary database work to implement the file list, updatemedia etc work....

and I understand how the plugin and player pairs interact.....

but i seem to be missing one link, how does the system know to talk with the DCE router plugin? right now it says "I can't play this media type for this entertainment area" and the DCErouter log confirms this

however, I _know_ there is a database table I'm missing, probably in pluto_main, which maps what media types go to which entertainment areas etc... totallymaxed: what am I missing?

Can you grep the sources for the "I can't play this media type for this entertainment area" string, post the file in which it's defined, and I'll try to figure out in the source where is the "missing link" and how to fix it.

but i seem to be missing one link, how does the system know to talk with the DCE router plugin? right now it says "I can't play this media type for this entertainment area" and the DCErouter log confirms this

however, I _know_ there is a database table I'm missing, probably in pluto_main, which maps what media types go to which entertainment areas etc... totallymaxed: what am I missing?

Thom,

There is a routine somewhere called getDeviceForEntertainmentArea or something like that. I remember looking at it, at one stage and it might take a bit of tracing but it should lead you to the tables. If you havn't found anything and I get a chance tonight I will have a bit of a browse and see if I can help (that will be at least 12 hours from this post though)