CN101702659B - Detection device for expanding monitoring quantity by CAN bus - Google Patents
Detection device for expanding monitoring quantity by CAN bus Download PDFInfo
- Publication number
- CN101702659B CN101702659B CN200910235906.0A CN200910235906A CN101702659B CN 101702659 B CN101702659 B CN 101702659B CN 200910235906 A CN200910235906 A CN 200910235906A CN 101702659 B CN101702659 B CN 101702659B
- Authority
- CN
- China
- Prior art keywords
- data
- fpga
- control unit
- expanding
- instruction control
- 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.)
- Active
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/12—Discovery or management of network topologies
Abstract
The invention discloses a detection device for expanding the monitoring quantity by a CAN bus, comprising a main CAN device and a programmable logic controller FPGA expansion system, wherein in the FPGA expansion system, a CAN IP core is used for receiving the data on the CAN bus and sending the data into an information filter; the data returned by a command controller is sent to the main CAN device; when judging the data is received by the FPGA expansion system, the information filter sends the data into the command controller; and the command controller executes the corresponding operation according to the data coming from the information filter and returns the operation result data. The invention also correspondingly discloses a detection method for expanding the monitoring quantity by the CAN bus. As the invention has little dependency for the original system, and any CAN bus can be used, the invention has better expansibility; furthermore, less hardware resource is used, the flexibility of design can be realized to the utmost extent.
Description
Technical field
The present invention relates to monitoring technique, particularly relate to a kind of checkout gear by CAN (Controll Area Network) bus extension monitoring parameter and method.
Background technology
Along with the development of monitoring technique and automaticity improve constantly, in the fields such as Industry Control, communication, automobile, consumer electronics and product, increasing signal demand is monitored in real time, to reach unattended object.
But, owing to monitoring the continuous increase of demand, original watch-dog all can not be replaced, no matter so in time or cost is all unallowed, so, wish the detection system can expanding the monitoring parameter made new advances on original watch-dog basis again.
At present, the detection method for expansion monitoring variable mainly contains following several:
1) expanded by parallel bus;
2) Extended serial-bus is passed through;
3) expanded by CPU+CAN controller.
Although this several mode above can realize while satisfied monitoring demand, save time and cost to a certain extent, but, by parallel, Extended serial-bus requires that original system must leave parallel or universal serial bus and have corresponding interface, then require original system by the expansion of CPU+CAN controller and must CPU be had, corresponding expansion could be implemented, so, expanded by parallel bus, pass through Extended serial-bus, by the expansion of CPU+CAN controller all by the restriction of original system, autgmentability there is limitation, use hardware resource many simultaneously, flexibility is not strong.
Summary of the invention
In view of this, main purpose of the present invention is to provide a kind of checkout gear by CAN expanding monitoring quantity and method, can improve the flexibility of design, and have good autgmentability.
For achieving the above object, technical scheme of the present invention is achieved in that
A kind of checkout gear by CAN expanding monitoring quantity, comprise: CAN main equipment and programmable logic controller (PLC) FPGA expanding system, communicated by CAN between CAN main equipment and programmable logic controller (PLC) FPGA expanding system, described FPGA expanding system specifically comprises: CAN IP kernel, signal filter, instruction control unit, wherein
Described CAN main equipment, for sending control command data and obtaining the data needed by CAN;
Received data for receiving the data in CAN, and are sent to signal filter by described CAN IP kernel; And the data to be returned by instruction control unit send to CAN main equipment by CAN;
Described data for filtering the data from CAN IP kernel, and when judging that described data are data of this FPGA expanding system reception, are sent to instruction control unit by described signal filter;
Described instruction control unit, for according to the data from signal filter, performs and operates accordingly, and return operating result data to CAN IP kernel.
Described FPGA expanding system also comprises data storage,
Described instruction control unit, also for obtaining data according to the data from signal filter to data storage;
Described data storage, for providing the data of real-time change to instruction control unit.
Described FPGA expanding system also comprises sampling module,
Described instruction control unit, also for realizing gating according to the data notification sampling module from signal filter;
Described sampling module, realizes gating for the notice according to instruction control unit.
This device also comprises AD conversion device,
Described sampling module, also for directly sampling to digital quantity, and is sampled to analog quantity by AD conversion device, and sampled result is saved to data storage;
Described AD conversion device, for changing for realizing analog quantity sampling.
This device also comprises power module, for powering for FPGA expanding system and AD conversion device.
By a detection method for CAN expanding monitoring quantity, FPGA expanding system comprises: CAN IP kernel, signal filter, instruction control unit, and the method comprises:
When CAN IP kernel detection CAN having data, receive described data, and described data are sent to signal filter;
Signal filter judges that described data are the data that this FPGA expanding system receives, then described data are sent to instruction control unit;
Instruction control unit performs corresponding operation according to described data, and returns operating result data to CAN IP kernel;
Described operating result data are sent to CAN main equipment by CAN by CAN IP kernel.
The address of FPGA expanding system is set to a fixing address, described signal filter judges whether data are the data that this FPGA expanding system receives and are: judge that whether the receiver address of described data is consistent with the address of this FPGA expanding system.
FPGA expanding system also comprises data storage, and described instruction control unit performs according to the data received and is operating as digital independent accordingly, then read corresponding data in instruction control unit to data storage.
FPGA expanding system also comprises sampling module, and when described instruction control unit is operating as the gating of control simulation passage accordingly according to the data execution received, then instruction control unit notice sampling module realizes gating.
The method also comprises: sampling module is directly sampled to digital quantity, and is sampled to analog quantity by AD conversion device, and sampled result is saved to data storage.
Described sampling module is directly sampled to digital quantity, and when being sampled to analog quantity by AD conversion device, carries out filtering.
The present invention passes through checkout gear and the method for CAN expanding monitoring quantity, based on programmable logic controller (PLC) (FPGA), and is realized the expansion sampling of digital quantity and analog quantity by hardware description language.Because the present invention is very little to the dependence of original system, as long as there is CAN, just can use, so have good autgmentability; In addition, the hardware resource that the present invention uses is few, and a lot of logic realizes by hardware logic language, thus farthest can realize the flexibility of design.
Accompanying drawing explanation
Fig. 1 is the structure of the detecting device schematic diagram of the present invention by CAN expanding monitoring quantity;
Fig. 2 is the detection method schematic flow sheet of the present invention by CAN expanding monitoring quantity;
Fig. 3 is sampling module workflow schematic diagram.
Embodiment
Basic thought of the present invention is: based on programmable logic controller (PLC) (FPGA), and realizes the expansion sampling of digital quantity and analog quantity by hardware description language.
Fig. 1 is the structure of the detecting device schematic diagram of the present invention by CAN expanding monitoring quantity, as shown in Figure 1, the present invention is comprised by the checkout gear of CAN expanding monitoring quantity: CAN main equipment 11 and programmable logic controller (PLC) (FPGA) expanding system 12, communicated by CAN between CAN main equipment 11 and FPGA expanding system 12, described FPGA expanding system 12 specifically comprises: CAN IP kernel 121, signal filter 122, instruction control unit 123, wherein
CAN main equipment 11, for sending control command data and obtaining the data needed by CAN.
Received data for receiving the data in CAN, and are sent to signal filter 122 by CAN IP kernel 121; And the data to be returned by instruction control unit 123 send to CAN main equipment 11 by CAN.This partial logic does not need from the beginning to design, existing business logic modules can be adopted to carry out apolegamy and the reduction of function, to adapt to our system needs, system due to us is the expanding system detected as analog quantity and digital quantity, and therefore this system only needs to be configured in CAN one from equipment.
Described data for filtering the data from CAN IP kernel 121, and when judging that described data are data of this FPGA expanding system reception, are sent to instruction control unit 123 by signal filter 122;
Instruction control unit 123, for according to the data from signal filter 122, performs and operates accordingly, and return operating result data to CAN IP kernel 121.
FPGA expanding system 12 also comprises data storage 124,
Instruction control unit 123, also for obtaining data according to the data from signal filter 122 to data storage 124;
Data storage 124, for providing the data of real-time change to instruction control unit 123.
FPGA expanding system 12 also comprises sampling module 125,
Instruction control unit 123, also for realizing gating according to the data notification sampling module 125 from signal filter 122;
Sampling module 125, for realizing gating according to the notice of instruction control unit 123.
This device also comprises AD conversion device 13,
Sampling module 125, also for directly sampling to digital quantity, and is sampled by AD conversion device 13 pairs of analog quantitys, and sampled result is saved to data storage 124;
AD conversion device 13, for changing for realizing analog quantity sampling.
This device also comprises power module 14, for powering for FPGA expanding system 12 and AD conversion device 13.
It should be noted that, the FPGA expanding system of a corresponding CAN main equipment can have multiple.
Based on the device shown in Fig. 1, its operation principle is described below.
Fig. 2 is the detection method schematic flow sheet of the present invention by CAN expanding monitoring quantity, and as shown in Figure 2, the present invention generally comprises following steps by the detection method of CAN expanding monitoring quantity:
Step 201:CAN IP kernel detects in CAN whether have data, if so, performs step 202; Otherwise, return step 201.
It should be noted that, in practical application, when being suspended in CAN by a FPGA expanding system, need the communication mode etc. of the address of the system that sets, traffic rate and CAN.Afterwards, CAN main equipment just can send control command to this FPGA expanding system by CAN.
Step 202:CAN IP kernel receives described data, and described data are sent to signal filter.
Step 203: signal filter judges whether described data are the data that this FPGA expanding system receives, and if so, perform step 204; Otherwise, perform step 207.
For simplifying system logic, general the address of each FPGA expanding system is set to a fixing special address, after the signal filter of FPGA expanding system receives the data from CAN IP kernel, whether consistent with the address of this FPGA expanding system by judging the receiver address of described data, judge whether described data are the data that this FPGA expanding system receives.If consistent, then continue to receive, if inconsistent, then abandon this packet.
Step 204: described data are sent to instruction control unit by signal filter.
Step 205: instruction control unit performs corresponding operation according to described data, and returns operating result data to CAN IP kernel.
Instruction control unit carrys out resolve command by reading order word in the data of always self information filter, and performs corresponding order, as received reading digital information, then reads corresponding digital information in instruction control unit to data storage; When needing the gating of control simulation passage, instruction control unit specifically notifies that sampling module realizes gating.
Fig. 3 is sampling module workflow schematic diagram, and as shown in Figure 3, the sampling principle of sampling module to data is generally:
In digital quantity sample port, when the change of certain I/O port generation state being detected, just upgrade this digital information of data storage;
In analog quantity sample port, the analog quantity channel that cycle strobe is different, different analog data of sampling, and real-time update is in data storage.
It should be noted that, sampling module, when sampling to digital quantity and analog quantity, often needs to carry out filtering, to avoid external interference on the impact of data correctness.
Described operating result data are sent to CAN main equipment by CAN by step 206:CAN IP kernel, and flow process connects bundle.
Step 207: abandon described packet, return step 201.
Embodiment
In the present embodiment, FPGA expanding system has 8 railway digital amounts, the extended capability of 8 tunnel analog quantitys, and certain combinations of communication power-supply system, has CAN, is articulated in CAN by this FPGA expanding system by CAN data wire, as from equipment.Such monitoring unit is exactly main equipment.
The course of work that this system is concrete is as follows:
1) the CAN communication speed of FPGA expanding system is arranged with main equipment consistent, adopt peli pattern, the data of 13 bytes that what such CAN-IP core exported is exactly, the address simultaneously setting this FPGA expanding system is 0xFE, digital quantity memory DD, memorized in analogue device AA0 ~ AA7, analog quantity channel selector R.
2) monitoring unit reads this expansion from the digital quantity of equipment and analog quantity information every 50ms.
3) when FPGA expanding system detects, CAN there are data, are first sent to CAN-IP core and carry out unpacking process, be then sent to signal filter, when the address field detecting packet equals 0xFE, then receive this packet, otherwise just by this data packet discarding.
4) if there is the packet of correct reading amount of information, be then sent to command control module, carry out command analysis.
5) from data storage, the digital information DD of 8 is read, and 1 road analog quantity information AAn, then data are packed, be sent to CAN-IP core module, then mail to bus.
6) synchronous, at digital quantity sampling module, when detecting that any generation state in 8 bit digital quantity changes, then real-time renewal digital quantity memory DD.
7) at analog quantity sampling module, every 10ms, carry out the switching of analog quantity channel R, the data message of reading is stored in memorized in analogue device AAr.Like this, a process reading data just completes.
Can find out, adopt the method for sampling of expansion variable of the present invention and analog quantity, by existing CAN, can expand a lot of digital quantity and analog quantity very easily, hardware designs is simple, and device is few; Without the need to the restriction of too many service condition, may be used for a lot of supervisory control system.
The above, be only preferred embodiment of the present invention, be not intended to limit protection scope of the present invention.
Claims (9)
1. the checkout gear by CAN expanding monitoring quantity, it is characterized in that, this device comprises: CAN main equipment and programmable logic controller (PLC) FPGA expanding system, communicated by CAN between CAN main equipment and programmable logic controller (PLC) FPGA expanding system, described FPGA expanding system specifically comprises: CAN IP kernel, signal filter, instruction control unit and data storage, wherein
Described CAN main equipment, for sending control command data and obtaining the data needed by CAN;
Received data for receiving the data in CAN, and are sent to signal filter by described CAN IP kernel; And the data to be returned by instruction control unit send to CAN main equipment by CAN;
Described data for filtering the data from CAN IP kernel, and when judging that described data are data of this FPGA expanding system reception, are sent to instruction control unit by described signal filter;
Described instruction control unit, for according to the data from signal filter, performs corresponding operation and returns operating result data to CAN IP kernel, and obtaining data according to the data from signal filter to data storage;
Described data storage, for providing the data of real-time change to instruction control unit.
2. the checkout gear by CAN expanding monitoring quantity according to claim 1, it is characterized in that, described FPGA expanding system also comprises sampling module,
Described instruction control unit, also for realizing gating according to the data notification sampling module from signal filter;
Described sampling module, realizes gating for the notice according to instruction control unit.
3. the checkout gear by CAN expanding monitoring quantity according to claim 2, it is characterized in that, this device also comprises AD conversion device,
Described sampling module, also for directly sampling to digital quantity, and is sampled to analog quantity by AD conversion device, and sampled result is saved to data storage;
Described AD conversion device, for changing for realizing analog quantity sampling.
4. the checkout gear by CAN expanding monitoring quantity according to any one of claims 1 to 3, it is characterized in that, this device also comprises power module, for powering for FPGA expanding system and AD conversion device.
5., by a detection method for CAN expanding monitoring quantity, it is characterized in that, FPGA expanding system comprises: CAN IP kernel, signal filter, instruction control unit and data storage, and the method comprises:
When CAN IP kernel detection CAN having data, receive described data, and described data are sent to signal filter;
Signal filter judges that described data are the data that this FPGA expanding system receives, then described data are sent to instruction control unit;
Instruction control unit performs corresponding operation according to described data, and returns operating result data to CAN IP kernel;
Described operating result data are sent to CAN main equipment by CAN by CAN IP kernel;
When described instruction control unit is operating as digital independent accordingly according to the data execution received, then read corresponding data in instruction control unit to data storage; Wherein, the data in described data storage are the data of real-time change.
6. the detection method by CAN expanding monitoring quantity according to claim 5, it is characterized in that, the address of FPGA expanding system is set to a fixing address, described signal filter judges whether data are the data that this FPGA expanding system receives and are: judge that whether the receiver address of described data is consistent with the address of this FPGA expanding system.
7. the detection method by CAN expanding monitoring quantity according to claim 5, it is characterized in that, FPGA expanding system also comprises sampling module, when described instruction control unit is operating as the gating of control simulation passage accordingly according to the data execution received, then instruction control unit notice sampling module realizes gating.
8. the detection method by CAN expanding monitoring quantity according to claim 7, it is characterized in that, the method also comprises: sampling module is directly sampled to digital quantity, and is sampled to analog quantity by AD conversion device, and sampled result is saved to data storage.
9. the detection method by CAN expanding monitoring quantity according to claim 8, it is characterized in that, described sampling module is directly sampled to digital quantity, and when being sampled to analog quantity by AD conversion device, carries out filtering.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN200910235906.0A CN101702659B (en) | 2009-10-29 | 2009-10-29 | Detection device for expanding monitoring quantity by CAN bus |
PCT/CN2010/072071 WO2010145320A1 (en) | 2009-10-29 | 2010-04-22 | Detecting device and method for expanding monitor capacity through controller area network (can) bus |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN200910235906.0A CN101702659B (en) | 2009-10-29 | 2009-10-29 | Detection device for expanding monitoring quantity by CAN bus |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101702659A CN101702659A (en) | 2010-05-05 |
CN101702659B true CN101702659B (en) | 2015-07-22 |
Family
ID=42157554
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN200910235906.0A Active CN101702659B (en) | 2009-10-29 | 2009-10-29 | Detection device for expanding monitoring quantity by CAN bus |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN101702659B (en) |
WO (1) | WO2010145320A1 (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112148646A (en) * | 2020-09-18 | 2020-12-29 | 明峰医疗系统股份有限公司 | CAN network node data monitoring method of CT system |
CN115019949A (en) * | 2022-08-08 | 2022-09-06 | 丹娜(天津)生物科技股份有限公司 | Medical equipment data monitoring system and medical equipment data monitoring method |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR20020086786A (en) * | 2001-05-11 | 2002-11-20 | 엘지이노텍 주식회사 | Radar system for preventing impact of vehicle |
CN201111179Y (en) * | 2007-10-08 | 2008-09-03 | 北京全路通信信号研究设计院 | Vehicle mounted data recorder |
CN101262355A (en) * | 2008-04-18 | 2008-09-10 | 北京锐安科技有限公司 | A data switch processing board and its corresponding switch processing system |
CN101355575A (en) * | 2008-09-04 | 2009-01-28 | 上海交通大学 | System and method for monitoring civil engineering strained base on CAN network |
CN201238361Y (en) * | 2008-06-19 | 2009-05-13 | 同济大学 | Video collection apparatus |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN100530009C (en) * | 2007-08-07 | 2009-08-19 | 广西工学院 | Universal small-sized programmable controller and control method thereof |
CN201095563Y (en) * | 2007-09-24 | 2008-08-06 | 南京工业大学 | Distributed escalator controlling device based on CAN bus wire |
CN101159641B (en) * | 2007-11-15 | 2010-10-06 | 东信和平智能卡股份有限公司 | Can bus extension method |
-
2009
- 2009-10-29 CN CN200910235906.0A patent/CN101702659B/en active Active
-
2010
- 2010-04-22 WO PCT/CN2010/072071 patent/WO2010145320A1/en active Application Filing
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR20020086786A (en) * | 2001-05-11 | 2002-11-20 | 엘지이노텍 주식회사 | Radar system for preventing impact of vehicle |
CN201111179Y (en) * | 2007-10-08 | 2008-09-03 | 北京全路通信信号研究设计院 | Vehicle mounted data recorder |
CN101262355A (en) * | 2008-04-18 | 2008-09-10 | 北京锐安科技有限公司 | A data switch processing board and its corresponding switch processing system |
CN201238361Y (en) * | 2008-06-19 | 2009-05-13 | 同济大学 | Video collection apparatus |
CN101355575A (en) * | 2008-09-04 | 2009-01-28 | 上海交通大学 | System and method for monitoring civil engineering strained base on CAN network |
Also Published As
Publication number | Publication date |
---|---|
WO2010145320A1 (en) | 2010-12-23 |
CN101702659A (en) | 2010-05-05 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106131056B (en) | Industrial wireless adapter and working method thereof | |
CN110471880B (en) | ARINC429 bus module supporting Label number screening based on FPGA and data transmission method thereof | |
CN101839790A (en) | Intelligent on-line calibration system | |
CN201887792U (en) | Multi-protocol conversion gateway | |
CN204305072U (en) | A kind of Multi-protocol converter | |
CN105306298A (en) | Vehicle network based remote wireless testing system and testing method | |
CN105573239A (en) | High speed backboard bus communication control device and method | |
CN102752166A (en) | Debugging method, chip, single board and system | |
CN106383472B (en) | A kind of integrated highly reliable high-precision Long-term Monitoring Systems | |
CN107832247A (en) | The data concentrator of adaptive communications | |
CN105281433A (en) | Distribution terminal communication system | |
CN102013024B (en) | Grain depot and grain situation wireless monitoring system based on multistage RFID reader-writer network | |
CN101702659B (en) | Detection device for expanding monitoring quantity by CAN bus | |
CN206946006U (en) | A kind of small-sized weather station integral control system | |
CN203133584U (en) | CAN communication interface, cable monitor and cable monitoring system | |
CN202025234U (en) | Field bus module used in self-diagnosis sensor | |
CN102184637A (en) | Sensor network-based method, device and system for acquiring traffic state | |
CN204392275U (en) | A kind of MVB data interception system with Ethernet interface | |
CN102881146A (en) | Industrial on-site equipment data acquirer of multiple industrial buses | |
CN102938730B (en) | Traffic signal control system, traffic signal transmission device and method | |
CN202735809U (en) | Mining intrinsic safe type control substation | |
CN201991567U (en) | Intelligent mobile Sink node based on Internet of things for monitoring coal mine gas and system thereof | |
CN103454993A (en) | Yarn defect detection system and implementation method | |
CN116074397A (en) | Data sharing system | |
CN204836207U (en) | Register is synthesized to 1394B bus interface protection type |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant |