Jump to content
IGNORED

Javatari Emulator is now Javatari.js! 100% HTML5/Javascript


Paulo Peccin

Recommended Posts

Random Terrain, you should have no problems anymore, please try the new version.

 

Thanks. I moved them back to their original pages:

 

randomterrain.com/atari-2600-memories-program-seaweed-assault.html

 

randomterrain.com/atari-2600-memories-program-tone-toy-2008.html

 

I didn't play around with Seaweed Assault that much before the latest update, so I don't know if this also happened with the previous version. I just noticed that the game has short spurts of sluggishness or lag or whatever you want to call it where movement and sound slows down temporarily. My computer has been on for a day and a half, so that could explain it. I might need to restart it.

Link to comment
Share on other sites

I just noticed that the game has short spurts of sluggishness or lag or whatever you want to call it where movement and sound slows down temporarily

Well, running entirely in Javascript, the complete emulation (video and audio) is a bit heavy on the browser and the CPU. It requires a lot of processing power, and it has to share resources with other things running in the browser at the same page.

That is the cost associated to running things inside the browser sandbox. It is nice, but not without a penalty.

 

So, the less scripts and background tasks runnning on the browser, the better.

Web browsers are getting better and better at handling all this video, audio and processing multi-tasking each day.

 

But at the end of the day, the standalone Java version running outside the browser will always be faster and more fluent.

 

Paulo

  • Like 1
Link to comment
Share on other sites

Well, running entirely in Javascript, the complete emulation (video and audio) is a bit heavy on the browser and the CPU. It requires a lot of processing power, and it has to share resources with other things running in the browser at the same page.

That is the cost associated to running things inside the browser sandbox. It is nice, but not without a penalty.

 

So, the less scripts and background tasks runnning on the browser, the better.

Web browsers are getting better and better at handling all this video, audio and processing multi-tasking each day.

 

But at the end of the day, the standalone Java version running outside the browser will always be faster and more fluent.

 

Paulo

 

Does JavaScript have some kind of thing that could give Javatari a higher priority or is that beyond the abilities of JavaScript?

Link to comment
Share on other sites

I've tried this new emulator on three different laptops, running Windows, Linux, and with both Firefox and Chrome. I couldn't find any combination where the emulation was the same speed as a real 2600: usually the speed was something like 60-70% of a real console. Sound was often way off and very warbly.

 

This isn't a gripe, just feedback. I appreciate what you're doing. Hopefully future versions will be optimized and speedier.

Link to comment
Share on other sites

 

Thanks. I moved them back to their original pages:

 

randomterrain.com/atari-2600-memories-program-seaweed-assault.html

 

randomterrain.com/atari-2600-memories-program-tone-toy-2008.html

 

I didn't play around with Seaweed Assault that much before the latest update, so I don't know if this also happened with the previous version. I just noticed that the game has short spurts of sluggishness or lag or whatever you want to call it where movement and sound slows down temporarily. My computer has been on for a day and a half, so that could explain it. I might need to restart it.

 

 

Worked for me!

  • Like 1
Link to comment
Share on other sites

Thank you all for the testing and feedback. Keep them coming!

I used the "Cosmic Ark" trick for the stars in Stay Frosty:

post-3056-0-71950600-1430692715_thumb.png

 

Javatari doesn't emulate it:

post-3056-0-85577200-1430692735_thumb.png

 

Here's the ROM:

StayFrosty.bin

 

This is the bit of code that causes the effect:

	ldx #$70
	stx HMM1
	sta WSYNC
	sta HMOVE     ;  3
	SLEEP 16      ; 16 19
	dex           ;  2 21
	stx HMM1      ;  3 24 ; this confuses the TIA and generates stars :-)

The effect is caused by writing to the HMxx register too soon after HMOVE was strobed. While I used missile 1, Cosmic Ark did it with missile 0:

    sta    HMOVE            ; 3
    jsr    TimeStarTrick    ;18             a = $60 = -6
    sta    HMM0             ; 3 @24         to early! (Cosmic Ark stars trick)
Link to comment
Share on other sites

 

I used the "Cosmic Ark" trick for the stars in Stay Frosty. Javatari doesn't emulate it.

 

Yes, Javatari still does not emulate the "Cosmic Ark Starfield Effect" correctly.

That is a very tricky behavior to emulate, I left it at the end of the list of quirks to emulate.

 

Paulo

Link to comment
Share on other sites

I've tried this new emulator on three different laptops, running Windows, Linux, and with both Firefox and Chrome. I couldn't find any combination where the emulation was the same speed as a real 2600: usually the speed was something like 60-70% of a real console. Sound was often way off and very warbly.

 

This isn't a gripe, just feedback. I appreciate what you're doing. Hopefully future versions will be optimized and speedier.

 

Well, in my testing I get the opposite results. I have conducted tests in 2 notebooks and 1 desktop. One of the notebooks is a Macbook.

Everything runs very smoothly on the 3 machines, even while using Gamepads to control.

 

But, I still have to test Linux machines. They tend to be way more complicated and diverse.

I also have to do more testing in slow machines.

 

Audio emulation is probably the biggest problem. In order to achieve low sound latency, I am currently using a small audio buffer. But the smaller the buffer, the more CPU it takes, so in slow machines this can mess the entire emulation.

 

This will be easily configurable in future versions. By now, the audio buffer can only be changed by modifying the emulator parameters with Javascript code on the page.

 

Paulo

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...