CN104836829B - The long-distance monitoring method and remote monitoring system of vehicle - Google Patents
The long-distance monitoring method and remote monitoring system of vehicle Download PDFInfo
- Publication number
- CN104836829B CN104836829B CN201410584461.8A CN201410584461A CN104836829B CN 104836829 B CN104836829 B CN 104836829B CN 201410584461 A CN201410584461 A CN 201410584461A CN 104836829 B CN104836829 B CN 104836829B
- Authority
- CN
- China
- Prior art keywords
- diagnostic data
- communication server
- data
- server
- vehicle
- 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.)
- Expired - Fee Related
Links
Landscapes
- Debugging And Monitoring (AREA)
- Telephonic Communication Services (AREA)
Abstract
The invention discloses a kind of long-distance monitoring methods of vehicle comprising following steps:Communication server receives the diagnostic data that vehicle monitor terminal is sent by first thread, and starts the first timer;The communication server preserves the diagnostic data to local log file, and records the number of the diagnostic data;And when reaching the timing cycle of first timer, the communication server stores the data in the local log file to database server according to the number of the diagnostic data.The long-distance monitoring method of the vehicle of the present invention can improve the reliability of vehicle remote monitoring to avoid the loss of diagnostic data during vehicle remote monitoring, facilitate the remote monitoring of vehicle factor or operator to vehicle.The invention also discloses a kind of remote monitoring systems of vehicle.
Description
Technical field
The present invention relates to technical field of vehicle, more particularly to the long-distance monitoring method of a kind of vehicle and a kind of vehicle it is long-range
Monitoring system.
Background technology
With the development of vehicle technology, mounted remote monitoring system applies to a variety of models by more and more extensive
On, become very necessary for monitoring the running different data of vehicle, therefore remote monitoring being carried out to vehicle.
Due to the necessity of vehicle remote monitoring, to which mounted remote monitoring system needs run without interruption for 24 hours.But
It is that mounted remote monitoring system abnormal closing phenomenon can occur because of artificial maloperation or system reason, and once occur
This phenomenon, usual user are difficult to find in time, this results in the communication disruption of certain time, so as to cause largely to examine
Disconnected loss of data.In addition, also can there is a phenomenon where sporadic loss data when general communication server normal operation.And lose
Diagnostic data can not be traced, this will bring great inconvenience to vehicle factor or operator.
Therefore, it is necessary to the remote control technologies to vehicle to be improved.
Invention content
The purpose of the present invention aims to solve at least above-mentioned technological deficiency.
For this purpose, an object of the present invention is to provide a kind of long-distance monitoring method of vehicle, this method can be to avoid vehicle
The loss of diagnostic data, improves the reliability of vehicle remote monitoring, facilitates vehicle factor or operator pair during remote monitoring
The remote monitoring of vehicle.
Another purpose of the invention is to propose a kind of remote monitoring system of vehicle.
In order to achieve the above objectives, a kind of long-distance monitoring method for vehicle that one aspect of the present invention embodiment proposes comprising
Following steps:Communication server receives the diagnostic data that vehicle monitor terminal is sent by first thread, and starts the first timing
Device;The communication server preserves the diagnostic data to local log file, and records the number of the diagnostic data;When
When reaching the timing cycle of first timer, the communication server is according to the number of the diagnostic data by the local
Data in journal file are stored to database server.
Wherein, the communication server deposits the data in the local log file according to the number of the diagnostic data
Storage is specifically included to database server:If the number of the diagnostic data is greater than or equal to predetermined threshold value, by described
Data in ground journal file are stored to the database server, and remove corresponding data in the local log file;
If the number of the diagnostic data is less than the predetermined threshold value, by the local log file after postponing preset time
In data store to the database server, and remove corresponding data in the local log file.
According to one embodiment of present invention, the long-distance monitoring method of the vehicle further includes:The communication server
Communication request is sent to the vehicle monitor terminal by the second thread, and starts the second timer;It is counted when reaching described second
When device timing cycle when, the communication server updates the operating status of communication server described in the database server
Information.
Wherein, the communication server updates the operating status letter of communication server described in the database server
Breath, specifically includes:The communication server updates the system operation time of the database server.
Preferably, described after the system operation time that the communication server updates the database server
The long-distance monitoring method of vehicle further includes:After auxiliary monitor client starts, start third timer;When reaching described
When the timing cycle of three timers, the auxiliary system of the monitor client by database server described in third thread pool
Run time;Judge whether the difference of the system operation time and current time is more than the first preset time threshold;If it is greater than
First preset time threshold, then the auxiliary monitor client start the communication server.
Pass through the difference of comparison system run time and current time, it can be determined that the operating condition of communication server, specifically
, when the system is operated between and current time difference be more than the first preset time threshold, illustrate that communication server has been switched off, it is auxiliary
It helps monitor client that need to start communication server in time, thus can lead to Communications service to avoid maloperation or system problem
The loss of a large amount of diagnostic datas is closed and caused to device.
Also, the long-distance monitoring method of the vehicle further includes:After auxiliary monitor client startup, start
4th timer;When reaching the timing cycle of the 4th timer, the auxiliary monitor client inquires the communication garment
The diagnostic data whether is had recorded in local log file described in business device;If it is determined that being recorded in the local log file
The diagnostic data, then further judge the diagnostic data whether is had recorded in the database server;If it is determined that
The diagnostic data is not recorded in the database server, then obtains the timestamp of Current Diagnostic data;Judge described current
Whether the timestamp of diagnostic data and the difference of current time are more than the second preset time threshold;If the Current Diagnostic data
The difference of timestamp and the current time is more than second preset time threshold, then will be described in the local log file
Diagnostic data is stored to the database server.It can be achieved to restore the diagnostic data of loss in this way, avoid diagnosis number
According to complete loss.
The long-distance monitoring method of vehicle according to the ... of the embodiment of the present invention, using auxiliary monitor client real time monitoring communication
The operating status of server, if detecting, communication server is closed, and needs to be restarted in time, to effectively avoid communication garment
Business device may cause a large amount of diagnostic data loss because artificial maloperation or system reason abnormal closings phenomenon occur;And
Diagnostic data loss can also be detected the presence of in real time, and the diagnostic data of loss is restored and is saved to database clothes
Business device, the sporadic hidden danger for losing diagnostic data, substantially increases vehicle remote monitoring when communication server being avoided to work normally
Reliability, facilitate the remote monitoring of vehicle factor or operator to vehicle.
In addition, another aspect of the present invention embodiment also proposed a kind of remote monitoring system of vehicle comprising communication
Server, vehicle monitor terminal and database server, wherein the communication server is received described vehicle-mounted by first thread
The diagnostic data that monitor terminal is sent, and start the first timer;The communication server preserves the diagnostic data to this
Ground journal file, and record the number of the diagnostic data;It is described and when reaching the timing cycle of first timer
Data in the local log file are stored to the database according to the number of the diagnostic data and are taken by communication server
Business device.
Specifically, the communication server according to the number of the diagnostic data by the data in the local log file
When storing to the database server, wherein described logical if the number of the diagnostic data is greater than or equal to predetermined threshold value
Inquiry server then stores the data in the local log file to the database server, and removes the local daily record
Corresponding data in file;If the number of the diagnostic data is less than the predetermined threshold value, communication server if, is prolonging
The data in the local log file are stored to the database server after slow preset time, and remove the local
Corresponding data in journal file.
According to one embodiment of present invention, the communication server is also by the second thread to the vehicle monitor terminal
Communication request is sent, and starts the second timer, and when reaching the timing cycle of second timer, the communication garment
Business device updates the running state information of communication server described in the database server.
Wherein, the communication server is by updating the system operation time of the database server to update the number
According to the running state information of communication server described in the server of library.
Preferably, the remote monitoring system of the vehicle further includes auxiliary monitor client, wherein in the communication garment
It is described auxiliary after business device updates the system operation time of the database server, and after auxiliary monitor client starts
Monitor client is helped to start third timer;When reaching the timing cycle of the third timer, the auxiliary monitors client
The system operation time that end passes through database server described in third thread pool;The auxiliary monitor client judges the system
Whether the difference of run time of uniting and current time is more than the first preset time threshold;If it is greater than the first preset time threshold
Value, the auxiliary monitor client then start the communication server, it is ensured that communication server works normally.
Preferably, after the auxiliary monitor client starts, the auxiliary monitor client also starts the 4th timer;
When reaching the timing cycle of the 4th timer, the auxiliary monitor client is inquired described in the communication server originally
Whether the diagnostic data is had recorded in ground journal file;If the auxiliary monitor client judges the local log file
In have recorded the diagnostic data, then further judge the diagnostic data whether is had recorded in the database server;Such as
It assists monitor client to judge not recording the diagnostic data in the database server described in fruit, then obtains Current Diagnostic number
According to timestamp;Whether the difference of the timestamp for assisting monitor client to judge the Current Diagnostic data and current time is big
In the second preset time threshold;If the timestamp of the Current Diagnostic data and the difference of the current time are more than described second
Preset time threshold, the auxiliary monitor client then store the diagnostic data in the local log file to described
Database server.It can be achieved to restore the diagnostic data of loss in this way, avoid the complete loss of diagnostic data.
The remote monitoring system of vehicle according to the ... of the embodiment of the present invention, using auxiliary monitor client real time monitoring communication
The operating status of server, if detecting, communication server is closed, and needs to be restarted in time, to effectively avoid communication garment
Business device may cause a large amount of diagnostic data loss because artificial maloperation or system reason abnormal closings phenomenon occur;And
Diagnostic data loss can also be detected the presence of in real time, and the diagnostic data of loss is restored and is saved to database clothes
Business device, the sporadic hidden danger for losing diagnostic data, substantially increases vehicle remote monitoring when communication server being avoided to work normally
Reliability, facilitate the remote monitoring of vehicle factor or operator to vehicle.
The additional aspect of the present invention and advantage will be set forth in part in the description, and will partly become from the following description
Obviously, or practice through the invention is recognized.
Description of the drawings
Above-mentioned and/or additional aspect and advantage of the invention will become from the following description of the accompanying drawings of embodiments
Obviously and it is readily appreciated that, wherein:
Fig. 1 is the block diagram according to the remote monitoring system of the vehicle of one embodiment of the invention;
Fig. 2 is the flow chart according to the long-distance monitoring method of the vehicle of the embodiment of the present invention;
Fig. 3 is to pass through first thread according to communication server in the long-distance monitoring method of the vehicle of one embodiment of the invention
Work flow diagram;
Fig. 4 is to pass through the second thread according to communication server in the long-distance monitoring method of the vehicle of one embodiment of the invention
Work flow diagram;
Fig. 5 is to assist monitor client to pass through third according in the long-distance monitoring method of the vehicle of one embodiment of the invention
The work flow diagram of thread;And
Fig. 6 is to assist monitor client to pass through the 4th according in the long-distance monitoring method of the vehicle of one embodiment of the invention
The work flow diagram of thread.
Specific implementation mode
The embodiment of the present invention is described below in detail, examples of the embodiments are shown in the accompanying drawings, wherein from beginning to end
Same or similar label indicates same or similar element or element with the same or similar functions.Below with reference to attached
The embodiment of figure description is exemplary, and is only used for explaining the present invention, and is not construed as limiting the claims.
Following disclosure provides many different embodiments or example is used for realizing the different structure of the present invention.For letter
Change disclosure of the invention, hereinafter the component of specific examples and setting are described.Certainly, they are merely examples, and
It is not intended to limit the present invention.In addition, the present invention can in different examples repeat reference numerals and/or letter.It is this heavy
It is for purposes of simplicity and clarity, itself not indicate the relationship between discussed various embodiments and/or setting again.This
Outside, the present invention provides various specific techniques and material example, but those of ordinary skill in the art may realize that
The applicable property of other techniques and/or the use of other materials.In addition, fisrt feature described below second feature it
The structure of "upper" may include the embodiment that the first and second features are formed as being in direct contact, and can also include other feature shape
At the embodiment between the first and second features, such first and second feature may not be to be in direct contact.
In the description of the present invention, it should be noted that unless otherwise specified and limited, term " installation ", " connected ",
" connection " shall be understood in a broad sense, for example, it may be mechanical connection or electrical connection, can also be the connection inside two elements, it can
, can also indirectly connected through an intermediary, for the ordinary skill in the art to be to be connected directly, it can basis
Concrete condition understands the concrete meaning of above-mentioned term.
With reference to the accompanying drawings come describe the vehicle proposed according to inventive embodiments long-distance monitoring method and vehicle it is remote
Range monitoring system.
Fig. 1 is according to the block diagram of the remote monitoring system of the vehicle of one embodiment of the invention, and Fig. 2 is according to this
The flow chart of the long-distance monitoring method of the vehicle of inventive embodiments.Wherein, as shown in Figure 1, the remote monitoring system packet of the vehicle
Include vehicle monitor terminal 10, communication server 20 and database server 30, auxiliary monitor client 40, vehicle monitor terminal
It can mutually be communicated according to ICP/IP protocol by wireless GPRS network between 10 and communication server 20.Vehicle-mounted monitoring is whole
It is responsible for sending diagnostic data to communication server 20 in end 10;Communication server 20 is responsible for receiving examining for the transmission of vehicle monitor terminal 10
Disconnected data are simultaneously parsed, and are organized packet diagnostic data in batches and preserved the diagnostic data after group packet in batches to local daily record text
In part and database server 30, while also periodically updating the data the operating status letter of communication server 20 in library server 30
Breath;Database server 30 is responsible for preserving the running state information of diagnostic data and communication server;Assist monitor client 40
It is responsible for the data in timing inquiry database server to determine the operating status of communication server, if detecting communication server
It closes, diagnostic data in communication server, and timing detection local log file and database server need to be opened in time
Information, if detecting, diagnostic data is lost, and need to be confirmed the data information of loss and is saved in database server.
As shown in Fig. 2, the long-distance monitoring method of the vehicle of the embodiment of the present invention includes the following steps:
S1, communication server receive the diagnostic data that vehicle monitor terminal is sent by first thread, and start the first meter
When device.
S2, communication server preserve diagnostic data to local log file, and the number of recording and diagnosing data.
S3, when reaching the timing cycle of the first timer, communication server is according to the number of diagnostic data by local day
Data in will file are stored to database server.
Specifically, according to one embodiment of present invention, as shown in figure 3, the work that communication server passes through first thread
Flow specifically includes:
S301, starts the communication of communication server and vehicle monitor terminal, and waits for the connection of vehicle monitor terminal.I.e.
Speech, communication server can send communication request to establish the company with vehicle monitor terminal by first thread to vehicle monitor terminal
It connects.
S302 opens the first timer, wherein the timing cycle of the first timer can be 10 milliseconds.
S303, judges whether communication server connect with vehicle monitor terminal.If so, executing step S304;If
No, return to step S303 continues to judge.
S304, judges whether communication server receives the diagnostic data of vehicle monitor terminal transmission.If so, executing step
Rapid S305;If not, return to step S304, continues to judge.
S305 parses diagnostic data.
S306 adds up to the number of diagnostic data, i.e. the number+1 of number=diagnostic data of diagnostic data.
That is, if establishing connection between communication server and vehicle monitor terminal, communication server waits for vehicle-mounted
Monitor terminal sends diagnostic data, also, if communication server receives diagnostic data, should according to the parsing of GPRS communication protocols
Diagnostic data information such as parsing CAN ID (mark), frame length, data fields and timestamp, and to the number of diagnostic data
It adds up.
S307 preserves the diagnostic data received to local log file, and records the number of this batch of diagnostic data.
S308 judges whether such as 10 milliseconds of timing cycle for reaching the first timer.If so, executing step S309;
If not, return to step S308, continues to judge.
S309, judges whether the number of this batch of diagnostic data is greater than or equal to predetermined threshold value such as 1000.If so, holding
Row step S310;If not, executing step S313.
S310 preserves in local log file this batch of diagnostic data to database server.
S311 removes this batch of diagnostic data in local log file.
The number of this batch of diagnostic data is reset, returns to step S308 by S312.
S313 judges to postpone whether preset time such as 100 break periods (1 second) reach.If so, executing step
S314;If not, return to step S308.
S314 preserves in local log file this batch of diagnostic data to database server.
S315 removes this batch of diagnostic data in local log file.
The number of this batch of diagnostic data is reset, returns to step S308 by S316.
Therefore says, in step s3, the communication server is according to the number of the diagnostic data by the local daily record
Data in file are stored to database server, are specifically included:If the number of the diagnostic data is greater than or equal to default
Threshold value such as 1000 then stores the data in the local log file to the database server, and described in removing
Corresponding data in local log file;It is default in delay if the number of the diagnostic data is less than the predetermined threshold value
The data in the local log file are stored to the database server after such as 1 second time, and remove described
Corresponding data in ground journal file.
In an embodiment of the present invention, due to needing the diagnostic data storage in local log file to database server
It takes some time, to improve the efficiency that data preserve, needs Diagnostic Time carrying out group packet in batches, disposably by one
Diagnostic data storage is criticized to database server, rather than a data preserve with connecing a data.
According to one embodiment of present invention, the long-distance monitoring method of above-mentioned vehicle further includes:The communication server
Communication request is sent to the vehicle monitor terminal by the second thread, and starts the second timer;It is counted when reaching described second
When device timing cycle when, the communication server updates the operating status of communication server described in the database server
Information.
Wherein, the communication server updates the operating status letter of communication server described in the database server
Breath, specifically includes:The communication server updates the system operation time of the database server.
Specifically, as shown in figure 4, communication server is specifically included by the workflow of the second thread:
S401, starts the communication of communication server and vehicle monitor terminal, and waits for the connection of vehicle monitor terminal, simultaneously
The second timer is opened, the timing cycle of the second timer can be 5 seconds.That is, communication server passes through the second thread
Communication request is sent to establish the connection with vehicle monitor terminal to vehicle monitor terminal.
S402 judges whether the timing cycle for reaching the second timer.If so, executing step S403;If not, returning
Step S402 continues to judge.
S403, updates the data operating status (in work) information of communication server in the server of library, such as by database
Server up time is updated to current system run time, to characterize communication server in continuous operation.
Therefore, in an embodiment of the present invention, communication server can open two worker threads i.e. first thread and second
Thread, first thread are used for realizing that real-time reception, parsing and the preservation of diagnostic data, the second thread are used for updating the data library clothes
The running state information of communication server in business device.
According to one embodiment of present invention, the system operation of the database server is updated in the communication server
After time, the long-distance monitoring method of above-mentioned vehicle further includes:After auxiliary monitor client starts, start third timing
Device;When reaching the timing cycle of the third timer, the auxiliary monitor client passes through number described in third thread pool
According to the system operation time of library server;When judging whether the difference of the system operation time and current time is default more than first
Between threshold value;If it is greater than first preset time threshold, then the auxiliary monitor client starts the communication server.
Specifically, as shown in figure 5, auxiliary monitor client includes by the workflow of third thread:
S501 starts auxiliary monitor client, and opens third timer, wherein the timing cycle of third timer can
Think 5 seconds.
S502, judges whether to reach the timing cycle of third timer such as 5 seconds.If so, executing step S503;If
No, return to step S502 continues to judge.
S503, the running state information for inquiring communication server in database server for example inquire database server
System operation time.
S504, when judging whether the difference of the updated newest run time of database server and current time is more than first
Between threshold value such as 10 seconds.If so, executing step S505;If not, return to step S502.
S505 starts communication server.
In an embodiment of the present invention, the operating status of communication server is monitored in real time using auxiliary monitor client, such as
Fruit detects that communication server is closed, and can start communication server in time, is lost to can avoid a large amount of diagnostic data.
Also, the long-distance monitoring method of above-mentioned vehicle further includes:After auxiliary monitor client startup, start
4th timer;When reaching the timing cycle of the 4th timer, the auxiliary monitor client is looked by the 4th thread
It askes and whether has recorded the diagnostic data in local log file described in the communication server;If it is determined that the local day
The diagnostic data is had recorded in will file, then further judges the diagnosis number whether is had recorded in the database server
According to;If it is determined that not recording the diagnostic data in the database server, then the timestamp of Current Diagnostic data is obtained;Sentence
Whether the timestamp for the Current Diagnostic data of breaking and the difference of current time are more than the second preset time threshold;If described current
The difference of the timestamp of diagnostic data and the current time is more than second preset time threshold, then by the local daily record text
The diagnostic data in part is stored to the database server.
Specifically, as shown in fig. 6, auxiliary monitor client includes by the workflow of the 4th thread:
S601 starts auxiliary monitor client, and opens the 4th timer, wherein the timing cycle of the 4th timer can be with
It is 2 seconds.
S602, judges whether to reach the timing cycle of the 4th timer such as 2 seconds.If so, executing step S603;If
No, return to step S602 continues to judge.
S603 inquires the diagnostic data in local log file.
S604 judges whether have recorded diagnostic data in local log file.If so, executing step S605;If not,
Return to step S602.
Wherein, if not recording any diagnostic data in local log file, it can be confirmed that diagnostic data is not lost at this time,
Diagnostic data in local log file has been saved in database server, on the contrary, it is also necessary to being recorded in the server of data library
Data information inquired.
S605 judges the diagnostic data in local log file whether is preserved in database server.If so, returning to step
Rapid S602;If not, executing step S606.
Whether the difference of S606, the timestamp and current time that judge Current Diagnostic data are more than the second preset time threshold example
Such as 5 seconds.If so, executing step S607;If not, executing step S608.
S607 stores the diagnostic data in local log file to database server, return to step S602.
S608 is delayed such as 5 seconds certain time.
S609 judges the diagnostic data in local log file whether is preserved in database server.If so, returning to step
Rapid S602;If not, executing step S610.
Diagnostic data in journal file is saved in database server, return to step S602 by S610.
That is, from step S605-S610, if having preserved corresponding diagnostic data in database server, confirmation is examined
Disconnected data are not lost, conversely, judging whether the timestamp of this batch of diagnostic data is more than 5 seconds apart from current time;If this batch diagnoses
The timestamp of data is more than 5 seconds apart from current time, confirms that diagnostic data is lost, need to preserve corresponding diagnostic data to database
Server;Conversely, delay judges whether preserved corresponding diagnostic data in database server after 5 seconds;If it is not, confirming diagnosis
Loss of data need to preserve corresponding diagnostic data to database server.
Therefore, auxiliary monitor client can also open two worker threads such as third thread and the 4th thread, wherein the
Three threads are used for realizing that the confirmation and processing of communication server operating status, the 4th thread are used for confirming whether diagnostic data loses
And corresponding processing.
In conclusion in the embodiment of the present invention, communication server opens two worker thread, that is, first threads and the
Two threads, and receive by first thread the diagnostic data of vehicle monitor terminal transmission in time, then diagnostic data preserve to
Local log file, and when the arrival of the timing cycle of the number of recording and diagnosing data and the first timer, communication server root
The data in local log file are stored to database server according to the number of diagnostic data, simultaneous communications server passes through
Two threads send communication request to vehicle monitor terminal, and start the second timer, and when the timing for reaching the second timer
When the period, communication server updates the data the running state information of communication server in the server of library;And assist monitor client
After start-up, start third timer, and when reaching the timing cycle of third timer, auxiliary monitor client passes through the
The running state information of three thread pool database servers is to monitor the operating status of communication server in real time, if detecting logical
Inquiry server is closed, and needs to be started in time, avoids causing a large amount of diagnostic data to lose because communication server is closed, together
When, auxiliary monitor client also starts the 4th timer, and when reaching the timing cycle of the 4th timer, auxiliary monitoring client
Whether end in local log file in the 4th thread pool communication server by having recorded diagnostic data, if it is determined that local day
Diagnostic data is had recorded in will file, then further judges diagnostic data whether is had recorded in database server, and judging
The timestamp for obtaining Current Diagnostic data in database server when non-recording and diagnosing data, then judges Current Diagnostic data
The difference of timestamp and current time whether be more than the second preset time threshold, if it is determined that the timestamp of Current Diagnostic data with work as
The difference of preceding time is more than the second preset time threshold, then stores the diagnostic data in local log file to database service
Device restores the diagnostic data of loss to realize, is effectively prevented losing for diagnostic data during vehicle remote monitoring
It loses, improves the reliability of vehicle remote monitoring.
The long-distance monitoring method of the vehicle of the embodiment of the present invention is based on TCP/IP technologies, real-time using auxiliary monitor client
The operating status of communication server is monitored, communication server is closed if detecting, needs to be restarted in time, to effectively keep away
A large amount of diagnostic data may be caused because artificial maloperation or system reason abnormal closing phenomenon occur by exempting from communication server
It loses;And diagnostic data loss can also be detected the presence of in real time, and the diagnostic data of loss restore and preserved
To database server, the sporadic hidden danger for losing diagnostic data, substantially increases vehicle when communication server being avoided to work normally
The reliability of remote monitoring, facilitates the remote monitoring of vehicle factor or operator to vehicle.
The embodiment of the present invention also proposed a kind of remote monitoring system of vehicle.As shown in Figure 1, the long-range prison of the vehicle
Control system includes communication server 20, vehicle monitor terminal 10, database server 30, vehicle monitor terminal 10 and Communications service
It can mutually be communicated according to ICP/IP protocol by wireless GPRS network between device 20.
Wherein, communication server 20 receives the diagnostic data that vehicle monitor terminal 10 is sent by first thread, and starts
First timer;Communication server 20 preserves the diagnostic data to local log file, and records the diagnostic data
Number;When reaching such as 10 milliseconds of the timing cycle of first timer, communication server 20 is according to the diagnostic data
Number the data in the local log file are stored to database server 30.
According to one embodiment of present invention, communication server 20 according to the number of the diagnostic data by the local day
When data in will file are stored to database server 30, wherein if the number of the diagnostic data is greater than or equal in advance
If threshold value such as 1000, communication server 20 then stores the data in the local log file to database server
30, and remove corresponding data in the local log file;If the number of the diagnostic data is less than the predetermined threshold value,
Communication server 20 then later stores the data in the local log file to database in delay preset time for such as 1 second
Server 30, and remove corresponding data in the local log file.
Also, communication server 20 also sends communication request by the second thread to vehicle monitor terminal 10, and starts the
Two timers, and when reaching the timing cycle of second timer, communication server 20 updates the data library server 30
The running state information of middle communication server 20.
Specifically, communication server 20 updates the data library clothes by updating the data the system operation time of library server 30
The running state information of communication server 20 in business device 30.
Therefore, in an embodiment of the present invention, communication server 20 can open two worker threads i.e. first thread and
Two threads, first thread are used for realizing that real-time reception, parsing and the preservation of diagnostic data, the second thread are used for updating the data library
The running state information of communication server in server, such as database server run-time updating is run for current system
Time, to characterize communication server in continuous operation.
According to one embodiment of present invention, as shown in Figure 1, the remote monitoring system of above-mentioned vehicle further includes auxiliary prison
Control client 40, wherein supervised after the system operation time that communication server 20 updates the data library server 30, and in auxiliary
After controlling the startup of client 40, auxiliary monitor client 40 starts third timer;When the timing for reaching the third timer
When the period, system operation time of the monitor client 40 by third thread pool database server 30 is assisted;Auxiliary monitoring
Client 40 judges whether the difference of the system operation time and current time is more than the first preset time threshold such as 10 seconds;Such as
Fruit is more than first preset time threshold, and auxiliary monitor client 40 then starts communication server 20.
In an embodiment of the present invention, the operating status of auxiliary monitor client real time monitoring communication server, if inspection
Communication server closing is measured, communication server can be started in time, is lost to can avoid a large amount of diagnostic data.
Also, after auxiliary monitor client 40 starts, auxiliary monitor client 40 also starts the 4th timer;When up to
To the 4th timer timing cycle when, auxiliary monitor client 40 pass through institute in the 4th thread pool communication server 20
It states and whether has recorded the diagnostic data in local log file;If auxiliary monitor client 40 judges the local daily record text
The diagnostic data is had recorded in part, then further judges the diagnostic data whether is had recorded in database server 30;Such as
Fruit assists monitor client 40 to judge not recording the diagnostic data in database server 30, then obtains Current Diagnostic data
Timestamp;Auxiliary monitor client 40 judges whether the timestamp of the Current Diagnostic data and the difference of current time are more than second
Preset time threshold such as 5 seconds;If the timestamp of the Current Diagnostic data and the difference of the current time are more than described the
Two preset time thresholds, auxiliary monitor client 40 then store the diagnostic data in the local log file to data
Library server 30.
That is, if not recording any diagnostic data in local log file, it can be confirmed that diagnostic data is not at this time
It loses, the diagnostic data in local log file has been saved in database server, on the contrary, it is also necessary to in the server of data library
The data information of record is inquired.If having preserved corresponding diagnostic data in database server, confirm that diagnostic data is not lost
It loses, conversely, judging whether the timestamp of this batch of diagnostic data is more than 5 seconds apart from current time;If the time of this batch of diagnostic data
Stamp is more than 5 seconds apart from current time, confirms that diagnostic data is lost, need to preserve corresponding diagnostic data to database server;Instead
It, delay judges corresponding diagnostic data whether has been preserved in database server after 5 seconds;If it is not, confirm that diagnostic data is lost,
Corresponding diagnostic data need to be preserved to database server.
Therefore, auxiliary monitor client can also open two worker threads such as third thread and the 4th thread, wherein the
Three threads are used for realizing that the confirmation and processing of communication server operating status, the 4th thread are used for confirming whether diagnostic data loses
And corresponding processing.
In conclusion in the embodiment of the present invention, communication server opens two worker thread, that is, first threads and the
Two threads, and receive by first thread the diagnostic data of vehicle monitor terminal transmission in time, then diagnostic data preserve to
Local log file, and when the arrival of the timing cycle of the number of recording and diagnosing data and the first timer, communication server root
The data in local log file are stored to database server according to the number of diagnostic data, simultaneous communications server passes through
Two threads send communication request to vehicle monitor terminal, and start the second timer, and when the timing for reaching the second timer
When the period, communication server updates the data the running state information of communication server in the server of library;And assist monitor client
After start-up, start third timer, and when reaching the timing cycle of third timer, auxiliary monitor client passes through the
The running state information of three thread pool database servers is to monitor the operating status of communication server in real time, if detecting logical
Inquiry server is closed, and needs to be started in time, avoids causing a large amount of diagnostic data to lose because communication server is closed, together
When, auxiliary monitor client also starts the 4th timer, and when reaching the timing cycle of the 4th timer, auxiliary monitoring client
Whether end in local log file in the 4th thread pool communication server by having recorded diagnostic data, if it is determined that local day
Diagnostic data is had recorded in will file, then further judges diagnostic data whether is had recorded in database server, and judging
The timestamp for obtaining Current Diagnostic data in database server when non-recording and diagnosing data, then judges Current Diagnostic data
The difference of timestamp and current time whether be more than the second preset time threshold, if it is determined that the timestamp of Current Diagnostic data with work as
The difference of preceding time is more than the second preset time threshold, then stores the diagnostic data in local log file to database service
Device restores the diagnostic data of loss to realize, is effectively prevented losing for diagnostic data during vehicle remote monitoring
It loses, improves the reliability of vehicle remote monitoring.
The remote monitoring system of vehicle according to the ... of the embodiment of the present invention is based on TCP/IP technologies, and client is monitored using auxiliary
The operating status of end real time monitoring communication server, if detecting, communication server is closed, and needs to be restarted in time, to
Effectively avoid communication server that from may causing largely to examine because artificial maloperation or system reason abnormal closing phenomenon occur
Disconnected loss of data;And can also detect the presence of in real time diagnostic data loss, and the diagnostic data of loss is restored and incite somebody to action
It is preserved to database server, and the sporadic hidden danger for losing diagnostic data, carries significantly when communication server being avoided to work normally
The high reliability of vehicle remote monitoring, facilitates the remote monitoring of vehicle factor or operator to vehicle.
Any process described otherwise above or method description are construed as in flow chart or herein, and expression includes
It is one or more for realizing specific logical function or process the step of executable instruction code module, segment or portion
Point, and the range of the preferred embodiment of the present invention includes other realization, wherein can not press shown or discuss suitable
Sequence, include according to involved function by it is basic simultaneously in the way of or in the opposite order, to execute function, this should be of the invention
Embodiment person of ordinary skill in the field understood.
Expression or logic and/or step described otherwise above herein in flow charts, for example, being considered use
In the order list for the executable instruction for realizing logic function, may be embodied in any computer-readable medium, for
Instruction execution system, device or equipment (system of such as computer based system including processor or other can be held from instruction
The instruction fetch of row system, device or equipment and the system executed instruction) it uses, or combine these instruction execution systems, device or set
It is standby and use.For the purpose of this specification, " computer-readable medium " can any can be included, store, communicating, propagating or passing
Defeated program is for instruction execution system, device or equipment or the dress used in conjunction with these instruction execution systems, device or equipment
It sets.The more specific example (non-exhaustive list) of computer-readable medium includes following:Electricity with one or more wiring
Interconnecting piece (electronic device), portable computer diskette box (magnetic device), random access memory (RAM), read-only memory
(ROM), erasable edit read-only storage (EPROM or flash memory), fiber device and portable optic disk is read-only deposits
Reservoir (CDROM).In addition, computer-readable medium can even is that the paper that can print described program on it or other are suitable
Medium, because can be for example by carrying out optical scanner to paper or other media, then into edlin, interpretation or when necessary with it
His suitable method is handled electronically to obtain described program, is then stored in computer storage.
It should be appreciated that each section of the present invention can be realized with hardware, software, firmware or combination thereof.Above-mentioned
In embodiment, software that multiple steps or method can in memory and by suitable instruction execution system be executed with storage
Or firmware is realized.It, and in another embodiment, can be under well known in the art for example, if realized with hardware
Any one of row technology or their combination are realized:With the logic gates for realizing logic function to data-signal
Discrete logic, with suitable combinational logic gate circuit application-specific integrated circuit, programmable gate array (PGA), scene
Programmable gate array (FPGA) etc..
Those skilled in the art are appreciated that realize all or part of step that above-described embodiment method carries
Suddenly it is that relevant hardware can be instructed to complete by program, the program can be stored in a kind of computer-readable storage medium
In matter, which includes the steps that one or a combination set of embodiment of the method when being executed.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing module, it can also
That each unit physically exists alone, can also two or more units be integrated in a module.Above-mentioned integrated mould
The form that hardware had both may be used in block is realized, can also be realized in the form of software function module.The integrated module is such as
Fruit is realized in the form of software function module and when sold or used as an independent product, can also be stored in a computer
In read/write memory medium.
Storage medium mentioned above can be read-only memory, disk or CD etc..
In the description of this specification, reference term " one embodiment ", " some embodiments ", " example ", " specifically show
The description of example " or " some examples " etc. means specific features, structure, material or spy described in conjunction with this embodiment or example
Point is included at least one embodiment or example of the invention.In the present specification, schematic expression of the above terms are not
Centainly refer to identical embodiment or example.Moreover, particular features, structures, materials, or characteristics described can be any
One or more embodiments or example in can be combined in any suitable manner.
It although an embodiment of the present invention has been shown and described, for the ordinary skill in the art, can be with
Understanding without departing from the principles and spirit of the present invention can carry out these embodiments a variety of variations, modification, replace
And modification, the scope of the present invention is by appended claims and its equivalent limits.
Claims (6)
1. a kind of long-distance monitoring method of vehicle, which is characterized in that include the following steps:
Communication server receives the diagnostic data that vehicle monitor terminal is sent by first thread, and starts the first timer;
The communication server preserves the diagnostic data to local log file, and records the number of the diagnostic data;
And
When reaching the timing cycle of first timer, the communication server is according to the number of the diagnostic data by institute
The data in local log file are stated to store to database server;
Further include:The communication server sends communication request by the second thread to the vehicle monitor terminal, and starts the
Two timers;When reaching the timing cycle of second timer, the communication server updates the database server
Described in communication server running state information;The communication server updates communication garment described in the database server
The running state information of business device, specifically includes:The communication server updates the system operation time of the database server;
After the system operation time that the communication server updates the database server, further include:Client is monitored in auxiliary
After end starts, start third timer;When reaching the timing cycle of the third timer, the auxiliary monitor client
Pass through the system operation time of database server described in third thread pool;Judge the system operation time and current time
Difference whether be more than the first preset time threshold;If it is greater than first preset time threshold, then the auxiliary monitors client
End starts the communication server.
2. the long-distance monitoring method of vehicle as described in claim 1, which is characterized in that the communication server is examined according to
The number of disconnected data stores the data in the local log file to database server, specifically includes:
If the number of the diagnostic data is greater than or equal to predetermined threshold value, the data in the local log file are stored
To the database server, and remove corresponding data in the local log file;
If the number of the diagnostic data is less than the predetermined threshold value, by the local daily record after postponing preset time
Data in file are stored to the database server, and remove corresponding data in the local log file.
3. the long-distance monitoring method of vehicle as described in claim 1, which is characterized in that further include:
After auxiliary monitor client startup, start the 4th timer;
When reaching the timing cycle of the 4th timer, the auxiliary monitor client described in the 4th thread pool by leading to
Whether the diagnostic data is had recorded in local log file described in inquiry server;
If it is determined that having recorded the diagnostic data in the local log file, then the database server is further judged
In whether have recorded the diagnostic data;
If it is determined that not recording the diagnostic data in the database server, then the timestamp of Current Diagnostic data is obtained;
Whether the difference of the timestamp and current time that judge the Current Diagnostic data is more than the second preset time threshold;
If the timestamp of the Current Diagnostic data and the difference of the current time are more than second preset time threshold,
The diagnostic data in the local log file is stored to the database server.
4. a kind of remote monitoring system of vehicle, which is characterized in that taken including communication server, vehicle monitor terminal and database
Business device, wherein
The communication server receives the diagnostic data that the vehicle monitor terminal is sent by first thread, and starts the first meter
When device;
The communication server preserves the diagnostic data to local log file, and records the number of the diagnostic data;
And
When reaching the timing cycle of first timer, the communication server is according to the number of the diagnostic data by institute
The data in local log file are stated to store to the database server;
The communication server also sends communication request by the second thread to the vehicle monitor terminal, and starts the second timing
Device, and when reaching the timing cycle of second timer, the communication server updates in the database server
The running state information of the communication server;The system operation that the communication server passes through the update database server
Time is to update the running state information of communication server described in the database server;Further include auxiliary monitoring client
End, wherein after the system operation time that the communication server updates the database server, and in auxiliary monitoring visitor
After family end starts, the auxiliary monitor client starts third timer;When the timing cycle for reaching the third timer
When, the auxiliary system operation time of the monitor client by database server described in third thread pool;The auxiliary
Monitor client judges whether the difference of the system operation time and current time is more than the first preset time threshold;If it is greater than
First preset time threshold, the auxiliary monitor client then start the communication server.
5. the remote monitoring system of vehicle as claimed in claim 4, which is characterized in that the communication server is examined according to
When the number of disconnected data stores the data in the local log file to the database server, wherein
If the number of the diagnostic data is greater than or equal to predetermined threshold value, by the local daily record text if communication server
Data in part are stored to the database server, and remove corresponding data in the local log file;
If the number of the diagnostic data is less than the predetermined threshold value, if the communication server after postponing preset time
Data in the local log file are stored to the database server, and are removed corresponding in the local log file
Data.
6. the remote monitoring system of vehicle as claimed in claim 4, which is characterized in that
After auxiliary monitor client startup, the auxiliary monitor client also starts the 4th timer;
When reaching the timing cycle of the 4th timer, the auxiliary monitor client described in the 4th thread pool by leading to
Whether the diagnostic data is had recorded in local log file described in inquiry server;
If the auxiliary monitor client judges to have recorded the diagnostic data in the local log file, further sentence
The diagnostic data whether is had recorded in the disconnected database server;
If the auxiliary monitor client judges not recording the diagnostic data in the database server, obtain current
The timestamp of diagnostic data;
The auxiliary monitor client judges whether the timestamp of the Current Diagnostic data and the difference of current time are more than second
Preset time threshold;
If the timestamp of the Current Diagnostic data and the difference of the current time are more than second preset time threshold, institute
Auxiliary monitor client is stated then to store the diagnostic data in the local log file to the database server.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410584461.8A CN104836829B (en) | 2014-10-27 | 2014-10-27 | The long-distance monitoring method and remote monitoring system of vehicle |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410584461.8A CN104836829B (en) | 2014-10-27 | 2014-10-27 | The long-distance monitoring method and remote monitoring system of vehicle |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104836829A CN104836829A (en) | 2015-08-12 |
CN104836829B true CN104836829B (en) | 2018-08-07 |
Family
ID=53814462
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410584461.8A Expired - Fee Related CN104836829B (en) | 2014-10-27 | 2014-10-27 | The long-distance monitoring method and remote monitoring system of vehicle |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104836829B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107479525B (en) * | 2016-12-23 | 2019-09-20 | 宝沃汽车(中国)有限公司 | Vehicle remote diagnosis system and its control method |
CN108243212B (en) * | 2016-12-24 | 2021-07-20 | 宝沃汽车(中国)有限公司 | Method and device for vehicle diagnosis |
CN107465695A (en) * | 2017-09-21 | 2017-12-12 | 扬州航盛科技有限公司 | A kind of method and system based on dynamic data base updating CAN analytic parameters |
CN109116832A (en) * | 2018-08-28 | 2019-01-01 | 安徽江淮汽车集团股份有限公司 | Vehicle diagnostic data wireless communication method |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101183329A (en) * | 2007-12-07 | 2008-05-21 | 杭州华三通信技术有限公司 | Diary management techniques and device |
CN101360036A (en) * | 2007-07-31 | 2009-02-04 | 比亚迪股份有限公司 | CAN bus gateway controller and data transmission method between CAN buses |
CN102184637A (en) * | 2011-04-28 | 2011-09-14 | 北京交通大学 | Sensor network-based method, device and system for acquiring traffic state |
CN203537568U (en) * | 2013-10-28 | 2014-04-09 | 北京农业信息技术研究中心 | Greenhouse environmental monitoring system based on wireless sensing network |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2013086036A1 (en) * | 2011-12-05 | 2013-06-13 | Qualcomm Incorporated | Telehealth wireless communication hub device and service platform system |
-
2014
- 2014-10-27 CN CN201410584461.8A patent/CN104836829B/en not_active Expired - Fee Related
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101360036A (en) * | 2007-07-31 | 2009-02-04 | 比亚迪股份有限公司 | CAN bus gateway controller and data transmission method between CAN buses |
CN101183329A (en) * | 2007-12-07 | 2008-05-21 | 杭州华三通信技术有限公司 | Diary management techniques and device |
CN102184637A (en) * | 2011-04-28 | 2011-09-14 | 北京交通大学 | Sensor network-based method, device and system for acquiring traffic state |
CN203537568U (en) * | 2013-10-28 | 2014-04-09 | 北京农业信息技术研究中心 | Greenhouse environmental monitoring system based on wireless sensing network |
Also Published As
Publication number | Publication date |
---|---|
CN104836829A (en) | 2015-08-12 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104836829B (en) | The long-distance monitoring method and remote monitoring system of vehicle | |
CA2333105C (en) | Fault data synchronization via peer-to-peer communications network | |
CN104932978B (en) | A kind of system operation automatic fault selftesting and the method and system of selfreparing | |
US20090024722A1 (en) | Proxying availability indications in a failover configuration | |
US7430688B2 (en) | Network monitoring method and apparatus | |
CN106415673B (en) | For diagnosing the method and diagnostic testing apparatus of the state in vehicle | |
US8902063B2 (en) | Safety detection system with integrated diagnostic functions | |
CN107480014A (en) | A kind of High Availabitity equipment switching method and device | |
CN105099762B (en) | A kind of self checking method and self-checking system of system O&M function | |
US20040221035A1 (en) | Remote-support system for an analysing apparatus | |
CN111130951B (en) | Equipment state detection method, device and storage medium | |
CN101776724A (en) | Control method, device and system for inquiring test result of submarine cable line | |
CN106123476B (en) | Intelligent detecting method for refrigerator | |
EP2394118A2 (en) | Household appliance and auxiliary device for a household appliance | |
CN101351827B (en) | Telemeter system, telemeter system control method, and information recording medium | |
CN106685744A (en) | Fault elimination method, apparatus and system | |
CN111324504B (en) | Method and device for monitoring running state of power communication network | |
CN102833115B (en) | A kind of alert processing method of port and system | |
GB2330045A (en) | Information matching system and method | |
CN104408059A (en) | Fault processing method and device | |
CN110492963B (en) | Wind power plant time synchronization system | |
CN208953929U (en) | A kind of remote on-line monitoring device | |
CN107306213A (en) | Diagnostic method and diagnostic device for network | |
CN103209093B (en) | Collecting method when network element is abnormal and system | |
JP4299572B2 (en) | Failure notification method and failure notification method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
EXSB | Decision made by sipo to initiate substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
TA01 | Transfer of patent application right | ||
TA01 | Transfer of patent application right |
Effective date of registration: 20180416 Address after: No. 188, Miyun District, Miyun District, Beijing, Beijing Applicant after: Beijing treasure Car Co.,Ltd. Address before: 102206 Changping District City, Shahe, Sha Yang Road, Beijing Applicant before: BEIQI FOTON MOTOR Co.,Ltd. |
|
GR01 | Patent grant | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20180807 Termination date: 20211027 |