Sound driver updated to version 2.5
This commit is contained in:
parent
910e109d64
commit
db2fd867a3
@ -1,7 +1,7 @@
|
||||
# This file tells config what files go into building a kernel,
|
||||
# files marked standard are always included.
|
||||
#
|
||||
# $Id: files.i386,v 1.29 1994/04/07 12:10:17 davidg Exp $
|
||||
# $Id: files.i386,v 1.30 1994/04/21 14:13:43 sos Exp $
|
||||
#
|
||||
i386/i386/autoconf.c standard device-driver
|
||||
i386/i386/cons.c standard
|
||||
@ -52,6 +52,7 @@ i386/isa/sound/gus_card.c optional snd device-driver
|
||||
i386/isa/sound/gus_midi.c optional snd device-driver
|
||||
i386/isa/sound/gus_vol.c optional snd device-driver
|
||||
i386/isa/sound/gus_wave.c optional snd device-driver
|
||||
i386/isa/sound/ics2101.c optional snd device-driver
|
||||
i386/isa/sound/midi.c optional snd device-driver
|
||||
i386/isa/sound/midibuf.c optional snd device-driver
|
||||
i386/isa/sound/mpu401.c optional snd device-driver
|
||||
|
@ -1,7 +1,7 @@
|
||||
# This file tells config what files go into building a kernel,
|
||||
# files marked standard are always included.
|
||||
#
|
||||
# $Id: files.i386,v 1.29 1994/04/07 12:10:17 davidg Exp $
|
||||
# $Id: files.i386,v 1.30 1994/04/21 14:13:43 sos Exp $
|
||||
#
|
||||
i386/i386/autoconf.c standard device-driver
|
||||
i386/i386/cons.c standard
|
||||
@ -52,6 +52,7 @@ i386/isa/sound/gus_card.c optional snd device-driver
|
||||
i386/isa/sound/gus_midi.c optional snd device-driver
|
||||
i386/isa/sound/gus_vol.c optional snd device-driver
|
||||
i386/isa/sound/gus_wave.c optional snd device-driver
|
||||
i386/isa/sound/ics2101.c optional snd device-driver
|
||||
i386/isa/sound/midi.c optional snd device-driver
|
||||
i386/isa/sound/midibuf.c optional snd device-driver
|
||||
i386/isa/sound/mpu401.c optional snd device-driver
|
||||
|
@ -1,5 +1,5 @@
|
||||
#ifndef _SOUNDCARD_H_
|
||||
#define _SOUNDCARD_H_ 1
|
||||
#define _SOUNDCARD_H_
|
||||
/*
|
||||
* Copyright by Hannu Savolainen 1993
|
||||
*
|
||||
@ -34,10 +34,10 @@
|
||||
*
|
||||
* Regards,
|
||||
* Hannu Savolainen
|
||||
* hsavolai@cs.helsinki.fi
|
||||
* hannu@voxware.pp.fi, Hannu.Savolainen@helsinki.fi
|
||||
*/
|
||||
|
||||
#define SOUND_VERSION 203
|
||||
#define SOUND_VERSION 205
|
||||
#define VOXWARE
|
||||
|
||||
#include <sys/ioctl.h>
|
||||
@ -310,6 +310,14 @@ struct patmgr_info { /* Note! size must be < 4k since kmalloc() is used */
|
||||
#define CTRL_EXPRESSION 253
|
||||
#define CTRL_MAIN_VOLUME 252
|
||||
#define SEQ_BALANCE 11
|
||||
#define SEQ_VOLMODE 12
|
||||
|
||||
/*
|
||||
* Volume mode decides how volumes are used
|
||||
*/
|
||||
|
||||
#define VOL_METHOD_ADAGIO 1
|
||||
#define VOL_METHOD_LINEAR 2
|
||||
|
||||
/*
|
||||
* Note! SEQ_WAIT, SEQ_MIDIPUTC and SEQ_ECHO are used also as
|
||||
@ -630,7 +638,8 @@ void seqbuf_dump(void); /* This function must be provided by programs */
|
||||
* }
|
||||
*/
|
||||
|
||||
#define SEQ_DEFINEBUF(len) unsigned char _seqbuf[len]; int _seqbuflen = len, _seqbufptr = 0
|
||||
#define SEQ_DEFINEBUF(len) unsigned char _seqbuf[len]; int _seqbuflen = len; int _seqbufptr = 0
|
||||
#define SEQ_DECLAREBUF() extern unsigned char _seqbuf[]; extern int _seqbuflen;extern int _seqbufptr
|
||||
#define SEQ_PM_DEFINES struct patmgr_info _pm_info
|
||||
#define _SEQ_NEEDBUF(len) if ((_seqbufptr+(len)) > _seqbuflen) seqbuf_dump()
|
||||
#define _SEQ_ADVBUF(len) _seqbufptr += len
|
||||
@ -644,6 +653,17 @@ void seqbuf_dump(void); /* This function must be provided by programs */
|
||||
_pm_info.parm1 = bank, _pm_info.parm2 = 128, \
|
||||
ioctl(seqfd, SNDCTL_PMGR_ACCESS, &_pm_info))
|
||||
|
||||
#define SEQ_VOLUME_MODE(dev, mode) {_SEQ_NEEDBUF(8);\
|
||||
_seqbuf[_seqbufptr] = SEQ_EXTENDED;\
|
||||
_seqbuf[_seqbufptr+1] = SEQ_VOLMODE;\
|
||||
_seqbuf[_seqbufptr+2] = (dev);\
|
||||
_seqbuf[_seqbufptr+3] = (mode);\
|
||||
_seqbuf[_seqbufptr+4] = 0;\
|
||||
_seqbuf[_seqbufptr+5] = 0;\
|
||||
_seqbuf[_seqbufptr+6] = 0;\
|
||||
_seqbuf[_seqbufptr+7] = 0;\
|
||||
_SEQ_ADVBUF(8);}
|
||||
|
||||
#define SEQ_START_NOTE(dev, voice, note, vol) {_SEQ_NEEDBUF(8);\
|
||||
_seqbuf[_seqbufptr] = SEQ_EXTENDED;\
|
||||
_seqbuf[_seqbufptr+1] = SEQ_NOTEON;\
|
||||
@ -734,8 +754,8 @@ void seqbuf_dump(void); /* This function must be provided by programs */
|
||||
_seqbuf[_seqbufptr+2] = (device);\
|
||||
_seqbuf[_seqbufptr+3] = 0;\
|
||||
_SEQ_ADVBUF(4);}
|
||||
#define SEQ_WRPATCH(patch, len) {if (_seqbufptr) seqbuf_dump();\
|
||||
if (write(seqfd, (char*)(patch), len)==-1) \
|
||||
#define SEQ_WRPATCH(patchx, len) {if (_seqbufptr) seqbuf_dump();\
|
||||
if (write(seqfd, (char*)(patchx), len)==-1) \
|
||||
perror("Write patch: /dev/sequencer");}
|
||||
|
||||
#endif
|
||||
|
@ -1,5 +1,5 @@
|
||||
#ifndef _SOUNDCARD_H_
|
||||
#define _SOUNDCARD_H_ 1
|
||||
#define _SOUNDCARD_H_
|
||||
/*
|
||||
* Copyright by Hannu Savolainen 1993
|
||||
*
|
||||
@ -34,10 +34,10 @@
|
||||
*
|
||||
* Regards,
|
||||
* Hannu Savolainen
|
||||
* hsavolai@cs.helsinki.fi
|
||||
* hannu@voxware.pp.fi, Hannu.Savolainen@helsinki.fi
|
||||
*/
|
||||
|
||||
#define SOUND_VERSION 203
|
||||
#define SOUND_VERSION 205
|
||||
#define VOXWARE
|
||||
|
||||
#include <sys/ioctl.h>
|
||||
@ -310,6 +310,14 @@ struct patmgr_info { /* Note! size must be < 4k since kmalloc() is used */
|
||||
#define CTRL_EXPRESSION 253
|
||||
#define CTRL_MAIN_VOLUME 252
|
||||
#define SEQ_BALANCE 11
|
||||
#define SEQ_VOLMODE 12
|
||||
|
||||
/*
|
||||
* Volume mode decides how volumes are used
|
||||
*/
|
||||
|
||||
#define VOL_METHOD_ADAGIO 1
|
||||
#define VOL_METHOD_LINEAR 2
|
||||
|
||||
/*
|
||||
* Note! SEQ_WAIT, SEQ_MIDIPUTC and SEQ_ECHO are used also as
|
||||
@ -630,7 +638,8 @@ void seqbuf_dump(void); /* This function must be provided by programs */
|
||||
* }
|
||||
*/
|
||||
|
||||
#define SEQ_DEFINEBUF(len) unsigned char _seqbuf[len]; int _seqbuflen = len, _seqbufptr = 0
|
||||
#define SEQ_DEFINEBUF(len) unsigned char _seqbuf[len]; int _seqbuflen = len; int _seqbufptr = 0
|
||||
#define SEQ_DECLAREBUF() extern unsigned char _seqbuf[]; extern int _seqbuflen;extern int _seqbufptr
|
||||
#define SEQ_PM_DEFINES struct patmgr_info _pm_info
|
||||
#define _SEQ_NEEDBUF(len) if ((_seqbufptr+(len)) > _seqbuflen) seqbuf_dump()
|
||||
#define _SEQ_ADVBUF(len) _seqbufptr += len
|
||||
@ -644,6 +653,17 @@ void seqbuf_dump(void); /* This function must be provided by programs */
|
||||
_pm_info.parm1 = bank, _pm_info.parm2 = 128, \
|
||||
ioctl(seqfd, SNDCTL_PMGR_ACCESS, &_pm_info))
|
||||
|
||||
#define SEQ_VOLUME_MODE(dev, mode) {_SEQ_NEEDBUF(8);\
|
||||
_seqbuf[_seqbufptr] = SEQ_EXTENDED;\
|
||||
_seqbuf[_seqbufptr+1] = SEQ_VOLMODE;\
|
||||
_seqbuf[_seqbufptr+2] = (dev);\
|
||||
_seqbuf[_seqbufptr+3] = (mode);\
|
||||
_seqbuf[_seqbufptr+4] = 0;\
|
||||
_seqbuf[_seqbufptr+5] = 0;\
|
||||
_seqbuf[_seqbufptr+6] = 0;\
|
||||
_seqbuf[_seqbufptr+7] = 0;\
|
||||
_SEQ_ADVBUF(8);}
|
||||
|
||||
#define SEQ_START_NOTE(dev, voice, note, vol) {_SEQ_NEEDBUF(8);\
|
||||
_seqbuf[_seqbufptr] = SEQ_EXTENDED;\
|
||||
_seqbuf[_seqbufptr+1] = SEQ_NOTEON;\
|
||||
@ -734,8 +754,8 @@ void seqbuf_dump(void); /* This function must be provided by programs */
|
||||
_seqbuf[_seqbufptr+2] = (device);\
|
||||
_seqbuf[_seqbufptr+3] = 0;\
|
||||
_SEQ_ADVBUF(4);}
|
||||
#define SEQ_WRPATCH(patch, len) {if (_seqbufptr) seqbuf_dump();\
|
||||
if (write(seqfd, (char*)(patch), len)==-1) \
|
||||
#define SEQ_WRPATCH(patchx, len) {if (_seqbufptr) seqbuf_dump();\
|
||||
if (write(seqfd, (char*)(patchx), len)==-1) \
|
||||
perror("Write patch: /dev/sequencer");}
|
||||
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user