CN107481742B - A kind of method and terminal playing voice document to the side TDM based on DSP - Google Patents

A kind of method and terminal playing voice document to the side TDM based on DSP Download PDF

Info

Publication number
CN107481742B
CN107481742B CN201710868513.8A CN201710868513A CN107481742B CN 107481742 B CN107481742 B CN 107481742B CN 201710868513 A CN201710868513 A CN 201710868513A CN 107481742 B CN107481742 B CN 107481742B
Authority
CN
China
Prior art keywords
data packet
voice
dsp
data
byte
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710868513.8A
Other languages
Chinese (zh)
Other versions
CN107481742A (en
Inventor
郭军勇
孟庆晓
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Genew Technologies Co Ltd
Original Assignee
Shenzhen Genew Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Genew Technologies Co Ltd filed Critical Shenzhen Genew Technologies Co Ltd
Priority to CN201710868513.8A priority Critical patent/CN107481742B/en
Publication of CN107481742A publication Critical patent/CN107481742A/en
Application granted granted Critical
Publication of CN107481742B publication Critical patent/CN107481742B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11BINFORMATION STORAGE BASED ON RELATIVE MOVEMENT BETWEEN RECORD CARRIER AND TRANSDUCER
    • G11B20/00Signal processing not specific to the method of recording or reproducing; Circuits therefor
    • G11B20/10Digital recording or reproducing
    • G11B20/10527Audio or video recording; Data buffering arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M7/00Arrangements for interconnection between switching centres
    • H04M7/006Networks other than PSTN/ISDN providing telephone service, e.g. Voice over Internet Protocol (VoIP), including next generation networks with a packet-switched transport layer
    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11BINFORMATION STORAGE BASED ON RELATIVE MOVEMENT BETWEEN RECORD CARRIER AND TRANSDUCER
    • G11B20/00Signal processing not specific to the method of recording or reproducing; Circuits therefor
    • G11B20/10Digital recording or reproducing
    • G11B20/10527Audio or video recording; Data buffering arrangements
    • G11B2020/10537Audio or video recording
    • G11B2020/10546Audio or video recording specifically adapted for audio data

Landscapes

  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Multimedia (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a kind of methods and terminal for playing voice document to the side TDM based on DSP, it between media sheet processor and mainboard processor by establishing a channel DSP, mainboard processor receives the first data packet that the channel DSP is sent at interval of preset time, and the second data packet is obtained using the data that preset voice data is replaced in first data packet, later in the source address and destination address for exchanging the channel DSP, second data packet is sent to media plate processing by the channel DSP, second data packet is sent on the time slot of TDM bus by media sheet processor, to which the voice data for carrying second data packet is played to TDM.The present embodiment is achieved that only by establishing between mainboard processor and media plate processing with the channel DSP and thinks that the side TDM plays voice and saved cost without installing fpga chip.Meanwhile also not limited by the memory inside DSP for storaged voice file, improve the success rate of voice broadcasting.

Description

A kind of method and terminal playing voice document to the side TDM based on DSP
Technical field
The present invention relates to communication technique field, in particular to it is a kind of based on DSP to the side TDM play voice document method and Terminal.
Background technique
VoIP (Voice over Internet Protocol) is to digitize analog signal (Voice), is sealed with data The form of packet (Data Packet) does real-time delivery on IP network (IP Network).VoIP can be transmitted on ip networks The business such as voice, fax, video and data.
Currently, VoIP system plays voice there are mainly two types of method to the side TDM, one kind is to be read using special chip FPGA There are the voice document of Flash, the program of FPGA directly plays voice to the side TDM of VoIP system;DSP can be used in another kind The interface of chip interior plays voice to the side TDM.However, both methods haves the shortcomings that corresponding, first method needs Additional fpga chip increases the production cost of terminal device;Second method can be deposited when playing excessive voice document The problem of applying dsp chip memory, and the interface use of DSP broadcasting voice document is also more complicated.
Thus the prior art could be improved and improve.
Summary of the invention
The technical problem to be solved in the present invention is that in view of the deficiencies of the prior art, providing one kind and being based on DSP to the side TDM The method and terminal for playing voice document increase terminal device to solve to need additional fpga chip in existing method Production cost the problem of.
In order to solve the above-mentioned technical problem, the technical solution adopted in the present invention is as follows:
A method of voice document is played to the side TDM based on DSP comprising:
The first data packet that the channel DSP carries is obtained at interval of preset time, and institute is replaced using preset voice data The first data packet is stated to generate the second data packet;
The source address in the channel DSP and destination address are exchanged, and second data packet is configured at the DSP and is led to Second data packet is sent to media sheet processor by road;
Second data packet is sent on the time slot of TDM bus by the media sheet processor, by institute's predicate Sound data playback is to the side TDM.
The method for playing voice document to the side TDM based on DSP, wherein described logical at interval of preset time acquisition DSP The first data packet that road carries, and use preset voice data replacement first data packet to generate the second data packet before Include:
Voice document to be sent in flash memory is obtained, and institute's voice file is stored in memory.
The method for playing voice document to the side TDM based on DSP, wherein described logical at interval of preset time acquisition DSP The first data packet that road carries, and it is specific to generate the second data packet to use preset voice data to replace first data packet Include:
The first data packet that the channel DSP carries is obtained at interval of preset time, wherein first data packet is RTP lattice Formula;
The first byte of first data packet is obtained, and chooses the voice of corresponding first byte from institute's voice file Data;
The voice data is used to replace the data in first data packet to generate the second data packet.
The method for playing voice document to the side TDM based on DSP, wherein described to obtain the of first data packet One byte, and the voice data for choosing from institute's voice file corresponding first byte specifically includes:
The first byte of first data packet is obtained, and obtains the pointer position of institute's voice file;
The voice data of first byte is chosen since the pointer position, and the pointer position is inclined to last bit Move first byte position.
The method for playing voice document to the side TDM based on DSP, wherein described to be chosen since the pointer position The voice data of first byte, and the pointer position is specifically included to last bit offset first byte position:
The last bit of institute's voice file is obtained, and calculates the second byte of the pointer position Yu the last bit interval;
Second byte is compared with the first byte;
If second byte is more than or equal to first byte, first word is chosen since the pointer position The voice data of section, and the pointer position is deviated into first byte position to last bit;
If second byte is less than first byte, the first voice number between pointer position and last bit is chosen According to, and use the first voice data described in quiet data polishing to obtain voice data, and pointer position is offset to last bit The last bit.
The method for playing voice document to the side TDM based on DSP, wherein described to be chosen since the pointer position The voice data of first byte, and by the pointer position to last bit deviate first byte position after further include:
Judge whether the pointer position is in the last bit of institute's voice file, and at which when last bit, described in closing The channel DSP.
The method for playing voice document to the side TDM based on DSP, wherein described logical at interval of preset time acquisition DSP The first data packet that road carries, and it is specific to generate the second data packet to use preset voice data to replace first data packet Include:
The first data packet that the channel DSP carries, and the detection when receiving the first data packet are obtained at interval of preset time The voice document mark that the channel DSP carries;
When institute's voice file is identified as default mark, use preset voice data replace first data packet with Generate the second data.
It is described based on DSP to the side TDM play voice document method, wherein the source address by the channel DSP with Destination address exchange, and second data packet is configured at the channel DSP, after playing voice to the side TDM further include:
The source address and destination address in the channel DSP are restored, and obtains number from TDM bus at interval of preset time According to;
The data are compiled to generate the first data packet, and first data packet is sent by the channel DSP.
A kind of storage medium, is stored with a plurality of instruction, and described instruction is suitable for being loaded by processor and being executed as described above The method for playing voice document to the side TDM based on DSP.
A kind of terminal comprising:
Processor is adapted for carrying out each instruction;And
Equipment is stored, is suitable for storing a plurality of instruction, described instruction is suitable for being loaded by processor and being executed as above any described The method for playing voice document to the side TDM based on DSP.
The utility model has the advantages that compared with prior art, playing voice document to the side TDM based on DSP the present invention provides a kind of Method and terminal, the method between media sheet processor and mainboard processor by establishing a channel DSP, mainboard processor The first data packet that the channel DSP is sent is received at interval of preset time, and described ground data are replaced using preset voice data Data in packet obtain the second data packet, later in the source address and destination address for exchanging the channel DSP, with logical by the DSP Second data packet is sent to media plate processing by road, and second data packet is sent to TDM by media sheet processor On the time slot of bus, to playing the voice data that second data packet carries to TDM.The present embodiment is only by mainboard It establishes between processor and media plate processing with the channel DSP, is achieved that and thinks that the side TDM plays voice, without installing fpga chip, Cost is saved.Meanwhile also do not limited by the memory inside DSP for storaged voice file, improve voice broadcasting at Power.
Detailed description of the invention
Fig. 1 is the flow chart of the method preferred embodiment provided by the invention for playing voice document to the side TDM based on DSP.
Fig. 2 is the structure principle chart of terminal provided by the invention.
Specific embodiment
The present invention provides a kind of method and terminal for playing voice document to the side TDM based on DSP, to make mesh of the invention , technical solution and effect it is clearer, clear, the present invention is described in more detail as follows in conjunction with drawings and embodiments. It should be appreciated that described herein, specific examples are only used to explain the present invention, is not intended to limit the present invention.
Those skilled in the art of the present technique are appreciated that unless expressly stated, singular " one " used herein, " one It is a ", " described " and "the" may also comprise plural form.It is to be further understood that being arranged used in specification of the invention Diction " comprising " refer to that there are the feature, integer, step, operation, element and/or component, but it is not excluded that in the presence of or addition Other one or more features, integer, step, operation, element, component and/or their group.It should be understood that when we claim member Part is " connected " or when " coupled " to another element, it can be directly connected or coupled to other elements, or there may also be Intermediary element.In addition, " connection " used herein or " coupling " may include being wirelessly connected or wirelessly coupling.It is used herein to arrange Diction "and/or" includes one or more associated wholes for listing item or any cell and all combinations.
Those skilled in the art of the present technique are appreciated that unless otherwise defined, all terms used herein (including technology art Language and scientific term), there is meaning identical with the general understanding of those of ordinary skill in fields of the present invention.Should also Understand, those terms such as defined in the general dictionary, it should be understood that have in the context of the prior art The consistent meaning of meaning, and unless idealization or meaning too formal otherwise will not be used by specific definitions as here To explain.
With reference to the accompanying drawing, by the description of the embodiment, further explanation of the contents of the invention are made.
Fig. 1 is please referred to, Fig. 1 is the preferable implementation of the method provided by the invention for playing voice document to the side TDM based on DSP The flow chart of example.The described method includes:
S100, the first data packet that the channel DSP carries is obtained at interval of preset time, and replaced using preset voice data First data packet is changed to generate the second data packet;
S200, the source address in the channel DSP and destination address are exchanged, and second data packet is configured at described Second data packet is sent to media sheet processor by the channel DSP;
S300, second data packet is sent on the time slot of TDM bus by the media sheet processor, by institute Predicate sound data playback is to the side TDM.
A kind of method that voice document is played to the side TDM based on DSP is present embodiments provided, by handling in media plate A channel DSP is established between device and mainboard processor, mainboard processor receives the first of the transmission of the channel DSP at interval of preset time Data packet, and the data in described ground data packet are replaced using preset voice data and obtain the second data packet, it is exchanging later The source address and destination address in the channel DSP, second data packet is sent to media plate processing by the channel DSP, Second data packet is sent on the time slot of TDM bus by media sheet processor, so that second data packet be taken The voice data of band is played to TDM.The present embodiment is only logical with DSP by establishing between mainboard processor and media plate processing Road is achieved that and thinks that the side TDM plays voice and saved cost without installing fpga chip.Meanwhile it not also being used for by the inside DSP The limitation of the memory of storaged voice file improves the success rate of voice broadcasting.
Specifically, in the step S100, the channel DSP is between media sheet processor and mainboard processor Channel, the source address in the channel DSP is the MAC Address of media plate, and destination address is the MAC Address of main sheet processor, and And the source address and destination address just configure completion in the DSP Path Setup.Correspondingly, it is described at interval of it is default when Between obtain the channel DSP carry the first data packet be main sheet processor at interval of preset time obtain the channel DSP carry first Data packet.
First data packet is that media plate processing is sent by the channel DSP to mainboard processor, and it is the matchmaker The data that body sheet processor is obtained from the time slot of TDM bus, and obtained after compiling.Correspondingly, the step S100 May include: before
S10, when receive to the side TDM play voice document instruction when, establish mainboard processor and media sheet processor Between the channel DSP;
S20, data are read from the time slot of TDM bus by media sheet processor, and the data read is compiled It translates to obtain the first data packet of RPT format;
S30, first data packet is sent to mainboard processor by DSP.
Specifically, the compiling RTP formatted file is encoded using PCMA, and code rate is the RTP packing of 64Kbps and configuration Shi Changwei 20ms.That is, carrying out PCMA coding to the data that media sheet processor is read needs 20ms, i.e., most fast every 20ms Generate first data packet of a RTP format.It is taken correspondingly, mainboard processor can receive a channel DSP at interval of 20ms First data packet of band, also, the media sheet processor also sends one second at interval of 20ms on the time slot of TDM bus Data packet, and data interaction is carried out to read one for being compiled as the first data with TDM bus when sending the second data packet The data of packet send first data packet to mainboard processor at interval of 20ms to realize the channel DSP.
Further, the voice data is the voice to be played to the side TDM being pre-stored in mainboard processor memory The content of file.And in practical applications, voice document is stored in mainboard processor can occupy the content of mainboard processor, and Mainboard processor memory is influenced in order to avoid voice document plays, voice document flash memory can be stored in, work as needs When voice document is played to the side TDM, voice document is being read from flash memory.Correspondingly, described at interval of preset time The first data packet that the channel DSP carries is obtained, and preset voice data is used to replace first data packet to generate second Include: before data packet
S01, voice document to be sent in flash memory is obtained, and institute's voice file is stored in memory.
Specifically, mainboard processor accesses flash memory by system bus, and read in flash storage to It is sent to the voice document of the side TDM, and institute's voice file is cached in the memory of mainboard processor, is broadcast to institute's voice file After putting, it is deleted from the memory of mainboard processor, in order to avoid occupy mainboard processor memory.
Further, since second data packet is the content replaced in the second data packet using voice data, thus institute The byte for stating the second data packet is identical as the byte needs of the second data packet, to need during generating the second data packet The byte of the first data packet is obtained, and chooses the voice data of respective byte according to the byte, to generate second number According to packet.
Illustratively, described that the first data packet that the channel DSP carries is obtained at interval of preset time, and use preset language Sound data are replaced first data packet and are specifically included with generating the second data packet:
S101, the first data packet that the channel DSP carries is obtained at interval of preset time, wherein first data packet is RTP format;
S102, the first byte for obtaining first data packet, and corresponding first byte is chosen from institute's voice file Voice data;
S103, the voice data is used to replace the data in first data packet to generate the second data packet.
Specifically, first data packet is the data packet of the RTP format generated by PCMA coding, first data The payload of packet is 160 bytes, wherein a byte number is 64*1000/8=8000byte/s, and 20 byte number is 8000*20/ 1000=160 bytes.Correspondingly, second data packet is also 160 bytes.
Further, since the byte of the voice document obtained in mainboard processor from flash memory is possibly more than 160 words Section, to need to choose the voice data of 160 bytes in voice document every time, to generate the second data packet.In this embodiment, The selection of the voice data successively chooses 160 words using the pointer position of voice document as starting point, from the starting point backward Section, and pointer position is deviated into 160 bytes.
Illustratively, first byte for obtaining first data packet, and chosen accordingly from institute's voice file The voice data of first byte number specifically includes:
S1021, the first byte for obtaining first data packet, and obtain the pointer position of institute's voice file;
S1022, the voice data that first byte is chosen since the pointer position, and by the pointer position to Last bit deviates first byte position.
Specifically, need to judge the finger before the voice data of first byte is chosen since the pointer position Whether the byte of the data between pin position and voice document last bit is greater than the first byte, because only that in pointer position and voice When the byte of data between file last bit is greater than the first byte, the voice data to the first byte could be chosen.Correspondingly, institute The voice data that first byte is chosen since the pointer position is stated, and by the pointer position to described in last bit offset First byte position specifically includes:
H10, the last bit for obtaining institute's voice file, and calculate the second word of the pointer position Yu the last bit interval Section;
H20, second byte is compared with the first byte;
If H30, second byte are more than or equal to first byte, described the is chosen since the pointer position The voice data of one byte, and the pointer position is deviated into first byte position to last bit;
If H40, second byte are less than first byte, the first voice between pointer position and last bit is chosen Data, and use the first voice data described in quiet data polishing to obtain voice data, and pointer position is deviated to last bit To the last bit.
Specifically, described to refer to the second byte subtracting the first word using the first voice data described in quiet data polishing It, so both can be with to obtain the first voice data of the first byte after the quiet data of section replenishes the voice data of selection The data that will be replaced using the first voice data of quiet data polishing in the first data packet, and the side TDM can be made not connect It is played to other voices outside voice document.
In one embodiment of this law invention, the voice that first byte is chosen since the pointer position Data, and by the pointer position to last bit deviate first byte position after further include:
Judge whether the pointer position is in the last bit of institute's voice file, and at which when last bit, described in closing The channel DSP.
Specifically, the last bit for judging whether the pointer position is in institute's voice file is to judge the voice text Whether part finishes.In practical applications, can be sentenced according to the length of voice document and the positional shift of voice document pointer Whether disconnected file finishes, and is turned off the channel DSP to upper-layer service with regard to reporting message if finishing, does not finish Wait for next RTP packet.
Further, since the channel DSP on media plate is there are two types of operating mode, respectively speech pattern and voice document Play mode, and when needing to play voice document and opening the channel DSP, voice text can be incidentally played for the channel DSP The voice document of part identifies.Institute's voice file is identified as software parameter, for example, the software parameter is 0 expression speech pattern, Voice document play mode is indicated for 1.Correspondingly, described obtain the first data packet that the channel DSP carries at interval of preset time, And it uses preset voice data to replace first data packet and is specifically included with generating the second data packet:
S101a, the first data packet that the channel DSP carries is obtained at interval of preset time, and is receiving the first data packet When detect the voice document mark that the channel DSP carries;
S102a, when institute's voice file is identified as default mark, the data packet is replaced using preset voice data To generate the second data.
Specifically, when mainboard processor receives RTP packet, check that the voice document in the channel DSP identifies whether as voice The mark of file play mode takes in 160 bytes if it is voice document play mode is played since voice document pointer Hold to replace the payload of 160 bytes in RTP packet, generates the second data packet, second data packet is also RTP format.
Further, in the step S200, the source address by the channel DSP refers to obtaining with destination address exchange The source address and destination address that the channel DSP carries, and source address is changed to destination address, with being changed to source by destination address Location, so that the direction of the DSP channel transfer file is changed into from source address to destination address transmission from destination address to source Second data packet is sent to media plate to realize by address transmission.In the present embodiment, by source address and destination address to being changed to Source address is changed to mainboard processor address, destination address is changed to media plate processor address, passes through the channel DSP mesh in this way The exchange for marking address and source address, realizes the transmitted in both directions in the channel DSP.
Further, in the step S300, on the time slot that the second data packet is sent to TDM bus, to pass through The TDM bus plays second data packet to the side TDM.And in practical applications, when media sheet processor is counted second When being sent on the time slot of TDM bus according to packet, data identical with the second data packet byte are obtained from the time slot of TDM bus, And the data of acquisition are compiled to obtain the first data packet, to realize between mainboard processor and media sheet processor Data are back and forth sent, so as to transmit the voice document of different length by the channel DSP, and by institute's voice file It plays to the side TDM.
Further, since exchange source address and destination address when the second data packet is sent to media sheet processor, that After media version processor obtains and generates the first data packet, need to restore the destination address in the channel DSP and source address, with The first data packet is sent to mainboard processor by the channel DSP.Correspondingly, the source address by the channel DSP It is exchanged with destination address, and second data packet is configured at the channel DSP, also wrapped later with playing voice to the side TDM It includes:
S400, the source address and destination address for restoring the channel DSP, and obtained from TDM bus at interval of preset time Access evidence;
S500, the compiling data send first data by the channel DSP to generate the first data packet Packet.
Specifically, the preset time is identical as the mainboard processor reception interval time of the first data packet, for example, being 20ms。
The present invention also provides a kind of storage mediums, are stored with a plurality of instruction, and described instruction is suitable for being loaded by processor And execute as above any method that voice document is played to the side TDM based on DSP.
The present invention also provides a kind of terminals, as shown in Figure 2 comprising at least one processor (processor) 20 with And memory (memory) 22, it can also include display screen 21, communication interface (Communications Interface) 23 Hes Bus 24.Wherein, processor 20, display screen 21, memory 22 and communication interface 23 can be completed mutual by bus 24 Communication.Display screen 21 is set as preset user in display initial setting mode and guides interface.Communication interface 23 can transmit letter Breath.Processor 20 can call the logical order in memory 22, to execute the method in above-described embodiment.
In addition, the logical order in above-mentioned memory 22 can be realized and as only by way of SFU software functional unit Vertical product when selling or using, can store in a computer readable storage medium.
Memory 22 is used as a kind of computer readable storage medium, and it is executable to may be configured as storage software program, computer Program, such as the corresponding program instruction of method or module in the embodiment of the present disclosure.Processor 30 is stored in memory by operation Software program, instruction or module in 22, thereby executing functional application and data processing, i.e. side in realization above-described embodiment Method.
Memory 22 may include storing program area and storage data area, wherein storing program area can storage program area, extremely Application program needed for a few function;Storage data area, which can be stored, uses created data etc. according to terminal device.This Outside, memory 22 may include high-speed random access memory, can also include nonvolatile memory.For example, USB flash disk, movement Hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), a variety of media that can store program code such as magnetic or disk, are also possible to transitory memory medium.
In addition, a plurality of instruction processing unit in above-mentioned storage medium and terminal loads and the detailed process that executes is above-mentioned It has been described in detail in method, has just no longer stated one by one herein.
Finally, it should be noted that the above embodiments are merely illustrative of the technical solutions of the present invention, rather than its limitations;Although Present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that: it still may be used To modify the technical solutions described in the foregoing embodiments or equivalent replacement of some of the technical features; And these are modified or replaceed, technical solution of various embodiments of the present invention that it does not separate the essence of the corresponding technical solution spirit and Range.

Claims (10)

1. a kind of method for playing voice document to the side TDM based on DSP, characterized in that it comprises:
The first data packet that the channel DSP carries is obtained at interval of preset time, and using preset voice data replacement described the One data packet is to generate the second data packet;
The source address in the channel DSP and destination address are exchanged, and second data packet is configured at the channel DSP, Second data packet is sent to media sheet processor;
Second data packet is sent on the time slot of TDM bus by the media sheet processor, by the voice number According to broadcasting to the side TDM.
2. according to claim 1 based on DSP to the side TDM play voice document method, which is characterized in that it is described at interval of Preset time obtains the first data packet that the channel DSP carries, and use preset voice data replacement first data packet with Include: before generating the second data packet
Voice document to be sent in flash memory is obtained, and institute's voice file is stored in memory.
3. according to claim 2 based on DSP to the side TDM play voice document method, which is characterized in that it is described at interval of Preset time obtains the first data packet that the channel DSP carries, and use preset voice data replacement first data packet with The second data packet is generated to specifically include:
The first data packet that the channel DSP carries is obtained at interval of preset time, wherein first data packet is RTP format;
The first byte of first data packet is obtained, and chooses the voice number of corresponding first byte from institute's voice file According to;
The voice data is used to replace the data in first data packet to generate the second data packet.
4. the method for playing voice document to the side TDM based on DSP according to claim 3, which is characterized in that the acquisition institute The first byte of the first data packet is stated, and the voice data for choosing from institute's voice file corresponding first byte specifically includes:
The first byte of first data packet is obtained, and obtains the pointer position of institute's voice file;
The voice data of first byte is chosen since the pointer position, and the pointer position is deviated into institute to last bit State the first byte position.
5. the method for playing voice document to the side TDM based on DSP according to claim 4, which is characterized in that described from described Pointer position starts to choose the voice data of first byte, and the pointer position is deviated first byte to last bit Position specifically includes:
The last bit of institute's voice file is obtained, and calculates the second byte of the pointer position Yu the last bit interval;
Second byte is compared with the first byte;
If second byte is more than or equal to first byte, first byte is chosen since the pointer position Voice data, and the pointer position is deviated into first byte position to last bit;
If second byte is less than first byte, the first voice data between pointer position and last bit is chosen, and Use the first voice data described in quiet data polishing to obtain voice data, and pointer position is offset to the end to last bit Position.
6. it is according to claim 4 or 5 based on DSP to the side TDM play voice document method, which is characterized in that it is described from The pointer position starts to choose the voice data of first byte, and the pointer position is deviated described first to last bit After byte position further include:
Judge whether the pointer position is in the last bit of institute's voice file, and at which when last bit, it is logical to close the DSP Road.
7. the methods for playing voice document to the side TDM based on DSP according to claim 1 or described in 3, which is characterized in that described every It is spaced preset time and obtains the first data packet that the channel DSP carries, and first data are replaced using preset voice data Packet is specifically included with generating the second data packet:
The first data packet that the channel DSP carries is obtained at interval of preset time, and when receiving the first data packet described in detection The voice document mark that the channel DSP carries;
When institute's voice file is identified as default mark, preset voice data is used to replace first data packet to generate Second data packet.
8. the method for playing voice document to the side TDM based on DSP according to claim 1, which is characterized in that it is described will be described The source address and destination address in the channel DSP are exchanged, and second data packet is configured at the channel DSP, to broadcast to the side TDM After putting voice further include:
The source address and destination address in the channel DSP are restored, and obtains data from TDM bus at interval of preset time;
The data are compiled to generate the first data packet, and first data packet is sent by the channel DSP.
9. a kind of storage medium, which is characterized in that it is stored with a plurality of instruction, and described instruction is suitable for being loaded and being executed by processor The method that voice document is played to the side TDM based on DSP as described in claim 1-8 is any.
10. a kind of terminal, characterized in that it comprises:
Processor is adapted for carrying out each instruction;And
Equipment is stored, is suitable for storing a plurality of instruction, described instruction is suitable for being loaded by processor and being executed as claim 1-8 is any The method for playing voice document to the side TDM based on DSP.
CN201710868513.8A 2017-09-22 2017-09-22 A kind of method and terminal playing voice document to the side TDM based on DSP Active CN107481742B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710868513.8A CN107481742B (en) 2017-09-22 2017-09-22 A kind of method and terminal playing voice document to the side TDM based on DSP

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710868513.8A CN107481742B (en) 2017-09-22 2017-09-22 A kind of method and terminal playing voice document to the side TDM based on DSP

Publications (2)

Publication Number Publication Date
CN107481742A CN107481742A (en) 2017-12-15
CN107481742B true CN107481742B (en) 2019-10-01

Family

ID=60586594

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710868513.8A Active CN107481742B (en) 2017-09-22 2017-09-22 A kind of method and terminal playing voice document to the side TDM based on DSP

Country Status (1)

Country Link
CN (1) CN107481742B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111025968B (en) * 2019-12-05 2022-09-27 深圳震有科技股份有限公司 DSP (digital Signal processor) number receiving fault detection processing method and device, computer equipment and medium
CN111447330B (en) * 2020-03-04 2022-02-18 深圳震有科技股份有限公司 Audio fault detection method, terminal and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1738224A (en) * 2004-08-19 2006-02-22 华为技术有限公司 TDM data and frame format conversion circuit and method , transmission switching system and method
CN101043282A (en) * 2006-03-24 2007-09-26 中兴通讯股份有限公司 Data storage means for multi-channel voice process
CN101252507A (en) * 2008-01-24 2008-08-27 中兴通讯股份有限公司 Method and device for exchanging sub time slot based on Ethernet

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100434053B1 (en) * 2001-12-31 2004-06-04 엘지전자 주식회사 Is-95a/b vocoder

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1738224A (en) * 2004-08-19 2006-02-22 华为技术有限公司 TDM data and frame format conversion circuit and method , transmission switching system and method
CN101043282A (en) * 2006-03-24 2007-09-26 中兴通讯股份有限公司 Data storage means for multi-channel voice process
CN101252507A (en) * 2008-01-24 2008-08-27 中兴通讯股份有限公司 Method and device for exchanging sub time slot based on Ethernet

Also Published As

Publication number Publication date
CN107481742A (en) 2017-12-15

Similar Documents

Publication Publication Date Title
KR100889977B1 (en) Media session framework using protocol independent control module to direct and manage application and service servers
US6982970B2 (en) Data transfer method and radio terminal for executing transport layer protocol on radio network
CN109246671A (en) Data transmission method, apparatus and system
CN107135256A (en) Bluetooth communication method, communicator, communication system and electronic equipment
CN104115500A (en) Bi-directional tunneling via user input back channel for wireless displays
CN103907327B (en) Unobtrusively content compression in communication network
CN106792454A (en) Bluetooth communication method, communicator, communication system and electronic equipment
JP2007049415A (en) Voice data conversion apparatus, network system, and control method and program
KR20100083233A (en) Apparatus and method for multimedia file streaming in portable terminal
CN108494817A (en) Data transmission method, relevant apparatus and system
CN105723674A (en) Methods for dynamically binding header field identifiers in a network control protocol
CN107481742B (en) A kind of method and terminal playing voice document to the side TDM based on DSP
CN102413147A (en) Agent server
JP2011050069A5 (en)
CN105227418A (en) Data channel establishing method and communication equipment
CN101938488B (en) Playing method, device, system, proxy server and mobile terminal of streaming media
JP2010124063A (en) Apparatus, method and program for connection control
CN110505112A (en) A kind of network performance monitoring method, device and storage medium
FI113324B (en) Enhanced Device Arrangement, Terminal and Method for Audio Signal Transmission in Packet Switched Data Network
US11470509B2 (en) Ad hoc communication protocol method and apparatus
CN109327435A (en) Media resource acquisition methods, device and gateway
CN101651473A (en) Communication apparatuses, methods for manufacturing chips and method for providing wireless communication profile
KR101104860B1 (en) Optimized trnasmitting method between media player and service using protocol converting for android mobile terminal
US7738459B2 (en) Method, system and apparatus for reliably transmitting packets of an unreliable protocol
US20050117604A1 (en) Transport layer protocol for a peripheral module for a communication device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
PE01 Entry into force of the registration of the contract for pledge of patent right

Denomination of invention: A method and terminal for playing voice files to TDM side based on DSP

Effective date of registration: 20220623

Granted publication date: 20191001

Pledgee: Shenzhen small and medium sized small loan Co.,Ltd.

Pledgor: SHENZHEN GENEW TECHNOLOGY Co.,Ltd.

Registration number: Y2022440020107

PE01 Entry into force of the registration of the contract for pledge of patent right
PC01 Cancellation of the registration of the contract for pledge of patent right

Date of cancellation: 20230803

Granted publication date: 20191001

Pledgee: Shenzhen small and medium sized small loan Co.,Ltd.

Pledgor: SHENZHEN GENEW TECHNOLOGY Co.,Ltd.

Registration number: Y2022440020107

PC01 Cancellation of the registration of the contract for pledge of patent right