• Embedded voice communication platform which designs with SPCE061A

    Introduction
        Along with digital signal processing technology development, pronunciation interactive embedded and network development already day by day mature. But because the embedded system has the storage space to be small, demonstration ability is insufficient the characteristic, must carry on widespread and the thorough embedded pronunciation compression, the voice communication aspect research and the analysis, some voice communication platform which consummates with the PC machine connected Taiwan principle. This article based on Taiwan Ling Yang company’s SPCE061A model micro controller and ADPCM (auto-adapted difference PCM) the principle, elaborated that realizes the embedded voice communication platform method, and proposes the target-oriented design strategy.

    1 platform skeleton
        Figure 1 is the platform functional module, the speech network which this article realizes for the star network topology, the PC machine server and many pronunciation terminals is connected through the MAX232 serial port, undertakes is corresponding intermediary and the empirical datum analysis duty.

        In the terminal functional module, the center control and processing select Ling Yang company’s SPCE061A. Its CPU essence is Ling Yang newest promoted Mu ‘ the SP 16 microprocessor chips, thus has the multi-purpose micro controllers and the high speed microprocessor’s dual characteristics. In the audio frequency processing aspect, it has the single channel sound mold/number switch, and built-in has the automatic gain control (AGC) microphone amplifier, thus simplified the pronunciation processing system’s hardware composition. The component detailed material sees the reference. The audio frequency input output module outputs two parts including the microphone input and the earphone. The microphone inputs to a/D sampling mouth between the month LM324N operational amplifier constructs a two level of against aliasing low pass filter. Between outputs the D/A mouth to the earphone uses the SPY0030 power amplifier, may provide biggest 500mW the output. The power source administration module has used SPY0029, may provide 3.14V the low power loss voltage standard. RS232 correspondence connection primary cognizance and PC machine correspondence. Here uses the MAX232 chip, may simultaneously provide two channel’s RS2.32 correspondence connections.
        On the PC machine software’s functional module chart, the complete module realizes by Visual C , has the friendly man-machine interaction contact surface. And the connection module realizes all communication task, the pronunciation algoritic module integration has each kind of algorithms and so on pronunciation compression, digital filtering, static sound examination as well as short-time analysis; The analysis module may provide the graphical interface, the demonstration pronunciation oscillogram and the frequency spectrum characteristic; The pronunciation algoritic module and the analysis module are only study the digital pronunciation algorithm to provide the convenience.

    2 ADPCM arranges the decoding principle
        ADPCM is in the speech compression coding the order of complexity low one method. It uses the voice signal the non-steady characteristic, uses the adaptive prediction and the auto-adapted quantification, can achieve the 64kb/s numerical code rate pronunciation quality in the 32kb/s numerical code rate (MOS to divide into 4.1), thus tallies enters the public network the request. Because ADPCM has such high performance, at present it obtained widely in the telecommunication long-distance transmission system neutral each kind of audio frequency transmission or the processing system should ADPCM code principle as shown in Figure 2.

        The ADPCM core thought is:①Uses the auto-adapted thought change quantification step the size, namely uses small quantification step (step-size) to code the small differential value, uses the big quantification step to code the big differential value;②The use past sample value estimate next input sample’s predicted value, caused between the actual sample value and the predicted value differential value is always smallest.
        Here has used the backward auto-adapted quantification and the forecast. Its main principle is, according to the preceding time quantizer’s output digital code determined that the quantizer the quantized interval, and determines this time predictor according to the preceding time’s counter quantification value the output.
        The quantification algorithm conforms to the Jayant algorithm, namely △ (k 1)=△(k)M (|I (k)|) in which, △ (k 1) and △ (k) respectively for this time and the preceding time’s quantized interval, I(k) is the preceding time output symbol, but M refers to take the symbol as the independent variable relational function, the value is as follows:
        |The I(k)| value is 1,2,3,4,5,6,7,8;
        M (|I(k)|) the value is 0.9,0.9,0.9,0.9,1.2,1.6,2.0,2,4.
        The forecast algorithm uses the parameter revision algorithm, namely Pred(k 1)=Pred(k) D (k) α△ (k) in which, △ (k) is the preceding time quantized interval, Pred(k) and Pred(k 1) respectively for the preceding time and this time predicted value, D(k) is the preceding time differential value, Alpha revises the parameter.
        The ADPCM concrete mathematics inferential reasoning may see reference [2] and [3].

    3 embedded voice communication platform realization
    3.1 pronunciations arrange the decoding to realize the strategy
        Here arranges the decoding to realize on the embedded system. In order to enhance the speech coding the speed, all arranges the decoding to operate uses the assembly language to realize completely: 伹 by introduces to the ADPCM principle may know, in the code process, the computation quantized interval involves to the decimal multiplication. This realizes in the fixed-point microprocessor is quite complex: Needs to judge the differential value the size, carries on the corresponding decimal changes again the integer, the multiplication and division, the integer changes the decimal and so on a series of transformations can obtain the current quantized interval value, the algorithm order of complexity is quite high. In view of this situation, this article uses the second-level retrieval the method to strive for the quantized interval. The concrete algorithm is as follows:
        ①According to Jayant algorithm establishment quantized interval table StepSizeTable[45] and quantized interval index change table IndexVariaty[8];
        ②Supposes index starting value Index=0;
        ③Using current differential value’s quantification absolute value Differ, looks up IndexVaria-tyTable[], obtains the index current change to measure IndexVariaty;
        ④Renews Index with Index lndexVanaty;
        ⑤Using Index, looks up StepSizeTable[] again, obtains the current quantized interval finally.
        Afterward code strives for the quantized interval is③,④,⑤Circulation. Uses the second-level retrieval method the advantage to lie, when establishes the StepSizeTable table might the multiply operation, the decimal change steps and so on integer has pretreated, thus reduced has arranged the decode procedure the algorithm order of complexity, reduced the terminal processing detention.
    3.2 real-time communication system strategies
        In order to guarantee that in the transmitting end sampling and the transmission, the receiving end broadcast and the receive real-time coordination, this article uses the Ling Yang rich clock interrupt, before having used, the backstage thought. The onstage is composed .TimerA by the counter TlmerA interrupt and the asynchronous communication UART interrupt routine fixed time for each l25μs to interrupt one time to actuate A/D or D/A carries on the audio frequency the sampling, the broadcast, but the UART interrupt processes the correspondence the transmission and the receive work. Because the transmission baudrate is higher than the sampling rate far, therefore the sampling pressing must be higher than the transmission the pressing, like this must establish the TimerA interrupt priority to be higher than UART far, guaranteed that in the transmitting end sampling, receiving end’s broadcast is not broken. The backstage is mainly arranges the decoding procedure the execution, keyboard control command response processing. In the pronunciation arranges in the decoding algorithm time order of complexity enough low situation, like already realized ADPCM, CVSD (continuous variable slope delta modulation) as well as Ling Yang integrates soft module SACM_DVR (innertube code) and so on. This kind of system may obtain the very good pronunciation interactive effect.
    3.3 real-time buffers realize the strategy
        Based on real-time communication thought that on the other hand the receiving end must achieve on the one hand receives broadcasts needs to rely on the real-time processing mechanism and the buffer strategy.
        In the buffer aspect, in monolithic integrated circuit SPCE061A SRAM only has 2KB, this speaking of wired connects the 115kb/s baudrate and between the broadcast data rate 32Kb/s disparity is not enough. Therefore, uses the pingpong system catarmaran buffer strategy, soon the buffer divides into two areas, each area size just is 1 data quantity size (114 bytes), through two area’s taking turn, has solved the data rate match problem well. First establishes an answering signal, the server take this as the transmission data signal, and 1 time only transmits l. In the PC machine end’s serial port event response code is:
        UINT stdcall Tlaread OnCommMscornml (PVOID pvParam) {
        if (m etrlComm, GetCommEvent()==2) {// event value is 2, indicates in the receive buffer to have the character
        iffiRunState=State_Receive) //, if for the receive condition, receives the data
        else the if(iRuIiState==State_Send) // ruo for the transmission condition indicated that receives the answering signal
        if (HaveSendedDataLen <DataReadedLen) // buffer also has 1 data at least
        SendOnePage(); // transmits 1 data
        }
      }

        Realizes as shown in Figure in the embedded terminal 3 specifically.

        This has only opened 288 bytes buffers, well has solved high speed and the low speed match problem.

    Conclusion
        This article constructs the platform not only may apply in the ADPCM algorithm voice communication, based on Ling Yang microprocessor’s handling ability, but also has the good extendibility. Like the increase code, the innertube code, the parameter code and so on may further transplant, regardless of has in the application in the research well profits from the value. In the application, may establish one based on this thought to have the common control, the handling ability star voice communication network; But in the research, may carry on the direct-viewing analysis in this platform to many kinds of pronunciation processing algorithm (profile, sense of hearing) or the spectral analysis. The low complexity algorithm which does in the embedded terminal (for example each kind of profile code) may spreads the symbol stream or the pronunciation delivers PC machine, provides the analysis tool analysis profile and the frequency spectrum change through the platform, contrasts each algorithm the loss degree which creates to the pronunciation primary signal; But high order of complexity algorithm which does on PC machine (for example parameter code), also after may processes the voice signal transmit to the embedded system, hears the algorithm the effect. In the article designed for has further laid the foundation to the pronunciation digital signal processing research and the development work.

    Share/Save/Bookmark

    Tuesday, September 9th, 2008 at 21:12
No comments yet.

Leave a comment

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

TOP
Copyright © 51 Research and Design, Electronic Engineers website - Embedded Systems, MCU, DSP, EDA, Test and Measurement, Components, Communications, Power, Microelectronics, Semiconductors
Powered by WordPress | Theme by mg12 | Valid XHTML 1.1 and CSS 3