Baud-rate automatic matching method for controller and CAN bus

A CAN bus, automatic matching technology, applied in the direction of program control, computer control, general control system, etc., can solve the problems of limiting the versatility of the controller, reducing work efficiency, and unable to reconfigure the baud rate of the controller, so as to improve the general and portability, to achieve the effect of automatic matching

Active Publication Date: 2014-05-07
CHONGQING CHANGAN AUTOMOBILE CO LTD
View PDF5 Cites 18 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

In practical applications, the baud rate of the CAN bus is not unique, and different CAN buses have different baud rates, and usually the baud rate of the controller has been fixed in the factory, resulting in when the controller is transplanted to a different When the baud rate is in the CAN bus, not only will there be a situation of inability to communicate, which will limit the versatility of the controller, but also when there is an error frame on the bus, it will even cause the CAN bus to be paralyzed, and the rest of the controllers will not work normally.
At the same time, the diagnostic instrument cannot reconfigure the baud rate of the controller. The only solution is to replace the controller with a new one.
This not only wastes resources but also increases costs and reduces work efficiency.

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Baud-rate automatic matching method for controller and CAN bus

Examples

Experimental program
Comparison scheme
Effect test

example 1

[0026] Assuming that the baud rate of the CAN bus is 500K, the initial value of the error count accumulator is 0, and the predetermined value X=2 of the error count accumulator is specified.

[0027] Step a: Write the controller code, pre-store a variety of standby standard baud rates (1M, 500K, 250K, 125K...) in the microcontroller used by the controller, connect the controller to the CAN bus, and connect the controller The default standard baud rate is set to 1M.

[0028] Perform step b: the controller receives the message sent by the CAN bus;

[0029] Perform step c: Since the default standard baud rate of the controller is 1M and the fixed baud rate of the CAN bus is 500K, it is clear that the message sent by the CAN bus is an error message received by the controller, so go to step e.

[0030] Step e: The controller receives an error message sent by the CAN bus, and the controller receives an error frame, and adds 1 to the value of the error count accumulator built into the contro...

example 2

[0041] Assuming that the baud rate of the CAN bus is 1M, the initial value of the error count accumulator is 0, and X=2 is specified.

[0042] Step a: Write the controller code, pre-store various standby standard baud rates (1M, 500K, 250K, 125K...) in the microcontroller used by the controller, connect the controller to the CAN bus, and connect the controller The default standard baud rate is set to 1M.

[0043] Perform step b: the controller receives the message sent by the CAN bus.

[0044] Perform step c: Determine whether the controller receives the correct message. Since the default initial baud rate of the controller is 1M and the fixed baud rate of the CAN bus is 1M, it is obvious that the controller receives the message sent by the CAN bus. For the correct message, go to step d.

[0045] Perform step d: The controller receives the correct message sent by the CAN bus, which means that the baud rate of the controller and the CAN bus is the same, and the baud rate is matched su...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

Disclosed is a baud-rate automatic matching method for a controller and a CAN bus, that is, a plurality of kinds of standby standard baud rates are stored in the controller and the controller is connected to the CAN bus; the default baud rate of the controller is set; the controller receives a message sent by the CAN bus; whether baud-rate matching is successful is judged according to whether the message sent by the CAN bus and received by the controller is correct; if the message sent by the CAN bus and received by the controller is incorrect, values in a built-in error count accumulator of the controller are accumulated; and whether to execute resetting of the baud rate of the controller is determined according to whether the value of the error count accumulator reaches a preset value. The method realizes baud-rate automatic matching between the controller and the CAN so that the controller is applicable to CAN buses of different fixed baud rates and universality and transportability of the controller are improved.

Description

Technical field [0001] The invention relates to the communication field of automobile electronic control systems, in particular to a method for automatically matching the baud rate of a controller and a CAN bus. Background technique [0002] As consumers' requirements for car performance and comfort continue to increase, the number of electronic control systems in cars has also increased accordingly. Controllers need to be connected to each other through a communication network. The most widely used interface is the CAN bus. Monitor and manage each controller through CAN bus. [0003] In the traditional communication method, the two parties communicating must have the same baud rate to be able to communicate normally, and the mutual communication between the car controller and the CAN bus must also have the same baud rate, that is, the controller can only It communicates with a specific CAN bus with the same baud rate as its own. In practical applications, the baud rate of the C...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G05B19/042
Inventor 张鹏韩蛟余秋实刘大全王冠翔
Owner CHONGQING CHANGAN AUTOMOBILE CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products