1. Trang chủ
  2. » Kỹ Thuật - Công Nghệ

Battery Charge Meter ppsx

75 144 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 75
Dung lượng 373,46 KB

Nội dung

Battery Charge Meter 4-76 system related data. In the other direction, the host can transfer instructions; stop or start of charge, start of data transmission, etc. The EEPROM contains the characteristic of the controlled accumulator (maxi- mum current, nominal capacity, end of charge criteria etc.) The EEPROM also contains the actual capacity (dependent on age and charge cycles) and a safe- ty copy of the actual charge register. For additional hardware proposals see Section 5.7, Battery Check and Power Fail Detection . COM SEL A1 A0 AGNDV SS P0.x 32 kHz LCD V CC TXD RCD DATA CLK EEPROM FULL SV CC Rext P0.y Voltage Regulator 3 V P0.z Current R3 Voltage A1 R2 R1 Batteries Load Shunt To Charger To Host Temperature Rex Q1 Figure 4–37. Battery Charge Meter MSP430C32x Connection of Sensors 4-77 Application Examples 4.7 Connection of Sensors The MSP430 family allows the connection of nearly all types of sensors. Some special connections are shown in the following sections. 4.7.1 Sensor Connection and Linearization Figure 4–38 shows the connection of simple resistive sensors to the MSP430C32x. The current source resistor Rex needs to be calculated in a way that allows its use for both sensor circuits (Rsens2 and Rsens3). The different connections, shown in Figure 4–38, are described in detail in Chapter 2, The Analog-to-Digital Converters . A7 AGND V SS A2 AGND SV CC Rext A0 A3 Rex I CS A1 R LIN R SENS2 R SENS1 R V SV CC A5 A4 A6 R SENS3 R SENS4 R1 R1 V I V CC 0 V 3 V or 5 V Figure 4–38. Resistive Sensors Connected to MSP430C32x 4.7.1.1 Voltage Supply The sensor Rsens1, in Figure 4–38, is connected this way. Resistor Rv sup- plies the sensor and is used for the Linearization also. The optimum value of Rv with dependence of Rsens is: Rv + Rm ( Ru ) Ro ) * 2 Ru Ro Ru ) Ro * 2 Rm Where: Ru Sensor resistance at the lower temperature limit Tu Ro Sensor resistance at the upper temperature limit To Rm Sensor resistance at the midpoint temperature (To + Tu)/2 The ADC values measured are independent of the supply voltage Vcc be- cause the measurements are made relative to Vcc. Connection of Sensors 4-78 4.7.1.2 Current Supply Sensor Rsens2, in Figure 4–38, is connected this way. If a linearization of the sensor is desired, the same formula used for the resistor Rv with voltage sup- ply can be used for the resistor Rlin (see Section 4.7.1.1, Voltage Supply ). 4.7.1.3 Use of Reference Resistors Two measurement methods with reference resistors are possible; use of one reference resistor, and, use of two reference resistors: - Measurement with one reference resistor: the reference resistor is chosen so that it equals the sensor resistance at the most important measurement point. Eventually, sensor and reference resistors are selected as pairs. The offset error is completely eliminated. So, only the slope error needs to be corrected. - Measurement with two reference resistors: the two reference resistors represent the sensor resistances at the limits of the measurement range. This method also corrects the influence of the internal resistance (RDSon of the TP outputs). If sensor and reference resistors are paired, no calibra- tion is necessary with this method. With two reference resistors Rref1 and Rref2 it is possible to compute slope and offset and to get the value of an unknown resistors Rx exactly: Rx + Nx * Nref1 Nref2 * Nref1 ( Rref2 * Rref1 ) ) Rref1 Where: Nx ADC conversion result for Rx Nref1 ADC conversion result for Rref1 Nref2 ADC conversion result for Rref2 Rref1 Resistance of Rref1 [Ω] Rref2 Resistance of Rref2 [Ω] As previously shown, only known or measurable values are needed for the cal- culation of Rx from Nx. Slope and offset of the ADC are corrected automatically. Connection of Sensors 4-79 Application Examples V SS TP.0 CIN TP.3 TP.1 R REF2 R SENS2 R SENS1 V CC 0 V 3 V or 5 V TP.2 R REF1 AGND C1 Figure 4–39. Measurement with Reference Resistors 4.7.1.4 Connection of Bridge Assemblies This kind of sensor is best known for pressure measurement: the voltage dif- ference of the bridge legs changes with the pressure to be measured. AGND V SS A2 AGND SV CC Rext A0 A3 A1 R2 SV CC A5 Bridge Assembly 2 V CC 0 V 3 V or 5 V Temp 1 _ + Temp 2 R1 V M V P Reference Bridge Assembly 1 A4 MSP430x32x Figure 4–40. Connection of Bridge Assemblies Figure 4–40 shows on its left side a bridge assembly that creates a voltage dif- ference that is big enough to be measured by the ADC of the MSP430. The measurement result is the difference of the two results of the analog inputs A2 and A1. Due to the temperature dependence of most bridge assemblies, a compensation of this dependence is necessary. The sensor, Temp1, is used to measure the temperature of the bridge legs. It is integrated in some bridge assemblies. Connection of Sensors 4-80 The used formula is: P + MWP ( Ye ) ( t * Tk ) Tke ) ) Yo ) ( T * Tk ) Tko Where: P Pressure to be measured MWP Difference of the measured values at A2 and A1 Ye Sensitivity of the pressure sensor T Temperature of the sensor Tke Temperature coefficient of the sensitivity Yo Offset Tko Temperature coefficient of the offset Tk Temperature during Calibration (e.g. +25ºC) The units depend on the system used (hP, kg/m 2 , kg/mm 2 a.s.o.) If the difference of the two measurements is too small to be used, an operation- al amplifier, as shown in Figure 4–40, can be used. Here the ability to measure the reference voltage (one of the two bridge legs) is shown also. Analog input A4 measures the reference that can be used for the A3 input. The same formu- la as shown previously can be used when MWP is calculated as shown in the following. MWP Difference of the measured values at A4 and A3: MWP = (A3 – A4) The actual measured voltage difference ∆V between the analog inputs A3 and A4 is: ∆V + V A3 * V A4 + v ( Vp * Vm ) ) Vp * Vp + v ( Vp * Vm ) Where: ∆V Voltage difference between analog inputs A3 and A4 [V] v Amplification of the operational amplifier: v = R1/R2 Vp Voltage at the bridge leg connected to the non-inverting input [V] Vm Voltage at the bridge leg connected to the inverting input [V] The use of the reference input A4 results in correct values for the measure- ments. If just the differences of two A3 measurements are used, the result needs to be corrected due to the following behavior: ∆V + V A32 * V A31 + v ( Vp2 * Vp1 * ( Vm2 * Vm1 )) ) Vp2 * Vp1 ∆V + ( v ) 1 )( Vp2 * Vp1 ) * v ( Vm2 * Vm1 ) Connection of Sensors 4-81 Application Examples It is shown that the voltage differences of the two bridge legs are amplified by different factors (v resp v+1). 4.7.1.5 Fixing of Bridge Assemblies into one ADC Range Bridge assemblies normally output only small signals, which makes amplifica- tion necessary, and have a relatively high temperature dependency. Both ef- fects together can shift the small amplifier output range over a large input range of the ADC. The four ranges A, B, C, and D of the ADC do not necessarily conform (slope and offset). Figure 4–41 shows a simplified characteristic of the ADC of the MSP430. Two different output ranges of the operational amplifier are indicated. The simplest way to get high accuracy is to fix the output range of the amplifier to only one ADC range; the one where the calibration was made. Range 2 Range A Range B Range C Range D ADC Value 0FFFh 1FFFh 2FFFh 3FFFh ADC Error (Steps) Range 1 10 –10 Figure 4–41. Simplified ADC Characteristic This fix is made by two TP outputs with the resistor values R and 3R (see Fig- ure 4–42). The software modifies the output state of these two TP outputs in a way that for a known state of the bridge (e.g., no load for a scale), the amplifi- er output is within a certain range of the ADC. Due to the possible TP-port out- put states Vcc, Vss and high impedance, nine different and nearly equally spaced correction currents Icorr are available. The correction is possible for the positive and for the negative direction. The correction current Icorr can also be fed into the bridge leg, Vm. The equation to calculate the correction resis- tors R and 3R is: Rb 2 v SV CC * SV CC 2 R| | 3R ) Rb 2 w SV CC 4 ³ R t Rb 4v * 2 3 Where: Rb Resistance of a bridge leg [Ω] Connection of Sensors 4-82 R Resistance of the correction resistor [Ω] v Amplification of the operational amplifier: v = R1/R2 AGND V SS A3 R2 SV CC TP.0 Bridge Assembly V CC 0 V 3 V or 5 V _ + R1 V M V P Reference A4 TP.1 3xR R I CORR R B R B MSP430x32x Figure 4–42. Fixing of Bridge Assemblies into One ADC Range 4.7.2 Connection of Special Sensors Not just analog sensors can be connected to members of the MSP430 family. Nearly all existing sensors can be connected to the MSP430 in a simple way. The following examples show this. 4.7.2.1 Gas Sensors The Figure 4–43 shows the connection of two gas sensors (CH 4 , hydrogen, alcohol, carbon monoxide, ozone, etc.). The gas sensor at the right side of the figure (connected to A0) is supplied by the internal current source of the MSP430C32x, where the current flowing through the sensor is defined by the resistor, Rex. The gas sensor shown on the left side of Figure 4–43 (connected to A1), owns a load resistance, RL, where the output voltage can be measured with the ADC input A1. Both sensors are heated by a pulse-width modulated voltage. The midpoint current is 133 mA, the power is 120 mW. The measurement of the sensor re- sistances is always made during the period with no current flow. The temperature dependence of the sensor is corrected by the measurement of the sensor temperature. This is made by sensor Temp2. Only the MSP430C32x can be used for this kind of sensors. They are not po- tential free so the Universal Timer/Port cannot be used. Connection of Sensors 4-83 Application Examples 32 kHz P0.x,Oy SV CC A1 Rext V SS A4 P0yx,Oz V CC A3 0 V 4 RH 1 3 2 Temp1 VH 5 V FIS SP-xx/ST-xx IH = 63 – 80 mA(SP-xx) IH = 200 mA(ST-xx) RL AGND 0 V 0 V 5 V Rex R L A2 A0 Temp2 5 V VH AGND AGND AGND 1 3 2 FIS BP-xx I MSP430x32x Figure 4–43. Gas Sensor Connection to the MSP430C32x The left part of Figure 4–43 shows the connection of another gas sensor. The heating of the sensor is done with 5-V dc. The connection is only possible as shown. Therefore, the current source cannot be used. Temperature com- pensation of the measurement result is needed here also. Sensor Temp1 is used for this purpose. 4.7.2.2 Digital Sensors Figure 4–44 shows two digital thermometers. They are controlled by instruc- tions via the data bus DQ. The signed measurement result (9 bits) and other internal registers are accessible via the data bus DQ. The circuit shown on the left uses a clock line for the data transfer, the right one differs the signals by their length (short is 1, long is 0). Connection of Sensors 4-84 V SS SV CC , V CC P0.x, Oz V CC 0 V 5 V P0.y AGND V DD CLK DQ RST GND P0.y, Oy DS1820 V SS SV CC , V CC V CC 0 V 3 V (5 V) P0.y AGND V DD DQ GND DS1820 To Other DS1820 Figure 4–44. Connection of Digital Sensors (Thermometer) 4.7.2.3 Sensors with Frequency Output The output signal of these sensors is a frequency that is proportional to the measured value. This output frequency can be connected to any of the eight inputs of Port0 and counted via interrupt with a simple software routine. The frequency is the number of interrupts occurring in a one second window de- fined by the basic timer. If the frequencies to be measured are above 30 kHz, the Universal Timer/Port or the 8-bit Interval Timer/Counter can be used for counting. The left part of Figure 4–45 shows the connection of the linear light-frequency converter (TSL220) to the MSP430. The TSL220 outputs a frequency propor- tional to the incoming light intensity. The range of this output frequency is de- fined by the capacitor, Cf. Timer_A is ideally suited for these applications (see Section 6.3, The Timer_A ). Connection of Sensors 4-85 Application Examples V SS SV CC , V CC V CC 0 V 3 V or 5 V P0.y AGND V DD OUT GND TSL220 C1 C2 C F Light V DD GND Data Sensor P0.x,CIN TAx AGND Figure 4–45. Connection of Sensors with Frequency Output Respective Time Output 4.7.2.4 Time Measurements If the information to be measured is represented by pulse distances or pulse widths, it is also easily measured with the MSP430. The right side of Figure 4–45 shows how this is done. The signal to be measured is connected to one of the eight inputs of Port0. Each one of these I/Os allows interrupt on the trailing and on the leading edge. With the basic timer, an appropriate timing is selected for the desired resolution and the measurement is made. The Universal Timer/Port can be used for this purpose also. The pulse to be measured is connected to terminal CIN and the time is measured from edge to edge. Even better resolution is possible with Timer_A. The input signal is connected to one of the TA inputs and a capture register is used for the time measure- ments (see Section 6.3, The Timer_A ). 4.7.2.5 Hall Sensors Digital hall sensors have an output signal that indicates when the magnetic flux flowing through them is larger or smaller than a certain value. They normally show a hysteresis. Figure 4–46 shows the connection of a revolution counter realized with the TL3101. Everytime one of the wings breaks the magnetic flux through the TL3101, a negative pulse is generated and outputed. These pulses are counted by the MSP430 with interrupts. [...]... Second Data Block Figure 4–54 Sequence of Data Transmission 4.8.6 RF Readout with Other Metering Applications The RF readout solutions shown can also be used for gas meters, water meters, heat allocation meters, and other metering applications The voltage supply for the RF part needs to be adapted to the battery used A battery with a high internal resistance needs a large capacitor in parallel to deliver... current consumption during the low power mode 3 4.9.3.2 Self Discharge of the Battery The self discharge element of the current consumption can not be influenced The battery manufacturer recommendations should be followed It is recommended that the battery be placed in a relatively cool location inside of the case This means do not place the battery next to hot parts (e.g., the radiator to be measured... the radiator to be measured with a heat cost allocator) An estimation value often used for the self discharge of a battery during 10 years, is to calculate only with 70% of the nominal charge This relates to 3.5% self discharge per year Expressed by a discharge current this means 2 µA for a 0.5 Ah battery 4.9.3.3 Current Consumption of Other System Components This current is composed of different parts... Key Range Control VSS + P0.z P0.n VCC P0.k Pulse Ws –2.5 V N R S T –2.5 V 2.5 V Backup Battery To Loads Figure 4–49 MSP430 EE Meter With RF Readout Application Examples 4-89 RF Readout 4.8.3 MSP430 Ferraris-Wheel Electricity Meter with RF Readout If an RF readout is needed for conventional Ferraris-wheel electricity meters, an MSP430C31x can be used An optical or magnetic pick-up counts the revolutions... Figure 4–60 Turn Off of External Circuits With the consumption values now known, the lifetime of the battery can be calculated: t Batt + Q I CC Batt )I Sys Where: tBatt Lifetime of the battery in hours Application Examples 4-101 Ultra-Low-Power Design With the MSP430 Family QBatt Icc ISys Usable charge of the battery in Ah (70% of 0,5 Ah for this example) Supply current of the MSP430 in A (1.83µA for this... TSS721 MBUS RCD RCV P0.y IR-IF Key + P0.z VSS VCC P0.k Pulse Ws –2.5 V –2.5 V 2.5 V Backup Battery Figure 4–50 MSP430 With a Ferraris-Wheel Meter and RF Readout 4-90 kW kWh RF Readout 4.8.4 RF-Interface Module The RF-interface module is normally connected to a supply voltage coming from the power supply of the EE Meter If this voltage is not available, the stepup power supply (shown in Figure 4–51) can... RCV 0V Range Control P0.y IR-IF A5 Key + P0.z P0.n VSS VCC –2.5 V P0.k 2.5 V Pulse Ws –2.5 V N R S T Backup Battery To Loads Figure 4–48 MSP430C32x EE Meter with RF Readout 4.8.2 MSP430 Electricity Meter with Front End Figure 4–49 shows an electricity meter with the MSP430C31x This singlechip microcomputer contains all necessary peripherals on-chip except the EEPROM and an ADC The measurement of voltage... gives an overview of these rules 4.9.1 The Ultra Low Power Concept of the MSP430 A lot of microcomputer applications need to be driven by a battery It is important for these applications to run as long as possible with as small a battery as possible To reach a battery life longer than 5 years, often the configuration shown in Figure 4–55 is used: - A low-frequency oscillator feeds a prescaler that... = 20°C and the consumption values calculated before the lifetime of the battery is: t Batt + 0.7 0.5 Ah + 84745 h 1.83 µA ) 2.3 µA This number of hours is equivalent to 9.6 years For ambient temperatures deviating from TA = 20ºC the typical values for ILPM3 can be seen in Figure 4–57 The exact values for the self-discharge of a battery can be found in the device specification 4.9.4 Correct Termination... MSP430 solution The cost advantage with fewer external components is obvious 32 kHz LCD SEL COM P0.x Port Port Port A0 A1 A2 VSS Signals Error m3 kWh Peripherals VDD 0.5 Ah Sensors Battery Figure 4–56 Solution with MSP430 for a Battery- Driven System The only constantly active components are the 32-kHz oscillator, the basic timer (which wakes-up the CPU in regular time intervals), the RAM, the LCD driver, . Battery Charge Meter 4-76 system related data. In the other direction, the host can transfer instructions; stop or start of charge, start of data transmission,. kHz LCD V CC TXD RCD DATA CLK EEPROM FULL SV CC Rext P0.y Voltage Regulator 3 V P0.z Current R3 Voltage A1 R2 R1 Batteries Load Shunt To Charger To Host Temperature Rex Q1 Figure 4–37. Battery Charge Meter MSP430C32x Connection of Sensors 4-77 Application Examples 4.7. Transmission 4.8.6 RF Readout with Other Metering Applications The RF readout solutions shown can also be used for gas meters, water me- ters, heat allocation meters, and other metering applications. The voltage

Ngày đăng: 24/07/2014, 04:20