MityDSP Documentation Index
Public Member Functions | Static Public Attributes
MityDSP::tcDspTmp0506 Class Reference

Instances of this class handle access to the TMP05/06 temperature sensors. More...

#include <core/DspTmp0506.h>

Inheritance diagram for MityDSP::tcDspTmp0506:
MityDSP::tcDspRamBlock

List of all members.

Public Member Functions

 tcDspTmp0506 (void *apAddress, int anLevel=gnAutoLevel)
 This constructor is used to initialize a TMP05/06 device using the generic RAM Block interface.
 ~tcDspTmp0506 ()
 Default Destructor.
float getTemperature (void)
 This routine reads the 8 most recent temperature readings, averages them and computes a temperature (in deg-C).
- Public Member Functions inherited from MityDSP::tcDspRamBlock
 tcDspRamBlock (void *apAddress, int anLevel=gnAutoLevel)
 This constructor is used to create the base class functionality required for cores that adhere to the MityDSP RAM Block interface.
virtual ~tcDspRamBlock ()
 This destructor is used to close up and free tcDspRamBlock resources.
virtual bool isDirty (unsigned int anId)
 Determine whether a given input block is dirty.
virtual int getBlockWidth (void)
 Returns the width of the registers in the RAM block interface.
virtual void writeBlock (unsigned int anId, unsigned int anValue)
 Writes the value at the specified RAM Block ID.
virtual unsigned int readBlock (unsigned int anId)
 Reads the value at the specified RAM Block ID.
virtual void interruptEnable (bool abEnable)
 Enables or disables the Block Dirty interrupt.
virtual void registerIsrHandler (tfIsrCallback afCallback)
 Registers the user-supplied callback to be run whenever the Block Dirty interrupt occurs.
virtual void registerIsrHandler (tfIsrCallbackWithArg afCallback, void *apUserArg=NULL)
 Registers the user-supplied callback to be run whenever the Block Dirty interrupt occurs.

Static Public Attributes

static const int gnNumReadings = 8
- Static Public Attributes inherited from MityDSP::tcDspRamBlock
static const int gnNUM_RAM_BLOCKS = 16

Additional Inherited Members

- Public Types inherited from MityDSP::tcDspRamBlock
typedef void(* tfIsrCallback )(unsigned int, tcDspRamBlock *)
 prototype for the ISR callback
typedef void(* tfIsrCallbackWithArg )(unsigned int, tcDspRamBlock *, void *)
- Static Public Member Functions inherited from MityDSP::tcDspRamBlock
static int interrupt_dispatch (Arg arMyObject)
 Static interrupt dispatch routine.
- Public Attributes inherited from MityDSP::tcDspRamBlock
unsigned int mnInterruptCount
 ISR counter (debug).
- Protected Member Functions inherited from MityDSP::tcDspRamBlock
void blockDirtyInterrupt (void)
 Interrupt service routine for RAM Block-based cores.
- Protected Attributes inherited from MityDSP::tcDspRamBlock
SEM_Handle mhMutex
 Used to serialize access.
volatile unsigned int * mpBaseAddr
 Core base address.
unsigned short mnMyIntMask
 core interrupt mask
int mnMyIntLevel
 core interrupt level
int mnMyIntVector
 core interrupt vector
tfIsrCallback mfIsrCallback
 ISR callbacks.
tfIsrCallbackWithArg mfIsrCallbackWithArg
 ISR callback with user argument.
void * mpUserArg
 User-supplied callback parameter.
int mnBlockWidth
 RAM block data width (bytes)

Detailed Description

Instances of this class handle access to the TMP05/06 temperature sensors.

See also:
tcDspTmp0506 Page

Constructor & Destructor Documentation

tcDspTmp0506::tcDspTmp0506 ( void *  apAddress,
int  anLevel = gnAutoLevel 
)

This constructor is used to initialize a TMP05/06 device using the generic RAM Block interface.

Parameters:
[in]apAddress- Base Address of the TMP05/06 RAM Block interface
[in]anLevel- Optional interrupt level parameter
Returns:
None.
See also:
DspRamBlock.h
DspTmp0506.h
tcDspTmp0506::~tcDspTmp0506 ( )

Default Destructor.


Member Function Documentation

float tcDspTmp0506::getTemperature ( void  )

This routine reads the 8 most recent temperature readings, averages them and computes a temperature (in deg-C).

Returns:
Temperature in deg-C (-1000 if no readings available).
See also:
DspTmp0506.h

Member Data Documentation

const int MityDSP::tcDspTmp0506::gnNumReadings = 8
static

  
Generated on Mon Apr 22 2013 11:33:04 for MityDSP Core by  Doxygen Version 1.8.1.1
Copyright © 2009, Critical Link LLC, All rights reserved.