File nut/dev/spi_vscodec.c


Included Files


Preprocessor definitions

#define VSREQ_PLAY 0x00000001

#define VSREQ_CANCEL 0x00000002

#define VSREQ_VOLUPD 0x00000004

#define VSREQ_AUDIOE 0x00000008

#define VSREQ_BEEP 0x00000010

#define VSREQ_RECORD 0x00000020


Global Variable zero_chunk

uint8_t zero_chunk[32]
Visible in:   nut/dev/spi_vscodec.c

Global Function FeederThread()

void FeederThread ( void* arg )
Prototyped in: nut/include/dev/vscodec.h
Calls: VsCodecBeep() nut/dev/spi_vscodec.c
  VsCodecReg() nut/dev/spi_vscodec.c
  VsCodecWaitReady() nut/dev/spi_vscodec.c
  VsDecoderSetBass() nut/dev/spi_vscodec.c
  VsDecoderSetVolume() nut/dev/spi_vscodec.c
  NutEventPost(), NutEventWait(), NutSegBufReadLast(), NutSegBufReadRequest(), NutSegBufReset(), NutSegBufUsed(), NutSegBufWriteRequest(), NutThreadSetPriority()

Global Function VsCodecBeep()

uint16_t VsCodecBeep ( NUTDEVICE* dev, uint16_t fsin )
Prototyped in: nut/include/dev/vscodec.h
Calls: VsCodecMode() nut/dev/spi_vscodec.c
Called by: FeederThread() nut/dev/spi_vscodec.c

Global Function VsCodecClose()

int VsCodecClose ( NUTFILE* nfp )
Prototyped in: nut/include/dev/vscodec.h
Calls: VsDecoderBufferFlush() nut/dev/spi_vscodec.c
  free() nut/crt/malloc.c

Global Function VsCodecIOCtl()

int VsCodecIOCtl ( NUTDEVICE* dev, int req, void* conf )
Prototyped in: nut/include/dev/vscodec.h
Calls: VsCodecLoadPlugIn() nut/dev/spi_vscodec.c
  VsCodecWriteWRam() nut/dev/spi_vscodec.c
  VsDecoderBufferInit() nut/dev/spi_vscodec.c
  NutEventPost(), NutSegBufAvailable(), NutSegBufUsed()
Called by: VsCodecOpen() nut/dev/spi_vscodec.c
  VsDecoderBufferFlush() nut/dev/spi_vscodec.c

Global Function VsCodecMode()

uint16_t VsCodecMode ( NUTDEVICE* dev, uint_fast16_t flags, uint_fast16_t mask )
Prototyped in: nut/include/dev/vscodec.h
Calls: VsCodecReg() nut/dev/spi_vscodec.c
Called by: VsCodecBeep() nut/dev/spi_vscodec.c

Global Function VsCodecOpen()

NUTFILE* VsCodecOpen ( NUTDEVICE* dev, const char* name, int mode, int acc )
Prototyped in: nut/include/dev/vscodec.h
Calls: VsCodecIOCtl() nut/dev/spi_vscodec.c
  malloc() nut/crt/malloc.c
  strcmp() nut/c/string/strcmp.c
  NutSegBufReset()

Global Function VsCodecRead()

int VsCodecRead ( NUTFILE* nfp, void* data, int len )
Prototyped in: nut/include/dev/vscodec.h
Calls: memcpy() nut/c/string/memcpy.c
  NutEventPost(), NutEventWait(), NutSegBufReadLast(), NutSegBufReadRequest()

Global Function VsCodecReg()

uint16_t VsCodecReg ( NUTDEVICE* dev, uint_fast8_t op, uint_fast8_t reg, uint_fast16_t val )
Prototyped in: nut/include/dev/vscodec.h
Calls: VsCodecWaitReady() nut/dev/spi_vscodec.c
Called by: FeederThread() nut/dev/spi_vscodec.c
  VsCodecLoadPlugIn() nut/dev/spi_vscodec.c
  VsCodecMode() nut/dev/spi_vscodec.c
  VsCodecWriteWRam() nut/dev/spi_vscodec.c
  VsDecoderSetVolume() nut/dev/spi_vscodec.c

Global Function VsCodecWaitReady()

int VsCodecWaitReady ( NUTDEVICE* dev, uint32_t tmo )
Prototyped in: nut/include/dev/vscodec.h
Calls: NutEventWait()
Called by: FeederThread() nut/dev/spi_vscodec.c
  VsCodecReg() nut/dev/spi_vscodec.c

Global Function VsCodecWrite()

int VsCodecWrite ( NUTFILE* nfp, const void* data, int len )
Prototyped in: nut/include/dev/vscodec.h
Calls: VsDecoderBufferFlush() nut/dev/spi_vscodec.c
  memcpy() nut/c/string/memcpy.c
  NutEventPost(), NutEventWait(), NutSegBufWriteLast(), NutSegBufWriteRequest()

Global Function VsCodecWrite_P()

int VsCodecWrite_P ( NUTFILE* nfp, const char* buffer, int len )
Prototyped in: nut/include/dev/vscodec.h

Global Function VsDecoderBufferInit()

int VsDecoderBufferInit ( NUTDEVICE* dev, uint32_t size )
Prototyped in: nut/include/dev/vscodec.h
Calls: NutSegBufAvailable(), NutSegBufInit()
Called by: VsCodecIOCtl() nut/dev/spi_vscodec.c

Global Function VsDecoderSetBass()

int VsDecoderSetBass ( NUTDEVICE* dev, int treb, int tfin, int bass, int bfin )
Prototyped in: nut/include/dev/vscodec.h
Called by: FeederThread() nut/dev/spi_vscodec.c

Global Function VsDecoderSetVolume()

int VsDecoderSetVolume ( NUTDEVICE* dev, int left, int right )
Prototyped in: nut/include/dev/vscodec.h
Calls: VsCodecReg() nut/dev/spi_vscodec.c
Called by: FeederThread() nut/dev/spi_vscodec.c

Local Function VsCodecLoadPlugIn()

static int VsCodecLoadPlugIn ( NUTDEVICE* dev, VS_PLUGIN_INFO* plg )
Calls: VsCodecReg() nut/dev/spi_vscodec.c
  NutSleep()
Called by: VsCodecIOCtl() nut/dev/spi_vscodec.c

Local Function VsCodecWriteWRam()

static int VsCodecWriteWRam ( NUTDEVICE* dev, VS_WRAM_DATA* vswd )
Calls: VsCodecReg() nut/dev/spi_vscodec.c
  NutSleep()
Called by: VsCodecIOCtl() nut/dev/spi_vscodec.c

Local Function VsDecoderBufferFlush()

static int VsDecoderBufferFlush ( NUTDEVICE* dev, uint32_t tmo )
Calls: VsCodecIOCtl() nut/dev/spi_vscodec.c
  NutEventWait(), NutSegBufUsed()
Called by: VsCodecClose() nut/dev/spi_vscodec.c
  VsCodecWrite() nut/dev/spi_vscodec.c