示例#1
0
void petsound_store_rate(CLOCK t)
{
    snddata[2] = (BYTE)(t & 0xff);
    snddata[3] = (BYTE)((t >> 8) & 0xff);
    sound_store((WORD)(pet_sound_chip_offset | 2), snddata[2], 0);
    sound_store((WORD)(pet_sound_chip_offset | 3), snddata[3], 0);
}
示例#2
0
int sfx_soundsampler_snapshot_read_module(snapshot_t *s)
{
    BYTE vmajor, vminor;
    snapshot_module_t *m;

    m = snapshot_module_open(s, SNAP_MODULE_NAME, &vmajor, &vminor);
    if (m == NULL) {
        return -1;
    }

    if ((vmajor != CART_DUMP_VER_MAJOR) || (vminor != CART_DUMP_VER_MINOR)) {
        snapshot_module_close(m);
        return -1;
    }

    if (0 || (SMR_B(m, &sfx_soundsampler_sound_data) < 0)) {
        snapshot_module_close(m);
        return -1;
    }

    if (!sfx_soundsampler_sound_chip.chip_enabled) {
        set_sfx_soundsampler_enabled(1, NULL);
    }
    sound_store(sfx_soundsampler_sound_chip_offset, sfx_soundsampler_sound_data, 0);

    snapshot_module_close(m);
    return 0;
}
示例#3
0
static void digiblaster_store(WORD addr, BYTE value)
{
    if ((addr & 1) == 0) {
        digiblaster_sound_data = value;
        sound_store(digiblaster_sound_chip_offset, value, 0);
    }
}
示例#4
0
void userport_dac_store(BYTE value)
{
    if (userport_dac_sound_chip.chip_enabled) {
        userport_dac_sound_data = value;
        sound_store(userport_dac_sound_chip_offset, value, 0);
    }
}
示例#5
0
static void sfx_soundexpander_sound_store(WORD addr, BYTE value)
{
    if (addr == 0x40) {
        if (sfx_soundexpander_chip == 3812) {
            ym3812_write(YM3812_chip, 0, value);
        } else {
            ym3526_write(YM3526_chip, 0, value);
        }
    }
    if (addr == 0x50) {
        sound_store(sfx_soundexpander_sound_chip_offset, value, 0);
    }
}
static void userport_digimax_store_pbx(BYTE value)
{
    BYTE addr = 0;

    switch (userport_digimax_address) {
        case 0x0:
            addr = 2;
            break;
        case 0x4:
            addr = 3;
            break;
        case 0x8:
            addr = 0;
            break;
        case 0xc:
            addr = 1;
            break;
    }

    digimax_sound_data[addr] = value;
    sound_store((WORD)(digimax_sound_chip_offset | addr), value, 0);
}
示例#7
0
static void sfx_soundsampler_sound_store(WORD addr, BYTE value)
{
    sfx_soundsampler_sound_data = value;
    sound_store(sfx_soundsampler_sound_chip_offset, value, 0);
}
示例#8
0
void digiblaster_store(WORD addr, BYTE value)
{
    digiblaster_sound_data = value;
    sound_store(digiblaster_sound_chip_offset, value, 0);
}
示例#9
0
void digimax_sound_store(WORD addr, BYTE value)
{
    digimax_sound_data[addr] = value;
    sound_store((WORD)(digimax_sound_chip_offset | addr), value, 0);
}
示例#10
0
/* For manual control of CB2 sound using $E84C */
void petsound_store_manual(int value)
{
    snddata[4] = value;
    sound_store((WORD)(pet_sound_chip_offset | 4), snddata[4], 0);
}
示例#11
0
void petsound_store_sample(BYTE sample)
{
    snddata[1] = sample;
    sound_store((WORD)(pet_sound_chip_offset | 1), snddata[1], 0);
}
示例#12
0
void petsound_store_onoff(int value)
{
    snddata[0] = value;
    sound_store(pet_sound_chip_offset, snddata[0], 0);
}
示例#13
0
static void REGPARM2 sfx_soundsampler_sound_store(WORD addr, BYTE value)
{
    sfx_soundsampler_sound_data = value;
    sound_store((WORD)0x40, value, 0);
}