CN106249634A - A kind of real-time clock based on electric automobile data acquisition function - Google Patents

A kind of real-time clock based on electric automobile data acquisition function Download PDF

Info

Publication number
CN106249634A
CN106249634A CN201610899606.2A CN201610899606A CN106249634A CN 106249634 A CN106249634 A CN 106249634A CN 201610899606 A CN201610899606 A CN 201610899606A CN 106249634 A CN106249634 A CN 106249634A
Authority
CN
China
Prior art keywords
time
processor unit
real
time clock
electric automobile
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201610899606.2A
Other languages
Chinese (zh)
Inventor
吴成加
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Anhui Ankai Automobile Co Ltd
Original Assignee
Anhui Ankai Automobile Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Anhui Ankai Automobile Co Ltd filed Critical Anhui Ankai Automobile Co Ltd
Priority to CN201610899606.2A priority Critical patent/CN106249634A/en
Publication of CN106249634A publication Critical patent/CN106249634A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B19/00Programme-control systems
    • G05B19/02Programme-control systems electric
    • G05B19/04Programme control other than numerical control, i.e. in sequence controllers or logic controllers

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Electric Clocks (AREA)
  • Synchronisation In Digital Transmission Systems (AREA)

Abstract

The invention provides a kind of real-time clock based on electric automobile data acquisition function, it includes Big Dipper module, CAN transceiver, SD card circuit, real time clock circuit, processor unit;Described Big Dipper module is connected with processor unit interactive mode, and described CAN transceiver is connected with processor unit interactive mode, and SD card circuit is connected with processor unit interactive mode, and real time clock circuit is connected with processor unit interactive mode.The present invention provides the time error of the Big Dipper module of employing less, and after using satellite time, whole CAN network all uses satellite time, also makes the time synchronized of CAN system be guaranteed, and precision and the concordance of time are all significantly improved.

Description

