Emuforums.com

Go Back   Emuforums.com > General Discussion > Web development / Programming
Home Register Downloads FAQ Members List Calendar Arcade Mark Forums Read

WON'T YOU JOIN US?
You are not a registered member and
are viewing this site as a guest.
Registration is simple and FREE.
Join this CrowdGather community today.
Registration offers the following perks:

» Less advertising throughout
» Post and participate in discussions
» Network with other forum members
» Free private messaging

join

Reply
 
Thread Tools Display Modes
Old March 26th, 2008, 01:44   #1
ShendoXT
Moderator
 
ShendoXT's Avatar
 
Join Date: Feb 2006
Location: Croatia
Posts: 4,548
Chip-8 emu

If you reached this thread in order to download my emu then proceed here where you can find the newest version.

The old emulator was inaccurate, slow and a resource hog. The new one is much better.
Also the "Chip 8 emu" name was changed to "NetChip8".
__________________
Shendo's software blog

Core i5 2400 3.1 Ghz | ASRock H67M | GTX460 768Mb | 8GB DDR3 1333 | 1500 Gb HDD
Grundig VLC 7121 C (1080p) 32" | Razer DeathAdder | Logitech G110 | Windows 7 x64

Don't PM or ask me about VMP-MCR conversions. I will ignore you if you do.

Last edited by ShendoXT; August 18th, 2010 at 21:12..
ShendoXT is offline   Reply With Quote

Advertisement [Remove Advertisement]
Old March 26th, 2008, 05:23   #2
TheCloudOfSmoke
Menthol Flavored
 
TheCloudOfSmoke's Avatar
 
Join Date: Mar 2005
Location: Maryland, USA.
Posts: 3,925
Best of luck with your emulation projects. It's good to see more aspiring emu authors out there. It gives me hope for the scene. I hope to see a really awesome emu from you one day Shendo. Good luck. Sorry if my post didn't help you whatsoever.
__________________
http://thecloudofsmoke.deviantart.com
Quote:
Originally Posted by BigIg View Post
If I support the game company, then I won't won't be supporting the blank DVD business.

Decisions, decisions.

TheCloudOfSmoke is offline   Reply With Quote
Old March 26th, 2008, 06:14   #3
blueshogun96
Last Xbox Emu Author
 
blueshogun96's Avatar
 
Join Date: Jun 2004
Location: Seattle, WA, USA
Posts: 5,843
Okay, there's not much out there related to emulating sound and you'll soon find out the google is not your friend on this subject. I'll do my best to answer your question.

1. Before learning about sound emulation, it's highly recommended that you learn about how sound works (if you don't know already). First learn a low-level sound API such as DirectSound, OpenAL or XAudio (which is still in beta stages) and create some sound programs that can output sound by sending some raw data to a sound buffer. DirectSound is so far the most prominent while sound emulation with OpenAL is rather hard and XAudio... I don't know because I haven't seen it used for anything yet. Finding tutorials on low level sound APIs are very hard to find (except OpenAL which is more for 3D games) and once again Google might not be your friend on this subject. If you want you can either read the docs on the sound API such as the microsoft SDK documentation or MSDN. If you need tutorials on DirectSound, ask me and I will write them for you personally.

2. As far as tutorials on how to emulate sound, this is the best I can find to date: Blargg's Video Game Sound Emulation
Here's another: How to write an emulator It's an overall tutorial on emulation, but the sound emulation section is the largest and it shows some actual DirectSound code being used.

3. Be sure to have the documentation on the sound hardware you're trying to emulate!

4. I'm not sure how far indepth you want to get with sound emulation, but let me tell you this, emulating sound [usually] gets harder and harder as the console gets more advanced VERY quickly (sometimes more then the CPU itself). While GameBoy, SpaceInvaders, and NES usually aren't so bad, other old consoles such as Atari2600 and SNES have certain issues to be dealt with (for Atari usually has to deal with Pitfall II, for SNES the DSP) in order to get accurate emulation. The newer consoles and arcade hardware such as SegaSaturn/Titan Video, GC, PS2 have very advanced audio systems with either more than one core or advanced and undocumented DSPs. Instead of using basic PSG or FM based audio chips that generate simple waveforms (i.e. sin and cos for wave generation), these are APUs that create more complex audio effects and uses more complex methods (i.e. envelopes, KON/KOF, attack - sustain - decay rates, etc.). So far the most complex audio system I've seen [actual] specs on to date is Xbox1 with(at least 3 DSPs, an AC'97 Audio codec, and an NVIDIA SoundStorm APU. I know that PS3's audio system is the most advanced (where every object can have it's own sound channel!), but I don't think you'll be trying to emulate anytime soon (or even in your lifetime) Anyone can feel free to correct me if I'm wrong about any of this.

