Changeset 763444e in mainline


Ignore:
Timestamp:
2011-09-25T19:41:22Z (13 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
57542304
Parents:
0687e1b
Message:

sb16: Implement direct mode digital sound I/O.

Location:
uspace/drv/audio/sb16
Files:
1 added
4 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/audio/sb16/Makefile

    r0687e1b r763444e  
    3838
    3939SOURCES = \
     40        dsp.c \
    4041        main.c \
    4142        mixer.c \
  • uspace/drv/audio/sb16/dsp.h

    r0687e1b r763444e  
    2626 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    2727 */
    28 
    2928/** @addtogroup drvaudiosb16
    3029 * @{
    3130 */
    3231/** @file
    33  * @brief SB16 main structure combining all functionality
     32 * @brief Sound Blaster Digital Sound Processor (DSP) helper functions.
    3433 */
    3534#ifndef DRV_AUDIO_SB16_DSP_H
     
    3736
    3837#include <libarch/ddi.h>
     38#include <errno.h>
    3939
    4040#include "registers.h"
     41#include "dsp_commands.h"
    4142
    4243#ifndef DSP_PIO_DELAY
     
    9091        pio_write_8(&regs->dsp_reset, 0);
    9192}
     93/*----------------------------------------------------------------------------*/
     94int dsp_play_direct(sb16_regs_t *regs, const uint8_t *data, size_t size,
     95    unsigned sample_rate, unsigned channels, unsigned bit_depth);
    9296#endif
    9397/**
  • uspace/drv/audio/sb16/dsp_commands.h

    r0687e1b r763444e  
    3636#define DRV_AUDIO_SB16_DSP_COMMANDS_H
    3737
    38 /** See SoundBlaster Series HW programming Guide Chapter 6. */
     38/** See Sound Blaster Series HW programming Guide Chapter 6. */
    3939typedef enum dsp_command {
    4040        DIRECT_8B_OUTPUT = 0x20, /* Followed by unsigned byte of digital data,
  • uspace/drv/audio/sb16/sb16.c

    r0687e1b r763444e  
    8787        dsp_read(drv->regs, &drv->dsp_version.major);
    8888        dsp_read(drv->regs, &drv->dsp_version.minor);
    89         ddf_log_note("Sound blaster DSP (%x.%x) Initialized.\n",
     89        ddf_log_note("Sound blaster DSP (%x.%x) initialized.\n",
    9090            drv->dsp_version.major, drv->dsp_version.minor);
    9191
Note: See TracChangeset for help on using the changeset viewer.