CN102468853A - Method for realizing ADC (analog to digital converter) on mobile phone at low cost - Google Patents

Method for realizing ADC (analog to digital converter) on mobile phone at low cost Download PDF

Info

Publication number
CN102468853A
CN102468853A CN 201010545070 CN201010545070A CN102468853A CN 102468853 A CN102468853 A CN 102468853A CN 201010545070 CN201010545070 CN 201010545070 CN 201010545070 A CN201010545070 A CN 201010545070A CN 102468853 A CN102468853 A CN 102468853A
Authority
CN
China
Prior art keywords
adc
universal
voltage
port
mobile phone
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.)
Pending
Application number
CN 201010545070
Other languages
Chinese (zh)
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.)
Shenyang Chenxun Simcom Technology Co Ltd
Original Assignee
Shenyang Chenxun Simcom Technology 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 Shenyang Chenxun Simcom Technology Co Ltd filed Critical Shenyang Chenxun Simcom Technology Co Ltd
Priority to CN 201010545070 priority Critical patent/CN102468853A/en
Publication of CN102468853A publication Critical patent/CN102468853A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Telephone Function (AREA)

Abstract

The invention discloses a method for realizing ADC function on a mobile phone with low cost, which fundamentally solves the problem of increased cost of the mobile phone caused by adding an ADC chip or adding an ADC module built in an analog switch multiplexing baseband chip. The technical key points are as follows: outputting high and low levels Vo with fixed period through a general IO port GPIO1 of the mobile phone baseband chip, and connecting a resistor R1 in series; the general IO port GPIO1 is connected with another general IO port GPIO2 of the baseband chip and a measured voltage Vi end connected with a resistor R2 in series in parallel and then connected with a capacitor C1, and the other end of the capacitor C1 is grounded; the general IO port GPIO2 detects a voltage Vt, and enables the voltage Vt to reach a threshold voltage range. The method has the advantage of reducing the cost of the mobile phone on the basis of ensuring the realization of the requirement of ADC function precision.

Description

