You are not logged in.

Read the FAQ and Knowledge Base before posting.
We won't make a 3DS/2DS emulator.



#1 2010-01-09 21:04:21

zeromus
Radical Ninja
Registered: 2009-01-05
Posts: 6,169

Emulator communication protocol

I've been wanting to work on this for some time now, but it's never going to get done unless we get a thread started. So let's talk about it.

I would like to make an extensible emulator communication protocol, so that arbitrary messages can be sent to the emulator by game software. This may be similar to the no$gba or ideas protocols, or perhaps some folks feel that those are defective and something better is necessary.

Obviously one of the first messages would be a basic putstring.  But I've often thought it would also be helpful to have some high level filesystem messages (directory list, open/read/write/close etc.) which would enable more thorough and easy emulation of libfat in the emulator by permitting simple read/write access to a directory on the host filesystem, instead of relying on the emulator's DLDI implementation which is not as convenient.

I used to have some other ideas but I've forgotten them.

We need to discuss the mechanism for communicating to the emulator (come up with a bulletproof protocol which will not confuse the nds hardware) and make sure that the mechanism is truly extensible enough to be able to handle any kinds of messages.

For example, suppose a message is simply a u32 message ID and a u32 payload length, which constitute the header of a stream of bytes sent to some mysterious port. One message might be called QUERY_CAPABILITIES which should return a list of every message ID handled by the emulator; that way games could interrogate their execution environment and adapt to it. Another might be called PROFILE_FUNCTION_ENTER and PROFILE_FUNCTION_EXIT, which would permit an emulator to assist with profiling. The emulator might not support those messages, and so it would know how to skip the payload size until it was ready for a new message.

I would make it super easy to drop your own message handlers into the emulator. This would also make it super easy for us to integrate them if your messages were demanded by others.

There is no time frame for this project. Just thinking about it for now.

Offline

#2 2010-03-12 01:52:26

loki
Member
Registered: 2010-03-12
Posts: 1

Re: Emulator communication protocol

Hmm, i wouldn't want roms to have filesystem access.  That would invite viruses disguised as roms.

Offline

#3 2010-03-12 02:37:05

zeromus
Radical Ninja
Registered: 2009-01-05
Posts: 6,169

Re: Emulator communication protocol

It would only access paths under the directory you specify.

Offline

#4 2010-03-15 21:26:49

Luigi__
Member
From: Peach__'s castle
Registered: 2009-05-29
Posts: 18
Website

Re: Emulator communication protocol

That sounds quite interesting! I hope it can help me with wifi development.


Kuribo64 - If you're wondering where Mario__ is, he's currently saving Peach__ once again.

Offline

Board footer

Powered by FluxBB