CN205212819U - HDB3 coder circuit based on CPLD - Google Patents
HDB3 coder circuit based on CPLD Download PDFInfo
- Publication number
- CN205212819U CN205212819U CN201521049977.9U CN201521049977U CN205212819U CN 205212819 U CN205212819 U CN 205212819U CN 201521049977 U CN201521049977 U CN 201521049977U CN 205212819 U CN205212819 U CN 205212819U
- Authority
- CN
- China
- Prior art keywords
- hdb3
- cpld
- input
- output
- unit
- 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.)
- Expired - Fee Related
Links
Landscapes
- Dc Digital Transmission (AREA)
Abstract
The utility model discloses a HDB3 coder circuit based on CPLD, including CPLD treater and singlechip, the singlechip passes through SPI serial communication interface and realizes electric the connection with the CPLD treater, the CPLD treater includes HDB3 encoder module and HDB3 decoder module. The utility model has the advantages of circuit structure is simple, and system stability is high to be convenient for the user according to the debugging of making amendment of detailed design needs. In addition the utility model discloses still have and to realize HDB3's the volume decoding circuit data bit error rate and transmission rate autoanalysis's advantage.
Description
Technical field
The utility model relates to a kind of HDB3 coder, and specifically one realizes HDB3 encoder and HDB3 decoder based on CPLD simultaneously, and is integrated in the HDB3 coder in same chip.
Background technology
High Density Bipolar 3 (be called for short: HDB3 code) is a kind of coded system being applicable to baseband transmission, and it occurs having power dissipation, the features such as anti-destructive is strong in order to the shortcoming overcoming AMI code.
Because HDB3 code has become the conventional pattern of the chnnel coding in digital baseband signal transmission, in the digital transmission interface of the basic group of PCM, quadratic gropup and tertiary group, all adopt HDB3 code, it is very valuable for therefore designing the high HDB3 coder of a cost performance.And although the widely used CD22103 chip of prior art has the coding and decoding function of HDB3, need configuration synchronization to extract and polarity of voltage change-over circuit, be not easy to the system integration, upgrading and maintenance; And the above-mentioned technical approach adopted in prior art can not realize the automatic analysis of coding and decoding circuit error rates of data to HDB3 and transmission rate.
Utility model content
For prior art above shortcomings, the purpose of this utility model is: how to provide a kind of HDB3 coder circuit being conducive to the system integration, upgrading and maintenance.
To achieve these goals, the utility model have employed following technical scheme.
Based on a HDB3 coder circuit of CPLD, it is characterized in that: comprise CPLD processor and single-chip microcomputer;
CPLD processor, described single-chip microcomputer realizes being electrically connected with CPLD processor by SPI serial communication interface;
Described CPLD processor comprises HDB3 coder module and HDB3 decoder module;
The delivery outlet and four of described HDB3 coder module selects the numerical control end of a numerical control analog switch to be connected, first input/output port ground connection of numerical control analog switch, second input/output port of numerical control analog switch connects+5V power supply, and the second input/output port of numerical control analog switch connects-5V power supply.
Further, described HDB3 decoder module mainly comprises V pulse detection unit and BV pulse skipping unit, the input of V pulse detection unit is the input port of HDB3 decoder module, the output of V pulse detection unit is connected with the input of BV pulse skipping unit, and the output of BV pulse skipping unit is the delivery outlet of HDB3 decoder module.
Further, described HDB3 coder module is primarily of V code generation unit, B code generation unit and single bipolarity converting unit composition, the output input port being input as HDB3 coder module of described V code generation unit, the output of V code generation unit is connected with the input of B code generation unit, the output of B code generation unit is connected with the input of single bipolarity converting unit, and the output of single bipolarity converting unit is the delivery outlet of HDB3 coder module.
Further, described four a numerical control analog switch is selected to be CD405 chip.
Compared to existing technology, the utility model tool has the following advantages:
In the utility model, the coding module of HDB3 and the decoding module of HDB3 are integrated on same chip, simplify the hardware configuration of system, decrease part category and quantity, improve the stability of system, simultaneously due to CPLD, there is online programmable function and pin can customize function, be conducive to user and revise debugging, in sum, the devices such as CD22103 chip are adopted to realize the coding and decoding function of HDB3 compared to existing technology, it is simple that the utility model has circuit structure, the stability of a system is high, and be convenient to user and need according to specific design the advantage of debugging of modifying.In addition the utility model also has the advantage of coding and decoding circuit error rates of data and the transmission rate automatic analysis that can realize HDB3.
Accompanying drawing explanation
Fig. 1 is circuit structure diagram of the present utility model;
Embodiment
Below in conjunction with the drawings and specific embodiments, the utility model is described in further detail.
The coding rule of HDB3 code is: 1, message code is transformed into AMI code: AMI code (AlternateMarkInversion) full name is alternate mark inversion code.This is that message code 0 and 1 is encoded by one according to the following rules: code 0 is still transformed to transmission code 0, and 1 in code is alternately become+1 ,-1 ,+1 of transmission code ,-...2, check company 0 situation in AMI code, when the company 0 without more than 4 or 4 goes here and there, then keep the form of AMI constant; If occur, more than 4 or 4 when connecting 0 string, then the 4th 0 after 1 is become the symbol with last non-zero code (+1 or-1) same polarity, represent (+1 is designated as+V, and-1 is designated as-V) with V.Whether the number 3, checking the non-O code of adjacent v intersymbol is even number, if even number, then again the 1st 0 after the last non-O code of current v code is become+B or-B code, and the polarity of B is contrary with the polarity of last non-O code, and makes non-zero code alternately change again from V code below.
The decoding of HDB3 code is the inverse process of coding, and its decoding is simpler relative to coding.According to the coding rule of HDB3 code, first V symbol can not appear at front 3 positions, namely each destroy symbol V always with last non-zero symbol same polarity, the code position that this guarantees below subtracts 3 meaningful and can not overflow.Therefore, from the HDB3 code sequence received, easily identify V symbol, also V symbol and 3 symbols above thereof must be connect 0 symbol certainly simultaneously, so can revert to 0 yard, 4 companies, and then just obtain former message code after becoming+1 by all-1.
As shown in Figure 1, HDB3 coder is integrated in same CPLD chip by the utility model, and realizes being electrically connected by SPI serial communication interface and CPLD processor to the single-chip microcomputer of the coding and decoding circuit error rates of data of HDB3 and the automatic analysis of transmission rate for realizing.
The inner integrated HDB3 coder module of CPLD processor adopts following circuit structure respectively:
HDB3 decoder module mainly comprises V pulse detection unit and BV pulse skipping unit, the input of V pulse detection unit is the input port of HDB3 decoder module, the output of V pulse detection unit is connected with the input of BV pulse skipping unit, and the output of BV pulse skipping unit is the delivery outlet of HDB3 decoder module.
HDB3 coder module is primarily of V code generation unit, B code generation unit and single bipolarity converting unit composition, the output input port being input as HDB3 coder module of V code generation unit, the output of V code generation unit is connected with the input of B code generation unit, the output of B code generation unit is connected with the input of single bipolarity converting unit, and the output of single bipolarity converting unit is the delivery outlet of HDB3 coder module.
The specific design of each functional unit of HDB3 decoder module and HDB3 coder module can adopt calls the realization of schematic diagram unit, and state machine comparatively common in prior art also can be adopted to realize.The common approach that schematic diagram unit or state machine technique are all CPLD designing techniques is called in employing.
In addition it is to be noted that the coding result 01,11 and 00 that HDB3 coder module is exported by CPLD pin is encoded, not also HDB3 code truly. because the code signal waveform of HDB3 code correspondence has pulse train that is positive and negative, 03 kinds of level, therefore also need to select a numerical control analog switch to become positive pulse .11 transcoding, coding transform to become negative pulse 01 transcoding, coding transform with four, 00 transcoding, coding transform becomes zero level.
Particular circuit configurations is: the delivery outlet (two signals) of HDB3 coder module selects the numerical control end of a numerical control analog switch to be connected with four, first input/output port ground connection of numerical control analog switch, second input/output port of numerical control analog switch connects+5V power supply, and the second input/output port of numerical control analog switch connects-5V power supply.Numerical control analog switch common port be HDB3 code output truly.Four select a numerical control analog switch to select CD405 chip.First and second and three input/output ports and common port are connected according to different 01,11 and 00 codes selection by CD405 chip, thus realize conversion.
Utility model works principle is as follows:
The HDB3 encoder of CPLD chip internal and HDB3 decoder independently complete its coding and decoding work, it is identical with process with the code and decoding principle of HDB3 decoder that HDB3 code and decoding principle and process and other technologies means in employing prior art realize HDB3 encoder, do not repeat them here, difference is only that the HDB3 encoder of CPLD chip internal in the utility model and HDB3 decoder can simultaneously and independently carry out coding and decoding work.What will set forth below is the automatic analysis how the utility model realizes coding and decoding circuit error rates of data to HDB3 and transmission rate: test data sends to HDB3 coding module to carry out coding by SPI serial communication interface and exports by single-chip microcomputer, and is exported by HDB3 coding module coding and return to single-chip microcomputer by SPI serial communication interface thus the automatic analysis being carried out HDB3 coding module error rates of data and transmission rate by single-chip microcomputer by comparing process.Same method can complete the corresponding test of HDB3 decoding module.
In addition single-chip microcomputer realizes by SPI serial communication interface and CPLD processor the principle that electric communication is connected and is: single-chip microcomputer produces the SPI communication interface that SPI work schedule realizes between single-chip microcomputer and CPLD chip, this communication mode at least has root 4 line when one-way communication (only need 3 lines also can realize), concrete respectively: 1, from device data input line SDI, be also main equipment DOL Data Output Line; 2, from device data output line SDO, be also main equipment Data In-Line; 3, clock cable SCLK, clock signal is produced by main equipment; 4, from devices enable holding wire CS.
Main equipment and carry out synchronous serial-data transmission between equipment, under the shift pulse of main equipment, data step-by-step is transmitted, and high-order front, status, rear, is full-duplex communication, simply efficiently.In the utility model, single-chip microcomputer is main equipment, and CPLD is from equipment, and CPLD can be first temporary after receiving the data of single-chip microcomputer, then for control or the data input of CPLD internal digital logic unit.
What finally illustrate is, above embodiment is only in order to illustrate the technical solution of the utility model and unrestricted, although be described in detail the utility model with reference to preferred embodiment, those of ordinary skill in the art is to be understood that, can modify to the technical solution of the utility model or equivalent replacement, and not departing from aim and the scope of technical solutions of the utility model, it all should be encompassed in the middle of right of the present utility model.
Claims (4)
1., based on a HDB3 coder circuit of CPLD, it is characterized in that: comprise CPLD processor and single-chip microcomputer;
CPLD processor, described single-chip microcomputer realizes being electrically connected with CPLD processor by SPI serial communication interface;
Described CPLD processor comprises HDB3 coder module and HDB3 decoder module;
The delivery outlet and four of described HDB3 coder module selects the numerical control end of a numerical control analog switch to be connected, first input/output port ground connection of numerical control analog switch, second input/output port of numerical control analog switch connects+5V power supply, and the second input/output port of numerical control analog switch connects-5V power supply.
2. a kind of HDB3 coder circuit based on CPLD according to claim 1, it is characterized in that: described HDB3 decoder module mainly comprises V pulse detection unit and BV pulse skipping unit, the input of V pulse detection unit is the input port of HDB3 decoder module, the output of V pulse detection unit is connected with the input of BV pulse skipping unit, and the output of BV pulse skipping unit is the delivery outlet of HDB3 decoder module.
3. a kind of HDB3 coder circuit based on CPLD according to claim 1, it is characterized in that: described HDB3 coder module is primarily of V code generation unit, B code generation unit and single bipolarity converting unit composition, the output input port being input as HDB3 coder module of described V code generation unit, the output of V code generation unit is connected with the input of B code generation unit, the output of B code generation unit is connected with the input of single bipolarity converting unit, and the output of single bipolarity converting unit is the delivery outlet of HDB3 coder module.
4. a kind of HDB3 coder circuit based on CPLD according to claim 1,2 or 3, it is characterized in that, described four select a numerical control analog switch to be CD405 chip.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201521049977.9U CN205212819U (en) | 2015-12-10 | 2015-12-10 | HDB3 coder circuit based on CPLD |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201521049977.9U CN205212819U (en) | 2015-12-10 | 2015-12-10 | HDB3 coder circuit based on CPLD |
Publications (1)
Publication Number | Publication Date |
---|---|
CN205212819U true CN205212819U (en) | 2016-05-04 |
Family
ID=55850505
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201521049977.9U Expired - Fee Related CN205212819U (en) | 2015-12-10 | 2015-12-10 | HDB3 coder circuit based on CPLD |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN205212819U (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110380736A (en) * | 2019-06-13 | 2019-10-25 | 华南师范大学 | A kind of new HDB3 code encoding method, device, equipment and storage medium |
CN112350967A (en) * | 2019-08-06 | 2021-02-09 | 天津光电通信技术有限公司 | HDB3 encoding and decoding methods and devices |
-
2015
- 2015-12-10 CN CN201521049977.9U patent/CN205212819U/en not_active Expired - Fee Related
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110380736A (en) * | 2019-06-13 | 2019-10-25 | 华南师范大学 | A kind of new HDB3 code encoding method, device, equipment and storage medium |
CN110380736B (en) * | 2019-06-13 | 2023-04-21 | 华南师范大学 | Novel HDB 3code encoding method, device, equipment and storage medium |
CN112350967A (en) * | 2019-08-06 | 2021-02-09 | 天津光电通信技术有限公司 | HDB3 encoding and decoding methods and devices |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101493674B (en) | B code demodulating and decoding method and apparatus thereof | |
CN101330326B (en) | Digital circuit for implementing audio data optical transmission using CPLD and method thereof | |
CN101009501A (en) | A DC power line carrier communication method, system and lamp series using the system | |
CN205212819U (en) | HDB3 coder circuit based on CPLD | |
CN104158853A (en) | Manchester-code-based power electronic conversion system communication control framework | |
CN104467865B (en) | Serial communication protocol controller, byte split circuit and 8b10b encoders | |
CN105072058B (en) | A kind of positive and negative phase coding method of data and data transmission method based on optical fiber transmission | |
CN201667011U (en) | Embedded multi-input multi-output data acquisition template | |
CN206236264U (en) | A kind of medium-voltage carrier system | |
CN103199865B (en) | A kind of light adaptive serial port decoding circuit | |
CN100417058C (en) | Coder-decoder for return-to-zero code or mark inverse code | |
CN108023680A (en) | Low speed variable bit rate multi-mode encoding modulator based on VTDM frame structures | |
CN201994936U (en) | Multi-carrier communication conversion module for power line | |
CN203135884U (en) | Relay-protection multi-communication intelligent switching device | |
CN201628861U (en) | Bus transmission system | |
CN103001901B (en) | Integrated circuit high-speed digital interface module based on modified difference pulse code modulation (MDPCM) | |
CN103401747B (en) | A kind of distributed floating controller Local network communication system | |
CN202500555U (en) | Data transmission system in petroleum logger | |
CN202331792U (en) | Data collection transmission system for transformer substation | |
CN105259784B (en) | Power system simulation-oriented signaling coding method and high-speed data transmission method thereof | |
CN201393232Y (en) | Bus communication circuit applying novel CMI encoding | |
CN105389865B (en) | Shorten the digital signal method of sending and receiving and mobile terminal of sending time | |
CN105103446B (en) | A kind of signal processing apparatus | |
CN203632640U (en) | Two-way transmission interface converting circuit | |
CN206311695U (en) | A kind of cable detecting system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20160504 Termination date: 20161210 |