So if you need anything else, feel free to ask me anytime. Know this, I don't know everything

And about your emulator, what APIs are you using? btw, nice debugger! Looking great!
__________________

Official Website of Shogun3D's RyuAwai!

Shogun3D Game Development Blog

Zengjük a Dalt: Manliest Song Ever!

Last edited by blueshogun96; March 26th, 2008 at 06:42.. Reason: Added more information that might be useful, informative, or overall educational for that matter.
blueshogun96 is offline   Reply With Quote
Old March 26th, 2008, 06:21   #4
Phil
339.9
 
Phil's Avatar
 
Join Date: Oct 2007
Location: USA
Posts: 14,777
well direct sound is not supported in Vista...only XP downwords..stick with OpenAL
__________________
Vision is the art of seeing what is invisible to others
Phil is offline   Reply With Quote
Old March 26th, 2008, 06:46   #5
blueshogun96
Last Xbox Emu Author
 
blueshogun96's Avatar
 
Join Date: Jun 2004
Location: Seattle, WA, USA
Posts: 5,843
Quote:
Originally Posted by Phil View Post
well direct sound is not supported in Vista...only XP downwords..stick with OpenAL
Yes it is. DirectSound only can be used in software mode, but it still works just fine. EAX support has been resurrected but only for the Creative Audigy users. I wouldn't recommend using OpenAL for sound emulation for beginners because it's harder for beginners to grasp it.
__________________

Official Website of Shogun3D's RyuAwai!

Shogun3D Game Development Blog

Zengjük a Dalt: Manliest Song Ever!
blueshogun96 is offline   Reply With Quote
Old March 26th, 2008, 06:54   #6
Phil
339.9
 
Phil's Avatar
 
Join Date: Oct 2007
Location: USA
Posts: 14,777
that's what i meant. A card using directsound will have to run on software mode...which sucks as i was going to get the Auzentech Prelude specifically for it's hardware mode...I still might get it....just waiting till Auzentech sorts out Creative's drivers
__________________
Vision is the art of seeing what is invisible to others
Phil is offline   Reply With Quote
Old March 26th, 2008, 06:59   #7
blueshogun96
Last Xbox Emu Author
 
blueshogun96's Avatar
 
Join Date: Jun 2004
Location: Seattle, WA, USA
Posts: 5,843
But for emulation it's not too critical, unless the hardware you're trying to emulate uses features that can only be emulated in hardware (which so far no situation like that has come up yet afaik). Besides, using low-level DirectSound is still great for beginners to learn because the APIs and interfaces are usually self explanatory.
__________________

Official Website of Shogun3D's RyuAwai!

Shogun3D Game Development Blog

Zengjük a Dalt: Manliest Song Ever!
blueshogun96 is offline   Reply With Quote
Old March 26th, 2008, 07:04   #8
Phil
339.9
 
Phil's Avatar
 
Join Date: Oct 2007
Location: USA
Posts: 14,777
you have a point...
__________________
Vision is the art of seeing what is invisible to others
Phil is offline   Reply With Quote
Old March 26th, 2008, 11:01   #9
@ruantec
Crazy GFX coder
 
@ruantec's Avatar
 
Join Date: Nov 2002
Location: Dominican Republic/Austria
Posts: 8,115
Looks like you progressed well since last time we talked about it

Directsound should be fine to reproduce the sounds and it works with Vista. i don´t know if you worked with directsound before.... but i think it shouldn´t be a problem for you
__________________


Current development tools:

Visual C++.net, Visual C#.net
Visual VB.net, Visual Webdeveloper.net
Bloodshed Dev C++, Borland C++
Visual Basic 6
@ruantec is offline   Reply With Quote
Old March 26th, 2008, 12:24   #10
refraction
PCSX2 Coder
 
refraction's Avatar
 
Join Date: Jan 2004
Location: Plymouth, UK
Posts: 10,037
when i first made a chip8 emu with sound, i basically sent a load of rubbish in to the SDL buffer, but it made random buzzes, as the original system only had a buzzer, so it was no need to be impressive

