diff options
author | 2009-05-07 15:46:14 +0000 | |
---|---|---|
committer | 2009-05-07 15:46:14 +0000 | |
commit | 673ca66750503dbef77b967ed1fbaa0d86355513 (patch) | |
tree | 3d26385d287b623e0dedc2cdd5d3fc3a9dafde31 /src/emu | |
parent | c80c4730c4170342f34e5b92e3ca9132490bf977 (diff) |
Cleanups and version bump.mame0131u1
Diffstat (limited to 'src/emu')
-rw-r--r-- | src/emu/cpu/h83002/h8_8.c | 4 | ||||
-rw-r--r-- | src/emu/machine/x76f041.c | 2 | ||||
-rw-r--r-- | src/emu/machine/x76f100.c | 2 | ||||
-rw-r--r-- | src/emu/sound/sn76496.c | 56 | ||||
-rw-r--r-- | src/emu/sound/wave.c | 2 | ||||
-rw-r--r-- | src/emu/validity.c | 8 |
6 files changed, 37 insertions, 37 deletions
diff --git a/src/emu/cpu/h83002/h8_8.c b/src/emu/cpu/h83002/h8_8.c index 4d1a695158b..6a4b7934e2f 100644 --- a/src/emu/cpu/h83002/h8_8.c +++ b/src/emu/cpu/h83002/h8_8.c @@ -310,9 +310,9 @@ static int h8_get_priority(h83xx_state *h8, UINT8 bit) case 11: // IRQ7 if (h8->per_regs[0xc7]&0x80) res = 1; break; case 28: // SCI0 Rx - if (h8->per_regs[0xda]&0x40) res = 1; break; + if (h8->per_regs[0xda]&0x40) res = 1; break; case 32: // SCI1 Rx - if (h8->per_regs[0x8a]&0x40) res = 1; break; + if (h8->per_regs[0x8a]&0x40) res = 1; break; } return res; } diff --git a/src/emu/machine/x76f041.c b/src/emu/machine/x76f041.c index fb26eaf74de..c54617a3db6 100644 --- a/src/emu/machine/x76f041.c +++ b/src/emu/machine/x76f041.c @@ -115,7 +115,7 @@ void x76f041_init( running_machine *machine, int chip, UINT8 *data ) if( data == NULL ) { - data = auto_alloc_array( machine, UINT8, + data = auto_alloc_array( machine, UINT8, SIZE_RESPONSE_TO_RESET + SIZE_READ_PASSWORD + SIZE_WRITE_PASSWORD + diff --git a/src/emu/machine/x76f100.c b/src/emu/machine/x76f100.c index d355b7c6cac..80c77d54b27 100644 --- a/src/emu/machine/x76f100.c +++ b/src/emu/machine/x76f100.c @@ -84,7 +84,7 @@ void x76f100_init( running_machine *machine, int chip, UINT8 *data ) if( data == NULL ) { - data = auto_alloc_array( machine, UINT8, + data = auto_alloc_array( machine, UINT8, SIZE_RESPONSE_TO_RESET + SIZE_READ_PASSWORD + SIZE_WRITE_PASSWORD + diff --git a/src/emu/sound/sn76496.c b/src/emu/sound/sn76496.c index d356c791771..3804edbeef3 100644 --- a/src/emu/sound/sn76496.c +++ b/src/emu/sound/sn76496.c @@ -32,24 +32,24 @@ 23/04/2007 : Lord Nightmare Major update, implement all three different noise generation algorithms and a set_variant call to discern among them. - + 28/04/2009 : Lord Nightmare Add READY line readback; cleaned up struct a bit. Cleaned up comments. Add more TODOs. Fixed some unsaved savestate related stuff. TODO: * Implement a function for setting stereo regs for the game gear. - Requires making the core support both mono and stereo, and have - a select register which determines which channels go where. - * Implement the TMS9919 and SN94624, which are earlier versions, - possibly lacking the /8 clock divider, of the SN76489, and hence - would have a max clock of 500Khz and 4 clocks per sample, as - opposed to max of 4Mhz and 32 clocks per sample on the SN76489A - * Implement the T6W28; has registers in a weird order, needs writes - to be 'sanitized' first. Also is stereo, similar to game gear. - * Implement the NCR 7496; Is probably 100% compatible with SN76496, - but the whitenoise taps could be different. Needs someone with a - Tandy 1200 or whatever it was which uses this to run some tests. - * Factor out common code so that the SAA1099 can share some code. + Requires making the core support both mono and stereo, and have + a select register which determines which channels go where. + * Implement the TMS9919 and SN94624, which are earlier versions, + possibly lacking the /8 clock divider, of the SN76489, and hence + would have a max clock of 500Khz and 4 clocks per sample, as + opposed to max of 4Mhz and 32 clocks per sample on the SN76489A + * Implement the T6W28; has registers in a weird order, needs writes + to be 'sanitized' first. Also is stereo, similar to game gear. + * Implement the NCR 7496; Is probably 100% compatible with SN76496, + but the whitenoise taps could be different. Needs someone with a + Tandy 1200 or whatever it was which uses this to run some tests. + * Factor out common code so that the SAA1099 can share some code. ***************************************************************************/ #include "sndintrf.h" @@ -162,7 +162,7 @@ WRITE8_DEVICE_HANDLER( sn76496_w ) /* N/512,N/1024,N/2048,Tone #3 output */ R->Period[3] = ((n&3) == 3) ? 2 * R->Period[2] : (STEP << (5+(n&3))); /* Reset noise shifter */ - R->RNG = R->FeedbackMask; + R->RNG = R->FeedbackMask; R->Output[3] = R->RNG & 1; } break; @@ -179,15 +179,15 @@ static STREAM_UPDATE( SN76496Update ) /* If the volume is 0, increase the counter; this is more or less - a speedup hack for when silence is to be output */ + a speedup hack for when silence is to be output */ for (i = 0;i < 4;i++) { if (R->Volume[i] == 0) { - /* note that I do count += samples, NOT count = samples + 1. - You might think it's the same since the volume is 0, but doing - the latter could cause interferencies when the program is - rapidly modulating the volume. */ + /* note that I do count += samples, NOT count = samples + 1. + You might think it's the same since the volume is 0, but doing + the latter could cause interferencies when the program is + rapidly modulating the volume. */ if (R->Count[i] <= samples*STEP) R->Count[i] += samples*STEP; } } @@ -197,7 +197,7 @@ static STREAM_UPDATE( SN76496Update ) int vol[4]; unsigned int out; int left; - + /* decrement Cycles to READY by one */ if (R->CyclestoREADY >0) R->CyclestoREADY--; @@ -209,14 +209,14 @@ static STREAM_UPDATE( SN76496Update ) { if (R->Output[i]) vol[i] += R->Count[i]; R->Count[i] -= STEP; - /* Period[i] is the half period of the square wave. Here, in each - loop I add Period[i] twice, so that at the end of the loop the - square wave is in the same status (0 or 1) it was at the start. - vol[i] is also incremented by Period[i], since the wave has been 1 - exactly half of the time, regardless of the initial position. - If we exit the loop in the middle, Output[i] has to be inverted - and vol[i] incremented only if the exit status of the square - wave is 1. */ + /* Period[i] is the half period of the square wave. Here, in each + loop I add Period[i] twice, so that at the end of the loop the + square wave is in the same status (0 or 1) it was at the start. + vol[i] is also incremented by Period[i], since the wave has been 1 + exactly half of the time, regardless of the initial position. + If we exit the loop in the middle, Output[i] has to be inverted + and vol[i] incremented only if the exit status of the square + wave is 1. */ while (R->Count[i] <= 0) { R->Count[i] += R->Period[i]; diff --git a/src/emu/sound/wave.c b/src/emu/sound/wave.c index d9b5e1dd265..b16446aa646 100644 --- a/src/emu/sound/wave.c +++ b/src/emu/sound/wave.c @@ -34,7 +34,7 @@ static STREAM_UPDATE( wave_sound_update ) state = cassette_get_state(image); state &= CASSETTE_MASK_UISTATE | CASSETTE_MASK_MOTOR | CASSETTE_MASK_SPEAKER; - + if (image_exists(image) && (ALWAYS_PLAY_SOUND || (state == (CASSETTE_PLAY | CASSETTE_MOTOR_ENABLED | CASSETTE_SPEAKER_ENABLED)))) { cassette = cassette_get_image(image); diff --git a/src/emu/validity.c b/src/emu/validity.c index adfbb207a48..77de5af944b 100644 --- a/src/emu/validity.c +++ b/src/emu/validity.c @@ -301,19 +301,19 @@ static void quark_tables_free(void) if (source_table != NULL) free(source_table); source_table = NULL; - + if (name_table != NULL) free(name_table); name_table = NULL; - + if (description_table != NULL) free(description_table); description_table = NULL; - + if (roms_table != NULL) free(roms_table); roms_table = NULL; - + if (defstr_table != NULL) free(defstr_table); defstr_table = NULL; |