一种基于混合编码的电流舵型数模转换器A current rudder type digital-to-analog converter based on mixed coding
技术领域Technical field
本发明涉及集成电路技术,特别涉及一种基于混合编码的电流舵型数模转换器,属于基本电子电路的技术领域。The invention relates to integrated circuit technology, in particular to a current steering type digital-to-analog converter based on hybrid coding, which belongs to the technical field of basic electronic circuits.
背景技术Background technique
数模转换器(Digital to Analog Converter,DAC)是能够将数字信号转换为模拟信号的一种信号转换器,广泛应用于需要进行信号处理的各个领域。数模转换器有多种类型,其中,电流舵型数模转换器(Current Steering Digital to Analog Converter)是一种常用的数模转换器结构,具有匹配精度高、响应速度快的优势,在高速且对匹配性要求较高的电路中有着广泛的应用,并且电流舵型数模转换器的能量利用率较高,当对输出信号进行差分利用时几乎能将所有的能量输出。Digital to Analog Converter (DAC) is a signal converter that can convert digital signals into analog signals, and is widely used in various fields that require signal processing. There are many types of digital-to-analog converters. Among them, the current steering digital-to-analog converter (Current Steering Digital to Analog Converter) is a commonly used digital-to-analog converter structure, which has the advantages of high matching accuracy and fast response speed. And it has a wide range of applications in circuits with higher matching requirements, and the current steering type digital-to-analog converter has a higher energy utilization rate. When the output signal is used differentially, almost all the energy can be output.
然而,常规的电流舵型数模转换器使用电流值成二进制倍数关系的电流源阵列,由于电流源受限于电阻值的匹配精度,在工艺、光刻等原因导致电阻值并不完全相同的时候,不可避免地存在着失配,直接影响到数模转换的精度。数模转换器所能达到的精度一定程度上取决于电流源的失配误差。因此,如何降低电流源阵列的电流失配,进而提高数模转换器的转换精度是急需解决的技术问题。However, the conventional current steering digital-to-analog converter uses a current source array whose current value is a binary multiple. Because the current source is limited by the matching accuracy of the resistance value, the resistance value is not exactly the same due to reasons such as process and photolithography. At this time, there is inevitably a mismatch, which directly affects the accuracy of the digital-to-analog conversion. The accuracy that the digital-to-analog converter can achieve depends to a certain extent on the mismatch error of the current source. Therefore, how to reduce the current mismatch of the current source array and thereby improve the conversion accuracy of the digital-to-analog converter is an urgent technical problem to be solved.
发明内容Summary of the invention
本发明的发明目的是针对上述背景技术的不足,提供了一种基于混合编码的电流舵型数模转换器,通过引入译码电路将二进制码的数字输入信号转换为高位部分温度计码与低位部分二进制码混合编码的数字控制信号,将传统的电流值成二进制倍数关系的电流源阵列转换为电流值相同的电流源,并用高位部分温度计码低位部分二进制码的混合编码数字信号进行控制,由于电流源阵列中电阻值和电流值均为单一值,使得电流源阵列的电流失配相对比较小,进而有效提高电流舵型数模转换器的转换精度,解决了如何降低电流舵型数模转换器电流源阵列电流失配的技术问题。The purpose of the present invention is to address the shortcomings of the above-mentioned background technology and provide a current-steering digital-to-analog converter based on hybrid coding, which converts the digital input signal of the binary code into the high-order part of the thermometer code and the low-order part by introducing a decoding circuit The binary code mixed coded digital control signal converts the traditional current value into a binary multiple relationship current source array into a current source with the same current value, and uses the mixed coded digital signal of the high part of the thermometer code and the low part of the binary code for control. The resistance value and current value in the source array are both a single value, making the current mismatch of the current source array relatively small, thereby effectively improving the conversion accuracy of the current steering type digital-to-analog converter, and solving how to reduce the current steering type digital-to-analog converter The technical problem of the current mismatch of the current source array.
本发明为实现上述发明目的采用如下技术方案:The present invention adopts the following technical solutions to achieve the above-mentioned purpose of the invention:
一种基于混合编码的电流舵型数模转换器,包括:A current steering digital-to-analog converter based on hybrid coding, including:
译码电路,其输入端接n+m位的二进制数字信号,将低位部分n位二进制码的数字输入信号转换为K0、K1···Kn-1的n位二进制码的数字控制信号,译码电路将高位部 分m位二进制码的数字输入信号转换为S1、S2···S2^m-1的2^m-1位温度计码的数字控制信号,n、m位大于等于1的自然数,;Decoding circuit, whose input terminal is connected with a binary digital signal of n+m bits, and converts the digital input signal of the lower part of the n-bit binary code into the digital control signal of the n-bit binary code of K0, K1···Kn-1. The code circuit converts the digital input signal of the high-order m-bit binary code into the digital control signal of the 2^m-1 digit thermometer code of S1, S2···S2^m-1, and the n and m bits are natural numbers greater than or equal to 1, ;
电流源模块,包含输出电流值为I且受控于低位部分二进制码的电流源阵列,和,输出电流值为2I且受控于高位部分温度计码的电流源阵列,输出电流值为I的电流源阵列的输出端与地之间接有R-2R网络,两个电源阵列的输出端并接后为电流源模块的输出端;The current source module includes a current source array whose output current value is I and controlled by the low-order part of the binary code, and the current source array whose output current value is 2I and is controlled by the high-order part of the thermometer code, and the output current value is I. An R-2R network is connected between the output terminal of the source array and the ground, and the output terminals of the two power arrays are connected in parallel as the output terminal of the current source module;
比较器模块,其正相输入端接参考电压,其反相输入端接负载电阻模块的一端及电流源模块的输出端,输出模拟电压信号;Comparator module, whose non-inverting input terminal is connected to the reference voltage, and its inverting input terminal is connected to one end of the load resistance module and the output terminal of the current source module to output an analog voltage signal;
负载电阻模块,其另一端与电流源模块共同接地;及,Load resistance module, the other end of which is grounded together with the current source module; and,
反馈电阻模块,接在比较器模块反相输入端和输出端之间。The feedback resistance module is connected between the inverting input terminal and the output terminal of the comparator module.
进一步地,输出电流值为I且受控于低位部分二进制码的电流源阵列包括:n路电流值为I的电流源支路,每路电流源支路串接有开关管,各开关管受控于低位部分二进制码的一位编码,R-2R网络包括n-1个第一电阻和n-2个第二电阻,第m个第一电阻接在第1路电流源支路输出端和地之间,第p个第二电阻接在第p路电流源输出端和第p+1路电流源输出端之间,0≤m≤n-1,0≤p≤n-2,当m=0时第一电阻的阻值为R,当0<m<n时第一电阻的阻值为2R。Further, the current source array whose output current value is I and controlled by the low-order part of the binary code includes: n current source branches with current value I, each current source branch is connected in series with a switch tube, and each switch tube receives Controlled by the one-bit code of the low-order part of the binary code, the R-2R network includes n-1 first resistors and n-2 second resistors. The m-th first resistor is connected to the output terminal of the first current source branch and Between ground, the p-th second resistor is connected between the p-th current source output terminal and the p+1-th current source output terminal, 0≤m≤n-1, 0≤p≤n-2, when m When = 0, the resistance of the first resistor is R, and when 0<m<n, the resistance of the first resistor is 2R.
进一步地,输出电流值为2I且受控于高位部分温度计码的电流源阵列包括2^m-1路电流值为2I的电流源支路,每路电流源支路串接有开关管,各开关管受控于高位部分温度计码的一位编码。Further, the current source array with an output current value of 2I and controlled by a high-level thermometer code includes 2^m-1 current source branches with a current value of 2I, and each current source branch is connected in series with a switch tube, each The switch tube is controlled by the one-bit code of the upper part of the thermometer code.
进一步的,比较器模块包括基于运算放大器的比较器,比较器的正相输入端接入参考电压Vref。Further, the comparator module includes a comparator based on an operational amplifier, and the non-inverting input terminal of the comparator is connected to the reference voltage Vref.
进一步的,反馈电阻模块包括反馈电阻Rf,反馈电阻Rf的一端与所述比较器模块反相输入端相接,反馈电阻Rf的另一端与所述比较器模块的输出端相接。Further, the feedback resistance module includes a feedback resistance Rf, one end of the feedback resistance Rf is connected to the inverting input end of the comparator module, and the other end of the feedback resistance Rf is connected to the output end of the comparator module.
进一步的,负载电阻模块包括负载电阻R1,负载电阻R1的一端与所述比较器模块反相输入端相接,负载电阻R1的另一端接地。Further, the load resistance module includes a load resistance R1, one end of the load resistance R1 is connected to the inverting input terminal of the comparator module, and the other end of the load resistance R1 is grounded.
进一步地,基于混合编码的电流舵型数模转换器的输出电压Vout为:Further, the output voltage Vout of the current steering digital-to-analog converter based on hybrid coding is:
合理的选取比较器模块正相输入端接入的参考电压Vref、I、负载电阻模块的阻值R1、反馈电阻模块的阻值R
f,就可以让数模转换器的模拟输出电压处于所需要的范围。
Reasonably select the reference voltage Vref, I, the resistance value of the load resistance module R1, the resistance value Rf of the feedback resistance module connected to the positive phase input of the comparator module, and the analog output voltage of the digital-to-analog converter can be at the required level. Range.
本发明采用上述技术方案,具有以下有益效果:本发明提出了一种基于混合编码的电流舵型数模转换器,通过译码电路将二进制码的数字输入信号转换为高位部分温度计码与低位部分二进制码混合编码的数字控制信号,将传统的电流值成二进制倍数关系的电流源阵列转换为电流值相同的电流源,并采用混合编码数字信号进行控制,由于电流源阵列中的电阻值和电流值均为单一值,所以电流源阵列的电流失配相对比较小,进而有效提高电流舵型数模转换器的转换精度。The present invention adopts the above technical solution and has the following beneficial effects: The present invention proposes a current-steering digital-to-analog converter based on hybrid coding, which converts the digital input signal of the binary code into the high-order part of the thermometer code and the low-order part through the decoding circuit The binary code mixed coded digital control signal converts the traditional current source array with the binary multiple relationship into a current source with the same current value, and uses the mixed coded digital signal to control, due to the resistance value and current in the current source array The values are all single values, so the current mismatch of the current source array is relatively small, thereby effectively improving the conversion accuracy of the current steering type digital-to-analog converter.
附图说明Description of the drawings
图1为本发明提出的一种基于混合编码的电流舵型数模转换器的电路结构图。Fig. 1 is a circuit structure diagram of a current steering digital-to-analog converter based on hybrid coding proposed by the present invention.
图2为本发明实施例涉及的译码电路的原理图。Fig. 2 is a schematic diagram of a decoding circuit involved in an embodiment of the present invention.
图3为本发明实施例提出的一种基于混合编码的电流舵型数模转换器的电路原理图。Fig. 3 is a circuit schematic diagram of a current steering digital-to-analog converter based on hybrid coding proposed by an embodiment of the present invention.
具体实施方式detailed description
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其它实施例都属于本发明保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative work shall fall within the protection scope of the present invention.
另外,本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。另外,本文中字符“/”,一般表示前后关联对象是一种“或”的关系。In addition, the term "and/or" in this article is only an association relationship that describes associated objects, which means that there can be three relationships, for example, A and/or B, which can mean: A alone exists, and A and B exist at the same time. There are three cases of B alone. In addition, the character "/" in this text generally indicates that the associated objects before and after are in an "or" relationship.
如图1所示,本发明提出的一种基于混合编码的电流舵型数模转换器,包括译码电路、电流源模块、比较器模块、负载电阻模块与反馈电阻模块,译码电路的输入端接入数字输入信号,译码电路的输出端与电流源模块的输入端相连,电流源模块的输出端与比较器模块的反相输入端相连,比较器模块的正相输入端接参考电压Vref,比较器模块的输出端与反馈电阻模块的一端相连,反馈电阻模块的另一端与比较器模块的反相输入端和负载电阻模块相连,译码电路将二进制码的数字输入信号转换为高位部分温度计码与低位部分二进制码的混合编码数字控制信号。其中,数模转换器的二进制码的数字输入信号为n+m位,低位部分n位,高位部分m位,n、m为大于等于1的自然数。As shown in Figure 1, a current steering digital-to-analog converter based on hybrid coding proposed by the present invention includes a decoding circuit, a current source module, a comparator module, a load resistance module and a feedback resistance module, and the input of the decoding circuit The terminal is connected to the digital input signal, the output terminal of the decoding circuit is connected to the input terminal of the current source module, the output terminal of the current source module is connected to the inverting input terminal of the comparator module, and the non-inverting input terminal of the comparator module is connected to the reference voltage Vref, the output terminal of the comparator module is connected to one end of the feedback resistance module, and the other end of the feedback resistance module is connected to the inverting input terminal of the comparator module and the load resistance module. The decoding circuit converts the digital input signal of the binary code into high bits. The mixed coded digital control signal of part thermometer code and low-order part binary code. Among them, the digital input signal of the binary code of the digital-to-analog converter is n+m bits, the low part is n bits, the high part is m bits, and n and m are natural numbers greater than or equal to 1.
如图2和图3所示,译码电路将n+m位二进制码的数字输入信号的低位部分n位二进制码的数字输入信号转换为K0、K1···Kn-1的n位二进制码的数字控制信号,将高位部分m位二进制码的数字输入信号转换为S1、S2···S2^m-1的2^m-1位温度计码的数 字控制信号。将传统的电流值成二进制倍数关系的电流源阵列转换为电流值为单一值的电流源,并用高位部分温度计码低位部分二进制码的混合编码数字信号进行控制,由于电流源阵列中电阻值和电流值均为单一值,使得电流源阵列的电流失配相对比较小,进而有效提高的数模转换器的转换精度。As shown in Figure 2 and Figure 3, the decoding circuit converts the lower part of the n-bit binary code digital input signal of the n+m-bit binary code digital input signal into the n-bit binary code of K0, K1...Kn-1 The digital control signal converts the high-order m-bit binary code digital input signal into S1, S2···S2^m-1 2^m-1 bit thermometer code digital control signal. Convert the traditional current source array whose current value is a binary multiple relationship into a current source whose current value is a single value, and use the mixed coded digital signal of the upper part of the thermometer code and the lower part of the binary code for control, due to the resistance value and current in the current source array The values are all a single value, so that the current mismatch of the current source array is relatively small, thereby effectively improving the conversion accuracy of the digital-to-analog converter.
如图3所示,电流源模块包括电流源阵列,电流源阵列包括n个电流值相同为I的电流源Ii,每个电流源Ii与相应的开关Ki的一端相接,i为0到n-1的自然数;电流源阵列还包括j个电流值相同为2I的电流源Ij,每个电流源Ij与相应的开关Sj的一段相接,j为1到2^m-1的自然数。电流源阵列还包括一个R-2R电阻网络,电阻网络包括m个第一电阻Ram和p个第二电阻Rbp,所第一电阻Ram的第一端与相应的开关Ki的另一端相连,第一电阻Ram的第二端依次相连接并接地,第二电阻Rbp位于相邻两个第一电阻Ram的第一端之间,第二电阻Rbp依次相连并与比较器模块的反相输入端相接,0≤m≤n-1,0≤p≤n-2;开关Sj的另一端依次相连并与所述比较器模块的反相输入端相接。当m=0时,第一电阻Ram的电阻值为R;当0<m<n时,第一电阻Ram的电阻值为2R,2R为两个串联的电阻值R;第二电阻Rbp的电阻值为R。开关Ki和开关Sj的栅极构成电流源模块的输入端,开关Ki与开关Sj的电流流出端构成电流源模块的输出端。As shown in Figure 3, the current source module includes a current source array. The current source array includes n current sources Ii with the same current value as I. Each current source Ii is connected to one end of a corresponding switch Ki, and i is 0 to n. A natural number of -1; the current source array also includes j current sources Ij with the same current value of 2I, each current source Ij is connected to a section of the corresponding switch Sj, and j is a natural number from 1 to 2^m-1. The current source array also includes a R-2R resistor network. The resistor network includes m first resistors Ram and p second resistors Rbp. The first end of the first resistor Ram is connected to the other end of the corresponding switch Ki. The second end of the resistor Ram is connected and grounded in sequence, the second resistor Rbp is located between the first ends of two adjacent first resistors Ram, and the second resistor Rbp is connected in sequence and connected to the inverting input end of the comparator module , 0≤m≤n-1, 0≤p≤n-2; the other end of the switch Sj is connected in sequence and connected with the inverting input end of the comparator module. When m=0, the resistance value of the first resistor Ram is R; when 0<m<n, the resistance value of the first resistor Ram is 2R, 2R is the resistance value R of two series connected; the resistance of the second resistor Rbp The value is R. The gates of the switch Ki and the switch Sj constitute the input end of the current source module, and the current outflow ends of the switch Ki and the switch Sj constitute the output end of the current source module.
如图3所示,比较器模块包括基于运算放大器的比较器,包括正相输入端、反相输入端与输出端,其中,正相输入端接入参考电压Vref,反相输入端分别与电流源模块的输出端、反馈电阻模块Rf的一端、负载电阻模块R1的一端相连,输出端输出相应电压Vout。负载电阻R1的另一端接地。具体的,负载电阻R1的电阻值为R,R的具体数值需要根据实际情况而具体设定,在此仅作为一个标识。As shown in Figure 3, the comparator module includes a comparator based on an operational amplifier, including a non-inverting input, an inverting input, and an output. The non-inverting input is connected to the reference voltage Vref, and the inverting input is connected to the current The output end of the source module, one end of the feedback resistance module Rf, and one end of the load resistance module R1 are connected, and the output end outputs a corresponding voltage Vout. The other end of the load resistor R1 is grounded. Specifically, the resistance value of the load resistor R1 is R, and the specific value of R needs to be specifically set according to actual conditions, which is only used as an identification here.
负载电阻Rf的电阻值为R,R的具体数值需要根据实际情况而具体设定,在此仅作为一个标识。The resistance value of the load resistor Rf is R, and the specific value of R needs to be specifically set according to the actual situation, which is only used as an identification here.
上述基于混合编码的电流舵型数模转换器,引入译码电路将二进制码的数字输入信号转换为高位部分温度计码与低位部分二进制的码混合编码数字控制信号,将传统的电流值成二进制倍数关系的电流源阵列转换为电流值相同的电流源,并用高位部分温度计码低位部分二进制码的混合编码数字信号进行控制,由于电流源阵列中电阻值和电流值均为单一值,使得电流源阵列的电流失配相对比较小,进而有效提高的数模转换器的转换精度。The above-mentioned current-steering digital-to-analog converter based on mixed coding introduces a decoding circuit to convert the digital input signal of the binary code into a high-order part of the thermometer code and the low-order part of the binary code to mix-encode a digital control signal, and convert the traditional current value into a binary multiple The current source array of the relationship is converted into current sources with the same current value, and controlled by the mixed-coded digital signal of the high-order part of the thermometer code and the low-order part of the binary code. Because the resistance value and the current value in the current source array are both a single value, the current source array The current mismatch is relatively small, thereby effectively improving the conversion accuracy of the digital-to-analog converter.
优选的,如图3所示,数模转换器的输出电压Vout为:Preferably, as shown in Fig. 3, the output voltage Vout of the digital-to-analog converter is:
其中,合理的选取Vref、I、R1、R
f的值,就可以让数模转换器的模拟输出电压处于所需要的范围。
Among them, a reasonable selection of the values of Vref, I, R1, and R f can keep the analog output voltage of the digital-to-analog converter in the required range.
通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到本申请的发明构思,为方便并简洁地描述,仅以上述各功能单元的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元完成,即将装置的内部结构划分成不同的功能单元,以完成以上描述的全部或者部分功能。上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Through the description of the above embodiments, those skilled in the art can clearly understand the inventive concept of this application. For convenience and concise description, only the division of the above-mentioned functional units is used as an example for illustration. In actual applications, it can be as required. The above-mentioned function allocation is completed by different functional units, that is, the internal structure of the device is divided into different functional units to complete all or part of the functions described above. For the specific working process of the above-described system, device, and unit, reference may be made to the corresponding process in the foregoing method embodiment, which is not repeated here.
以上所述仅为本发明的具体实施方式,但本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内可轻易想到的变化或替换都应涵盖在本发明的保护范围之内。因此,本发明的保护范围应以权利要求划定的范围为准。The above are only specific embodiments of the present invention, but the scope of protection of the present invention is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed by the present invention shall be covered Within the protection scope of the present invention. Therefore, the protection scope of the present invention should be subject to the scope defined by the claims.