Utility model content
The application provides a kind of electronic equipment reduces the burning of Flash chip to simplify the burning process of Flash chip
Cost.
The embodiment of the present application provides a seed device:Master control unit, Flash chip are electrically connected with the master control unit
The processing component connect further includes the first control units part and the second control unit, wherein the first control units part and the master control
Component, the processing component, the Flash chip are electrically connected, second control unit and the master control unit, the place
Reason component, external storage unit are electrically connected;
The processing component is used in the output signal exception for detecting the master control unit, control first control
Component disconnects with the master control unit and connect the first control units part with the first Processing Interface of the processing component,
Second control unit and the master control unit is controlled to disconnect and by second control unit and the processing component
Second processing interface connects, and waits for recordable paper from storage unit acquisition by the second processing interface, and this is described
Wait for that recordable paper is burnt to the Flash chip by first Processing Interface, and when burning is completed, control described first
Control unit disconnects with first Processing Interface and is electrically connected the first control units part with the master control unit, control
The second processing interface of second control unit and the processing component disconnect and by second control unit with it is described
Master control unit is electrically connected.
First Processing Interface is the first processing SPI interface, and the second processing interface is second processing USB interface.
Preferably, the processing component is connect especially by third processing GPIO interface with the first control units part, is led to
Fourth process GPIO interface is crossed to connect with second control unit.
Preferably, the master control unit is connect especially by the first master control SPI interface with the first control units part, is passed through
Second master control USB interface is connect with second control unit.
Preferably, the master control unit is connect especially by third master control GPIO interface with the processing component;
The third master control GPIO that the master control unit is specifically not detected in the processing component in preset time connects
When mouth output high level signal, determine that the output signal of the master control unit is abnormal.
Preferably, the master control unit is main control chip, and the processing component is microcontroller, and the first control units part is
Digital switch, second control unit switch for USB.
Preferably, the storage device is USB flash disk.
Preferably, the processing component also preserves the filename for waiting for recordable paper, and the processing component specifically exists
Determine that the filename for waiting for recordable paper in the storage unit waits for recordable paper with the described of processing component preservation
Filename it is consistent when, from the storage unit acquisition wait for recordable paper.
Preferably, the electronic equipment further includes the tip parts being electrically connected with the processing component, the processing component
It is additionally operable to there is no described when recordable paper on determining the storage unit, control the tip parts and issue the user with
The standby signal of recordable paper is waited for described in the storage unit storage, and detects the storage unit again every preset duration
In with the presence or absence of described wait for recordable paper.
Preferably, the electronic equipment is EMBEDDED AVIONICS.
The embodiment of the present application has the beneficial effect that:In the embodiment of the present application, in the state that the output of master control unit is normal,
Flash chip is connect by the first control units part with master control unit, is normally worked, and is detecting the defeated of master control unit
When going out abnormal, processing component can control the first control units part and be disconnected with master control unit, and by the first control units part and handle
The first Processing Interface connection of component, the second control unit of control are disconnected with master control unit, and by second master control unit and are located
Manage the second processing interface connection of component, and by second interface obtain outside storage unit wait for recordable paper, by the
One Processing Interface is burnt to Flash chip, and then can be completed to Flash in the case where that need not be dismantled to Flash chip
The burning of chip, and when burning is completed, control the first control units part is disconnected with processing component, and itself and master control unit are connected
It connects, the second control unit of control is disconnected with processing component, and it is connect with master control unit, and then makes Flash chip and master control
Component is connected, and so that electronic equipment is worked normally, when to Flash chip burning, need not additionally be occupied master control unit
Interface resource need not also dismantle Flash chip, to Flash chip burning process simple operation, reliable and stable.
Specific implementation mode
The realization process of the embodiment of the present application is described in detail with reference to the accompanying drawings of the specification.It should be noted that
Same or similar label indicates same or similar element or element with the same or similar functions from beginning to end.Lead to below
It crosses the embodiment being described with reference to the drawings to be exemplary, is only used for explaining the application, and should not be understood as the limitation to the application.
Shown in referring to Fig. 1 and Fig. 2, the embodiment of the present application provides a kind of electronic equipment, including:Master control unit 1, Flash cores
Piece 2, the processing component 4 being electrically connected with master control unit 1 further include the first control units part 31 and the second control unit 32.
Wherein, in normal state, the first control units part 31 and master control unit 1, processing component 4, Flash chip 2 electricity
Connection, the second control unit 31 are electrically connected with master control unit 1, processing component 4, external storage unit 5.
Processing component 4 is used in the output signal exception for detecting master control unit 1, shown in Figure 2, the first control of control
Component 31 processed disconnects with master control unit 1 and connect the first control units part 31 with the first Processing Interface 41 of processing component 4, controls
The second control unit 32 is made to disconnect with master control unit 1 and by the second processing interface of second control unit 32 and processing component 4
42 connections, and this is waited for that recordable paper waits for recordable paper by second processing interface 42 from the acquisition of storage unit 5, at first
Reason interface 41 is burnt to Flash chip 2, and when burning is completed, and controls the first control units part 31 and the first Processing Interface 41 is disconnected
It opens and is electrically connected the first control units part 31 with master control unit 1, at the second control unit of control 32 and the second of processing component 4
Reason interface 42 disconnects and is electrically connected second control unit 32 with master control unit 1.
In the embodiment of the present application, in the state that the output of master control unit is normal, Flash chip passes through the first control units part
It connect with master control unit, is normally worked, and in the output abnormality for detecting master control unit, processing component can control
The first control units part is disconnected with master control unit, and the first Processing Interface of the first control units part and processing component is connected, control
It makes the second control unit to disconnect with master control unit, and second master control unit and the second processing interface of processing component is connected,
And recordable paper is waited for by the storage unit outside second interface acquisition, and this is waited for that recordable paper passes through the first Processing Interface
It is burnt to Flash chip, and then the burning to Flash chip can be completed in the case where that need not be dismantled to Flash chip
Record, and when burning is completed, control the first control units part is disconnected with processing component, and it is connect with master control unit, controls the
Two control units are disconnected with processing component, and it is connect with master control unit, and then Flash chip is made to be connected with master control unit,
Electronic equipment is set to be worked normally.
In the specific implementation, master control unit 1 can be main control chip, and processing component 4 can be microcontroller, the first control units
Part 31 can be digital switch, and the second control unit 32 can be that USB is switched, and storage device 5 can be USB flash disk, wherein number is opened
It is a kind of single-pole double-throw switch (SPDT) to close similar with USB switches, by digital switch and USB switches in different situations in main control part
Switch between part and processing component, and then complete to wait for that recordable paper is burnt to Flash chip, and makes Flash chip and master
Control normal work when component connection.First Processing Interface 41 can be the first processing serial peripheral (Serial Peripheral
Interface, SPI) interface, second processing interface 42 can be second processing general serial (Universal Serial Bus,
USB) interface.
In the specific implementation, being electrically connected for processing component 4 and the first control units part 31, processing component 3 and second are controlled
The electrical connection of component 32 processed, shown in Figure 3, processing component 4 handles universal input/output (General especially by third
Purpose Input Output, GPIO) interface 43 connect with the first control units part 31, by fourth process GPIO interface 44 with
Second control unit 32 connects, to be and master control unit 1 according to the output situation of master control unit 1 control the first control units part 31
Connection, or connect with processing component 2, that is, the first control units part 31 is handled during burning with the third of processing component 4
GPIO interface 43 is always maintained at connection status, fourth process of second control unit 32 during burning with processing component 4
GPIO interface 44 is always maintained at connection status.
Preferably, for the connection of master control unit 1 and the first control units part 31, referring to Fig. 4, master control unit 1 especially by
First master control SPI interface 11 is connect with the first control units part 31, is connected by the second master control usb 12 and the second control unit 32
Connect, that is, will after recordable paper is burnt to Flash chip 2 or when determining that the output signal of master control unit 1 is normal,
One control unit 31 is specifically electrically connected with the first master control SPI interface 11 of master control unit 1 so that the first control units part 31 and master control
Component 1 is electrically connected, and the second control unit 32 is specifically electrically connected with the second master control usb 12 of master control unit 1 so that the second master
Control component 32 is electrically connected with master control unit 1.In the embodiment of the present application, after it will wait for that recordable paper is burnt to Flash chip 2 or
When determining that the output signal of master control unit 1 is normal, the first control units part 31 specifically connects with the first master control SPI of master control unit 1
Mouth 11 is electrically connected, and the second control unit 32 is specifically electrically connected with the second master control usb 12 of master control unit 1, due to main control part
Part 1 is generally both provided with SPI interface and USB interface, and then can be burnt to Flash chip that will wait for recordable paper and make
It, can be with by being multiplexed the SPI interface and USB interface of master control unit when Flash chip is electrically connected with master control unit to work normally
Without the interface resource for additionally occupying master control unit.
Preferably, processing component 4 is electrically connected with master control unit 1, shown in Figure 5, master control unit 1 is especially by
Three master control GPIO interfaces 13 are connect with the 5th processing GPIO interface 45 of processing component 4, that is, processing component 4 is in preset time
When the output high level signal of third master control GPIO interface 13 of master control unit 1 being not detected by the 5th processing GPIO interface 45,
Determine that the output signal of master control unit 1 is abnormal.Certainly, in the specific implementation, the output signal of processing component detection master control unit
It is whether normal, it, can also be by detecting number of pulses or pulse in addition to detecting output low and high level detection by GPIO interface
Sequence is realized.If system resource is sufficient, it can also be realized and be detected by low speed bus such as serial ports, I2C.
It is shown in Figure 6, in the specific implementation, for Flash chip 2, SPIFlash interfaces 20 can also be provided with,
External storage component 5 can be electrically connected by the equipment USB interface of electronic equipment with the second control unit.
It is below main control chip with master control unit 1, processing component 4 is microcontroller, and the first control units part 31 is digital switch,
Second control unit 32 be USB switch, External memory equipment be USB flash disk for, to electronic equipment provided by the embodiments of the present application
Operation principle is specifically described as follows:
In the initial state, digital switch and USB switches are electrically connected with main control chip, that is, digital switch and master control core
First master control SPI interface of piece connects, and USB is switched to be electrically connected with the second master control USB switches of main control chip;And detecting master
When controlling the output signal exception of chip, microcontroller controls digital switch and USB switches are disconnected with main control chip, by the two and list
Piece mechatronics, specifically, the first processing SPI interface of digital switch and microcontroller be electrically connected, the of USB switches and microcontroller
Two processing USB interface connections, and by the USB flash disk outside monolithic machine testing with the presence or absence of recordable paper is waited for, if there are this to wait for burning
Microcontroller is then read this and waits for recordable paper by file, and is burnt in Flash chip;Later, microcontroller control number is opened
It closes and USB switches is electrically connected with main control chip, reset main control chip.Wherein, since for general main control chip, it is all arranged
There are SPI interface and USB interface, the application to carry out burning by being multiplexed the free SPI interface of main control chip itself and USB interface,
It is not take up the SPI interface and USB interface resource of main control chip, and then the cost of burning Flash chip can be reduced.
In the specific implementation, in the specific implementation, whether need the file of burning in storage unit 5 for how to determine,
Can be specifically to preserve the filename for waiting for recordable paper in processing component 4 in advance, and wait burning by detecting in storage unit 5
Record file filename with preserved in processing component 4 when the filename of recordable paper is consistent, determine and exist in storage unit 5
Need the file of burning, and then will wait for that the file of burning is saved in Flash chip 2.And when the two is inconsistent, determination is currently deposited
There is no the files for waiting for burning in storage component 5.For storage unit 5 there is currently no when recordable paper, electronic equipment may be used also
Tip parts is arranged, which can specifically be electrically connected with processing component 4, and processing component 4 is in determining storage unit 5
There is currently no when recordable paper, control tip parts, which sends out prompt user and stored into storage unit, waits for carrying for recordable paper
Show information, specifically, burning is waited for prompt user to send out needs storage into storage unit for example, it may be being flickered by trouble light
File, and then can there is currently no when recordable paper, may remind the user that store into storage unit to wait in storage unit 5
Recordable paper, and processing component 4 can also detect to whether there is in storage unit 5 again and wait for recordable paper every preset duration, into
And Flash chip 2 will can be again burnt to by processing component 4 after recordable paper is stored in storage unit 5 in user
In.
Certainly, the file for whether needing burning in storage unit 5 for how to determine can also be and wait for burning by detection
The modes such as the size of file or the homing sequence that waits for recordable paper combine to realize, or by above two or several means
Come, to improve the Stability and veracity of detection.
Preferably, electronic equipment provided by the embodiments of the present application is EMBEDDED AVIONICS.
For the burning flow of the clearer Flash chip for understanding electronic equipment provided by the embodiments of the present application, with master
Control component is main control chip, and processing component is microcontroller, and the first control units part is digital switch, and the second control unit is opened for USB
For pass, and it is specifically described in conjunction with Fig. 7:
Step S101, electronic equipment powers on.
Step S102, microcontroller control main control chip powers on.
Step S103, equipment starts, and digital switch and USB switches are connected to main control chip under default conditions.
Step S104, whether high level is exported in GPIO output interface preset times of the microcontroller by detecting main control chip
To judge whether Flash chip is normal, if exporting high level in detection preset time, S104 is thened follow the steps, otherwise, executes step
Rapid S108.
If the GPIO output interfaces output high level of main control chip step S105, is not detected in preset time, it is determined that
Flash chip is abnormal, needs to carry out burning again, and then microcontroller control digital switch and USB switches are connected to microcontroller.
Step S106, judge in USB flash disk with the presence or absence of with microcontroller preserve wait for the filename of recordable paper it is consistent wait burning
Record file, and if it exists, then follow the steps S107, otherwise, execute step S109.
What step S107, microcontroller reading USB flash disk stored waits for recordable paper, and this is waited for that recordable paper is burnt to main control chip
In.
Step S108, microcontroller control digital switch and USB switches are connected to main control chip.
Step S109, system worked well.
Step S110, microcontroller control trouble light flicker waits for recordable paper with prompt for being stored into USB flash disk.
Step S111, whether the preset duration of setting arrives, if arriving, thens follow the steps S106.
It should be noted that the embodiment of the present application, except the Flash in the above situation when electronic equipment Flash chip exception
Chip restores, and the application applies also for the modification and upgrading of electronic equipment Flash chip program, i.e., normally transported in electronic equipment
Burning flash chip program is forced in the case of row.Workflow is as follows:Microcontroller control main control chip powers on, and main control chip is just
Often start, main control chip corresponds to programming and judges that signal is also normally sent out, at this time by stirring the modes such as toggle switch by microcontroller
The GPIO of detection main control chip turntable is dragged down so that microcontroller can not detect the normal enabling signal of main control chip, start programming
Flow, after programming, release drags down operation to GPIO, completes the modification and upgrading of Flash chip.
The embodiment of the present application has the beneficial effect that:In the embodiment of the present application, in the state that the output of master control unit is normal,
Flash chip is connect by the first control units part with master control unit, is normally worked, and is detecting the defeated of master control unit
When going out abnormal, processing component can control the first control units part and be disconnected with master control unit, and by the first control units part and handle
The first Processing Interface connection of component, the second control unit of control are disconnected with master control unit, and by second master control unit and are located
Manage the second processing interface connection of component, and by second interface obtain outside storage unit wait for recordable paper, by the
One Processing Interface is burnt to Flash chip, and then can be completed to Flash in the case where that need not be dismantled to Flash chip
The burning of chip, and when burning is completed, control the first control units part is disconnected with processing component, and itself and master control unit are connected
It connects, the second control unit of control is disconnected with processing component, and it is connect with master control unit, and then makes Flash chip and master control
Component is connected, and so that electronic equipment is worked normally, when to Flash chip burning, need not additionally be occupied master control unit
Interface resource need not also dismantle Flash chip, to Flash chip burning process simple operation, reliable and stable.
Obviously, those skilled in the art can carry out the application essence of the various modification and variations without departing from the application
God and range.In this way, if these modifications and variations of the application belong to the range of the application claim and its equivalent technologies
Within, then the application is also intended to include these modifications and variations.