Summary of the invention
Technical matters to be solved by this invention provides a kind of wireless distributed power source aging test monitoring method and system, this wireless distributed power source aging test monitoring method and system can support the collection of plurality of voltages and temperature on the aging vehicle, finish the automatic test of a plurality of Switching Power Supplies.
The technical solution of invention is as follows:
A kind of wireless distributed power source aging test monitor system comprises that mainboard is used for the daughter board that is connected with the testing power supply of aging vehicle with being connected piece, and mainboard and daughter board communicate to connect;
Described daughter board comprises microprocessor, voltage collection circuit, temperature collection circuit and switches off control circuit; Voltage collection circuit, temperature collection circuit and being connected all is connected with microprocessor;
In the voltage collection circuit of daughter board, a plurality of signal input parts of the first MUX connect respectively the output voltage of the multi-channel test power supply of aging vehicle; The output terminal of the first MUX links to each other with the input port of microprocessor with the first A/D converter through amplifying circuit successively; The sheet choosing end of the first MUX all links to each other with the output port of microprocessor with passage gating end.
Described amplifying circuit is the adjustable amplifying circuit of enlargement factor that amplifies based on secondary, and its circuit structure is:
The positive input terminal of the first operational amplifier connects the output terminal of the first MUX through resistance R 1; The negative input end of the first operational amplifier is through resistance R 5 ground connection; The N of the second a MUX input end is received respectively the output terminal of the first MUX through N resistance; The output terminal of output termination first operational amplifier of N 〉=2, the second MUX; The output port of the passage gating termination microprocessor of the second MUX, the output terminal of the first operational amplifier also connects the positive input terminal of the second operational amplifier by resistance R 3; The negative input end of the second operational amplifier is through resistance R 6 ground connection; Cross-over connection has resistance R 4 between the positive input terminal of the second operational amplifier and the output terminal; The signal input part of output termination first A/D converter of the second operational amplifier.
Totally 8 of described the first MUX are 16 and select 1 analogue selector, altogether access 128 road voltage signals, and the input end with amplifying circuit behind the equal short circuit of the output terminal of all the first MUX joins;
Described the second MUX is 4 to select 1 analogue selector; N=4; The resistance that links to each other from the second MUX input end is 4 different resistance resistance.[be used for changing the amplifying circuit enlargement factor, corresponding prime enlargement factor is respectively 10 times, 5 times, 3 times, 1 times]
In the temperature collection circuit of daughter board, a plurality of signal input parts of the 3rd MUX connect respectively the output voltage of the multi way temperature sensor of aging vehicle; The output terminal of the 3rd MUX links to each other with the input port of microprocessor with the second A/D converter through second amplifying circuit successively; The sheet choosing end of the 3rd MUX all links to each other with the output port of microprocessor with passage gating end; Described the 3rd MUX is 16 to select 1 analogue selector; The amplifying circuit of described second amplifying circuit for being formed by 2 operational amplifier cascades.
In the switching off control circuit of daughter board, the serial data input end SI of deserializer, shift control end RSCK write control end RCK with register and all link to each other with the output port of microprocessor, and the M of a deserializer parallel output terminal connects respectively M output unit; M 〉=8; [deserializer is a plurality of, and a plurality of deserializers in twos one group of cascade use]
Microprocessor also connects an output unit with the general supply of control aging vehicle by an independent output port;
The structure of each output unit is: the signal input part of output unit connects the b utmost point of PNP triode by electronics R169; The e utmost point of PNP triode connects positive source, and the c utmost point of PNP triode connects the negative pole of diode D1, the plus earth of diode D1; The coil of relay is in parallel with diode D1; Relay has 3 output contacts, and the first contact and the second contact form normally closed switch, and the first contact and the 3rd contact form normal open switch;
When output unit was connected with i output terminal of M parallel output terminal of deserializer, the first contact met the i road power supply Vsi of aging vehicle; The second contact meets aging vehicle power supply Vs, the 3rd contact ground connection; I=1 ..., M;
When output unit was connected with the independent output port of microprocessor, the first contact met aging vehicle power supply Vs; The second contact meets external power supply Vss, the 3rd contact ground connection.
Mainboard is connected by the ZigBee module communication with daughter board.
Mainboard comprises MCU, ZigBee module and alarm module; ZigBee module and alarm module all are connected with MCU, and alarm module comprises 3 pilot lamp and hummer, mainboard and PC communication connection.
A kind of wireless distributed power source aging test monitoring method adopts at least one daughter board to monitor the aging vehicle of respective amount; Daughter board is communicated by letter with mainboard by wireless communication module, and mainboard is provided with alarm module; Daughter board 1) gathers the output voltage of a plurality of testing power supplies on the aging vehicle by voltage collection circuit, 2) gather temperature on the pull-up resistor that a plurality of testing power supplies are corresponding on the aging vehicle by temperature collection circuit, 3) power supply by each testing power supply of control that switches off control circuit.
In voltage collection circuit, amplify and the A/D conversion is laggard enters microprocessor through signal by a plurality of the first MUX gating one road voltage signals that are controlled by microprocessor; Signal amplifies by the adjustable amplifying circuit of enlargement factor to be realized;
In current collection circuit, amplify and the A/D conversion is laggard enters microprocessor through signal by a plurality of the 3rd MUX gating one road temperature signals that are controlled by microprocessor;
In the switching off control circuit of daughter board, microprocessor is finally controlled arbitrary road out-put supply access power supply VS or the deenergization VS of aging vehicle by a plurality of output units based on relay and triode of deserializer control;
Microprocessor also connects a described output unit by an independent output port and whether accesses external power supply VSS with the general supply of controlling aging vehicle.It is characterized in that, it is characterized in that, adopt aforesaid wireless distributed power source aging test monitor system to realize the power source aging test.
Beneficial effect:
Wireless distributed power source aging test monitoring method of the present invention and system adopt Distributed Design and communication, and this design favorable expandability is easy to installation and maintenance.Adopt the ports-Extending technology, improved the single-chip I/O mouth service efficiency, saved system cost.Coupled system software is so that system management and simple and convenient.
Described ports-Extending technology, simulated data selector switch and bus driving circuits in daughter board voltage and temperature collection circuit, have been used, so that daughter board can gather 128 the road or more multivoltage and temperature parameter, in daughter board switches off control circuit, use serial-parallel conversion circuit, can independently control 128 the road or the more shutoff of multiple power supplies and the shutoff of general supply.
Daughter board is accepted the mainboard management by the ZigBee wireless communication technology, to reduce system's line, makes things convenient for setup and manage;
The present invention adopts modular design, communication, has simple, the automaticity high of installation and maintenance.
Embodiment
Below with reference to the drawings and specific embodiments the present invention is described in further details:
Embodiment 1:
Such as Fig. 1, system mainly comprises detection daughter board, mainboard and host computer, each detects the monitoring that daughter board is responsible for an aging vehicle, when power supply status change or regularly then daughter board corresponding information can be uploaded to mainboard, and can be to carrying out the shutoff control of relay.Mainboard mainly is responsible for and the communicating by letter of host computer, the management of daughter board, warning, the management of daughter board mainly is the setting of voltage, temperature, time threshold, communicating by letter between mainboard and daughter board, what use is the ZigBee radio communication, can greatly reduce system wiring, improves the extensibility of system.On host computer, the voltage of test and temperature threshold, test duration can be set, can check the testing power supply state, software can be controlled the shutoff of each drive test examination power supply automatically simultaneously, and with logout in system journal.Be completed, the automatic closing system primary power forms test report simultaneously.
The daughter board subsystem is as shown in Figure 2: be divided into voltage acquisition path, temperature acquisition path, turn-off control module, four parts of communication module.Voltage acquisition at first passes through multi-channel data selector and (specifically selects 16 to select one device.) path that select to need gathers, then the use that also can save the IO mouth is input among the MCU behind bleeder circuit (when needing), amplifying circuit and A/D converter; The temperature acquisition path adopts the NTC thermistor, has stronger antijamming capability; In the shutoff control module, adopt serial mode output shutoff instruction, then wearing long also, change-over circuit changes into 16 tunnel shutoff instruction control driving circuits, the shutoff of last driving circuit driving relay; In the communication module, MCU is by universal serial bus and ZigBee module communication, and the ZigBee module is communicated by letter with mainboard by wireless transmission method again.Because the system data amount is very large, therefore only have the data of the state change of testing power supply just can upload, communication module is only transmitted a small amount of state variation data and some steering orders.
The main board system block diagram is as shown in Figure 3: mainboard is furnished with the ZigBee communication module and communicates by letter with daughter board, to carry out the parameter setting and to receive power supply state changing information; The warning subsystem responsible is according to the light on and off of power state information control signal lamp; Adopt at last 232 buses and PC to communicate.
1, hardware circuit design
1.1 daughter board hardware circuit design
The daughter board main control chip adopts certain 51 kernel single-chip microcomputer, and it adopts 51 ripe kernels, has abundant IO mouth available (80), is fit to very much this project application.12 ADC, 2 tunnel of in addition, also integrated 8 tunnel inputs are the UART communication module independently.
The voltage acquisition path adopts 16 to select 1 simulated data selector switch CD4067, data selector is selected corresponding path by sheet choosing and address bus, the sheet choosing is controlled by single-chip microcomputer P4 mouth, the address is controlled by a latch by the P5 mouth, so that the control signal of MCU is input to the address mouth of CD4067 simultaneously, to strengthen the stability to analogue selector control.Amplifying circuit adopts the two stage amplifer mode, and first order enlargement factor is adjustable, second level rectified input voltage polarity.The enlargement factor of amplifying circuit can be passed through the analogue selector regulating and controlling, enlargement factor control is by P0.4 and the P0.5 combination control of single-chip microcomputer, be divided into four shelves, corresponding enlargement factor is respectively 10 times, 5 times, 3 times, 1 times, voltage corresponding to its input is respectively 3.5~5V, 9~12V, 18~24V, (voltage of namely inputting 3.5~5V amplifies 10 times to 48~53V after unified dividing potential drop, the voltage of input 9~12V amplifies 5 times after unified dividing potential drop, the voltage of input 18~24V amplifies 3 times after unified dividing potential drop, the voltage of input 48~53V amplifies 1 times after unified dividing potential drop).Voltage acquisition has designed 8 the tunnel, and every road 16 selects 1 simulated data selector switch can gather 16 road voltages, and every daughter board can be responsible for gathering 128 road voltages like this.Voltage collection circuit as shown in Figure 4.
The temperature acquisition path adopts thermistor, and such as the RT1~RT127 in the accompanying drawing 5, temperature measurement range is-30 ℃~125 ℃, has very strong antijamming capability, can adapt to the strongly disturbing working environment of Switching Power Supply.The temperature acquisition path selects 1 simulated data selector switch by 16 equally, and its control mode is identical with voltage acquisition, and the sheet choosing is by the control of single-chip microcomputer P6 mouth, and the address is by the control of P7 mouth, and address bus has adopted bus driver equally.Temperature path amplifying circuit adopts the two stage amplifer mode equally, but enlargement factor is non-adjustable.Same every group of 16 passages of temperature acquisition, 8 groups of totally 128 paths.Temperature collection circuit as shown in Figure 5.
Turn-off control and adopted serial-parallel conversion circuit, adopted the cascade method of attachment of string and conversion chip 74LS595 as shown in Figure 6, be controlled to be one group with 16 the tunnel, totally 8 groups, only need 3 groups of IO mouths can realize that 128 the tunnel turn-off control.Also have in addition one the tunnel directly by single-chip microcomputer GPIO control, this road is used for controlling the aging vehicle general supply and turn-offs.Each testing power supply turn-offs control by single-chip microcomputer P1~P3 mouth control, and whole aging vehicle shutoff controlled by P0.7.Turn-offing driving circuit adopts the positive-negative-positive triode to drive.Switch off control circuit as shown in Figure 6.V among the figure
0~V
127Be 128 drive tests examination power supply, V
SBe aging vehicle power supply, V
SSBe external power supply.
Ripe circuit module is adopted in ZigBee communication in the communication module, and daughter board is by RS232 and ZigBee module communication.Therefore increase a slice level transferring chip MAX232 in the daughter board and the TTL/CMOS level is converted into the RS232 level gets final product, as shown in Figure 7.The RX of the communication module of daughter board, TX and RX, the TX cross connection of ZigBee module can realize communicating by letter of single-chip microcomputer and ZigBee intermodule.
1.2 motherboard hardware circuit design
The mainboard main control chip is the same with daughter board, and mainboard is provided with the two-way serial communication circuit, the one tunnel with the ZigBee module communication, the one tunnel communicates by letter with PC; Also have in addition warning circuit, adopt red, yellow, and green LED lamp and a hummer as warning device.Motherboard circuit is as shown in Figure 8:
2, Software for Design
2.1 daughter board program design
The signals collecting of daughter board software and security monitoring are operated in the master routine to be finished, and the daughter board master routine as shown in Figure 9.Adopt touring mode to gather voltage and the temperature information of each power supply, and according to Information Monitoring analyte sensors fault, power supply status.If there is sensor fault then failure message to be transferred to the ZigBee module by serial ports, the ZigBee module uploads to mainboard in the mode of wireless transmission again; If power state information changes (normal → unusual or unusual → normal), then take to turn-off control accordingly, and power state information is uploaded, what power transmission formula and sensor fault information were uploaded on it is the same.
The serial ports receive interruption of daughter board is processed function and is responsible for receiving mainboard through Threshold and shutoff steering order that the ZigBee wireless communication module sends, then carries out threshold value according to command information and resets or turn-off control, and its flow process as shown in Figure 10.
In order to realize the timing power-off function of aging vehicle, the master routine setting has also started timer, and Interruption is processed the power operation after function just is responsible for regularly arriving, and will finish instruction after the outage and upload to mainboard through the ZigBee wireless communication module, then waits for and restarting.Interruption is processed the function process flow diagram as shown in Figure 11.
2.2 mainboard program design
Mainboard is main management and the coordination function of rising in system, and its master routine mainly is responsible for the initial work of system and parameter, then is that idle loop waits for that main program flow chart as shown in Figure 12.Mainboard is communicated by letter with daughter board by the ZigBee wireless communication module by serial ports 0 again; Mainboard is then directly finished by serial ports 1 with communicating by letter of PC.Therefore, serial port of mainboard 0 receive interruption handling procedure is mainly processed and is received the data that daughter board is sent, and serial ports 1 receive interruption processing function is mainly processed the instruction of transmitting on the PC.
Serial ports 0 interrupts processing function mainly is responsible for processing the information that daughter board sends.After program parses information type, according to transmission (sending to the daughter board of request), controlling alarm, power supply status that information type is finished respectively threshold value upload, the work such as sensor fault is uploaded, finish that instruction is uploaded, its process flow diagram as shown in Figure 13:
Serial ports 1 receive interruption is processed function and then is responsible for processing the command informations such as the Threshold of upper computer software transmission, shutoff control, and the instruction that receives sends to daughter board by the Zigbee radio communication again.Its process flow diagram as shown in Figure 14.
2.3ZigBee program design
The ZigBee module just is responsible for the data transfer task in system, its workflow is constantly to receive and forwarding data, wherein, the ZigBee module on every daughter board receives only the data of mainboard ZigBee module, and mainboard ZigBee module then receives the data of other all ZigBee modules.
The master routine of daughter board ZigBee module mainly is responsible for the initialization of ZigBee module, then waits for serial ports receive interruption and ZigBee receive interruption.
Mainboard is responsible for the similar of ZigBee module program design and daughter board, and just the ZigBee receive interruption is processed and lacked a data source verification step.
2.3 upper computer software design
The upper computer software framework comprises that mainly system management, parameter setting, state show, fault shows, aging vehicle is managed several modules as shown in Figure 15, and system master interface as shown in Figure 16.The function of system management module has account management, rights management, system journal etc., guarantees system safety operation; It mainly is to be responsible for the setting of voltage, temperature detection threshold value, the setting of aging vehicle test duration that parameter arranges module; The state display module is responsible for showing that the state of aging vehicle and power supply shows, intend adopting graphical display mode Pagination Display, every page of real-time status that shows an aging vehicle and testing power supply thereof, the state color differentiating of each power supply, green is normal, and redness is unusual; The fault display module is responsible for showing sensor fault information, adopts forms mode to show, form data should comprise aging vehicle under the fault sensor, the numbering in aging vehicle and position thereof, possible fault type etc.; The aging vehicle administration module be responsible for fault get rid of resume work or finish when testing after the test aging vehicle next time some turn-off operation.
Daughter board and mainboard have adopted wireless distributed management design.Mainboard and daughter board have adopted principal and subordinate's design, and a mainboard can be managed 256 and detect daughter board, and every daughter board can be managed the burn-in test process monitoring of 128 road power supplys.Adopt the ZigBee wireless communication technology between mainboard and daughter board, can simplify system's line, make things convenient for system's setup and manage.System can arrange the intelligent management of realizing the power source aging test monitoring by software.System software can arrange a series of power source aging test parameters such as the required voltage detecting threshold value of power source aging test, monitoring temperature threshold value, burn-in test time; Simultaneity factor can also realize the functions such as outage, fault demonstration under abnormal conditions; At last can be after test be finished auto-breaking, form the functions such as testing journal sheet.
Daughter board namely can be managed the nearly burn-in test monitoring of 128 road power supplys by adopting a series of ports-Extending technology by 8 single-chip microcomputers of 1 cheapness.The power source aging monitoring content comprises: the collection of voltage, temperature signal, power remove are controlled, test parameter arranges etc.
Described ports-Extending technology is characterized in that having adopted respectively in voltage, temperature collection circuit and selects for 8 group 16 1 simulated data selector switch to carry out ports-Extending, shown in accompanying drawing 4 and accompanying drawing 5.Microcontroller selects control end by address bus and the sheet of control data selector, can select voltage and the temperature acquisition signal of 128 drive tests examination power supply.Driving force in order to ensure driving address bus is connected to the bus driver chip between microprocessor controls port and the address bus.
Described ports-Extending technology is characterized in that the ports-Extending that adopts the serial-parallel conversion circuit realization to switch off control circuit switching off control circuit.Serial-parallel conversion circuit is comprised of 8 bit strings and conversion chip, and per two 8 bit strings and conversion chip are cascaded into one group of 16 bit string and change-over circuit, 8 groups of these the electric circuit constitutes 128 road independent current sources switch off control circuit, as shown in Figure 6.