A kind of real-time clock based on electric automobile data acquisition function
Technical field
The present invention relates to technical field of new energy, a kind of height based on electric automobile data acquisition function Precision real-time clock.
Background technology
In the control system of electric automobile, the node that controls of some bus needs an accurate unified clock, due to CAN system belongs to dcs, the RTC clock that system node is built-in, is the most all to use 32.768KHz quartz oscillator, quartz oscillator produces a continuous print clock pulses, and RTC circuit is by frequency dividing Obtaining the clock signal of 1Hz from 32.768kHz crystal oscillator, crystal can not provide degree of precision in wide temperature range, Time deviation can be produced, deviation accumulation can time system time migration increasing, simultaneously because supply voltage deviation etc. because of Element, also results in its clock jitter, in some cases, owing to vibration or backup battery voltage exhaust, makes clock circuit power-off, The situations such as time and actual time that RTC clock circuit provides be inconsistent occur, ultimately results in bus system module (instrument, number According to monitor, teledata module, drive recorder etc.) it is difficult to obtain unified clock.At electric automobile real-time data acquisition Time, internal system needs a reliable and stable clock circuit, and when carrying out data record, processor needs to obtain and current is The system time, and preserve after corresponding data interpolation time tag, after internal system time clock deviation occurs or lost efficacy, right The collection of data and record, because not having ageing, cause the collection of data to lose meaning.
Summary of the invention
The invention provides a kind of real-time clock based on electric automobile data acquisition function, it includes Big Dipper mould Block, CAN transceiver, SD card circuit, real time clock circuit, processor unit;
Described Big Dipper module is connected with processor unit interactive mode, and described CAN transceiver is with processor unit interactive mode even Connecing, SD card circuit is connected with processor unit interactive mode, and real time clock circuit is connected with processor unit interactive mode.
It is preferred that described Big Dipper module receives satellite-signal, described satellite-signal includes that real-time time signal is believed with position Number.
It is preferred that described Big Dipper module receives satellite-signal, time signal will be received and send described processor unit to, This time signal is carried out synchronize with real time clock circuit by described processor unit, time signal is passed through CAN transceiver simultaneously Other node being sent on CAN network, completes the time synchronized of CAN.
It is preferred that processor unit is by the CAN transceiver reception to the header length in CAN, and will receive Information and Big Dipper module in time of sending, positional information process, preserved by SD card circuit after classification.
It is preferred that described processor unit is connected with SD card circuit by SPI interface, described SPI interface uses 4 line systems Carry out data communication, when processor unit receives data and has packed data, trigger a write signal, processor list Unit carries out communication by its hardware SPI interface and SD card circuit, and the present invention takes the mode temporally carrying out classifying, and per diem creates One file, in the file of every day, the size of each file is less than 2MB byte, when file content is more than 2MB, Close this document, again create a new file with current time and open it, after one time tag of write, subsequently Write needs the data message preserved, and completes a secondary data write and the process preserved.
The method have the advantages that
The present invention provide real-time clock based on electric automobile data acquisition function due to Big Dipper module time Between error less, use after satellite time, data acquisition unit can be avoided owing to the reasons such as crystal frequency, temperature, voltage error cause System time build up error, meanwhile, whole CAN tennis all uses satellite time, also make CAN system time Between synchronize to be guaranteed, precision and the concordance of time are all significantly improved.
Certainly, the arbitrary product implementing the present invention it is not absolutely required to reach all the above advantage simultaneously.
Accompanying drawing explanation
In order to be illustrated more clearly that the technical scheme of the embodiment of the present invention, embodiment will be described required use below Accompanying drawing is briefly described, it should be apparent that, the accompanying drawing in describing below is only some embodiments of the present invention, for ability From the point of view of the those of ordinary skill of territory, on the premise of not paying creative work, it is also possible to obtain the attached of other according to these accompanying drawings Figure.
Fig. 1 is the circuit block diagram of the real-time clock based on electric automobile data acquisition function that the present invention provides;
Fig. 2 is the read-write schematic flow sheet of the SD card that the present invention provides.
Detailed description of the invention
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete Describe, it is clear that described embodiment is only a part of embodiment of the present invention rather than whole embodiments wholely.Based on Embodiment in the present invention, those of ordinary skill in the art obtained under not making creative work premise all other Embodiment, broadly falls into the scope of protection of the invention.
During as it is shown in figure 1, embodiments provide a kind of high-precision real based on electric automobile data acquisition function Clock, including Big Dipper module, CAN transceiver, SD card circuit, real time clock circuit, processor unit;
Described Big Dipper module is connected with processor unit interactive mode, and described CAN transceiver is with processor unit interactive mode even Connecing, SD card circuit is connected with processor unit interactive mode, and real time clock circuit is connected with processor unit interactive mode.
The present invention receives satellite-signal by Big Dipper module, and described satellite-signal includes that real-time time signal is believed with position Number, send the real-time time signal received and position signalling to processor unit, processor unit by this information with in real time The information of clock synchronizes, other node module simultaneously temporal information being sent in bus network by CAN, complete Becoming CAN time synchronized, the information in bus is received targetedly by processor unit by CAN transceiver, and The time signal sent in the information of reception and Big Dipper module, position signalling are processed, after classification, is saved in SD card In circuit, it is achieved data storage writing function.
The Big Dipper module being connected with processor unit, includes an input front end and Big Dipper module UM220 III group Becoming, input front end includes gps antenna, radio-frequency front-end low-noise amplifier, SAW filter, connects satellite-signal Retractable is big, be input to UM220 III Big Dipper module after filtering, by UM220 III Big Dipper module by serial communication interface to Reason device timing delivery time and position signalling, its signal transmits frequency can be carried out by serial communication interface by processor unit Configuration, after processor unit receives the packet that UM220 III Big Dipper module is sended over by serial communication interface, right Data are received and verify, if verification is correct, then by this time as current system time, simultaneously by these data Synchronized update is to real time clock circuit.
The real time clock circuit that the embodiment of the present invention provides includes a RTC real-time clock module, RTC real-time clock module It is an I2The clock module DS3231 of C bus, the integrated crystalline substance with temperature compensation function of this clock module chip internal Oscillation body device and crystal, improve the long-term work degree of accuracy of device, and processor passes through I2C bus and DS3231 carry out communication, Obtain the second, point, time, week, the date, the moon, year information.Clock module DS3231 is also equipped with time backup functionality simultaneously, works as vehicle Travel in tunnel, culvert or when docking at place that underground garage etc. does not receives satellite-signal, Big Dipper module time information is lost Losing, now, system then uses time that DS3231 real-time clock module provides as system time.
The SD card circuit that the embodiment of the present invention provides includes SD card, and it is connected with processor unit by SPI interface, SD It is stuck in present daily life and uses widely in work, have become as the most general data storage card.Much setting All use SD card as its storage device for upper.It is cheap, memory capacity is big, easy to use, versatility and high safety Etc. advantage.SD card supports that SD mode is read and write with SPI mode.Wherein SD mode uses 6 line systems, SPI mode to use 4 line systems to count According to communication.Data transmission bauds during SD mode and SPI mode want fast, use SPI mode to carry out with processor in this programme Communication, when processor receives data and has packed data, triggers a write signal, and now, processor is hard by it Part SPI interface and SD card carry out communication, are illustrated in figure 2 the read-write flow chart of SD card, in the recording process of data, in order to just In data statistics and analysis, this programme takes the mode temporally carrying out classifying, and per diem creates a file, in every day In file, the size of each file is less than 2MB byte, when file content is more than 2MB, closes this document, again to work as The front time creates a new file and opens it, after one time tag of write, is subsequently written and needs data to be saved Information, completes a secondary data write and the process preserved.
Needing the data receiving and preserving to lead to CAN transceiver to complete, processor unit is received always by CAN transceiver Data, to needing the data receiving and preserving to be received, are then carried out point by the CAN message on line, and filter it After class pretreatment, being saved in the caching of processor, when carrying out data and preserving, data are directly carried out by processor by caching Extract, add the operational efficiency of system.
In order to realize the concordance of CAN system clock, processor unit is also by the second lock-out pulse of Big Dipper module In conjunction with the timing of CAN interface to bus transmission time information, receive UM220 at processor unit by serial communication interface While III Big Dipper module time information, it is same that UM220 III Big Dipper module exports a high-precision second also by hardware port Pace pulse exports, and its precision is better than 50ns, and dutycycle is 50%, and 1PPS signal rising edge is time synchronized point.Second lock-out pulse Output port is connected to the input capture port of processor, when this port captures a rising edge signal, triggers processor Producing and interrupt, processor unit is information be sent to bus by CAN transceiver lock in time in interrupt service routine On, completing bus clock and synchronize, in bus, other node is after receiving the CAN message of this time synchronized, carries out CAN transceiver and connects Receive, and update the time of current system, complete the synchronized update to clock.
Due to the fact that the time error of Big Dipper module is less, use after satellite time, data acquisition unit can avoid due to The system time that the reasons such as crystal frequency, temperature, voltage error cause builds up error, and meanwhile, whole CAN network is all adopted With satellite time, also making the time synchronized of CAN system be guaranteed, precision and the concordance of time are all significantly improved.
Present invention disclosed above preferred embodiment is only intended to help to illustrate the present invention.Preferred embodiment is the most detailed Describe all of details, be also not intended to the detailed description of the invention that this invention is only described.Obviously, according to the content of this specification, Can make many modifications and variations.These embodiments are chosen and specifically described to this specification, is to preferably explain the present invention Principle and actual application so that skilled artisan can be best understood by and utilize the present invention.The present invention is only Limited by claims and four corner thereof and equivalent.

