Posts for Alyosha


Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
I'll be using this opening post to keep track of current progress on console verifications and other testing. Currently testing: - HDMA edge cases in single speed mode _____________________________________ Dev Build: https://ci.appveyor.com/project/zeromus/bizhawk-udexo/build/artifacts Repo for input timestamp files: https://github.com/alyosha-tas/GBI_timestamps Dump script for 2.6.1 and older: http://tasvideos.org/userfiles/info/68761073876269603 Dump script for 2.6.2 and up: http://tasvideos.org/userfiles/info/71650785644185599 NOTE: use the setting 'TotalExecutedCycles Return Value' in GB->Settings in BizHawk and set it to GBI for double speed mode games _____________________________________ Several games use uninitialized RAM in a way that causes desyncs on real hardware, below is a list of some examples I found: Race Days (Select Dirty Racing) : This game checks a memory address to see if a block needs to be initialized. It does this many times in different locations. The same movie will desync in different ways each playthrough on console. Ex:
02EB:  EA 24 C2  LD   (#C224h),A         A:00 F:90 B:A8 C:FC D:02 E:00 H:A0 L:00 SP:DFFA Cy:61216123 LY:128 ZnhCie
Super R.C. Pro Am : This game checks 4 locations in memory before initializing them, these could be related to linking but I'm not really sure. There seems to be a high probability of these cases passing on a real console in my testing:
FFCD > 0x02 (FFCD unwritten)

FFCC != 0xDE (checks 3 times, FFCC unwritten)

FFCC != 0xDE (checks 3 times, FFCC unwritten)

FFC9 != FFC8 (FFC9 unwritten, FFC8 written 1)
Pokemon Crystal: When loading up the credits sequence it checks player state in the wrong bank, this doesn't seem to have any real impact, but would possibly cause a desync if you wanted to continue a movie past the credits:
4384:  FA 5D D9  LD   A,(#D95Dh)         A:00 F:80 B:C2 C:91 D:0A E:00 H:C2 L:91 SP:C0B9 Cy:323183331 LY:149 ZnhciE
4387:  FE 01     CP   #01h               A:00 F:80 B:C2 C:91 D:0A E:00 H:C2 L:91 SP:C0B9 Cy:323183347 LY:149 ZnhciE
Daiku no Gen-san - Ghost Building Company (Japan): uses uninitialized RAM at the start of level 2, this causes a desync towards the end of the level. It looks like all it does is use these values for starting xscroll possibly for the clouds. Battletoads: Reads from HRAM at the start of level one to set some values in WRAM. Doesn't effect the TAS but might effect casual play, not sure
09F9:  F0 C2     LDH  A,(#FFC2h)         A:24 F:00 B:00 C:20 D:C9 E:18 H:9A L:C3 SP:CAFC Cy:105661311 LY:0 znhcie
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
NOTE: probably this is only relevent for MESHUGGAH but I felt I should mention it anyway. Adelikat managed to make the 'platform' A78 again instead of 'A7800.' So this is now consistent betweeen cores. (I tried and failed to do this previously.) This is now present in the official release, so anything made using the dev build should have it's platform made to be A78 again. Other then that movies should work as normal.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
Really well done TAS, I like the pikachi platform part especially. Yes vote!
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
The encode itself was quite boring, but your short story to go along with it made it feel interesting and was a nice touch, that's good enough for a yes vote for me!
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
Woah improved Castlevania, that's surprising, great work Challenger!
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
http://tasvideos.org/userfiles/info/40758803637547300 - galaga http://tasvideos.org/userfiles/info/40758797349008389 - water ski Things to watch out for: In the header section, platform should be A7800 not A78 (which is assigned to EMU7800 and cant be used since it breaks the controllers.) The sync setting.json file should look like this:
{"o":{"$type":"BizHawk.Emulation.Cores.Atari.A7800Hawk.A7800Hawk+A7800SyncSettings, BizHawk.Emulation.Cores","_port1":"ProLine Controller","_port2":"ProLine Controller","_Filter":"None"}}
replace the 'Proline' with 'Joystick' as appropriate. In the input log, the first console section has 7 columns, i.e. |.......| Lightgun conversion wont work since EMU7800 has x and y swapped, so I never changed the mnemonics, sorry I wasn't clear about that. Hope this helps. Also it looks like you need to add 1 frame at the beginning of the bk2's for them to sync, but otherwise both galaga and water ski worked just fine. I've kind of run out of interest in this core, so except for bug fixes I'll probably be stopping development at this point. So, pokey chip, A2600 mode and filters for Tower Toppler will be left to future work.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
Cool! Seems like a good start to me so far, nice work!
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
If you post your movie and provide a link I should be able to get it working and figure out what went wrong. I imagine it's something fixable since things seem to be working on my end.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
0.1703 should contain everything light gun related, all the mnemonics, and the addition of a filter selection option in the A7800Hawk menu. The filter doesn't do anything yet, it's just a stub for now, but I needed to do a bit of reorganizing to the core so I decided to have a place holder for it. Should probably be done this week though.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
That's strange, I am getting identical LogKeys (both match the top one), not sure what to make of that. I don't see anything else to change and it works on my end.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
Another milestone is finally reached wiith Scrapyard Dog's sewer level finally being correctly emulated. This level was another main driver for me to create this emulator after seeing Mothrayas' TAS of this game contain a pretty bad graphical glitch in this level. What this glitch comes down to is DMA timing around what is called 'holey DMA.' Basically DMA can be told to ignore certain address blocks, and when it does so there is no DMA read penalty for addresses in that block. Except, there is a penalty for the first read in order to identify that block in the first place. Getting this (and pretty much everything else DMA related) right is what fixes scrapyard dog. EDIT: @MESHUGGAH: I unified the controller definitions between EMU7800 and A7800Hawk (at least for 2 button and joystick controllers) so you should be able to compare movies now I think.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
I still can't repro this, does it still happen in master? I rewrote the lgiht gun algorithm to match what Barnyard Blaster expects. That game goes through a two step process of first detecting light to a resolution of about 20 pixels, then going through a second loop that improves the resolution to about 4 pixels. This should clear up the issues experienced in shooting cans in Barnyard Blaster. I also imrpoved vertical accuracy a bit, but if I go up too much then Sentinel is aiming too high, so I chose a middle ground. This is probably as good as lightgun is going to get, as I don't think I'll put a lot more effort into it.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
Thanks to The8bitbeast we are down to 12 runs now! I plan to get back to this after A7800 is sorted out.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
MESHUGGAH wrote:
- I can't test it with controller (with cursor). Controllers joystick: can't shoot. I also had a random glitch from changing light gun to joystick, reset core, start game, white screen every 3rd-4th frame (like an autofire) without any input pressed/shown in display
I am unable to reproduce this, seems really strange though. Also the game only works with the 2 button controller. I am looking into the other lightgun issues now, I have a good idea what is going on, just need to find the best solution.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
Pretty cool. I can't recall ever seeing MUGG's submission before, and I've personally never even thought about playing SMB on PAL, so seeing that it's faster is quite a surprise, voting yes!
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
BizHawk and FCEUX set the RNG on different frames because FCEUX (erroneously) delays PPU startup by an extra frame. This at least is well understood. NESHawk or Mesen are you're only chances at matching console for behaviour this precise, trying to use FCEUX would be wasting your time. Otherwise yes, this RNG is very sensitive to initial condiitions of the NES. Aside from CPU/PPU alignment, there is also VBlank flag which is a variable. Aside from that, I strongly suspect that there are other variations in power up state as well. Your initial assessment that NES emulation may not be at a state where this can be easily duplicated may be correct. If Mesen doesn't give you the desired result, it is very unlikely that this can be reproduced at this time. It would be pretty easy to create a LUA script that will just randomly press buttons until you get the desired state you want (assuming it is possible) but the resulting input would obviously be useless for real time purposes.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
CLChambers00 wrote:
Does Mesen have a TAS Editor and a way to watch Ram Addresses? I will write up what I am looking for later on and we can go from there. Thanks!
It doesn't have a TAS Editor, but it does have savestates and an excellent debugger and memory viewer to keep track of RAM. I recommend giving it a try, it give you what you want right out of the box.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
phoenix1291 wrote:
Just a little question, because I never test it, but in cores that support light gun or equivalent in BizHawk, is it possible to use the mouse for it?
Yes, it works with mouse.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
It will be basically hopeless to try to match console with FCEUX or QuickNES. NESHawk I can work with, but I would need to know what state you are trying to achieve (i.e. what does it look like on hardware that is wrong in NESHawk.) Also, have you tried Mesen? It is another very accurate emulator that behaves very slightly differently from NESHawk, maybe it will give you what you want.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
@MESHUGGAH: I'll look at the nemonics next to see what went wrong, hopefully I should be able to get it to match up. In the mean time, I added light gun support. It still needs testing but I believe it is working correctly. I tested on Sentinel and Crossbow. The detection is not very good in general, so it's a bit hard to spot actual errors, so let me know if anything looks wrong.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
The CPU reads the ROM according to the memory mapping of the cart. Here is a list of most mappers and there logic: http://blog.kevtris.org/blogfiles/Atari%202600%20Mappers.txt The simplest ones just read the ROM directly, you just need to locate it correctly in the CPU address space. If you are trying to do the A2600, one of the most important documents you will need is this one: http://www.atarihq.com/danb/files/TIA_HW_Notes.txt If you are just getting started in emulation, A2600 is actually pretty complicated. You need to get every low level hardware timing pretty much perfect for it to look right. If you are open to suggestions, I might recommend doing A7800 instead as a first project. It uses the same 6502 CPU, but in my opinion is much simpler to get working (A7800 DMA is much easier then A2600 HMove.)
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
http://tasvideos.org/userfiles/info/40608078650579692 Here is a converson from Mupen to BizHawk for this run. I didn't see that exact plug in settings to convert with so I just used the defaults. (I'll even submit it if you want, since it's been like a week already might as well wrap this up)
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
@MESHUGGAH: sorry about the nemonics, I don't recommend trying to do any serious TAS stuff until the core is released, as other thing could still change. Also thank you for the continued testing. I'm making progress on finalizing some of the DMA timing stuff, and have fixed numerous small bugs in emulation. Now the bottom line in Xenophobe is fixed. There are only 3 graphical issues I am currently aware of. Sewer level in Scrapyard Dog: honestly, I'm not sure how to fix this one, The NMI is happening too early, but at the correct scanline according to the Maria DMA's, so I can't really change anything to change the behaviour. Tow Line in Water Ski: On one frame the tow line appears in the wrong spot, not sure what is causing it. Tower Toppler: Intentionally uses color artifacting, not yet implemented I'm also working on some of the more obscure ROMs out there. Here is Rescue on Fractalus, a pretty cool prototype. I'm always impressed by the clever things people are able to come up with to make good use of limited resources.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
I rewrote the Maria renderer in A7800Hawk to make it pixel accurate. Now the one stray line in Kung Fu Master is fixed. This also brought with it a dramatic simplification of the code, which makes it much more managable. As accuracy picks up the core is starting to slow down a bit though. I used to be stable 240 FPS at 4x speed, but now I'm maxed out at 200 or so. I'll try to recover a bit of that slowdown once all the bugs are worked out.
Alyosha
He/Him
Editor, Experienced Forum User, Published Author, Expert player (3536)
Joined: 11/30/2014
Posts: 2733
Location: US
Water Ski: Works fine for me, needs 2 button controller plugged in . 7800 Birthday: Can you post the name of the ROM you are using? Xenophobe: DMA timing issue, this is a work in progress. (There are a couple such issues, the most serious one being Scrapyard Dog Sewer level.) Tower Toppler: I still need to emulate color artifacting to make it look right. I think one other game needs this too.