The method of implemented with low cost ADC on mobile phone
Technical field
The present invention relates to the modulus conversion technique that mobile communication terminal adopts, particularly a kind of on mobile phone the method for implemented with low cost ADC function.
Background technology
Analog to digital converter (ADC) is for being responsible for analog signal conversion is become the electronic device of digital signal.Along with the development of integrated technique, the cost performance of analog to digital converter improves constantly, and its range of application is also more and more wider, particularly in the communications field.At present, analog to digital converter (ADC) module all is set in the baseband chip of mobile communication terminal (mobile phone).Along with market to the improving constantly of mobile phone functional requirement, cell-phone function is more and more, wherein a lot of functions all will be used the ADC module.Under these circumstances; Present mobile phone base band chip the not enough situation of ADC occurs through regular meeting; General remedial is the ADC module that adds the ADC chip or add analog switch multiplex baseband built-in chip type; This way can increase the mobile phone cost, and can take PCB (printed circuit board (PCB)) space.
Summary of the invention
The objective of the invention is for a kind of reliable, effective method of implemented with low cost ADC function on mobile phone is provided; Fundamentally solve the ADC module that adds the ADC chip or add analog switch multiplex baseband built-in chip type, the problem that the mobile phone cost that is brought increases.
Technical scheme of the present invention is: the method for implemented with low cost ADC function on mobile phone, its technical essential is: comprise the steps:
Export the high or low level (average voltage of a transfer process GPIO1 output is Vo) of fixed cycle through the universal I/O port GPIO1 of said mobile phone base band chip, GPIO1 connects resistance R 1 one ends; Another universal I/O port GPIO2 of said baseband chip connects resistance R 2 other ends.And GPIO2 connects a capacitor C 1, said capacitor C 1 other end ground connection.GPIO2 also connects a resistance R 2, and resistance R 2 other ends are exactly measured voltage Vi,
Set a variables A DC_Result, this variable record ADC conversion results is initialized as 0, sets a variables A DC_Bit again, and the conversion figure place of this specification of variables ADC is initialized as 0, utilizes universal I/O port GPIO2 to detect voltage Vt then;
When said universal I/O port GPIO2 reads voltage Vt when being high level, universal I/O port GPIO1 output low level at once then, variables A DC_Result adds 1 then; If it is low level that universal I/O port GPIO2 reads voltage Vt, then universal I/O port GPIO1 exports high level at once;
Delay time a small amount of time, said variables A DC_Bit adds 1;
According to the figure place of the ADC that will realize, judge whether said ADC_Bit equals the figure place respective value, if, this ADC function EOC; If, do not continue to utilize universal I/O port GPIO2 to detect voltage Vt to realizing ADC function EOC.
Advantage of the present invention and positive technique effect are: the present invention has just utilized two the universal I/O port GPIO1 and the GPIO2 of mobile phone base band chip; Add two resistance R 1, R2 and capacitor C 1 and realize the hardware requirement of conversion, set the figure place etc. of realization ADC function in addition through software programming.The present invention has just accomplished the translation function of ADC with extremely low cost with way of hardware and software combination; Fundamentally solve and use the ADC module that adds analog to digital converter (ADC) or add analog switch multiplex baseband built-in chip type, the problem that the mobile phone cost that is brought increases.Can set the figure place of realization ADC function simultaneously flexibly owing to software, and its conversion accuracy can be guaranteed.So having, the present invention guaranteeing to realize on the basis of ADC function required precision the advantage of reduction mobile phone cost.
Description of drawings
Fig. 1 is a realization sketch map of the present invention.
Fig. 2 is realization flow figure of the present invention.
Embodiment
Below in conjunction with accompanying drawing, specify technical scheme of the present invention.
Be illustrated in figure 1 as the circuit setting that realizes the ADC translation function.Vi wants measured voltage for us, and tested voltage Vi holds the resistance R 2 of having connected.The universal I/O port GPIO1 series resistance R1 of mobile phone base band chip, the resistance R 1 that while universal I/O port GPIO1 is connected, another universal I/O port GPIO2, tested voltage Vi end parallel connection back connect capacitor C 1, capacitor C 1 other end ground connection.Export the high or low level of fixed cycle through the universal I/O port GPIO1 of mobile phone base band chip; Universal I/O port GPIO2 detects voltage Vt; Can read voltage Vt is height or low level, and then control GPIO1 output is high or low level makes said voltage Vt reach the threshold voltage scope.
The groundwork of the method is exactly to make voltage Vt remain on the threshold voltage scope that universal I/O port GPIO2 detects under voltage Vo and the tested voltage Vi acting in conjunction of universal I/O port GPIO1 control.Because the threshold voltage of baseband chip is fixed, we can obtain voltage Vo through the high-low level ratio of output, and through Vt, Vo just can obtain we measured voltage Vi.
Be illustrated in figure 2 as the flow process that realizes the ADC translation function.
At first the high or low level through universal I/O port GPIO1 output is controlled voltage Vt, detects through universal I/O port GPIO2, makes voltage Vt reach universal I/O port GPIO2 detection threshold voltage range, and the purpose of doing like this is to eliminate the error of measuring at the beginning.
As voltage Vt during, begin to carry out the ADC conversion in the threshold voltage scope.Setting variable of two variablees is ADC_Result, the result of this variable record ADC conversion, and variable is relevant therewith for last measured voltage Vi.A variable is ADC_Bit, and software can be set the precision that ADC changes flexibly through this variable, such as realizing 8bit or 10bit ADC function.
The conversion beginning, at first universal I/O port GPIO2 detects voltage Vt, reads its level state, if read level for high, account for voltage Vt has been higher than threshold voltage.In order to keep voltage Vt in the threshold voltage scope, universal I/O port GPIO1 output is low, and then variables A DC_Result adds 1.If it is low that universal I/O port GPIO1 reads level, account for voltage Vt has been lower than threshold voltage, and in order to keep Vt in the threshold voltage scope, GPIO1 exports high;
And then delay time a small amount of set time such as 20us (its time is relevant with the RC constant), time-delay back variables A DC_Bit adds 1;
According to the figure place of the ADC that will realize, judge whether said ADC_Bit equals the figure place respective value.For example,, judge then whether ADC_Bit equals 255 if realize 8bit ADC function, if equal 255, ADC EOC this time then; If be not equal to, then universal I/O port GPIO2 continues measuring voltage Vt, keeps Vt voltage in threshold range through universal I/O port GPIO1 output is high or low, and the above-mentioned switch process that circulates is until realizing ADC function EOC.
Behind the EOC,, just can obtain tested voltage Vi through the numerical value of variables A DC_Result.The relation of ADC_Result and Vi is described below:
Can obtain following relational expression according to shown in Figure 1
(Vo?-?Vt)/?R1?=?(Vt?-?Vi)/?R2
By on can get: Vi=Vt – R2 (Vo-Vt)/R1
Vo=Vdd (1-ADC_Result/ADC_Bit) wherein
Then can obtain the size of voltage Vo through variables A DC_Result and ADC_Bit; Threshold voltage Vt size is fixed, and resistance R 1, R2 size all are known; Software has so just been realized the function of ADC fully through finally just having obtained the size of tested voltage Vi with co-relation.
Select different resistance R 1, R2 can determine the scope of measuring voltage, and its numerical value can be formulated according to actual needs.Such as on the basis of satisfying the measuring voltage range for convenience of calculation, two resistance can be set at 47K, and the representative value of oneself is all arranged as for every kind of baseband chip of threshold voltage.Different these numerical value of chip are different.