Claims (5)

1. a real-time clock based on electric automobile data acquisition function, it is characterised in that: include Big Dipper module, CAN transceiver, SD card circuit, real time clock circuit, processor unit;
Described Big Dipper module is connected with processor unit interactive mode, and described CAN transceiver is connected with processor unit interactive mode, SD Card circuit is connected with processor unit interactive mode, and real time clock circuit is connected with processor unit interactive mode.
2. real-time clock based on electric automobile data acquisition function as claimed in claim 2, it is characterised in that institute Stating Big Dipper module and receive satellite-signal, described satellite-signal includes real-time time signal and position signalling.
Real-time clock based on electric automobile data acquisition function the most according to claim 1, it is characterised in that To receive time signal and send described processor unit to, described processor unit is by this time signal and real time clock circuit Synchronize, utilize other joint that time signal is sent on CAN network by CAN transceiver by second lock-out pulse simultaneously Point, completes the time synchronized of CAN.
Real-time clock based on electric automobile data acquisition function the most according to claim 1, it is characterised in that Processor unit passes through the CAN transceiver reception to the header length in CAN, and by the information received and Big Dipper module In the time signal that sends, position signalling process, preserved by SD card circuit after classification.
Real-time clock based on electric automobile data acquisition function the most according to claim 1, it is characterised in that Described processor unit is connected with SD card circuit by SPI interface, and described SPI interface uses 4 line systems to carry out data communication, when After processor unit receives data and packed data, triggering a write signal, processor unit passes through its hardware SPI Interface and SD card circuit carry out communication, and the present invention takes the mode temporally carrying out classifying, and per diem creates a file, often In the file of day, the size of each file is less than 2MB byte, when file content is more than 2MB, closes this document, again Create a new file with current time and open it, after one time tag of write, being subsequently written and need preservation Data message, completes a secondary data write and the process preserved.
CN201610899606.2A 2016-10-14 2016-10-14 A kind of real-time clock based on electric automobile data acquisition function Pending CN106249634A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610899606.2A CN106249634A (en) 2016-10-14 2016-10-14 A kind of real-time clock based on electric automobile data acquisition function

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610899606.2A CN106249634A (en) 2016-10-14 2016-10-14 A kind of real-time clock based on electric automobile data acquisition function

