Mega Everdrive USB programming
Moderator: BigEvilCorporation
Mega Everdrive USB programming
Does anyone have an example of writing to the usb port in assembly for the mega everdrive from the megadrive side?
I believe it has write protection of some sorts that has to be disabled before writing to the port but i have not really seen any example of anyone utilizing this just yet.
I believe it has write protection of some sorts that has to be disabled before writing to the port but i have not really seen any example of anyone utilizing this just yet.
-
- Very interested
- Posts: 745
- Joined: Sat Dec 15, 2007 7:49 am
- Location: Kazakhstan, Pavlodar
Re: Mega Everdrive USB programming
Why don't you ask a developer?
Re: Mega Everdrive USB programming
Ive done a server/client test sometime back. Although its hacky I can share some of the code if you wish. Server is written in C# and client in ASM. I used this to test streaming music files, but the connection is too slow or unreliable to work properly.
Re: Mega Everdrive USB programming
You mean this ?
http://krikzz.com/pub/support/mega-ever ... ssf-v2.txt
it seems you only have to write/read "register" 0xA130E2....for USB
sample available (genny and pc side) : http://krikzz.com/pub/support/mega-ever ... sample.zip
http://krikzz.com/pub/support/mega-ever ... ssf-v2.txt
it seems you only have to write/read "register" 0xA130E2....for USB
sample available (genny and pc side) : http://krikzz.com/pub/support/mega-ever ... sample.zip
Re: Mega Everdrive USB programming
Natsumi wrote:Ive done a server/client test sometime back. Although its hacky I can share some of the code if you wish. Server is written in C# and client in ASM. I used this to test streaming music files, but the connection is too slow or unreliable to work properly.
Yes this would be a tremendous help!
Please pm me if you are willing to share the code. I am able to send data via usb, but receiving is very intermittent.
Re: Mega Everdrive USB programming
Actually it should be fast enough for music streaming. Transfer speed around 1MB/s. You should use large enough blocks for transfer (1KB or more). But if your communication protocol every time send few bytes and waiting for response, then speed will be really slowNatsumi wrote:Ive done a server/client test sometime back. Although its hacky I can share some of the code if you wish. Server is written in C# and client in ASM. I used this to test streaming music files, but the connection is too slow or unreliable to work properly.
Re: Mega Everdrive USB programming
What I did was, I set the C# code to transfer the entire file at once. 68K side I just kept in a loop reading the data, but I could get it to never sync, and from what I remember it never was able to keep up with the Z80 playback. I also remember that I had issues actually being able to read enough data from the USB as well. It's been a long time since I did this however, there could be a glaring error somewhere which caused this issue, and the code surely could have been much better...