00001 #ifndef _DEV_HXCODEC_H_ 00002 #define _DEV_HXCODEC_H_ 00003 /* 00004 * Copyright (C) 2001-2007 by egnite Software GmbH. All rights reserved. 00005 * 00006 * Redistribution and use in source and binary forms, with or without 00007 * modification, are permitted provided that the following conditions 00008 * are met: 00009 * 00010 * 1. Redistributions of source code must retain the above copyright 00011 * notice, this list of conditions and the following disclaimer. 00012 * 2. Redistributions in binary form must reproduce the above copyright 00013 * notice, this list of conditions and the following disclaimer in the 00014 * documentation and/or other materials provided with the distribution. 00015 * 3. Neither the name of the copyright holders nor the names of 00016 * contributors may be used to endorse or promote products derived 00017 * from this software without specific prior written permission. 00018 * 00019 * THIS SOFTWARE IS PROVIDED BY EGNITE SOFTWARE GMBH AND CONTRIBUTORS 00020 * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 00021 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 00022 * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL EGNITE 00023 * SOFTWARE GMBH OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 00024 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 00025 * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS 00026 * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 00027 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 00028 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF 00029 * THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 00030 * SUCH DAMAGE. 00031 * 00032 * For additional information see http://www.ethernut.de/ 00033 */ 00034 00035 /* 00036 * $Id: hxcodec.h 2459 2009-02-13 14:46:19Z haraldkipp $ 00037 */ 00038 00039 #include <cfg/audio.h> 00040 #include <sys/device.h> 00041 00051 00052 /* DAC min/max gain in dB. */ 00053 #ifndef AUDIO_DAC_MIN_GAIN 00054 #define AUDIO_DAC_MIN_GAIN -73 00055 #endif 00056 #ifndef AUDIO_DAC_MAX_GAIN 00057 #define AUDIO_DAC_MAX_GAIN 6 00058 #endif 00059 00060 /* 00061 * I/O control codes. 00062 */ 00063 /* 00064 * I/O control codes. 00065 */ 00066 #define AUDIO_SETWRITETIMEOUT 0x010d 00067 #define AUDIO_GETWRITETIMEOUT 0x010e 00068 00070 #define AUDIO_PLAY 0x3001 00071 00072 #define AUDIO_CANCEL 0x3002 00073 #define AUDIO_GET_STATUS 0x3003 00074 #define AUDIO_GET_PLAYGAIN 0x3004 00075 #define AUDIO_SET_PLAYGAIN 0x3005 00076 #define AUDIO_GET_PBSIZE 0x3006 00077 #define AUDIO_SET_PBSIZE 0x3007 00078 #define AUDIO_GET_PBLEVEL 0x3008 00079 #define AUDIO_GET_PBWLOW 0x3009 00080 #define AUDIO_SET_PBWLOW 0x300A 00081 #define AUDIO_GET_PBWHIGH 0x300B 00082 #define AUDIO_SET_PBWHIGH 0x300C 00083 #define AUDIO_BEEP 0x300F 00084 00085 #define AUDIO_GET_DECINFO 0x3010 00086 00087 #define AUDIO_GET_DECCAPS 0x3011 00088 00089 #define AUDIO_GET_DECFMTS 0x3012 00090 00091 #define AUDIO_SET_DECFMTS 0x3013 00092 00093 #define AUDIO_GET_CODINFO 0x3014 00094 00095 #define AUDIO_GET_CODCAPS 0x3015 00096 00097 #define AUDIO_GET_CODFMTS 0x3016 00098 00099 #define AUDIO_SET_CODFMTS 0x3017 00100 00101 #define AUDIO_GET_MIDINFO 0x3018 00102 00103 #define AUDIO_GET_MIDCAPS 0x3019 00104 00105 00106 /* 00107 * Status of the decoder 00108 */ 00109 #define CODEC_STATUS_IDLE 0 00110 #define CODEC_STATUS_PLAYING 1 00111 00112 00113 extern NUTDEVICE devHelixCodec; 00114 00117 #endif