Publications (1)

Publication Number Publication Date
CN106249634A true CN106249634A (en) 2016-12-21

Family

ID=57612705

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610899606.2A Pending CN106249634A (en) 2016-10-14 2016-10-14 A kind of real-time clock based on electric automobile data acquisition function

Country Status (1)

Country Link
CN (1) CN106249634A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112158358A (en) * 2020-09-29 2021-01-01 西安应用光学研究所 Data exchange and acquisition system for photoelectric pod

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1793301A1 (en) * 2005-11-30 2007-06-06 Thomson Licensing Method and apparatus for providing a stable clock signal
CN201569905U (en) * 2009-12-23 2010-09-01 中国电力科学研究院 Real-time monitor terminal of electric automobile
CN103092066A (en) * 2012-12-03 2013-05-08 国电联合动力技术有限公司 Clock synchronization device and method used for fan control system
CN203490489U (en) * 2013-08-26 2014-03-19 安徽安凯汽车股份有限公司 Data acquisition unit for electric vehicle
CN204242257U (en) * 2014-11-20 2015-04-01 山东广安电子科技股份有限公司 LNG monitors automobile travel recorder

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1793301A1 (en) * 2005-11-30 2007-06-06 Thomson Licensing Method and apparatus for providing a stable clock signal
CN201569905U (en) * 2009-12-23 2010-09-01 中国电力科学研究院 Real-time monitor terminal of electric automobile
CN103092066A (en) * 2012-12-03 2013-05-08 国电联合动力技术有限公司 Clock synchronization device and method used for fan control system
CN203490489U (en) * 2013-08-26 2014-03-19 安徽安凯汽车股份有限公司 Data acquisition unit for electric vehicle
CN204242257U (en) * 2014-11-20 2015-04-01 山东广安电子科技股份有限公司 LNG monitors automobile travel recorder

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112158358A (en) * 2020-09-29 2021-01-01 西安应用光学研究所 Data exchange and acquisition system for photoelectric pod

Similar Documents

Publication Publication Date Title
CN103269262B (en) A kind of punctual method of time synchronism apparatus
CA2688750A1 (en) Device time adjustment for accurate data exchange
EP3401707B1 (en) Systems and methods for seismic data acquisition
CN202008583U (en) Clock source of synchronous phasor measuring device
CN105446917B (en) The device that the data record and location information of a kind of PPK-RTK obtains
CN110928176B (en) Multifunctional time service equipment supporting multiple time service technologies
CN113259902B (en) Synchronization method based on V2X vehicle-mounted terminal, V2X vehicle-mounted terminal and vehicle
CN114964175A (en) Multi-sensor data synchronous acquisition device and acquisition method
CN103235500A (en) Satellite time service method and timing device based on beidou
CN206480058U (en) A kind of logger with Ethernet real-time Transmission function
CN106249634A (en) A kind of real-time clock based on electric automobile data acquisition function
CN110187237B (en) Power grid synchronous acquisition method and device for detecting and adjusting crystal oscillator output frequency in real time
CN113960413A (en) Time synchronization method for collecting unit and collecting unit in fault indicator
CN206627783U (en) A kind of real-time clock based on electric automobile data acquisition function
CN107171780A (en) Clock recovery phase ambiguity judges, the device and method of compensation
CN103001632A (en) CPLD-based (complex programmable logic device-based) GPS (global positioning system) synchronous sampling circuit
CN115865252B (en) High-precision GNSS time synchronization method capable of setting period
CN104991441B (en) GPS sync identification circuits
CN211344815U (en) Pipeline leakage signal detector
CN111932236B (en) NB-IoT-based vehicle insurance duration charging device and reliability processing method
CN105843768B (en) A kind of single line communication time-after-time programmable memory method for burn-recording and the burning device based on this method
WO2022110280A1 (en) Method and apparatus for updating local time, device, and storage medium
CN205334566U (en) Data record device, recording system and vehicle travel
CN101996149B (en) Data acquisition method and device
CN103699103B (en) The method of sequence of events recording in scattered control system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20161221

RJ01 Rejection of invention patent application after publication