altho my current (newest) one isnt quite as advanced as yours, it works pretty well, you can see it here with games and source ;p
RefChip8 - Chip8 Emulator
__________________

http://www.pcsx2.net
Intel i7 920 @ 3.4Ghz, POV GTX 570 1.3Gb, 1.8Tb HD space, 6Gb OCZ Reaper PC3-14400 Triple Channel
Dont PM me for help, use the forums, thats what its for!


My Chip16 Emulator RefChip16 http://code.google.com/p/refchip16/
refraction is offline   Reply With Quote
Old March 26th, 2008, 12:41   #11
Phil
339.9
 
Phil's Avatar
 
Join Date: Oct 2007
Location: USA
Posts: 14,777
Ref i love the deflicker system.
Nice (if basic) emu though
__________________
Vision is the art of seeing what is invisible to others
Phil is offline   Reply With Quote
Old March 26th, 2008, 14:42   #12
ShendoXT
Moderator
 
ShendoXT's Avatar
 
Join Date: Feb 2006
Location: Croatia
Posts: 4,548
@TheCloudOfSmoke: Thanks. Though it will take a lot of time before/if I even make something that can be measured with other emulators.

@blueshogun96: Thank you for the links, I'll check them out.
As for API it's GDI+. That probably is not suited for emulation but in this case I think it's ok.

@@ruantec-Man: Yeah I got rid of the most graphic glitches.

@refraction: Nice emu.
__________________
Shendo's software blog

Core i5 2400 3.1 Ghz | ASRock H67M | GTX460 768Mb | 8GB DDR3 1333 | 1500 Gb HDD
Grundig VLC 7121 C (1080p) 32" | Razer DeathAdder | Logitech G110 | Windows 7 x64

Don't PM or ask me about VMP-MCR conversions. I will ignore you if you do.
ShendoXT is offline   Reply With Quote
Old March 26th, 2008, 17:06   #13
refraction
PCSX2 Coder
 
refraction's Avatar
 
Join Date: Jan 2004
Location: Plymouth, UK
Posts: 10,037
Quote:
Originally Posted by Phil View Post
Ref i love the deflicker system.
Nice (if basic) emu though
cheap as hell but i worked Chip8 is very simplistic, so it uses 1 frame to draw the sprites, then the next to clear them, then the next to draw them in the new location, etc.

Quote:
Originally Posted by Shendo View Post
@refraction: Nice emu.

thanks, i know its nothing special, but i literally threw it together for an australian magazine thingy, so budding authors have something to go off. But if it helps with your emu thats all that matters
__________________

http://www.pcsx2.net
Intel i7 920 @ 3.4Ghz, POV GTX 570 1.3Gb, 1.8Tb HD space, 6Gb OCZ Reaper PC3-14400 Triple Channel
Dont PM me for help, use the forums, thats what its for!


My Chip16 Emulator RefChip16 http://code.google.com/p/refchip16/
refraction is offline   Reply With Quote
Old March 26th, 2008, 17:24   #14
@ruantec
Crazy GFX coder
 
@ruantec's Avatar
 
Join Date: Nov 2002
Location: Dominican Republic/Austria
Posts: 8,115
Quote:
Originally Posted by refraction View Post
cheap as hell but i worked Chip8 is very simplistic, so it uses 1 frame to draw the sprites, then the next to clear them, then the next to draw them in the new location, etc.




thanks, i know its nothing special, but i literally threw it together for an australian magazine thingy, so budding authors have something to go off. But if it helps with your emu thats all that matters
i think we shouldn´t understimate a Chip8 emulator........ indeed is nothing special(in comparation to emulators for consoles etc) but if you think what we learn from it then you will realize is actually very special because most of us started with a chip8 emulator that help us get the idea how emulation works.
__________________


Current development tools:

Visual C++.net, Visual C#.net
Visual VB.net, Visual Webdeveloper.net
Bloodshed Dev C++, Borland C++
Visual Basic 6
@ruantec is offline   Reply With Quote
Old March 26th, 2008, 17:26   #15
refraction
PCSX2 Coder
 
refraction's Avatar
 
Join Date: Jan 2004
Location: Plymouth, UK
Posts: 10,037
Quote:
Originally Posted by @ruantec-Man View Post
i think we shouldn´t understimate a Chip8 emulator........ indeed is nothing special(in comparation to emulators for consoles etc) but if you think what we learn from it then you will realize is actually very special because most of us started with a chip8 emulator that help us get the idea how emulation works.
that was the whole concept i worked on

