Lines Matching refs:reg_val
394 unsigned char reg_val; in snd_opl3_play_note() local
414 reg_val = (unsigned char) note->fnum; in snd_opl3_play_note()
416 opl3->command(opl3, opl3_reg, reg_val); in snd_opl3_play_note()
418 reg_val = 0x00; in snd_opl3_play_note()
421 reg_val |= OPL3_KEYON_BIT; in snd_opl3_play_note()
423 reg_val |= (note->octave << 2) & OPL3_BLOCKNUM_MASK; in snd_opl3_play_note()
425 reg_val |= (unsigned char) (note->fnum >> 8) & OPL3_FNUM_HIGH_MASK; in snd_opl3_play_note()
429 opl3->command(opl3, opl3_reg, reg_val); in snd_opl3_play_note()
442 unsigned char reg_val; in snd_opl3_set_voice() local
468 reg_val = 0x00; in snd_opl3_set_voice()
471 reg_val |= OPL3_TREMOLO_ON; in snd_opl3_set_voice()
474 reg_val |= OPL3_VIBRATO_ON; in snd_opl3_set_voice()
477 reg_val |= OPL3_SUSTAIN_ON; in snd_opl3_set_voice()
480 reg_val |= OPL3_KSR; in snd_opl3_set_voice()
482 reg_val |= voice->harmonic & OPL3_MULTIPLE_MASK; in snd_opl3_set_voice()
486 opl3->command(opl3, opl3_reg, reg_val); in snd_opl3_set_voice()
489 reg_val = (voice->scale_level << 6) & OPL3_KSL_MASK; in snd_opl3_set_voice()
491 reg_val |= ~voice->volume & OPL3_TOTAL_LEVEL_MASK; in snd_opl3_set_voice()
495 opl3->command(opl3, opl3_reg, reg_val); in snd_opl3_set_voice()
498 reg_val = (voice->attack << 4) & OPL3_ATTACK_MASK; in snd_opl3_set_voice()
500 reg_val |= voice->decay & OPL3_DECAY_MASK; in snd_opl3_set_voice()
504 opl3->command(opl3, opl3_reg, reg_val); in snd_opl3_set_voice()
507 reg_val = (voice->sustain << 4) & OPL3_SUSTAIN_MASK; in snd_opl3_set_voice()
509 reg_val |= voice->release & OPL3_RELEASE_MASK; in snd_opl3_set_voice()
513 opl3->command(opl3, opl3_reg, reg_val); in snd_opl3_set_voice()
516 reg_val = (voice->feedback << 1) & OPL3_FEEDBACK_MASK; in snd_opl3_set_voice()
519 reg_val |= OPL3_CONNECTION_BIT; in snd_opl3_set_voice()
523 reg_val |= OPL3_VOICE_TO_LEFT; in snd_opl3_set_voice()
525 reg_val |= OPL3_VOICE_TO_RIGHT; in snd_opl3_set_voice()
529 opl3->command(opl3, opl3_reg, reg_val); in snd_opl3_set_voice()
532 reg_val = voice->waveform & OPL3_WAVE_SELECT_MASK; in snd_opl3_set_voice()
534 opl3->command(opl3, opl3_reg, reg_val); in snd_opl3_set_voice()
541 unsigned char reg_val; in snd_opl3_set_params() local
543 reg_val = 0x00; in snd_opl3_set_params()
546 reg_val |= OPL3_KEYBOARD_SPLIT; in snd_opl3_set_params()
547 opl3->command(opl3, OPL3_LEFT | OPL3_REG_KBD_SPLIT, reg_val); in snd_opl3_set_params()
549 reg_val = 0x00; in snd_opl3_set_params()
552 reg_val |= OPL3_TREMOLO_DEPTH; in snd_opl3_set_params()
555 reg_val |= OPL3_VIBRATO_DEPTH; in snd_opl3_set_params()
558 reg_val |= OPL3_PERCUSSION_ENABLE; in snd_opl3_set_params()
565 reg_val |= OPL3_BASSDRUM_ON; in snd_opl3_set_params()
567 reg_val |= OPL3_SNAREDRUM_ON; in snd_opl3_set_params()
569 reg_val |= OPL3_TOMTOM_ON; in snd_opl3_set_params()
571 reg_val |= OPL3_CYMBAL_ON; in snd_opl3_set_params()
573 reg_val |= OPL3_HIHAT_ON; in snd_opl3_set_params()
575 opl3->command(opl3, OPL3_LEFT | OPL3_REG_PERCUSSION, reg_val); in snd_opl3_set_params()
593 unsigned char reg_val; in snd_opl3_set_connection() local
599 reg_val = connection & (OPL3_RIGHT_4OP_0 | OPL3_RIGHT_4OP_1 | OPL3_RIGHT_4OP_2 | in snd_opl3_set_connection()
602 opl3->command(opl3, OPL3_RIGHT | OPL3_REG_CONNECTION_SELECT, reg_val); in snd_opl3_set_connection()