Claims (1)

1. the method for an implemented with low cost ADC function on mobile phone is characterized in that: comprise the steps:
Export the high and low level Vo of fixed cycle through the universal I/O port GPIO1 of said mobile phone base band chip, and series resistance R1; Be connected capacitor C 1, said capacitor C 1 other end ground connection after the tested voltage Vi end parallel connection of said universal I/O port GPIO1 and another universal I/O port GPIO2 of said baseband chip, the resistance R 2 of having connected; Said universal I/O port GPIO2 detects voltage Vt, makes said voltage Vt reach the threshold voltage scope;
Set a variables A DC_Result, this variable record ADC conversion results is initialized as 0, sets a variables A DC_Bit again, and the conversion figure place of this specification of variables ADC is initialized as 0, utilizes universal I/O port GPIO2 to detect voltage Vt then;
When said universal I/O port GPIO2 reads voltage Vt when being high level, universal I/O port GPIO1 output low level at once then, variables A DC_Result adds 1 then; If it is low level that universal I/O port GPIO2 reads voltage Vt, then universal I/O port GPIO1 exports high level at once;
Delay time a small amount of time, said variables A DC_Bit adds 1;
According to the figure place of the ADC that will realize, judge whether said ADC_Bit equals the figure place respective value, if, this ADC function EOC; If, do not continue to utilize universal I/O port GPIO2 to detect voltage Vt to realizing ADC function EOC.
CN 201010545070 2010-11-16 2010-11-16 Method for realizing ADC (analog to digital converter) on mobile phone at low cost Pending CN102468853A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 201010545070 CN102468853A (en) 2010-11-16 2010-11-16 Method for realizing ADC (analog to digital converter) on mobile phone at low cost

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 201010545070 CN102468853A (en) 2010-11-16 2010-11-16 Method for realizing ADC (analog to digital converter) on mobile phone at low cost

Publications (1)

Publication Number Publication Date
CN102468853A true CN102468853A (en) 2012-05-23

Family

ID=46072097

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 201010545070 Pending CN102468853A (en) 2010-11-16 2010-11-16 Method for realizing ADC (analog to digital converter) on mobile phone at low cost

Country Status (1)

Country Link
CN (1) CN102468853A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103532562A (en) * 2012-06-30 2014-01-22 硅实验室公司 Apparatus for mixed signal interface circuit and associated method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103532562A (en) * 2012-06-30 2014-01-22 硅实验室公司 Apparatus for mixed signal interface circuit and associated method
CN103532562B (en) * 2012-06-30 2018-07-03 硅实验室公司 For the device and correlation technique of mixed signal interface circuit

Similar Documents

Publication Publication Date Title
CN104218951B (en) The operating method of semiconductor devices and semiconductor devices
CN103138761A (en) Analog-digital conversion circuit and battery voltage detection circuit
CN101668057A (en) Terminal and system with function of multimeter
CN103873038B (en) Delay time adjusting circuit, delay time adjusting method and integrated circuit
CN204330870U (en) A kind of on-off model testing circuit
CN102468853A (en) Method for realizing ADC (analog to digital converter) on mobile phone at low cost
CN203554417U (en) SAR ADC (Successive Approximation Register Analog to Digital Converter) circuit and electronic equipment
CN204350278U (en) Communication device
CN204119024U (en) A kind of voltage signal conditioning circuit based on TL431
CN201698195U (en) Expansion circuit of single chip microcomputer IO ports
CN201237635Y (en) Battery voltage detector and mobile terminal with the same
CN107947782B (en) Circuit for improving transmission characteristics of optocoupler
CN213633549U (en) Communication module testing device
CN210518267U (en) Low-rate level conversion circuit
CN104635830A (en) Voltage signal conditioning circuit based on controllable precise voltage regulator
CN104571252B (en) A kind of polymorphic type analog signal processing circuit of single power supply
CN203537553U (en) An Interface circuit realizing serial port and infrared multiplex functions
CN210922683U (en) Batch detection circuit based on temperature and humidity sensor, PCB and device thereof
CN210667157U (en) Wireless data receiving device
CN204117011U (en) A kind of voltage signal conditioning circuit based on controllable accurate source of stable pressure
CN101825652A (en) Automatic range selector of measuring equipment
CN207706053U (en) A kind of power supply circuit for CCD camera assembly and the intelligent terminal with the power supply circuit
CN202395987U (en) Diagnosis circuit for microphone
CN220457381U (en) IC chip with built-in multiple reference voltage comparators
CN112147399A (en) Analog quantity acquisition module and type automatic identification circuit thereof

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C02 Deemed withdrawal of patent application after publication (patent law 2001)
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20120523