i did intend on commenting it more but i couldnt be arsed lol. But the idea was keep it reasonably simple so people can work out for themselves how the emulator actually works.

can you see the copy and pasta from sdl tutorials? *hides*
__________________

http://www.pcsx2.net
Intel i7 920 @ 3.4Ghz, POV GTX 570 1.3Gb, 1.8Tb HD space, 6Gb OCZ Reaper PC3-14400 Triple Channel
Dont PM me for help, use the forums, thats what its for!


My Chip16 Emulator RefChip16 http://code.google.com/p/refchip16/
refraction is offline   Reply With Quote
Old March 26th, 2008, 17:39   #16
@ruantec
Crazy GFX coder
 
@ruantec's Avatar
 
Join Date: Nov 2002
Location: Dominican Republic/Austria
Posts: 8,115
"Copy and pasta" that was a good one anyways i think every chip8 emula8r is another step to a better emulation world

btw nice chip8 emu
__________________


Current development tools:

Visual C++.net, Visual C#.net
Visual VB.net, Visual Webdeveloper.net
Bloodshed Dev C++, Borland C++
Visual Basic 6
@ruantec is offline   Reply With Quote
Old March 27th, 2008, 00:20   #17
refraction
PCSX2 Coder
 
refraction's Avatar
 
Join Date: Jan 2004
Location: Plymouth, UK
Posts: 10,037
thx ;p but really, i think it sucks it just does the job lol

ill appreciate it more if people learnt from it
__________________

http://www.pcsx2.net
Intel i7 920 @ 3.4Ghz, POV GTX 570 1.3Gb, 1.8Tb HD space, 6Gb OCZ Reaper PC3-14400 Triple Channel
Dont PM me for help, use the forums, thats what its for!


My Chip16 Emulator RefChip16 http://code.google.com/p/refchip16/
refraction is offline   Reply With Quote
Old March 27th, 2008, 02:51   #18
cottonvibes
You're already dead...
 
cottonvibes's Avatar
 
Join Date: Sep 2007
Location: Planet Vegeta
Posts: 5,387
cool emulators, i might try to make one for the learning experience as well. (well, thats after i become more familiar with c++ :/)


Shendo do you mind posting links to the documentation you used?
__________________

"It was, of course, a lie what you read about my religious convictions, a lie which is being systematically repeated. I do not believe in a personal God and I have never denied this but have expressed it clearly. If something is in me which can be called religious then it is the unbounded admiration for the structure of the world so far as our science can reveal it." - Albert Einstein
check out my blog
cottonvibes is offline   Reply With Quote
Old March 27th, 2008, 02:59   #19
ShendoXT
Moderator
 
ShendoXT's Avatar
 
Join Date: Feb 2006
Location: Croatia
Posts: 4,548
Chip 8 instruction set
CHIP8 documentation by David Winter.

There is also a great thread at EmuTalk which contains a lot of information.
__________________
Shendo's software blog

Core i5 2400 3.1 Ghz | ASRock H67M | GTX460 768Mb | 8GB DDR3 1333 | 1500 Gb HDD
Grundig VLC 7121 C (1080p) 32" | Razer DeathAdder | Logitech G110 | Windows 7 x64

Don't PM or ask me about VMP-MCR conversions. I will ignore you if you do.
ShendoXT is offline   Reply With Quote
Old March 27th, 2008, 03:09   #20
blueshogun96
Last Xbox Emu Author
 
blueshogun96's Avatar
 
Join Date: Jun 2004
Location: Seattle, WA, USA
Posts: 5,843
Quote:
Originally Posted by refraction View Post
thx ;p but really, i think it sucks it just does the job lol

ill appreciate it more if people learnt from it
Obviously you haven't seen my chip8 emulator. If you think yours was bad, mine was 100x worse! Remember ChipAint?
__________________

Official Website of Shogun3D's RyuAwai!

Shogun3D Game Development Blog

Zengjük a Dalt: Manliest Song Ever!
blueshogun96 is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +1. The time now is 07:59.

© 2006 - 2012 Emu Forums | About Emu Forums | Advertisers | Investors | Legal | A member of the Crowdgather Forum Community


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2013, vBulletin Solutions, Inc.