⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 am_hw_string_primitive.h

📁 Motorola synergy audio component
💻 H
字号:
#ifndef AM_HARDWARE_STRING_PRIMITIVE_CLASS#define AM_HARDWARE_STRING_PRIMITIVE_CLASS/* * (c) Copyright Motorola 1996, All rights reserved. * Motorola Confidential Proprietary. * Contains confidential proprietary information of Motorola, Inc. * Reverse engineering is prohibited. * The copyright notice does not imply publication. *//******************************* REVISION HISTORY ****************************** Date        Author      Reference Number========    ========    ================01-12-23    byr003      LIBbb15362 - LCA catchup for R1.2.1 01-04-30    brd007      CR - LIBbb09128                        put neptune changes in #if (NEPTUNE == TRUE)01-04-30    baf044      CR - CSGce94381            catchup for LCA (p2k baseline: PHX4US-G_P_3000.0E.07_IG7.11) 00-12-21    mtaraba     CSGce82934            main_comp_hardware.h within engine_audio vob should be removed00-08-09    mtaraba     CR - CSGce55882            Eliminate file gsm.h from audio manager00-05-15    cfarrel     PR - CSGce58264            Use API queue for CDMA, HAPI MDI queue for other MAs00-04-05    hchuang     PR - CSGce53807            Replace API queue with HAPI MDI queue98-10-14    mkloza      PR - CSGce22795            VA/VR Whitecap - Interrupt data transfer97-09-09    gdrumma     PR - CSGce12941            Clean up of Modulus2 Audio updates            - removed global string buffer variables and made them static to AM_HW_Primitive_Builder.            97-08-18    gdrumma     PR - CSGce11316            Audio Manager Support for Modulus2            - Added two parameters to constructor of AM_HW_String_Primitive to tell              which type of string, and what buffer to use.            - Added member for string type            - Added function prototype for stamp_time() which manages the string's              timestamp counter            - Added 'timestamp' member which keeps track of the modulo 256 counter              used in sending messages to the DSP.            - Updated to coding standard.97-03-19    gdrumma     PR - CSGce09178            Add Warm Plug Codec support            - Added method 'set_disable_codec' to set bit in the status              register of the HW String Primitive.********************************************************************************//************** HEADER FILE INCLUDES ******************************************/#include <SUAPI/suapi.h>#include <stddef.h>#include <ENGINE_AUDIO/audio_conditional_compile_def.h>#include "am_hw_primitive_builder_tone.h"#include "am_hw_primitive_builder_gains.h"#include <ENGINE_AUDIO/am_hw_string_primitive.h>#include <ENGINE_HAPI/hapi_mdi_queue.h>          /************** GLOBAL VARIABLES **********************************************//************** CONSTANTS *****************************************************//************** STRUCTURES, ENUMS, AND TYPEDEFS *******************************//************** FUNCTION PROTOTYPES *******************************************//************** MACROS ********************************************************//************** CLASS DEFINITIONS *********************************************/class AM_HW_String_Primitive{public:     /*      * overload new and delete functions.     */    inline void * operator new(size_t) { return((void *) NULL); }    inline void operator delete(void *, size_t) {}    /*      * class Constructor      */    AM_HW_String_Primitive (AM_HW_STRING_TYPE string_type, UINT8 *buffer);    /*      * class destructor, do nothing, but prevents allocation of __Ptbl in      * everyfile that includes this .H file.     */    ~AM_HW_String_Primitive (void) {};    /*      * send a string primitive to speech coder manager.      */    void    send ( void );    /*     * operator to reserver enough memory in String primitive buffer.     * Syntax: << length.     * Note: there is no need to reserve memory if the req is less than 2 bytes.     */    AM_HW_String_Primitive&    operator <<     (     /* The length of data will be appended to string primitive buffer (in bytes). */     UINT8 length     );    /*      * operator to append a byte to string primitive buffer.      */    AM_HW_String_Primitive&    operator +     (     /* The byte will be added to string primitive buffer. */      UINT8 data     );    /*      * operator to append a word to string primitive buffer.      */    AM_HW_String_Primitive&    operator +     (     /* The word will be added to string primitive buffer. */     UINT16 data     );     /*      * operator to append a word to string primitive buffer.      */    AM_HW_String_Primitive&    operator +     (     /* The word will be added to string primitive buffer. */     INT16 data     );     /*      * operator to append an AM_HW_TONE_DATA data to string primitive buffer.      * Note: need to use << to reserve enough memory in the buffer.      */    AM_HW_String_Primitive&    operator +     (     /* The address of the data will be appended to string primitive. */     AM_HW_TONE_DEF *tone_ptr     );     /*     * Function to calculate and maintain time stamp for messages sent to the DSP      */         UINT8    stamp_time(void);#if (MAKE_NEPTUNE_CHIPSET == TRUE)/* moved from private for LCA debug */    UINT8 *am_hw_string_primitive_buffer; #endif    private:        /*     * function to check buffer over flow, if it will overflow with now data, flush it.      */    void    flush_buffer    (     /* The length of the data (in bytes) will to be added to buffer. */     UINT8 length     );#if (MAKE_NEPTUNE_CHIPSET == FALSE)    /* buffer used to hold all speech coder requests. */    UINT8 *am_hw_string_primitive_buffer;#endif    /* point to next available word in the local buffer. */    UINT8 *am_hw_string_primitive_buffer_pos_ptr;    /* queue type */    MDI_QUEUE_SELECT queue_type;    /* Whitecap API queue size */    UINT8 queue_size;        /* Timestamp counter */    static UINT8 timestamp;};#endif // end of AM_HARDWARE_STRING_PRIMITIVE_CLASS definition

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -