Home

Embedded SDK (Software Development Kit)

image

Contents

1. cwregs RW ORIGIN 0x0030 LENGTH 0x0010 C temp registrs in CodeWarrior iml1 RW ORIGIN 0x0040 LENGTH 0x07CO data 1 rom R ORIGIN 0x0800 LENGTH 0x0800 internal data ROM im2 RW ORIGIN 0x1000 LENGTH 0x0600 data 2 hole R ORIGIN 0x1600 LENGTH 0x0A00 hole data RW ORIGIN 0x2000 LENGTH 0xC000 data segment em RW ORIGIN OxE000 LENGTH 0x1000 data 3 stack RW ORIGIN OxF000 LENGTH Ox0F80 stack onchip1 RW ORIGIN OxFF80 LENGTH 0x0040 on chip peripheral register onchip2 RW ORIGIN OxFFCO LENGTH 0x0040 on chip peripheral registers V 8bis specific memory regions V8bis_align_ext_data RW ORIGIN 0x4000 LENGTH 0x0600 FORCE_ACTIVE FconfigInterruptVector SECTIONS Data X Memory Layout _EX_BIT 0 Internal Memory Partitions for mem h partitions _NUM_IM PARTITIONS 2 iml and im2 External Memory Partition for mem h partitions _NUM_EM PARTITIONS 1 em main_application_code text sections config c MUST be placed first otherwise the Interrupt Vector configInterruptVector will not be located at the correct address P 0x0000 config c text text rtlib text fp_engine text user text gt pram main_application_data
2. Define variables for C initialization code F_Xdata_start_addr_in_ROM ADDR rom SIZEOF rom 2 F_StackAddr ADDR stack F_StackEndAddr ADDR stack SIZEOF stack 2 1 F_Xdata_start_addr_in_RAM 5 2 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 V 8bis Library Memory layout data for SDK INCLUDE_MEMORY mem h support FmemEXbit WRITEH _EX_BIT FmemNumIMpartitions WR T TEH _NUM_IM_ PARTITIONS FmemNumEMpartitions WRITEH _NUM_EM PARTITIONS FmemIMpartitionList WRITEH ADDR im1 1 WRITEH SIZEOF im1 2 WRITEH ADDR im2 WRITEH SIZEOF im2 2 FmemEMpartitionList WR T TEH ADDR em WRITEH SIZEOF em 2 data sections data fp_state data rtlib data V8bis data sections start here v21_xrom data dtmf_rom data ALIGN 64 v21_mod_ram data ALIGN 256 v21_proml data ALIGN 512 v21_prom2 data V8bis data sections end here F_Xdata_ROMtoRAM_length 0 F_bss_start_addr _BSS_ADDR rtlib bss lo bss V8bis bss sections start here ToneGen_Common_Variable bss V8BIS_IS_RS_INIT bss
3. HOST bss ALIGN 32 ToneDet_Common_Variable bss V8bis bss sections end here F_bss_length _BSS_ADDR Copy DATA gt data FArchIO ADDR onchip2 MOTOROLA Linking Applications with the V 8bis Library 5 3 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Linking Applications with Freescale Semiconductor Inc 5 4 ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 V8bis data section starts here This section cannot be included in data region since inclusion leads to memory overlap This could be a tool bug V8bis_align_ext_data ALIGN 512 V8bis_Codec data gt V8bis_align_ext_data V8bis data section ends here T V 8bis Library For More Information On This Product Go to www freescale com MOTOROLA ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Chapter 6 V 8bis Applications 6 1 Test and Demo Applications To verify the V 8bis algorithm test and demo applications have been developed Refer to the Targeting Motorola DSP568xx Platform manual for the DSP you are using to see if the test and demo applications are available for your target MOTOROLA V 8bis Applications 6 1 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 V 8bis
4. Element Format number in the Content i Information bit input buffer x Don t care 5 N M 4 Number of words in the priorities list 0000 0000 iiii iiii Example P P N 1 8 for initiating station and P M 1 8 for responding station 54 N M 5 First word in the priorities list 0000 0000 iiii iiii 54 N M 6 54 N M P 4 Last word in the priorities list 0000 0000 iiii iii Any number of zeros required can be entered 0000 0000 0000 0000 Figure A 1 Input Buffer Format for V 8bis The host message type and data are shown in Table A 1 Table A 1 Host Message Types and Data MESSAGE TYPE DATA V8BIS_NIL_RX_HOST_MESSAGE 0000 NULL V8BIS_CONFIGURATION_MESSAGE 0001 Host Configuration word from Table V8BIS_CAPABILITIES_MESSAGE 0002 As shown in Table A 11 V8BIS_PRIORITIES_MESSAGE 0003 As shown in Table A 12 V8BIS_REMOTE_CAPABILITIES_MESSAGE 0004 As shown in Table A 11 V8BIS_TX_GAIN_FACTOR_MESSAGE 0007 gain 0 1 A 1 2 Host Config word The host config word allows the user to configure certain parameters It is a 16 bit word bit pattern and the function of each bit are shown in Figure A 2 15 14 13 12 x x1x les Rev No LN RK LK Rv aal T TA RC LC RC X Reserved Bits Figure A 2 Configuration Word A 2 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com I ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Fre
5. i UInt16 j Result res v8bis_sConfigure pConfig Configuration structure v8bis_sHandle pV8bis Handle structure UWord16 InputIS See Appendix A for filling this buffer WriteOutput MS Structure for writing the v8bis output mode selected S offset 0 Initialize pConfig pConfig Station V8BIS_INIT_STATION pConfig MessagePtr amp InputIS testcase_no 0 pConfig TXCallback pCallback ISCallbackTx pConfig TXCallback pCallbackArg NULL NULL because user has to just transmit the samples given by v8bis by writing into the codec pConfig RXCallback pCallback ISCallbackRx MOTOROLA V 8bis Library Interfaces 3 13 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 vVi bis Library Interfaces Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 pConfig RXCallback pCallbackArg WriteOutput amp MS Mode selected is provided by v8bis which has to be used by the user for further processing Call APIs pV8bis v8bisCreate amp pConfig Create an instance of V 8bis v8bisInit pV8bis amp pConfig V8bis Initialization Process the received samples until the transaction is complete passed or failed while res V8BIS_BUSY Collect NUMRX_SAMPLES number of samples from the codec into CodecRxBuffer b
6. ID Identification Ss SI Standard Information field EM SI For details refer to Section 8 of the V 8bis Standard Revision 1996 E A 1 4 Setting Up Priorities List Priorities are mentioned in a matrix Normally 8 octets describe the priorities of a single octet in the capa bilities list There is no corresponding priority matrix for the Revision Number and Message type The first entry of the capabilities list should shown the number of octets Table A 12 shows an example priority for the SPAR1 of the SI field FRE N L B ED HIN 1 i 9 Table A 12 Priority List 0040 Hex Number of words excluding this word 0001 1st bit is the top priority DATA application 0020 6th bit is the second priority Analog Telephony 0000 No other Priorities 0000 No other Priorities 0000 No other Priorities 0000 No other Priorities 63rd word 0000 No other Priorities 64th word MOTOROLA Guidelines for Setting Up the Input Buffer A 5 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Afr i ARG C A 2 Output from V 8bis The V 8 bis software returns the negotiated mode of communication to the user as output This will have certain octets the first octet will be any specified in Table A 13 Table A 13 Output Message Type and Data M
7. License Motorola does not represent or warrant that the Software is free of infringement of any third party patents copyrights trade secrets or other intellectual property rights or that Motorola has the right to grant the licenses contained herein Motorola does not represent or warrant that the Software is free of defect or that it meets any particular requirements or need of the Licensee or that it conforms to any documentation or that it meets any standards Motorola shall not be responsible to maintain the Software provide upgrades to the Software or provide any field service of the Software Motorola reserves the right to make changes to the Software without further notice to Licensee The Software is not designed intended or authorized for use as components in systems intended for surgical implant into the body or other applications intended to support or sustain life or for any other application in which the failure of the Software could create a situation where personal injury or death may occur Should Licensee purchase or use the Software for any such unintended or unauthorized application Licensee shall indemnify and hold Motorola and its officers employees subsidiaries affiliates and distributors harmless against all claims costs damages and expenses and reasonable attorney fees arising out of directly or indirectly any claim of personal injury or death associated with such unintended or unauthorized use even if suc
8. v8bisCreate v 8bisInit v8bisProcess The user needs to call this module whenever there are samples to be transmitted or when samples received are to be processed v8bisDestroy 5 1 1 Library Sections The internal data memory requirement for V 8bis is zero The external data memory sections for V 8bis are found in the example at the end of this section Note All sections are grouped together for placing in different memory regions on the target The memory regions and the sections under each region that follow are for reference The ORIGIN and LENGTH fields of the memory regions can be changed by the user application but ensure that the regions do not overlap An example linker cmd file is shown in Code Example 5 1 Code Example 5 1 linker cmd File Linker cmd file for DSP56824EVM External RAM using both internal and external data memory EX 0 and using external program memory Mode 3 MEMORY pram RWX ORIGIN 0x0000 LENGTH OxFF80 external program memory avail RW ORIGIN 0x0000 LENGTH 0x0030 available MOTOROLA Linking Applications with the V 8bis Library 5 1 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Linking Applications with Fressscale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005
9. 0 055044 n6dd5654 RR RRR A RR R se of vebisDestroy Interiate 2 6400 esxsceeveeednsaes cdvases EE ahh hh as cat Gr Rew ZE as Gh hare Ws wed Se List of Examples For More Information On This Product Go to www freescale com vii Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 viii Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 V 8bis Library For More Information On This Product Go to www freescale com MOTOROLA ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 About This Document This manual describes the V 8bis telecommunication algorithm for use with Motorola s Embedded Software Development Kit SDK Audience This document targets software developers implementing communications primarily modem functions within software applications Organization This manual is arranged in the following sections Chapter 1 Introduction provides a brief overview of this document Chapter 2 Directory Structure provides a description of the required core directories Chapter 3 V 8bis Library Interfaces describes all of the V 8bis Library functions Chapter 4 Building the V 8bis Library tells how to execute the system library project build Chapter 5 Linking Applications with the V 8bis Library describes the organization of the V 8bis Library Chapter 6 V 8bis Applications d
10. Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 List of Figures Figure 2 1 Figure 2 2 Figure 2 3 Figure 4 1 Figure 4 2 Figure 4 3 Figure A 1 Figure A 2 MOTOROLA Core Direcciones 6645654 be bbe beh es kai eadi ki beeen ieee us ee iE aa eee Ki TRET IIS gf sh oh ho eke eee bees e eee Dependency Build for vobis Projet icsiaarisadasacciacacarivaases WOO VI e bee cncanakesdngeuseedeuneeenacdessessxeaanes p IN os E 0b POKES HD SERA EEAES AEN DEH Oe ERROR ORE MAE EOS Input Buffer Pa Yat oe boas kw seen T A RE RR AE KA TRT Or 0 oe 54 6906 R K R RRR d RE RER EFE ETE List of Figures For More Information On This Product Go to www freescale com Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 vi Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 V 8bis Library For More Information On This Product Go to www freescale com MOTOROLA ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 List of Examples Code Example Code Example Code Example Code Example Code Example Code Example Code Example MOTOROLA 3 1 3 2 3 3 3 4 3 5 3 6 5 1 C Header File VIG 6 40435 02a eek edo R AA RL KRA KA seed mom E hho he 8 oe ohh eee bese Use of vSbisCreste ACE ok 2h ce ERG eee he eeew eens Use of Vibislnit eres chs i eds ence cneeanieannsda AKA AA N Lise of v8bisProcess Interface
11. export re export resell ship or divert or cause to be exported re exported resold shipped or diverted directly or indirectly the Software or a direct product thereof to any country which the United States government or any agency thereof at the time of export or re export requires an export license or other government approval without first obtaining such license or approval MOTOROLA License 7 1 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 THE SOFTWARE IS PROVIDED ON AN AS IS BASIS AND WITHOUT WARRANTY OF ANY KIND INCLUDING WITHOUT LIMITATION ANY WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE IN NO EVENT SHALL MOTOROLA BE LIABLE FOR ANY LIABILITY OR DAMAGES OF ANY KIND INCLUDING WITHOUT LIMITATION DIRECT OR INDIRECT OR INCIDENTAL OR CONSEQUENTIAL OR PUNITIVE DAMAGES OR LOST PROFITS OR LOSS OF USE ARISING FROM USE OF THE SOFTWARE OR THE PRODUCT REGARDLESS OF THE FORM OF ACTION OR THEORY OF LIABILITY INCLUDING WITHOUT LIMITATION ACTION IN CONTRACT NEGLIGENCE OR PRODUCT LIABILITY EVEN IF MOTOROLA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE THIS DISCLAIMER OF WARRANTY EXTENDS TO LICENSEE OR USERS OF PRODUCTS AND IS IN LIEU OF ALL WARRANTIES WHETHER EXPRESS IMPLIED OR STATUTORY INCLUDING IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR PARTICULAR PURPOSE
12. library services is defined in the C header file v8bis h shown in Code Example 3 1 Code Example 3 1 C Header File v8bis h File v8bis h ifndef __V8bis_H define __V8bis_H This include file is the master include file for the V8bis protocol The applications using v8bis should include this file A S EEEE KKK KK KKK k K k I k kk KK KKK Foundational Include Files XXX KKK KKK J include port h MOTOROLA V 8bis Library Interfaces 3 1 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Vae Library Infertaces Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 BRK KKK k k k k KKK k k k k k k k k k k k k Flags KAKAA A AA KKK KKK KKK K These are the flags returned by v8bisProcess function Please refer Sec 3 1 1 1 3 of the V 8bis Library user manual for more details XI define V8BIS_ BUSY 0 define V8BIS_FREE 1 BK KKK KKK KKK KK A k K IK k k k k k eH k k k k k V8bis Message Types Fe KARA kkk ee kkk kkk kkk kkk kkk kkk kk S These are the inputs the user has to use during the setting up of the V 8bis input buffer Please refer to 1 Appendix of the V 8bis Library User Manual Sec A 1 ka 2 The test files of V 8bis test_v8bisIS c and test_v8bisRS c define V8BIS_NIL RX HOST MESSAGE 0x0000
13. 8bis library Please s the test files test_v8bisIS c and test_v8bisRS c for more details ay typedef struct v8bis_eStation Station Station type UWord1l6 MessagePtr Input buffer pointer to V 8bis v8bis_sTXCallback TXCallback Tx Callback structure v8bis_sRXCallback RXCallback Rx Callback structure v8bis_sConfigure V8bis handle structure This is strictly for V 8bis internal use only Ay typedef struct Word1l6 Output v8bis_eStation Station UWord16 MessagePtr v8bis_sTXCallback TXCallback v8bis_sRXCallback RXCallback v8bis_sHandle S EE KK K K k k RRR KKK k k k k k k KKK Function Prototypes Fe KAKA A A KKK EXPORT v8bis_sHandle v8bisCreate v8bis_sConfigure pConfig EXPORT Result v8bisInit v8bis_sHandle pV8bis v8bis_sConfigure pConfig EXPORT Result v8bisProcess v8bis_sHandle pV8bis Word1l6 pSamples UWord16 NumSamples EXPORT void v8bisDestroy v8bis_sHandle pV8bis endif 3 4 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 3 3 Specifications The following pages describe the V 8bis library functions Specifications Function arguments for each routine are described as in out or
14. Applications Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 V 8bis Library For More Information On This Product Go to www freescale com MOTOROLA ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Chapter 7 License 7 1 Limited Use License Agreement LIMITED USE LICENSE AGREEMENT PLEASE READ THIS AGREEMENT CAREFULLY BEFORE USING THIS SOFTWARE BY USING OR COPYING THE SOFTWARE YOU AGREE TO THE TERMS OF THIS AGREEMENT The software in either source code form Source or object code form Object cumulatively hereinafter Software is provided under a license agreement Agreement as described herein Any use of the Software including copying modifying or installing the Software so that it is usable by or accessible by a central processing unit constitutes acceptance of the terms of the Agreement by the person or persons making such use or if employed the employer thereof Licensee and if employed the person s making such use hereby warrants that they have the authority of their employer to enter this license agreement If Licensee does not agree with and accept the terms of this Agreement Licensee must return or destroy any media containing the Software or materials related thereto and destroy all copies of the Software The Software is licensed to Licensee by Motorola Incorporated Motorola for use under the
15. Config RXCallback pCallbackArg WriteOutput amp MS Mode selected is provided by v8bis which has to be used by the user for further processing pV8bis v8bisCreate amp pConfig Create an instance of V 8bis For details on structures used in the above example see Code Example 3 1 3 8 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 3 3 2 v8bisInit Call s Specifications Result v8bisInit v8bis_sHandle pV8bis v8bis_sConfigure pConfig Required Header v8bis h Arguments Table 3 2 v8bisinit Arguments pV8bis in Handle to an instance of V 8bis pConfig in A pointer to a data structure containing data for initializing the V 8bis algorithm Description The vSbis nit function will initialize the V 8bis algorithm During initialization all resources will be set to their initial values in preparation for V 8bis operation Before calling the v8bis nit function a V 8bis instance must be created The V 8bis instance pVSbis can be created either by calling the v8bisCreate function see Section 3 3 1 or by statically allocating memory which does not require a call to the vSbisCreate function The parameter pConfig points to a data structure of type v8bis_sConfigure its fields initialize V 8bis operation in the fo
16. Configuration structure v8bis_sHandle pV8bis Handle structure UWord16 InputIS See Appendix A for filling this buffer WriteOutput MS Structure for writing the v8bis output mode selected S offset 0 Initialize pConfig MOTOROLA V 8bis Library Interfaces 3 11 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 VRS Library Infertaces Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 pConfig Station V8BIS_INIT_STATION pConfig MessagePtr amp InputIS testcase_no 0 pConfig TXCallback pCallback ISCallbackTx pConfig TXCallback pCallbackArg NULL NULL because user has to just transmit the samples given by v8bis by writing into the codec pConfig RXCallback pCallback ISCallbackRx pConfig RXCallback pCallbackArg WriteOutput amp MS Mode selected is provided by v8bis which has to be used by the user for further processing Call APIs pV8bis v8bisCreate amp pConfig Create an instance of V 8bis v8bisInit pV8bis amp pConfig V8bis Initialization Process the received samples until the transaction is complete passed or failed while res V8BIS_BUSY Collect NUMRX_SAMPLES number of samples from the codec into CodecRxBuffer buffer Process the received samp
17. ESSAGE TYPE DATA V8BIS_NIL_TX_HOST_MESSAGE 0000 NULL V8BIS_ACK_MESSAGE 0001 NULL V8BIS_ERROR_MESSAGE 0002 error_id see Table A 14 V8BIS_SUCCESS_INITIATE_HANDSHAKE 0003 The data will be the common mode of agreement This message type means that V 8bis is success ful asking the user to initiate the application o handshake S V8BIS_SUCCESS_LOOK_FOR_HANDSHAK 0004 The data will be the common mode of agreement g E This message type means that V 8bis is success 3 ful asking the user to look for the application handshake P Table A 14 Error Ids a Error_id O V8BIS_NIL_ID 0000 V8BIS_MODE_NOT_SUPPORTED 0001 V8BIS_RECEIVED_INVALID_MSG 0002 V8BIS_RECEIVED_NAK1_MSG 0003 ul V8BIS_TIMED_OUT 0004 ce V8BIS_TRANSACTION_BEGUN 0005 an V8BIS_INVALID_ MSG_FORMAT 0006 Ti V8BIS_RECEIVED_NAK2_Or_3_MSG 0007 A 6 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Index ACK x CL x CLR x CR x D DSP xi DSP56800 Family Manual xi DSP56824 User s Manual xi DTE xi E Embedded SDK Programmer s Guide xi F FCS xi l T O xi T O Services 3 1 5 1 IDE xi Input Buffer A 1 L LSB xi M MAC xi MIPS xi MS xi MSB xi NAK xi OMR xi OnCE xi P PC xi PSTN xi 1 1 MOTOROLA SD
18. Freescale Semiconductor Inc Q MOTOROLA Embedded SDK Software Development Kit V 8bis Library DK120 D Rev 2 07 23 2002 ato VN MOTOROLA nt Motorola Inc 2002 All rights reserved intelligence everywhere 9 digital dna For More Information On This Product o to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Contents About This Document ol ETE E ee ee eee ee ee eee eee eee ee ee ee ee ee ix DEA E e E E O E E E 59 ix KE T Redi ercosiprsipostenir bireti de eae ceeds baedee cieaadad ix Oe TTT x Definitions Acronyms and Abbreviations sd X OOG E 05 06 E E aE T E HR ET EEE TENET xi Chapter 1 Introduction 1 1 IC Be be ohn E EE E E E TEE E E E E E EE 1 1 12 RVR TIC OF V Goya 55 65s sh oe oe eee eee es 1 1 1 2 1 Sa Le ae CIs EE R S E EE E EE E EE E E T EN 1 2 122 Features and PS ch beh kG we L bs hws OER Heh SS hts eas os 1 2 Chapter 2 Directory Structure 2l Required Core Directories A 6 9 X K 9 K K R T KA ER RR i igesik RRR KR 2 1 2 2 Optional Domain Specific Directories sees 2 2 Chapter 3 V 8bis Library Interfaces 3 1 K T cl See T A E E E E A E EEE E NE E E 3 1 3 2 Ye NC ae ee re ee era ee rr er
19. K xi SP xi SPI xi SR xi SRC xi V V 8bis 1 1 V 8bis Applications 6 1 V 8bis Services 3 1 V8bis bss sections 5 3 V8bis data sections 5 3 V8bis_align_ext_data 5 2 5 4 v8bisCreate 3 6 v8bisDestroy 3 13 v8bisInit 3 9 v8bisProcess 3 11 Index For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Motorola reserves the right to make changes without further notice to any products herein Motorola makes no warranty representation or guarantee regarding the suitability of its products for any particular purpose nor does Motorola assume any liability arising out of the application or use of any product or circuit and specifically disclaims any and all liability including without limitation consequential or incidental damages Typical parameters which may be provided in Motorola data sheets and or specifications can and do vary in different applications and actual performance may vary over time All operating parameters including Typicals must be validated for each customer application by customer s technical experts Motorola does not convey any license under its patent rights nor the rights of others Motorola products are not designed intended or authorized for use as components in systems intended for surgical implant into the body or other applications intended to support or sus
20. Ps This document describes the V 8bis Library which is a part of Motorola s comprehensive Software Development Kit SDK for its DSPs In this document you will find all the information required to use and maintain the V 8bis Library interface and algorithms Motorola provides these algorithms to you for use with Motorola DSPs to expedite your application development and reduce the time it takes to bring your own products to market Motorola s V 8bis Library is licensed for your use on Motorola processors Please refer to the standard Software License Agreement in Chapter 7 for license terms and conditions please consult with your Motorola representative for premium product licensing 1 1 Quick Start Motorola s Embedded SDK is targeted to a large variety of hardware platforms To take full advantage of a particular hardware platform use Quick Start from the Targeting DSP568xx Platform documentation For example the Targeting DSP56824 Platform manual provides more specific information and examples about this hardware architecture If you are developing an application for the DSP56824EVM board or any other DSP56824 development system refer to the Targeting DSP56824 Platform manual for Quick Start or other DSP56824 specific information 1 2 Overview of V 8bis The V 8bis allows DCEs and DTEs with multiple modes of operation over the PSTN and on leased tele phone type circuits to perform these functions e selection of the desired m
21. SAGE 0x0002 define V8BIS_SUCCESS_INITIATE_HANDSHAKE 0x0003 define V8BIS_SUCCESS_LOOK_FOR_HANDSHAKE 0x0004 These are the possible types of errors that the V 8bis library can return to the host following the V8BIS_ERROR_MESSAGE message as defined above The host has to take appropriate action as per the error k define V8BIS_NIL_ID 0x0000 define V8BIS_MODE_NOT_SUPPORTED 0x0001 define V8BIS_RECEIVED_INVALID_MSG 0x0002 define V8BIS_RECEIVED_NAK1_MSG 0x0003 define V8BIS_TIMED_OUT 0x0004 define V8BIS_TRANSACTION_BEGUN 0x0005 define V8BIS_INVALID_MSG_FORMAT 0x0006 define V8BIS_RECEIVED_NAK2_Or_3_ MSG 0x0007 BKK KKK KK KK A A KKK K k k k k k k k k k HH k k k Structure for V8bis Capability List KARA A A ee AAA A He He HH IH I Receiver callback structure typedef struct void pCallback void pCallbackArg Wordl6 pChars UWord16 NumberChars void pCallbackArg v8bis_sRXCallback Transmitter callback structure typedef struct void pCallback void pCallbackArg Word1l6 pSamples UWord16 NumberSamples void pCallbackArg v8bis_sTXCallback MOTOROLA V 8bis Library Interfaces 3 3 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Vae Library Infertaces Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 User configurable structure This is the format in which the user can pass the parameters to V
22. Technical Information Center 1 800 521 6274 HOME PAGE http www motorola com semiconductors MOTOROLA S For More Information On This Product Go to www freescale com
23. The format is shown in Figure A 1 Also see the test files test_v8bisIS c and test_v8bisRS c To find these files go to modem v8bis test_v8bis c_sources and the InputIS and InputRS buffers in these files Element Format number in the Content i Information bit input buffer x Don t care 0 V8BIS_CONFIGURATION_MESSAGE See Table A 1 1 The host config word XXXI iili jiii tii 2 V8BIS_TX_GAIN_FACTOR_MESSAGE See Table A 1 3 The gain value jiii jiii iii tii 1 15 format 4 V8BIS_CAPABILITIES_ MESSAGE See Table A 1 5 No of words in the local capabilities list say N 0000 0000 000i iiii 6 First word in local capabilities list 0000 0000 iiii iiii 7 Second word in local capabilities list 0000 0000 iiii iiii 8 5 N Last word in local capabilities list 0000 0000 iiii iiii 5 N 1 V8BIS_REMOTE_CAPABILITIES_MESSAGE See Table A 1 5 N 2 Number of words in the remote capabilities list say M 0000 0000 000i iiii 54 N 3 First word in remote capabilities list 0000 0000 iiii iiii 5 N 4 5 N M 2 Last word in remote capabilities list 0000 0000 iii iiii 54 N M 3 V8BIS_PRIORITIES_ MESSAGE See Table A 1 MOTOROLA Guidelines for Setting Up the Input Buffer For More Information On This Product Go to www freescale com A 1 005 A 4 C R l TO NDUCT NICO l INC Freescale sencanmuceon Inc IIVED BY FRE IR INC 2005
24. Ves 5 RR 4 TEE eo LRR a es ee a x A 6 ji V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 List of Tables Table 3 1 Table 3 2 Table 3 3 Table 3 4 Table A 1 Table A 2 Table A 3 Table A 4 Table A 5 Table A 6 Table A 7 Table A 8 Table A 9 Table A 10 Table A 11 Table A 12 Table A 13 Table A 14 MOTOROLA VODISU Tene ATWUIMGNS ricrea ede oes kd ediki SORE EK Ge ees wd VO tS as oh oo 3 44S ewe IS Tees I os hk ae bee ek eee een ea eee se Henke v8bisDestroy Arguments Host Message Types and Daa wk os 66 6 Sac KR RRR RRR RRR REL TA Bit Function LARUE 25 1564 ER obeys o6954560 oR ENGSE ERA REA PENG ALE TE RELE Di 05 Soa Se ern Waw sedis ye h Hrag d ATE canst Hala cawdedasges Re LARD 6s sews 4b eae bbws R ARR Ae ie OE eS OE eS CAN As oe ek hn Geog beet eee eens Qutput Message Type and Data lt e x 69 969 R R sce ssce es Hee RR ES ARR RRR Error Ids List of Tables For More Information On This Product Go to www freescale com Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 V 8bis Library For More Information On This Product Go to www freescale com MOTOROLA ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor
25. chine The test_v8bis directory includes e Config includes user configurable files appconfig h appconfig c and linker cmd for testing the V 8bis library e c_sources Test source files in C for both Initiating and Responding stations 2 2 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Chapter 3 V 8bis Library Interfaces 3 1 V 8bis Services V 8bis provides the procedures for identification and selection of common modes of operation between DCEs and DTEs over the public switched telephone network and on leased point to point telephone type circuits The communication between the Initiating station and the Responding station is through a set of signals and messages A signal is a combination of dual and single tones while a message is transmitted using V 21 modulation Apart from certain initialization inputs detailed in Section 3 3 2 the library accepts as input the samples received by the user from the remote end The sampling rate is 7200 samples sec During transmission each station calls back the user with samples to be transmitted The user application must transmit these samples to the Codec at 7200 samples sec The V 8bis library can be accessed through the APIs v8bisCreate vSbisInit vSbisProcess and v8bisDestroy 3 2 Interface The C interface for V 8bis
26. clude v8bis h Note This example only illustrates the Initiating Station IS For details on the Responding Station see the test_v8bisRS c file in SDK An example structure for storing the output typedef struct char buffer 50 UWordl16 offset WriteOutput User context structure Function prototypes for Transmit and Receive callbacks void ISCallbackTX void pCallbackArg Wordl6 pSamples UWord1l6 NumSamples void ISCallbackRX void pCallbackArg Wordl6 pChars UWord1l6 NumChars void test_v8bisIS void v8bis_sConfigure pConfig Configuration structure v8bis_sHandle pV8bis Handle structure UWord16 InputIS See Appendix A for filling this buffer WriteOutput MS Structure for writing the v8bis output mode selected Initialize pConfig pConfig Station V8BIS_INIT_STATION pConfig MessagePtr amp InputIS 0 pConfig TXCallback pCallback ISCallbackTx pConfig TXCallback pCallbackArg NULL NULL because user has to just transmit the samples given by v8bis by writing into the codec pConfig RXCallback pCallback ISCallbackRx MOTOROLA V 8bis Library Interfaces 3 7 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 vVi bis Library Interfaces Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 p
27. define V8BIS_CONFIGURATION_MESSAGE 0x0001 define V8BIS_CAPABILITIES_MESSAGE 0x0002 define V8BIS_PRIORITIES_MESSAGE 0x0003 define V8BIS REMOTE CAPABILITIES MESSAGE 0x0004 define V8BIS_TX_ GAIN _FACTOR_MESSAGE 0x0007 BRK KKK KKK KKK KKK K Kind of station Fe KKK KKK To be used by the user to configure V 8bis of his end as either Initiating or Responding station Please refer test_v8bisIS c or test_v8bisRS c for more details Ay typedef enum V8BIS_INIT_STATION V8BIS_RESP_STATION v8bis_eStation RR KKK Kk KKK KKK KKK k k k k k enums for host user Fe KEKEKE KKK KKK K f 3 2 V 8bis Library For More Information On This Product Go to www freescale com MOTOROLA ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc Interface ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 V8bis library returns one of the following messages to the host followed by appropriate data The host has to use these to check in his application what type of message is returned by V 8bis library to take necessary further action Please refer to ba 1 Appendix of V 8bis Library User Manual Sec A 2 define V8BIS_NIL_TX_HOST_MESSAGE 0x0000 define V8BIS_ACK_ MESSAGE 0x0001 define V8BIS_ERROR_MES
28. e ere rere Te eee rrr se 3 1 a ie CAIN 2 dyed oh ees a E TA eee eee 3 5 Baud Le ee ee ee a ee eee ee eS ere eee a ee 3 6 3 3 2 VOOM Z n aE A R REE AE ara eaa bua 3 9 Be We OCR 2 6 payed 26s ess eee ee ar eee shh oak 3 11 3 3 4 ol R a a ares eee a ee toe ee ee eee ee et ere eee eee 3 13 Chapter 4 Building the V 8bis Library 4 1 Balog RE oo do ceo ee oo pia at eE 4 4 1 1 Dependency Build va 65055960035 K T res eel RA ERA E KA ese 4 1 4 1 2 Dirt BUE TTT 4 2 MOTOROLA Table of Contents For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Chapter 5 Linking Applications with the V 8bis Library IA KE E a E E A E E E E E EE E E 5 1 A Liban ye erea ese LRE ETEO RA EOE EE 5 1 Chapter 6 V 8bis Applications 6 1 Test and Demo Applications 614 424 0 0 d 0 T R 0 R de disedseeededsene does 6 1 Chapter 7 License FA Limited Use Ligene Agreement hohner ey ees HS 55404 AR RT L KE 7 1 Appendix A Guidelines for Setting Up the Input Buffer Pod AIG ih ons CENTAS EENET seems these cieeuwewansenesss A 1 A 1 1 Foret of Input BOTs a K EK 0 0 0 KA KA EARL EKA AE koropiko risti A 1 A 1 2 ST Ra o oo oe 5 he he ees does A 2 A 1 3 Setting Up the Capabilities List so c s a es XR a5 RE 0 AK R K R KE RA A RTL A 5 A 1 4 Be Up Priorities LASE bck canehosces L KR RR A ARR RRR A LLE RL RE K A 5 AL HHE Oh
29. e the build by pressing function key F7 or by choosing Make from the Project menu see Figure 4 3 Metrowerks CodeWarrior E 8bis mcp Link U rde SUIT SHH Make F7 Stop BONG SHOT EZEL EEIT Mikina PNP EDP DQ CDQ COQ CI CI CI CI CI IE EE b Bami Wenua F3 Figure 4 3 Execute Make At this point if the build is successful the vSbis lib library file is created in the vmodem v8bis Debug directory Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 MOTOROLA Building the V 8bis Library 4 3 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Building the V 8bis Libra FeeSeale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 4 4 V 8bis Library For More Information On This Product Go to www freescale com MOTOROLA ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Chapter 5 Linking Applications with the V 8bis Library 5 1 V 8bis Library The V 8bis library consists of the V 8bis state machine as specified in the V 8bis standard The instance of V 8bis can be created and initialized by the vSbisCreate function detailed in Section 3 3 1 The library contains APIs which provide the interface between the user application and the V 8bis modules To use the V 8bis library APIs must be called in the following order
30. emiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 DTE Data Terminal Equipment DSP Digital Signal Processor or Digital Signal Processing ES Escape Signal FCS Frame Check Sequence UO Input Output IDE Integrated Development Environment LSB Least Significant Bit MAC Multiply Accumulate MIPS Million Instructions Per Second MR Mode Request MS Mode Select MSB Most Significant Bit NAK Negative Acknowledge Message OnCE On Chip Emulation OMR Operating Mode Register PC Program Counter PSTN Public Switched Telephone Network SDK Software Development Kit SP Stack Pointer SPI Serial Peripheral Interface SR Status Register SRC Source References The following sources were referenced to produce this book 1 DSP56800 Family Manual DSP56800FM AD 2 DSP568xx User s Manual 3 Embedded SDK Programmer s Guide 4 ITU T V 8bis Standard Revision 1998 MOTOROLA Preface For More Information On This Product Go to www freescale com xi Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 xii Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 V 8bis Library For More Information On This Product Go to www freescale com MOTOROLA ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Chapter 1 Introduction Welcome to Motorola s family of Digital Signal Processors DS
31. escale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 TA bit Table A 2 This bit decides whether the Transmit Ack1 bit should be set or reset in the Identifica tion field s NPAR1 which in turn will decide if the remote modem should transmit ACK1 on receiving the MS message Table A 2 TA Bit Function TA Bit Function 0 Don t expect ACK1 from remote for MS message 1 Expect ACK1 from remote for MS message T bit Table A 3 Decides if the DCE supports telephony mode Table A 3 T Bit Function T Bit Function 0 Telephony mode not supported 1 Telephony mode supported AA bit Table A 4 Turns on off the local DCE s autoanswering capability Table A 4 AA Bit AA Bit Function 0 Disables auto answering 1 Enables auto answering RV bit Table A 5 Determines if the local DCE knows the remote has V 8bis capability This in turn determines the type of transaction which the local DCE will take up Table A 5 RV Bit RV Bit Function 0 No knowledge of the remote 1 Knows that remote has V 8bis capability LKRC bit Table A 6 This bit decides if the local knows remote capability If this bit is set then there will not be a phase of exchanging capabilities during the transaction minimizing the time taken for choosing the common mode Table A 6 LKRC Bit LKRC Bit Function 0 Local does
32. escribes the use of V 8bis Library through test demo applications Chapter 7 License provides the license required to use this product Appendix A Guidelines for Setting Up the Input Buffer assists in setting up the input buffer Suggested Reading We recommend that you have a copy of the following references DSP56800 Family Manual DSP56800FM AD DSP568xx User s Manual for the DSP device being implemented Inside CodeWarrior Core Tools Metrowerks Corp MOTOROLA Preface ix For More Information On This Product Go to www freescale com Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Conventions This document uses the following notational conventions Typeface Symbol or Term Meaning Examples Courier Monospaced Type Commands command parameters code examples expressions datatypes and directives Foundational include files a data structure of type vad_tConfigure ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Italic Calls functions statements the pConfig argument aR aaa 7 defined in the C header file aec h arguments file names an applications makes a call to the Callback procedure Bold Reference sources paths refer to the Targeting DSP56824 Platform emphasis manual see C Program Files Motorola Embedded SDK help tutorials Bold Italic Directory name project name and c
33. for storing the output typedef struct char buffer 50 UWord16 offset WriteOutput User context structure void test_v8bisIS void Result res v8bis_sConfigure pConfig Configuration structure v8bis_sHandle pV8bis Handle structure UWord16 InputIS See Appendix A for filling this buffer WriteOutput MS Structure for writing the v8bis output mode selected S offset 0 Initialize pConfig pConfig Station V8BIS_INIT_STATION pConfig MessagePtr amp InputIS testcase_no 0 pConfig TXCallback pCallback ISCallbackTx pConfig TXCallback pCallbackArg NULL NULL because user has to just transmit the samples given by v8bis by writing into the codec pConfig RXCallback pCallback ISCallbackRx pConfig RXCallback pCallbackArg WriteOutput amp MS Mode selected is provided by v8bis which has to be used by the user for further processing pV8bis v8bisCreate amp pConfig Create an instance of V 8bis v8bisInit pV8bis amp pConfig V8bis Initialization For details on structures used in the above example see Code Example 3 1 3 10 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 3 3 3 v8bisProcess Ca
34. h claim alleges that Motorola was negligent regarding the design or manufacture of the Software The term of this Agreement is for as long as Licensee uses the Software for its intended purpose and is not in default of any provisions of this Agreement Motorola may terminate this Agreement if Licensee is in default of any of the terms and conditions of this Agreement This Agreement shall be governed by and construed in accordance with the laws of the State of Arizona and can only be modified in a writing signed by both parties Licensee agrees to jurisdiction and venue in the State of Arizona By using modifying installing compiling or copying the Software Licensee acknowledges that this Agreement has been read and understood and agrees to be bound by its terms and conditions Licensee agrees that this Agreement is the complete and exclusive statement of the agreement between Licensee and Motorola and supersedes any earlier proposal or prior arrangement whether oral or written and any other communications relative to the subject matter of this Agreement 7 2 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com cry RV CD i CU OY FA Freescale Semiconductor Inc ED BY FRE E SEMICO Appendix A Guidelines for Setting Up the Input Buffer A 1 A 1 1 Inputs to V 8bis Format of Input Buffer R INC The input buffer is a combination of host message type and host message data
35. in the absence of an interfering voice or other audio This Recommendation provides for error detection and rejection of corrupted messages and rejection of mode selections that are unavailable 1 2 1 Background Two stations Initiating and Responding can have different capabilities some of which are common A common mode of communication must be agreed upon by both sides depending on the priorities on each side This is facilitated by V 8bis recommendation 1 2 2 Features and Performance The V 8bis library is not multichannel For details on Memory and MIPS for a particular DSP refer to the Libraries chapter of the appropriate Targeting manual 1 2 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Chapter 2 Directory Structure 2 1 Required Core Directories Figure 2 1 details required platform directories 2 59 sic E49 dspSb624evm H E applications H E bsp r contig SiE include H E sus H E tools Figure 2 1 Core Directories As shown in Figure 2 1 DSP56824EVM has no operating system support nos and includes the following core directories e applications contains applications software that can be exercised on this platform e bsp contains board support package specific for this platform e config contains default HW SW configurations for this
36. include v8bis_typedef h include mem h v8bis_sHandle v8bisCreate v8bis_sConfigure pConfig v8bis_sHandle pV8bis Word16 temp Allocate memory for structure SS pV8bis v8bis_sHandle memMalloc if pV8bis NULL return NULL sizeof v8bis_sHandle pV8bis gt Output Wordl6 memMallocEM 10 sizeof Wordl16 if pV8bis gt Output NULL return NULL pV8bis gt TXCallback v8bis_sTXCallback memMallocEM sizeof v8bis_sTXCallback if pV8bis gt TXCallback NULL return NULL pV8bis gt RXCallback v8bis_sRXCallback memMallocEM sizeof v8bis_sRXCallback if pV8bis gt RXCallback NULL return NULL Copy configuration into Handle i e initialize them pV8bis gt Station pConfig gt Station pV8bis gt MessagePtr pConfig gt MessagePtr pV8bis gt TXCallback gt pCallback pConfig gt TXCallback pCallback pV8bis gt TXCallback gt pCallbackArg pConfig gt TXCallback pCallbackArg pV8bis gt RXCallback gt pCallback pConfig gt RXCallback pCallback pV8bis gt RXCallback gt pCallbackArg pConfig gt RXCallback pCallbackArg return pV8bis 3 6 V 8bis Library MOTOROLA For More Information On This Product Go to www free
37. inout An in argument means that the parameter value is an input only to the function An out argument means that the parameter value is an output only from the function An inout argument means that a parameter value is an input to the function but the same parameter is also an output from the function Typically inout parameters are input pointer variables in which the caller passes the address of a pre allocated data structure to a function The function stores its results within that data structure The actual value of the inout pointer parameter is not changed MOTOROLA V 8bis Library Interfaces 3 5 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Vabe Library intertaces Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 3 3 1 v8bisCreate Call s v8bis_sHandle v8bisCreate v8bis_sConfigure pConfig Required Header v8bis h Arguments Table 3 1 v8bisCreate Arguments pConfig in Points to the configuration data for V 8bis Description The vSbisCreate function creates an instance of V 8bis During the vSbisCreate call any dynamic resources required by the V 8bis algorithm are allocated In each call to the vSbisCreate function 19 external memory words are allocated The library allocates memory dynamically using the mem library routines shown in Code Example 3 2 Code Example 3 2 mem Library include v8bis h
38. is_IS mcp Bis x application BES xy A E S DE Dependencies 66K 1K amp SDK Configuration 97 HG E SDK Projects 0 E E bsp mep n a va S D sys mcp n a na E fB tools mep n a na B AB o ona na E LC SDK Libs 27K 4K S HG MSL i 39K BK E S COC Sources 693 3K 16 files 67K 14K A Figure 4 1 Dependency Build for v8bis Project MOTOROLA Building the V 8bis Library 4 1 For More Information On This Product Go to www freescale com Building the V 8bis Libra FeeSeale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 4 1 2 Direct Build Direct build allows you to build a V 8bis library independently of any other build Follow these steps Step 1 Open vSbis mcp project as shown in Figure 4 2 wp 8bis mcp Link Order Targets a Library iE Sa A p g EMSQASM Sources HE common HE dspcontrol H E message CQ signal EMAC Sources HE common H E dspcontral H E message H E signal H E host HE state_machine Ea APIs HE ASM Sources CQ C Sources 1E PENG I END CO END I DI TI I b oe 53 files Figure 4 2 v8bis mcp Project Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 4 2 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Ing ding the V 8bis Library ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Step 2 Execut
39. les Once the processing is over v8bisProcess function will return V8BIS_FREE flag This is the condition for exiting this while loop T res v8bisProcess pV8bis CodecRxBuffer RX_SAMPLES For details on structures used in the above example see Code Example 3 1 3 12 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 3 3 4 v8bisDestroy Call s Specifications void v8bisDestroy v8bis_sHandle pV8bis Required Header v8bis h Arguments Table 3 4 v8bisDestroy Arguments pV8bis in Handle to an instance of V 8bis generated by a call to v8bisCreate Description The vSbisDestroy function destroys the instance of V 8bis originally created by a call to v8bisCreate If an instance was created by the user himself without using the v8bisCreate function the user must free the memory allocated Returns None Code Example 3 6 Use of v8bisDestroy Interface include v8bis h Note This example only illustrates the Initiating Station IS For details on the Responding Station please see the test_v8bisRS c file in SDK An example structure for storing the output typedef struct char buffer 50 UWord16 offset WriteOutput User context structure void test_v8bisIS void in
40. ll s Specifications Result v8bisProcess v8bis_sHandle pV8bis Word1l6 pSamples UWord16 NumSamples Required Header v8bis h Arguments Table 3 3 v8bisProcess Arguments pV8bis in Handle to an instance of V 8bis pSamples in Pointer to the user given Codec samples received from the remote station in 16 bit 1 15 format linear PCM to be processed by V 8bis in the local station NumSamples in The number of samples words to be processed Description This function processes the signal message samples received by the user from the remote station as required by the V 8bis state machine shown in the V 8bis standard This function must be called in a loop as illustrated in Code Example 3 5 making a number of references to v8bisProcess function The parameter pV8bis must have been generated from a call to the v8bisCreate function Returns This function returns V8BIS_BUSY if the transactions are not complete otherwise it returns V8BIS_FREE Code Example 3 5 Use of v8bisProcess Interface include v8bis h Note This example only illustrates the Initiating Station IS For details on the Responding Station please see the test_v8bisRS c file in SDK An example structure for storing the output typedef struct char buffer 50 UWord16 offset WriteOutput User context structure void test_v8bisIS void int i UIntl6 j Result res v8bis_sConfigure pConfig
41. llowing manner Station Indicates the type of station V8BIS_INIT_STATION Configures V 8bis as the initiating station V8BIS_RESP_STATION Configures V 8bis as the responding station MessagePtr A pointer to a buffer of type Uword16 Points to a buffer containing host config word local capabilities remote capabilities priorities list and transmission gain Details on filling the buffer pointed to by this pointer are found in Appendix A TXCallback A structure of type v8bis_sTXCallback describes the procedure which V 8bis will call as samples are generated by the V 8bis transmitter The callback procedure has the following declaration void pCallback void pCallbackArg UWord16 pSamples UWord16 NumberSamples The callback procedure parameter pCallbackArg is supplied by the user in the v8bis_sTX Callback structure this value is passed back to the user during the call to the callback procedure Typically pCallbackArg points to context information used by the callback procedure which must be written by the user The pointer to the buffer containing samples pSamples is to be transmitted to the remote station The total number of samples in the buffer to be transmitted is called NumberSamples RXCallback A structure of type v8bis_sRXCallback describes the procedure which v8bis will call once the transaction under consideration is complete Note that this callback is called by V 8bis only at the end Certain bytes
42. n t know remote s capability 1 Local knows remote s capability MOTOROLA Guidelines for Setting Up the Input Buffer A 3 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 RKLC bit Table A 7 This bit decides if the remote knows the local capabilities If this bit is set then there will not be a phase of exchanging capabilities during the transaction minimizing the time taken for choosing the common mode Table A 7 RKLC Bit RKLC Bit Function 0 Remote doesn t know local capability 1 Remote knows local capability LD bit Table A 8 This bit decides if the local wants the final say in selecting the mode This will influ ence the transaction in such a way that the local will finally send out an MS message Table A 8 LD Bit LD Bit Function 0 Local doesn t care 1 Local would like to have the final say in mode selection LNRC bit Table A 9 This bit decides if the local will send out a CL message asking for remote s capa bility Table A 9 LNRC Bit LNRC Bit Function 0 Local doesn t want remote s capability 1 Local wants to know the remote s capability Rev No bits This set of four bits decides the revision number of the V 8bis recommendation that this soft ware has implemented This should al
43. ode of operation at automatic call establishment on the PSTN controlled by either the calling or answering station e selection of the desired mode of operation while in telephony mode on an already established connection controlled by either station e determination by either station of whether the remote station supports V 8bis with minimum disturbance to a voice caller e exchange of available capabilities between stations on a connection at call establishment or while in telephony mode e graceful recovery in the event of transmission of errors or selection of an unavailable mode of operation MOTOROLA Introduction 1 1 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 These functions are provided by defining a set of signals messages and procedures Signals are intended to be detected in the presence of an interfering voice or other audio to turn around any echo suppressors in the network prior to the beginning of information transmission and to indicate the initiation of a V 8bis transaction to the receiving station while not appearing to the user and receiver as an indication of a data or facsimile device Introduction Messages convey significantly more information than signals Messages can only be used when they will not cause disruption to a voice caller They are intended to be used only
44. of information are returned to the user which will indicate the common mode of operation between two stations To interpret the output octets refer to Sec 8 of the V 8bis Standard Revision 1998 The callback procedure has the following declaration void pCallback void pCallbackArg UWord16 pChars UWord16 NumberChars MOTOROLA V 8bis Library Interfaces 3 9 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Vae Library Infertaces Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 The callback procedure parameter pCallbackArg is supplied by the user in the v8bis_sRX Callback structure this value is passed back to the user during the call to the callback procedure Typically pCallbackArg points to context information used by the callback procedure which must be written by the user The pointer to the character buffer given to the user by his receiver is pChars and contains the common mode of transaction selected between the two stations The number of characters in the buffer pointed to by pChars is called NumberChars Returns This function always returns PASS Special Considerations None Code Example 3 4 Use of v amp bisinit Interface include v8bis h Note This example only illustrates the Initiating Station IS For details on the Responding Station please see the test_v8bisRS c file in SDK An example structure
45. ontains these core directories applications contains applications software CodeWarrior project 3des mep is Blue Text Linkable on line fefer to Chapter 7 License Number Any number is considered a 3V positive value unless preceded 10 by a minus symbol to signify a i negative value DES ALL CAPITAL Variables directives defined INCLUDE_DSPFUNC LETTERS constants files libraries define INCLUDE_STACK_CHECK Brackets Function keys by pressing function key F7 Quotation marks Returned messages the message Test Passed is displayed f unsuccessful for any reason it will return NULL Definitions Acronyms and Abbreviations The following list defines the acronyms and abbreviations used in this document As this template develops this list will be generated from the document As we develop more group resources these acronyms will be easily defined from a common acronym dictionary Please note that while the acronyms are in solid caps terms in the definition should be initial capped ONLY IF they are trademarked names or proper nouns ACK CL CLR CR DCE Acknowledge Message Capabilities List Capabilities List Request Capabilities Request Data Circuit terminating Equipment V 8bis Library For More Information On This Product Go to www freescale com MOTOROLA ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale S
46. platform e include contains SDK header files which define the Application Programming Interface e sys contains required system components e tools contains useful utilities used by system components There are also optional directories that include domain specific libraries MOTOROLA Directory Structure 2 1 For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 2 2 Optional Domain Specific Directories Figure 2 2 demonstrates how V 8bis is encapsulated in the domain specific directory modem Directory Structure H E are EMO dsp56824evm 2 nos H E applications H E bsp contig include ES E JE modem ES ES ES signal SWS tools Figure 2 2 Modem Directory The modem directory includes modem specific algorithms such as V 8bis V 22bis and others The V 8bis directory includes the V 8bis specific algorithms and is shown in Figure 2 3 odem modem_Data v22 8bis E APIs G asm_sources E c_sources E Debug E test_v8bis v8bis_Data 3 O a a fp aaa DOO Figure 2 3 V8bis Directory Structure The v8 amp bis directory includes e APIs includes both C and assembly API files for the V 8bis library e asm_sources Assembly source files to implement the V 8bis state machine e c_sources C source files to implement the V 8bis state ma
47. scale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 For details on the v8bis_sHand_le structure please refer to Code Example 3 1 The pConfig argument points to the vSbis_sConfigure structure used to configure the V 8bis operation for details see Code Example 3 3 Specifications If a vSbisCreate function is called to create an instance then v8bisDestroy see Section 3 3 4 should be used to destroy the instance Alternatively the user can allocate memory statically which requires duplicating all statements in the v8bisCreate function In this case the user can call the v8bis nit function directly bypassing the v8bisCreate function If the user dynamically allocates memory without calling v8bisCreate then the user himself must destroy the memory allocated Returns Upon successful completion the vSbisCreate function will return a pointer to the specific instance of V 8bis created If v8bisCreate is unsuccessful for any reason it will return NULL Special Considerations e The current implementation of V 8bis requires memory sections to be allocated via linker commands For details on linking applications see Chapter 5 e The current V 8bis implementation is not re entrant so multiple instances are not supported In Code Example 3 3 the application creates an instance of V 8bis Code Example 3 3 Use of v8bisCreaite Interface in
48. tain life or for any other application in which the failure of the Motorola product could create a situation where personal injury or death may occur Should Buyer purchase or use Motorola products for any such unintended or unauthorized application Buyer shall indemnify and hold Motorola and its officers employees subsidiaries affiliates and distributors harmless against all claims costs damages and expenses and reasonable attorney fees arising out of directly or indirectly any claim of personal injury or death associated with such unintended or unauthorized use even if such claim alleges that Motorola was negligent regarding the design or manufacture of the part Motorola and the Stylized M Logo are registered trademarks of Motorola Inc Motorola Inc is an Equal Opportunity Affirmative Action Employer MOTOROLA and the Stylized M Logo are registered in the US Patent amp Trademark Office All other product or service names are the property of their respective owners Motorola Inc 2002 How to reach us USA EUROPE Locations Not Listed Motorola Literature Distribution P O Box 5405 Denver Colorado 80217 1 303 675 2140 or 1 800 441 2447 JAPAN Motorola Japan Ltd SPS Technical Information Center 3 20 1 Minami Azabu Minato ku Tokyo 106 8573 Japan 81 3 3440 3569 ASIA PACIFIC Motorola Semiconductors H K Ltd Silicon Harbour Centre 2 Dai King Street Tai Po Industrial Estate Tai Po N T Hong Kong 852 26668334
49. terms of this Agreement Motorola retains ownership of the Software Motorola grants only the rights specifically granted in this Agreement and grants no other rights Title to the Software all copies thereof and all rights therein including all rights in any intellectual property including patents copyrights and trade secrets applicable thereto shall remain vested in Motorola For the Source Motorola grants Licensee a personal non exclusive non assignable revocable royalty free right to use copy and make derivatives of the Source solely in a development system environment in order to produce object code solely for operating on a Motorola semiconductor device having a central processing unit Derivative Object For the Object and Derivative Object Motorola grants Licensee a personal non exclusive non assignable revocable royalty free right to copy use and distribute the Object and the Derivative Object solely for operating on a Motorola semiconductor device having a central processing unit Licensee agrees to a not use modify or copy the Software except as expressly provided herein b not distribute disclose transfer sell assign rent lease or otherwise make available the Software any derivatives thereof or this license to a third party except as expressly provided herein c not remove obliterate or otherwise defeat any copyright trademark patent or proprietary notices related to the Software d not in any form
50. uffer Process the received samples Once the processing is over v8bisProcess function will return V BIS_FREE flag This is the condition for exiting this while loop T res v8bisProcess pV8bis CodecRxBuffer NUMRX_SAMPLES Destroy the v8bis instance v8bisDestroy pV8bis For details on structures used in the above example see Code Example 3 1 3 14 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 Chapter 4 Building the V 8bis Library 4 1 Building the V 8bis Library The V 8bis library combines all of the components described in previous sections into one library v8bis lib To build this library a Metrowerks CodeWarrior project v8bis mcp is provided This project and all the necessary components to build the V 8bis library are located in the modem v8bis directory of the SDK directory structure There are two methods to execute a system library project build dependency build and direct build 4 1 1 Dependency Build Dependency build is the easiest approach and requires no additional work on the user s part If you add the V 8bis library project v8bis mcp to your application project as shown in Figure 4 1 the V 8bis library will automatically build when the application is built mtest_v8b
51. ways be 0001 for this version ES bit Table A 10 This bit tells the V 8bis software if the telephone line is expected to have echo sup pressor Table A 10 ES Bit ES bit Function 0 No echo suppressor in the telephone network 1 Echo suppressor present in the telephone network Reserved bits The reserved bits should be written as zero A 4 V 8bis Library MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc ARCHIVED BY FREESCALE SEMICONDUCTOR INC 2005 A 1 3 Setting Up the Capabilities List Local and remote capabilities are set as shown in Table A 11 ID Identification SI Standard Information field Please refer Sec 8 of 4 Table A 11 Capabilities List 0009 Number of words excluding this word 0012 Revision number amp Message type CL 0083 NPAR1 of ID field delimit bit v 8 short v 8 0080 SPAR1 of ID field only delimit bit Note Since there is no parameter set in this field there will be no NPAR2 byte 0080 NPAR1 of SI field only delimit bit D 00a1 SPAR1 of SI field delimit bit analog telephony data N 0002 1st octet of NPAR2 of DATA of SI field V 42 Z 0000 2nd octet of NPAR2 of DATA of SI field None selected id 00c2 3rd octet of NPAR2 of DATA of SI field delimit bits and V 22bis G 00c2 1st octet of NPAR2 of analog telephony of SI field delimit bits and Audio recording device

Download Pdf Manuals

image

Related Search

Related Contents

Guía de usuario del mensaje EDI de solicitud de  DM 22 gennaio 2014 - Collegio Nazionale degli Agrotecnici  Altiris and Intel® vPro™ Technology Evaluator`s Guide  PowerDAQ AO Series User Manual  User Guide  

Copyright © All rights reserved.
Failed to retrieve file