# Mcbsp_ChannelObj_t Struct Reference

Mcbsp channel Object. More...

`#include <mcbsp_pvt.h>`

## Data Fields

uint16_t | mode
Mcbsp_DriverState | chanState
Mcbsp_Object * | devHandle
Mcbsp_CallbackFxn | cbFxn
void * | cbArg
void * | edmaHandle
uint32_t | edmaEventQue
EDMA3_RM_TccCallback | edmaCallback
uint32_t | xferChan
uint32_t | tcc
uint32_t | pramTbl [Mcbsp_MAXLINKCNT]
uint32_t | pramTblAddr [Mcbsp_MAXLINKCNT]
void * | ptrQPendList
void * | ptrQFloatList
Mcbsp_IOBuf * | tempIOBuf
Mcbsp_IOBuf * | dataIOBuf
uint32_t | submitCount
Mcbsp_BufferFormat | dataFormat
Bool | nextFlag
volatile Bool | bMuteON
volatile Bool | paused
volatile Bool | flush
volatile Bool | isTempIOBufValid
Bool | enableHwFifo
Mcbsp_GblErrCallback | gblErrCbk
uint32_t | userDataBufferSize
void * | loopJobBuffer
uint16_t | loopJobLength
uint32_t | userLoopJobLength
uint32_t | nextLinkParamSetToBeUpdated
volatile Bool | loopjobUpdatedinParamset
uint16_t | roundedWordWidth
uint16_t | currentDataSize
Mcbsp_DataConfig | chanConfig
Mcbsp_ClkSetup | clkSetup
Mcbsp_McrSetup | multiChanCtrl
uint32_t | chanEnableMask [4]
Bool | userLoopJob
int32_t | currentError

## Detailed Description

Mcbsp channel Object.

This structure maintains the current channel state. It also holds information on DMA channel being used and holds the application callback function to be called in case of an interrupt.

This structure is initialized by mdCreateChan and a pointer to this is passed down to all other channel related functions. Lifetime of the data structure is from its creation by mdCreateChan till it is invalidated by mdDeleteChan.each instance object will have two channel object one for TX and one for the RX channel.

## Field Documentation

volatile Bool Mcbsp_ChannelObj_t::bMuteON

Flag to set the mute ON/OFF status

void* Mcbsp_ChannelObj_t::cbArg

Callback Function argument

Mcbsp_CallbackFxn Mcbsp_ChannelObj_t::cbFxn

Driver call back function to be called once a I/O buffer is processed

Mcbsp_DataConfig Mcbsp_ChannelObj_t::chanConfig

settings to configure the TX or RX hardware sections

uint32_t Mcbsp_ChannelObj_t::chanEnableMask[4]

Mask of the channels to be enabled or disabled

Mcbsp_DriverState Mcbsp_ChannelObj_t::chanState

operational state of the channel (opened/closed)

Mcbsp_ClkSetup Mcbsp_ChannelObj_t::clkSetup

clock setup for the RX or the TX section

uint16_t Mcbsp_ChannelObj_t::currentDataSize

data buffer size of the currently transferring buffer

int32_t Mcbsp_ChannelObj_t::currentError

Current I/O buffer error status

Mcbsp_BufferFormat Mcbsp_ChannelObj_t::dataFormat

Application supplied buffer format

Mcbsp_IOBuf* Mcbsp_ChannelObj_t::dataIOBuf

Temporary I/O buffer holder used to load the next buffer in to EDMA

Mcbsp_Object* Mcbsp_ChannelObj_t::devHandle

Pointer to McBSP device driver instance object

EDMA3_RM_TccCallback Mcbsp_ChannelObj_t::edmaCallback

Edma callback function pointer

uint32_t Mcbsp_ChannelObj_t::edmaEventQue

EDMA event queue to be used by the channel

void* Mcbsp_ChannelObj_t::edmaHandle

Handle to the EDMA3 driver(given by application)

Bool Mcbsp_ChannelObj_t::enableHwFifo

whether the FIFO has to be enabled for this channel

volatile Bool Mcbsp_ChannelObj_t::flush

Flag to indicate if the Driver IO request flush is set

Mcbsp_GblErrCallback Mcbsp_ChannelObj_t::gblErrCbk

Callback to called in case an error occurs(supplied by application)

volatile Bool Mcbsp_ChannelObj_t::isTempIOBufValid

Flag to indicate whether a valid buffer is available in tempIOBuf

void* Mcbsp_ChannelObj_t::loopJobBuffer

Buffer to be transferred when the loop job is running

uint16_t Mcbsp_ChannelObj_t::loopJobLength

Length of userloop job for each serialiser

volatile Bool Mcbsp_ChannelObj_t::loopjobUpdatedinParamset

Used to prevent updating second paramset with loopjob for * last dataIOBuf edma callback

uint16_t Mcbsp_ChannelObj_t::mode

Mode of operation of the channel (MCBSP_MODE_INPUT or MCBSP_MODE_OUTPUT)

Mcbsp_McrSetup Mcbsp_ChannelObj_t::multiChanCtrl

multiple channel control settings

Bool Mcbsp_ChannelObj_t::nextFlag

Flag to indicate if the state machine can be stopped or not

uint32_t Mcbsp_ChannelObj_t::nextLinkParamSetToBeUpdated

Used to store the next index of link param to be updated

volatile Bool Mcbsp_ChannelObj_t::paused

Flag to indicate if the audio is paused or not

uint32_t Mcbsp_ChannelObj_t::pramTbl[Mcbsp_MAXLINKCNT]

Logical channel numbers of EDMA, which are used for linking

uint32_t Mcbsp_ChannelObj_t::pramTblAddr[Mcbsp_MAXLINKCNT]

Physical address of logical channel numbers of EDMA, which * are used for linking

void* Mcbsp_ChannelObj_t::ptrQFloatList

Queue to manage floating I/O buffers in DMA

void* Mcbsp_ChannelObj_t::ptrQPendList

Queue to hold the pending I/O buffers received from the application

uint16_t Mcbsp_ChannelObj_t::roundedWordWidth

Word length bytes to be transferred for DMA transaction

uint32_t Mcbsp_ChannelObj_t::submitCount

Number of submit calls pending in the driver

uint32_t Mcbsp_ChannelObj_t::tcc

EDMA transfer completion code

Mcbsp_IOBuf* Mcbsp_ChannelObj_t::tempIOBuf

Temporary I/O buffer holder

uint32_t Mcbsp_ChannelObj_t::userDataBufferSize

Size of the data buffer to be transferred

Bool Mcbsp_ChannelObj_t::userLoopJob

Option to indicate if the user loop job is used or driver loop job

uint32_t Mcbsp_ChannelObj_t::userLoopJobLength

user specified loop job length to be used if supplied

uint32_t Mcbsp_ChannelObj_t::xferChan

eDMA ChannelID

The documentation for this struct was generated from the following file:

- mcbsp_pvt.h

Copyright 2012, Texas Instruments Incorporated