Battery management device and method for setting CAN baud rate

By integrating the interface unit and the microcontroller unit in the battery management device, using CAN bus communication and automatically setting the baud rate according to error detection, the baud rate compatibility problem between the battery pack and various models of external devices in the prior art is solved, and the effect of automated compatibility and reducing operational risks is achieved.

CN120021195APending Publication Date: 2025-05-20SAMSUNG SDI CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202410392578.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2023-11-20
Filing Date
2024-04-02
Publication Date
2025-05-20

AI Technical Summary

Technical Problem

When secondary batteries are used in multiple models of external devices, the prior art requires the separate setting of CAN baud rate or the use of preset baud rate information, which poses a risk of complex operation and possible operator errors.

Method used

A battery management device is provided, including an interface unit and a microcontroller unit, which communicates with an external device through a CAN bus, and automatically sets the CAN baud rate according to whether an error is detected in the received CAN message frame.

Benefits of technology

Automatic CAN baud rate compatibility between the battery pack and multiple models of external devices is achieved, reducing operational complexity and reducing the risk of operator error.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120021195A_ABST
    Figure CN120021195A_ABST
Patent Text Reader

Abstract

The present disclosure relates to a battery management apparatus and a method for setting a controller area network (CAN) baud rate, and the technical problem to be solved is to provide a method for setting a Baud rate in a battery pack of one type for various types of external devices (e.g., a controller area network (CAN) Baud rate, the invention relates to a battery management device capable of automatically setting a CAN Baud rate according to external equipment in case of an electric vehicle, a strenuous off-track vehicle (LEV), an x electric vehicle (xEV) or an energy storage system (ESS), and a method for setting the CAN Baud rate of a controller area network (CAN). To this end, the present disclosure provides a battery management apparatus including an interface unit configured to perform CAN communication with an external device through a CAN bus, and a microcontroller unit (MCU) configured to set a CAN Baud rate based on whether an error is detected in a CAN message frame received from the external device through the interface unit.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] Cross - reference to related applications

[0002] This application claims the priority and benefit of Korean Patent Application No. 10 - 2023 - 0159970, filed on November 20, 2023, the disclosure of which is incorporated herein by reference in its entirety. Technical field

[0003] Aspects of embodiments of the present disclosure relate to a battery management device and a method of setting a Controller Area Network (CAN) baud rate. Background art

[0004] Generally, unlike primary batteries that cannot be recharged, secondary batteries are batteries that can be charged and discharged. Low - capacity batteries in which one battery cell is encapsulated in a group have been used in small electronic devices such as mobile phones and portable cameras, and high - capacity batteries in which dozens of battery cells are connected have been used as power sources for drive motors of, for example, electric bicycles, electric scooters, hybrid vehicles, and electric vehicles.

[0005] When secondary batteries are used in external devices (e.g., a low - effort vehicle (LEV), an x - electric vehicle (xEV), or an energy storage system (ESS)), the secondary batteries and the external devices use Controller Area Network (CAN) communication to transmit and receive data.

[0006] Meanwhile, in a case where one type of secondary battery is used in multiple models of external devices (e.g., LEV, xEV, or ESS), when the CAN baud rates of each external device are different, in order to make the baud rate of the secondary battery compatible, there is a method of separately setting the baud rate through external communication or a method of providing pre - arranged baud rate information to a battery management system (BMS) using an external connector.

[0007] However, the method of separately setting the baud rate through communication outside the battery pack before connecting the CAN communication line of the BMS to the CAN bus of the external device has problems in that a separate setting device (e.g., a device for transmitting a personal computer (PC) combined with a graphical user interface (GUI) program or separate communication data) is required, and incorrect setting may be performed due to operator error.

[0008] In addition, the method of receiving a signal from an external connector connected to a battery pack in the BMS and operating at a pre - arranged baud rate has problems in that separate hardware for receiving external signals is required, and incorrect setting may be performed due to operator error.

[0009] The above-described information disclosed in the background section of the present invention is only for enhancing the understanding of the background of the present invention and may thus include information that does not constitute the prior art. Summary of the Invention

[0010] The present disclosure relates to providing a battery management device and a method for setting a Controller Area Network (CAN) baud rate, which can automatically set the CAN baud rate according to an external device when a type of battery pack is used for multiple models of external devices (e.g., a Light Electric Vehicle (LEV), an x Electric Vehicle (xEV), or an Energy Storage System (ESS)).

[0011] However, the technical problems to be solved by the present invention are not limited to the above-described problems, and other problems not described can be clearly understood by those skilled in the art from the description of the present invention described below.

[0012] Embodiments of the present invention provide a battery management device, which includes: an interface unit configured to perform CAN communication with an external device through a Controller Area Network (CAN) bus; and a Microcontroller Unit (MCU) configured to set the CAN baud rate based on whether an error is detected in a CAN message frame received from the external device through the interface unit.

[0013] Embodiments of the present invention provide a method for setting a Controller Area Network (CAN) baud rate, the method including: when the battery management device wakes up, initializing the CAN baud rate to the most recently used CAN baud rate through a Microcontroller Unit (MCU); determining, by the MCU, whether an abnormality has occurred in the battery pack based on battery status data; when no abnormality occurs in the battery pack, turning on a switch by the MCU to receive a CAN message frame from the external device through the CAN bus; and checking, by the MCU, whether an error is detected in the CAN message frame, and setting the initialized CAN baud rate as the final CAN baud rate when no error is detected.

[0014] An embodiment of the present invention provides a method for setting the baud rate of a Controller Area Network (CAN), the method comprising: judging, by a microcontroller unit (MCU), whether an abnormality occurs in a battery pack based on battery state data; when no abnormality occurs in the battery pack, turning on a switch by the MCU to receive a CAN message frame from an external device through a CAN bus; calculating, by the MCU, an interruption occurrence time interval every time an interruption occurs according to the reception of the CAN message frame; calculating, by the MCU, a baud rate based on the interruption occurrence time interval for a preset specific time period; obtaining, by the MCU, the baud rate most similar to the calculated baud rate from a baud rate table, and initializing the CAN baud rate to the obtained baud rate; and checking, by the MCU, whether an error is detected in the CAN message frame received from the external device at the initialized CAN baud rate, and setting the initialized CAN baud rate as the final CAN baud rate when no error is detected.

[0015] According to an embodiment of the present invention for solving the above technical problem, a battery management device automatically sets the CAN baud rate based on whether an error is detected in a CAN message frame received from an external device through a CAN bus. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] The drawings attached to the present specification below illustrate embodiments of the present disclosure, and further describe aspects and features of the present disclosure together with the detailed description of the present disclosure. Therefore, the present disclosure should not be construed as being limited to the drawings, in which:

[0017] Figure 1 is a diagram illustrating a system for setting the baud rate of a Controller Area Network (CAN) of a battery pack according to an embodiment of the present invention;

[0018] Figure 2 is a diagram illustrating a circuit of a battery pack according to an embodiment of the present invention;

[0019] Figure 3 is a diagram illustrating a CAN bus connecting an external device and a battery pack according to an embodiment of the present invention;

[0020] Figure 4 is a diagram schematically illustrating the configuration of a battery management device according to an embodiment of the present invention;

[0021] Figure 5 is a diagram illustrating an example of a CAN message frame;

[0022] Figure 6 is a diagram illustrating an example of an interruption generation time interval according to an embodiment of the present invention;

[0023] Figure 7FIG. is a diagram illustrating a method of setting a CAN baud rate according to an embodiment of the present invention; and

[0024] Figure 8 FIG. is a diagram illustrating a method of setting a CAN baud rate according to another embodiment of the present invention. DETAILED DESCRIPTION

[0025] Hereinafter, embodiments of the present disclosure will be described in detail with reference to the accompanying drawings. The terms or words used in this specification and claims should not be construed as limited to the ordinary or dictionary meanings, and should be interpreted as meanings and concepts consistent with the technical idea of the present disclosure based on the concept that the inventor can be his / her own lexicographer to appropriately define the terms in order to best explain the principle of his / her invention.

[0026] The embodiments described in this specification and the configurations shown in the drawings are only some of the embodiments of the present disclosure, and do not represent all of the technical ideas, aspects, and features of the present disclosure. Therefore, it should be understood that various equivalents and modifications that can replace or modify the embodiments described herein may exist at the time of filing this application.

[0027] It will be understood that when an element or layer is referred to as being "on", "connected to", or "coupled to" another element or layer, the element or layer can be directly on, directly connected to, or directly coupled to the other element or layer or there can also be one or more intervening elements or layers. When an element or layer is referred to as being "directly on", "directly connected to", or "directly coupled to" another element or layer, there are no intervening elements or layers. For example, when a first element is described as being "coupled" or "connected" to a second element, the first element can be directly coupled or directly connected to the second element, or the first element can be indirectly coupled or indirectly connected to the second element via one or more intervening elements.

[0028] In the accompanying drawings, for the sake of clarity of illustration, the dimensions of various elements, layers, etc. may be exaggerated. The same reference numerals designate the same elements. As used herein, the term "and / or" includes any and all combinations of one or more of the associated listed items. Additionally, when describing embodiments of the present disclosure, the use of "may" pertains to "one or more embodiments of the present disclosure". When following a list of elements, expressions such as "at least one of..." and "any one of..." modify the entire list of elements and not a single element of the list. When a phrase such as "at least one of A, B, and C", "at least one selected from the group consisting of A, B, and C", or "at least one selected from among A, B, and C" is used to specify a list of elements A, B, and C, the phrase may refer to any and all suitable combinations or subsets of A, B, and C, such as A, B, C, A and B, A and C, B and C, or A and B and C. As used herein, the terms "use", "in use", and "being used" may be considered synonymous with the terms "utilize", "in utilization", and "being utilized", respectively. As used herein, the terms "substantially", "about", and similar terms are used as approximate terms rather than terms of degree and are intended to account for the inherent deviations of measured or calculated values that would be recognized by a person of ordinary skill in the art.

[0029] It will be understood that although terms such as "first", "second", "third", etc. may be used herein to describe various elements, components, regions, layers, and / or parts, these elements, components, regions, layers, and / or parts should not be limited by these terms. These terms are used to distinguish one element, component, region, layer, or part from another element, component, region, layer, or part. Thus, a first element, component, region, layer, or part discussed below may be referred to as a second element, component, region, layer, or part without departing from the teachings of the exemplary embodiments.

[0030] For ease of description, spatial relative terms such as "below", "beneath", "under", "above", and "on" may be used herein to describe the relationship of one element or feature to another (other) element or feature as illustrated in the accompanying drawings. It will be understood that, in addition to the orientation depicted in the accompanying drawings, spatial relative terms are intended to encompass different orientations of the device during use or operation. For example, if the device in the accompanying drawings is flipped, an element described as "below" or "beneath" other elements or features will then be oriented "above" or "over" the other elements or features. Thus, the term "below" can encompass both the upper and lower orientations. The device may be oriented in other ways (rotated 90 degrees or in other orientations), and the spatial relative descriptors used herein should be interpreted accordingly.

[0031] The terms used in this document are for the purpose of describing embodiments of the present disclosure and are not intended to limit the present disclosure. As used herein, unless the context clearly dictates otherwise, the singular form "a" is intended to also include the plural form. It will be further understood that when used in this specification, the terms "comprises" and / or "comprising" specify the presence of the stated features, integers, steps, operations, elements, and / or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof.

[0032] In addition, any numerical range disclosed and / or recited herein is intended to include all sub-ranges of the same numerical precision subsumed within the recited range. For example, a range of "1.0 to 10.0" is intended to include all sub-ranges between the recited minimum value 1.0 and the recited maximum value 10.0 (and including the minimum value 1.0 and the maximum value 10.0), that is, all sub-ranges having a minimum value equal to or greater than 1.0 and a maximum value equal to or less than 10.0, such as, for example, 2.4 to 7.6. Any maximum numerical limitation recited herein is intended to include all lower numerical limitations subsumed therein, and any minimum numerical limitation recited in this specification is intended to include all higher numerical limitations subsumed therein. Accordingly, the applicant reserves the right to amend this specification (including the claims) to expressly recite any sub-ranges subsumed within the ranges expressly recited herein.

[0033] Referring to two compared elements, features, etc. as "the same" can mean that they are "substantially the same". Thus, the phrase "substantially the same" can include cases having a deviation considered low in the art, e.g., a deviation of 5% or less. Additionally, when a particular parameter is said to be uniform in a given region, this can mean that it is uniform in terms of the average value.

[0034] Throughout the specification, unless otherwise stated, each element can be single or multiple.

[0035] When any element is said to be disposed (or located or positioned) "above (or below)" or "on (or under)" a component, this can mean that the any element is placed in contact with the upper (or lower) surface of the component, and can also mean that another component can be between the component and any element disposed (or located or positioned) on (or under) the component.

[0036] In addition, it will be understood that when an element is referred to as being "coupled", "linked" or "connected" to another element, these elements can be "coupled", "linked" or "connected" directly to each other, or intervening elements can be present between these elements, through which the element can be "coupled", "linked" or "connected" to the other element. In addition, when a part is referred to as being "electrically coupled" to another part, the part can be directly connected to the other part or intervening parts can be present between the part and the other part such that the part and the other part are indirectly connected to each other.

[0037] Throughout the specification, unless otherwise stated, when "A and / or B" is stated, it means A, B or A and B. That is, "and / or" includes any or all combinations of the recited items. Unless otherwise specified, when "C to D" is stated, it means C or more and D or less.

[0038] Figure 1 FIG. is a diagram illustrating a system for setting a controller area network (CAN) baud rate of a battery pack according to an embodiment of the present invention, Figure 2 FIG. is a diagram illustrating a circuit of a battery pack according to an embodiment of the present invention, Figure 3 FIG. is a diagram illustrating a CAN bus connecting an external device and a battery pack according to an embodiment of the present invention, Figure 4 FIG. is a schematic diagram illustrating a configuration of a battery management device according to an embodiment of the present invention, Figure 5 FIG. is a diagram illustrating an example of a CAN message frame, and Figure 6 FIG. is a diagram illustrating an example of an interruption generation time interval according to an embodiment of the present invention.

[0039] Reference Figure 1 and Figure 2 , a system for setting a CAN baud rate of a battery pack according to an embodiment of the present invention may include an external device 10 and a battery pack 100.

[0040] The external device 10 has a structure that can be electrically connected through a positive connection terminal P+ and a negative connection terminal P− of the battery pack 100.

[0041] The external device 10 may be a load that receives power from the battery pack 100, or a charging device that supplies power to the battery pack 100 to charge a plurality of battery modules 110.

[0042] When the external device 10 is a load, the battery pack 100 can discharge by operating as a power source that supplies power to the load. The external device 10 operating as a load can be, for example, an electronic device, a transportation vehicle, or an energy storage system (ESS), and the transportation vehicle can be, for example, an electric vehicle, a hybrid vehicle, or a smart mobility.

[0043] In addition, the external device 10 can transmit a predetermined communication signal at a predetermined period while being connected to the battery pack 100. In this case, the external device 10 and the battery pack 100 can transmit and receive signals (data) through CAN communication. That is, an upper controller (not shown) of the external device 10 (e.g., an electric system, an electric vehicle) (e.g., a vehicle control unit (VCU), an electronic control unit (ECU), etc.) and the battery pack 100 can be connected to the CAN bus to transmit and receive data through the CAN bus, as Figure 3 illustrated.

[0044] The upper controller of the external device 10 can transmit a CAN message frame to the battery pack 100 through the CAN bus. In addition, the upper controller of the external device 10 can receive a CAN message frame from the battery pack 100 through the CAN bus.

[0045] The battery pack 100 can be connected to the external device 10 through the connector 140, and the power terminals of the external device 10 can be connected to the first set of terminals P+ (i.e., the positive connection terminal P+ of the battery pack 100) and the second set of terminals P- (i.e., the negative connection terminal P- of the battery pack 100) of the connector 140.

[0046] The battery pack 100 can include a first set of terminals P+ and a second set of terminals P- corresponding to a plurality of battery cells, and the battery pack 100 can be connected to the external device 10 through the first set of terminals P+ and the second set of terminals P-.

[0047] The battery pack 100 can be provided to be installed in the external device 10 (e.g., an electric vehicle), and can include at least one battery module 110, a switch 130, and a battery management device (BMS) 120. In various embodiments, the battery pack 100 can further include other components.

[0048] The battery module 110 can include a plurality of battery cells and a module housing. The battery module 110 can include a plurality of battery cells connected in series or in parallel. The battery module 110 can be connected in series or in parallel. "B+" and "B-" are the terminal voltages of the two terminals of the battery module 110, and "DATA" represents the data exchanged between the BMS 120 and the external device 10.

[0049] The battery cells can be accommodated in the module housing in a stacked form. The battery cells can include positive leads and negative leads. Depending on the shape of the battery, round, angular, or pouch-shaped battery cells can be used.

[0050] In the battery pack 100, instead of the battery module 110, one module can be formed by stacking a single cell. The cell stack can be accommodated in the accommodation space of the battery pack housing, or can be accommodated in the accommodation space separated by a frame, a partition, etc.

[0051] During charging / discharging, a large amount of heat is generated in the battery cell. The generated heat accumulates in the battery cell and accelerates the deterioration of the battery cell. Therefore, the battery pack 100 may further include a cooling member to suppress the deterioration of the battery cell. The cooling member is provided below the accommodation space where the battery cell is provided, but is not limited thereto, and may also be provided on the upper or side surface depending on the battery pack 100.

[0052] The exhaust gas generated inside the battery cell under abnormal operating conditions (also referred to as thermal runaway or thermal event of the battery cell) may be discharged outside the battery cell. The battery pack 100 or the battery module 110 may be provided with an exhaust port or the like for discharging the exhaust gas to suppress damage to the battery pack 100 or the battery module 110.

[0053] The switch 130 may be connected between the battery module 110 and at least one of the first set of terminals P+ and the second set of terminals P- to block / allow the electrical connection between the battery module 110 and the external device 10.

[0054] The switch 130 may be installed on the current path for charging and discharging the battery module 110.

[0055] The switch 130 may control the electrical connection between the battery pack 100 and the external device 10. When the switch 130 is turned on, the battery pack 100 and the external device 10 may be electrically connected to perform charging or discharging. When the switch 130 is turned off, the battery pack 100 and the external device 10 may be electrically separated from each other. That is, when the switch 130 is turned on, power may be supplied from the battery module 110 to the external device 10 or power may be supplied from the external device 10 to the battery module 110. When the switch 130 is turned off, the charging or discharging of the battery module 110 may stop. In this case, the switch 130 may be turned on or off under the control of the battery management device 120.

[0056] This switch 130 may be implemented as a mechanical relay (contactor) that is turned on / off by the magnetic force of a coil, a semiconductor switch such as a metal oxide semiconductor field effect transistor (MOSFET), etc.

[0057] The battery management device 120 can determine whether an abnormality has occurred in the battery pack 100 based on battery status data indicating the status of the battery module 110. When no abnormality occurs in the battery pack 100, the switch 130 is turned on to receive a CAN message frame from the external device 10 via the CAN bus, and the CAN baud rate is set based on whether an error is detected in the received CAN message frame. In this case, when no error is detected in the CAN message frame, the battery management device 120 can determine that the CAN baud rate is the same as the CAN baud rate of the external device 10. When an error is detected in the CAN message frame, the battery management device 120 can determine that the CAN baud rate is different from the CAN baud rate of the external device 10, and can change a preset CAN baud rate to a different CAN baud rate.

[0058] The battery management device 120 may include a memory 122, a detection unit 124, an interface unit 126, and a microcontroller unit (MCU) 128.

[0059] The memory 122 is a component that stores data related to the operation of the battery management device 120. Specifically, the memory 122 may store a program (application or applet) that can set the CAN baud rate based on whether an error is detected in the CAN message frame received from the external device 10, and the stored information can be selected by the processor as needed. That is, the memory 122 stores various types of data generated during the execution of an operating system or program (application or applet) for driving the battery management device 120. In addition, the settable CAN baud rates are stored in the memory 122. Here, the settable CAN baud rates may include all the baud rates of the available external device 10, or may include all the commonly set CAN baud rates. For example, the settable CAN baud rates may include 100 kbps, 125 kbps, 250 kbps, 500 kbps, 1 Mbps, etc. Therefore, a baud rate table in which multiple different CAN baud rates are set can be stored in the memory 122.

[0060] The memory 122 generally refers to a non-volatile storage device that continues to hold the stored information even when power is not supplied, as well as a volatile storage device that requires power to hold the stored information. In addition, the memory 122 can perform the function of temporarily or permanently storing data processed by the processor. Here, in addition to the volatile storage device that requires power to maintain the stored information, the memory 122 may also include a magnetic storage medium or a flash memory medium, but the scope of the present invention is not limited thereto.

[0061] The detection unit 124 can detect the state (voltage, current, temperature, etc.) of the battery module 110 and detect battery state data indicating the state of the battery module 110. The detection unit 124 can detect the voltage of each cell constituting the battery module 110 or detect the voltage of each battery module 110. The detection unit 124 can detect the current flowing through the battery module 110 or each battery module 110 constituting the battery pack 100. The detection unit 124 can also detect the ambient temperature at at least one point of the battery module 110.

[0062] The detection unit 124 can include a voltage sensor, a current sensor, a temperature sensor, etc.

[0063] The detection unit 124 can be configured to periodically output battery state data indicating the voltage, current, ambient temperature, etc. of the battery module 110 detected for each specific period (e.g., unit time) to the MCU 128.

[0064] The interface unit 126 can perform CAN communication with the external device 10 via the CAN bus.

[0065] The interface unit 126 can implement CAN communication between the MCU 128 and an upper controller (not shown) of the external device 10 (e.g., an electrical system or an electric vehicle) (e.g., VCU and ECU).

[0066] When the external device 10 is connected to the connector 140 of the battery pack 100, the interface unit 126 can implement CAN communication between the battery management device 120 and the external device 10. In this case, the external device 10 and the battery pack 100 can be connected to the CAN bus and transmit and receive data via the CAN bus.

[0067] Therefore, the interface unit 126 can transmit or receive CAN message frames via the CAN bus. That is, the interface unit 126 can transmit the CAN message frame received from the CAN bus to the MCU 128, or transmit the CAN message frame indicating the information of the battery pack 100 or battery management information to the CAN bus under the control of the MCU 128.

[0068] The MCU 128 can detect the CAN message frame received from the external device 10 via the interface unit 126. In this case, the MCU 128 can determine whether there is a CAN message frame based on the number of bits of the bit signal received via the interface unit 126. That is, when the received bit signal is a frame according to the CAN communication protocol, the MCU 128 can determine that the frame is a CAN message frame.

[0069] The CAN message frame (or CAN frame) for CAN communication can have the same as Figure 5The same structure as shown in. As Figure 5 As shown in the figure, the CAN message frame may include a start of frame (SOF) indicating the start of the frame, an arbitration identifier (ID) field for inserting an arbitration ID for arbitrating data priority, a remote transmission request (RTR) bit for requesting transmission of data with a specific ID, a control field for transmitting control signals, a data field carrying data with a predetermined data length, a cyclic redundancy check (CRC) field including a CRC sequence and a CRC delimiter for error detection, an acknowledgment (ACK) field including an ACK slot and an ACK delimiter for indicating the accuracy of data reception, and an end of frame (EOF). The control field typically includes an identifier extension (IDE) indicating whether the length of the arbitration ID is standard (11 bits) or extended (29 bits) and a data length code (DLC) indicating the data length.

[0070] Therefore, when the feedback bit signal has Figure 5 the structure shown in the figure, the MCU 128 may determine the corresponding bit signal as a CAN message frame.

[0071] The MCU 128 may set the CAN baud rate based on whether an error is detected in the CAN message frame received from the external device 10 through the interface unit 126. In this case, the MCU 128 may set the CAN baud rate through error detection of the CAN message frame or set the CAN baud rate based on the pulse width of the CAN message frame. The CAN baud rate set by the MCU 128 may be the same baud rate as the CAN baud rate of the external device 10.

[0072] Hereinafter, a detailed description of a method in which the MCU 128 sets the CAN baud rate to be the same as the CAN baud rate of the external device 10 will be given.

[0073] First, a method in which the MCU 128 sets the CAN baud rate through error detection of the CAN message frame will be described.

[0074] When the battery management device 120 wakes up, the MCU 128 may initialize the CAN baud rate to the most recently used CAN baud rate, check whether an error is detected in the CAN message frame received from the external device 10 at the initialized CAN baud rate, set the initialized CAN baud rate as the final CAN baud rate when no error is detected, and change the initialized CAN baud rate to an unused CAN baud rate among the CAN baud rates set in the baud rate table when an error is detected.

[0075] Specifically, when a signal for operating the external device 10 is input or a signal for turning on the battery pack 100 is input, the battery management device 120 may wake up.

[0076] For example, when the electric vehicle is connected and the engine is turned on, the battery management device 120 can be awakened. Additionally, in the case where the battery pack 100 has an external switch, when the external switch is turned on, the battery management device 120 can be awakened.

[0077] When the battery management device 120 is awakened, the MCU 128 can initialize the CAN baud rate to the baud rate stored in the memory 122. Here, the baud rate stored in the memory 122 can refer to the most recently used CAN baud rate.

[0078] When the CAN baud rate is initialized, the MCU 128 can determine whether an abnormality has occurred in the battery pack 100. In this case, the MCU 128 can determine whether an abnormality has occurred in the battery pack 100 based on the battery state data detected by the detection unit 124.

[0079] The MCU 128 can receive battery state data indicating the state of the battery module 110 from the detection unit 124, and determine whether an abnormality has occurred in the battery pack 100 based on the battery state data. That is, the MCU 128 can receive the state data (voltage, current, temperature, etc.) of the battery module 110 from the detection unit 124. Then, the MCU 128 can monitor and calculate the state (voltage, current, temperature, state of charge (SOC), state of health (SOH)) of the battery module 110 based on the state data received from the detection unit 124. Additionally, based on the state monitoring results, the MCU 128 can perform control functions (such as temperature control, balance control, charge / discharge control, etc.), protection functions (such as over-discharge, over-charge, over-current prevention, short circuit, fire extinguishing function, etc.), and so on.

[0080] The MCU 128 controls the battery to operate stably through the judgment of the battery state, and when the judgment result determines that the battery can no longer operate, the MCU 128 controls the battery pack 100 to stop operating, thereby preventing various problems that may occur due to the battery. That is, the MCU 128 can determine the possible abnormalities in the battery pack 100 based on the battery state data.

[0081] The MCU 128 can control the switch 130 to be turned on or off according to the judgment result of the battery pack 100. That is, when it is determined that no abnormality has occurred in the battery pack 100, the MCU 128 can turn on the switch 130. When it is determined that an abnormality has occurred in the battery pack 100, the MCU 128 can turn off the switch 130. For example, when the voltage, current, or temperature is greater than or equal to the threshold value or a sensor failure is judged, the MCU 128 can not turn on the switch 130, thereby preventing the battery pack 100 from being used.

[0082] When the switch 130 is turned on, the MCU 128 can receive CAN message frames from the external device 10 through the interface unit 126. That is, when the switch 130 is turned on, the external device 10 and the battery module 110 are connected, and the external device 10 can transmit CAN message frames to the MCU 128 via the CAN bus.

[0083] For example, when the switch 130 is turned on, when components of the external device 10 that receive power from the slave battery pack 100 and operate (for example, in the case of an electric vehicle, other components sharing the CAN bus, such as the instrument panel and the motor controller) receive power and wake up, the external device 10 can transmit CAN message frames to the MCU 128 via the CAN bus. Additionally, when the external device 10 is a charger, since the charger is receiving AC power, the charger is in a wake-up state, and thus, the charger can transmit CAN message frames to the MCU 128 via the CAN bus.

[0084] Meanwhile, depending on the type of the external device 10, the CAN message frames may not be transmitted to the battery management device 120 during a preset initial baud rate setting time. In this case, the MCU 128 can transmit CAN message frames to the external device 10.

[0085] That is, when no CAN message frames are received from the external device 10 for a preset initial baud rate setting time, the MCU 128 can transmit CAN message frames (for example, CAN message frames for waking up) to the external device 10 and receive response CAN message frames to the transmitted CAN message frames. For example, when the MCU 128 transmits CAN message frames for waking up to the external device 10, the external device 10 can transmit response CAN message frames to the MCU 128.

[0086] When the CAN baud rate of the battery management device 120 and the CAN baud rate of the external device 10 are set to be the same, the MCU 128 receives normal CAN message frames. When the CAN baud rate of the battery management device 120 and the CAN baud rate of the external device 10 are different, an error will be detected in the CAN message frames.

[0087] Therefore, the MCU 128 can check whether an error is detected in the CAN message frames received from the external device 10. That is, the MCU 128 can detect errors by analyzing the CAN message frames.

[0088] For example, the MCU 128 can detect bit errors, stuffing errors, format errors, cyclic redundancy check (CRC) errors, and acknowledgment bit errors. A bit error occurs when the information transmitted from a node is not represented on the CAN bus. A stuffing error occurs when six consecutive bit values appear on the CAN bus, even though these bit values cannot occur in principle. A format error occurs when a bit value designated as 0 or 1 appears differently. A CRC error occurs when it is confirmed through CRC calculation of the CRC area of the received information that some bits have been changed. An acknowledgment bit error occurs when the control unit receives information without errors and the acknowledgment bit with a bit value of 0 has a different value.

[0089] When no error is detected in the CAN message frame, the MCU 128 can set the initialized CAN baud rate to the final CAN baud rate and store the final CAN baud rate in the memory 122. That is, when no error is detected in the CAN message frame, the MCU 128 can determine that the CAN baud rate is the same as the CAN baud rate of the external device 10 and set the initialized CAN baud rate to the final CAN baud rate.

[0090] When an error is detected in the CAN message frame, the MCU 128 can use a counter (not shown) to count the number of detected errors, compare the number of errors with a preset threshold, and change the initialized CAN baud rate to a different CAN baud rate when the number of errors is greater than or equal to the threshold. That is, when the number of errors detected in the CAN message frame is greater than or equal to the threshold, the MCU 128 can determine that the CAN baud rate is different from the CAN baud rate of the external device 10 and automatically change the initialized CAN baud rate to a different CAN baud rate. Here, the threshold is a randomly set number and can be set differently depending on the number of CAN message frames on the CAN bus.

[0091] When the number of detected errors is greater than or equal to the threshold, the MCU 128 can change the initialized CAN baud rate to a different CAN baud rate and use the changed CAN baud rate to determine whether an error has occurred in the CAN message frame received from the external device 10. When no error is detected, the changed CAN baud rate is determined as the final CAN baud rate and the final CAN baud rate is stored in the memory 122. In this case, the MCU 128 can select a CAN baud rate different from the initialized CAN baud rate among the CAN baud rates in the baud rate table stored in the memory 122 and change the initialized CAN baud rate to the selected CAN baud rate.

[0092] For example, 100 kbps, 125 kbps, 250 kbps, 500 kbps, and 1 Mbps are set as the CAN baud rates in the baud rate table, and when the CAN baud rate after initialization is 125 kbps, the MCU 128 can change the CAN baud rate to 250 kbps.

[0093] When the CAN baud rate is changed, the MCU 128 can receive a CAN message frame from the external device 10 at the changed CAN baud rate and check whether an error occurs in the received CAN message frame.

[0094] When there is no error in the CAN message frame received from the external device 10 at the changed CAN baud rate, the MCU 128 can determine the changed CAN baud rate as the final CAN baud rate.

[0095] When an error is detected in the CAN message frame received from the external device 10 at the changed CAN baud rate, the MCU 128 can compare the number of detected errors with a threshold, and when the number of errors is greater than or equal to the threshold, change the changed CAN baud rate to a different CAN baud rate. In this case, the MCU 128 can select an unused CAN baud rate from the baud rate table and change the CAN baud rate to the selected unused CAN baud rate.

[0096] For example, 100 kbps, 125 kbps, 250 kbps, 500 kbps, and 1 Mbps are set as the CAN baud rates in the baud rate table, and when the number of errors occurring due to changing the CAN baud rate after initialization from 125 kbps to 250 kbps is greater than or equal to the threshold, the MCU 128 can change the CAN baud rate to 250 kbps.

[0097] The MCU 128 can obtain an unused CAN baud rate from the baud rate table and continue to change the CAN baud rate to the obtained CAN baud rate until no error is detected in the CAN message frame.

[0098] In this way, the MCU 128 can select one of the CAN baud rates stored in the memory 122 and continue to change the CAN baud rate to the selected CAN baud rate until no error is detected and a normal CAN message frame is received.

[0099] The MCU 128 can store the CAN baud rate with successful communication in the memory 122 (NVM).

[0100] Changing the CAN baud rate when a CAN error is detected can be operated only for a specific time period after the battery management device 120 is awakened to detect an actual CAN communication error.

[0101] When no error occurs, the MCU 128 can transmit a test message to the external device 10 via the CAN bus at the changed CAN baud rate to finally determine the baud rate. In this case, the MCU 128 can check whether an error has occurred, and when no error occurs, finally determine the changed CAN baud rate as the final CAN baud rate, so that smooth communication can be achieved between the battery management device 120 and the external device 10. That is to say, the MCU 128 can change the CAN baud rate of the battery pack 100 to match the CAN baud rate of the external device 10, so that smooth communication can be achieved between the battery management device 120 and the external device 10.

[0102] Next, a method of changing the baud rate using the pulse width of the CAN message frame will be described.

[0103] When the CAN receive pin (CAN RX pin) is set to the external interrupt mode, the MCU 128 can calculate the interrupt occurrence time interval whenever an interrupt occurs, calculate the baud rate based on the interrupt occurrence time interval for a preset specific time period, obtain the baud rate most similar to the calculated baud rate from the baud rate table and initialize the CAN baud rate to this baud rate, and check whether an error is detected in the CAN message frame received from the external device 10 at the initialized CAN baud rate and set the initialized CAN baud rate as the final CAN baud rate when no error is detected.

[0104] Specifically, when connected to the external device 10, the MCU 128 can determine whether an abnormality has occurred in the battery pack 100. In this case, the MCU 128 can determine whether an abnormality has occurred in the battery pack 100 based on the battery state data detected by the detection unit 124.

[0105] The MCU 128 can control the switch 130 to be turned on or off according to the judgment result of the battery pack 100. That is to say, when it is judged that an abnormality has occurred in the battery pack 100, the MCU 128 can turn off the switch 130. When it is judged that no abnormality has occurred in the battery pack 100, the MCU 128 can turn on the switch 130.

[0106] When the switch 130 is turned on, the MCU 128 can receive a CAN message frame from the external device 10 via the interface unit 126. That is to say, when the switch 130 is turned on, the external device 10 and the battery module 110 are connected, and the external device 10 can transmit a CAN message frame to the MCU 128 via the CAN bus.

[0107] In this case, when no CAN message frame is received from the external device 10 for a preset initial baud rate setting time, the MCU 128 can transmit a CAN message frame (e.g., a CAN message frame for wake-up) to the external device 10 and receive a response CAN message frame to the CAN message frame. For example, when the MCU 128 transmits a CAN message frame for wake-up to the external device 10, the external device 10 can transmit a response CAN message frame to the MCU 128.

[0108] When a CAN message frame is received from the external device 10, each time an interruption occurs, the MCU 128 can calculate the time interval at which the interruption occurs. In this case, the interruption can be set to occur at the rising edge and the falling edge.

[0109] Therefore, the MCU 128 can use a timer to calculate the time interval at which an interruption occurs each time the interruption occurs at the rising edge or the falling edge. In this case, the CAN RX pin of the MCU 128 can be set to the external interruption mode. The CAN RX pin of the MCU 128 can be used for a CAN communication mode, an external interruption mode, etc., but these modes cannot be used simultaneously. Therefore, the CAN RX pin of the MCU 128 is set to the external interruption mode, the time can be calculated each time an interruption occurs, and when determining the CAN baud rate, the CAN RX pin can be changed to the CAN communication mode.

[0110] When calculating the interruption occurrence time interval, the MCU 128 can select the minimum time as one bit time among the interruption occurrence time intervals for a preset specific time period and use the selected minimum time to calculate the baud rate. In this case, the MCU 128 can calculate the baud rate by calculating the reciprocal of the selected minimum time. In other words, the MCU 128 can calculate "1 / minimum time" as the baud rate.

[0111] For example, when an interruption as illustrated in (a) of Figure 6 occurs, 1 μs is the minimum time, and thus the MCU 128 can calculate the baud rate as 1 Mbps (1 / 1 μs = 1 Mbps).

[0112] When an interruption as illustrated in (b) of Figure 6 occurs, 2 μs is the minimum time, and thus the MCU 128 can calculate 500 Mbps (1 / 2 μs = 500 Mbps) as the baud rate.

[0113] When calculating the baud rate, the MCU 128 can initialize the CAN baud rate to the baud rate most similar to the calculated baud rate from the baud rate table stored in the memory 122.

[0114] Due to measurement errors of the timer, etc., the calculated baud rate may not be the exact baud rate, and commonly used CAN baud rates (such as 100 kbps, 125 kbps, 250 kbps, 500 kbps, and 1 Mbps) are pre-stored in the memory 122. Therefore, the MCU 128 can select the CAN baud rate that is most similar to the calculated baud rate among the CAN baud rates set in the baud rate table stored in the memory 122 as the CAN baud rate.

[0115] Meanwhile, when the CAN baud rate of the battery management device 120 and the CAN baud rate of the external device 10 are set to be the same, the MCU 128 receives normal CAN message frames. When the CAN baud rate of the battery management device 120 and the CAN baud rate of the external device 10 are different, an error will be detected in the CAN message frame.

[0116] Therefore, when the CAN baud rate is initialized, the MCU 128 can receive CAN message frames from the external device 10 at the initialized CAN baud rate, check whether an error occurs in the received CAN message frame, and determine the initialized CAN baud rate as the final CAN baud rate when no error occurs.

[0117] Specifically, the MCU 128 can check whether an error occurs in the CAN message frame received from the external device 10. That is, the MCU 128 can detect errors by analyzing the CAN message frame.

[0118] For example, the MCU 128 can detect bit errors, stuffing errors, form errors, cyclic redundancy check (CRC) errors, and acknowledgment bit errors.

[0119] When no error is detected in the CAN message frame received from the external device 10, the MCU 128 can finally determine the initialized CAN baud rate as the final CAN baud rate.

[0120] When an error is detected in the CAN message frame received from the external device 10, every time an interruption occurs, the MCU 128 can recalculate the interruption occurrence time interval, select again the minimum time among the interruption occurrence time intervals for a preset specific time period as 1 bit time, recalculate the baud rate using the selected minimum time, and reselect the CAN baud rate that is most similar to the calculated baud rate from the baud rate table stored in the memory 122 and initialize the CAN baud rate to the reselected baud rate.

[0121] In this way, the MCU 128 can continue to change the CAN baud rate until no error is detected and normal CAN message frames are received.

[0122] The MCU 128 can store the CAN baud rate that has been successfully communicated with it in the memory 122 (NVM).

[0123] Here, the MCU 128 can be implemented as a processor, a central processing unit (CPU), or a system-on-chip (SoC), and can operate on an operating system or an application program to control multiple hardware or software components connected to the MCU 128, thereby performing various data processing and operations. The MCU 128 can be configured to execute at least one command stored in the memory 122 and store the execution result data in the memory 122.

[0124] Figure 7 It is a diagram showing a method of setting a CAN baud rate according to an embodiment of the present invention.

[0125] Reference Figure 7 , when the external device 10 is connected (S702) and the battery management device 120 wakes up (S704), the MCU 128 initializes the CAN baud rate to the baud rate stored in the memory 122 (S706). When a signal for operating the external device 10 is input or a signal for turning on the battery pack 100 is input, the battery management device 120 can wake up. Here, the baud rate stored in the memory 122 can mean the most recently used CAN baud rate.

[0126] When performing operation S706, the MCU 128 determines whether an abnormality has occurred in the battery pack 100 (S708). In this case, the MCU 128 can determine whether an abnormality has occurred in the battery pack 100 based on the battery state data detected by the detection unit 124.

[0127] As a result of the determination in operation S708, when no abnormality occurs in the battery pack 100 (S710), the MCU 128 turns on the switch 130 (S712) and determines whether a CAN message frame from the external device 10 has been received within a preset specific time period (S714).

[0128] As a result of the determination in operation S714, when a CAN message frame is received from the external device 10 within the specific time period, the MCU 128 checks whether an error has been detected in the CAN message frame received from the external device 10 (S716).

[0129] As a result of the check in operation S716, when an error is detected in the CAN message frame, the MCU 128 uses a counter to count the number of detected errors to determine whether the number of errors is greater than or equal to a threshold value (S718).

[0130] As a result of the determination in operation S718, when the number of errors is greater than or equal to the threshold, the MCU 128 changes the initialized CAN baud rate to a different CAN baud rate (S720) and performs operation S716.

[0131] As a result of the determination in operation S718, when the number of errors is not greater than or equal to the threshold, the MCU 128 performs operation S716.

[0132] As a result of the check in operation S716, when no error is detected in the CAN message frame, the MCU 128 stores the initialized CAN baud rate as the final CAN baud rate (S722).

[0133] As a result of the determination in operation S714, when no CAN message frame is received from the external device 10 within a specific time period, the MCU 128 transmits the CAN message frame to the external device 10 (S724).

[0134] As a result of the determination in operation S708, when an abnormality occurs in the battery pack 100, the MCU 128 disconnects the switch 130 (S726).

[0135] Figure 8 FIG. is a diagram illustrating a method of setting a CAN baud rate according to another embodiment of the present invention.

[0136] Reference Figure 8 , when the external device 10 is connected (S802) and the battery management device 120 wakes up (S804), the MCU 128 determines whether an abnormality has occurred in the battery pack 100 (S806). In this case, the MCU 128 can determine whether an abnormality has occurred in the battery pack 100 based on the battery state data detected by the detection unit 124.

[0137] As a result of the determination in operation S806, when no abnormality occurs in the battery pack 100 (S808), the MCU 128 turns on the switch 130 (S810) and receives the CAN message frame (S812).

[0138] When performing operation S812, the MCU 128 calculates the time interval between each interruption. In this case, the interruption can be set to occur at both the rising edge and the falling edge. Therefore, the MCU 128 can use a timer to calculate the time interval of the interruption when the interruption occurs at the rising edge or the falling edge. In this case, the CANRX pin of the MCU 128 can be set to the external interruption mode.

[0139] When performing operation S814, the MCU 128 calculates the CAN baud rate based on the interruption occurrence time interval for a preset specific time period (S816). In this case, the MCU 128 can select the minimum time among the interruption occurrence time intervals as one bit time, and use the selected minimum time to calculate the baud rate. The MCU 128 can calculate the baud rate by calculating the reciprocal of the selected minimum time. In other words, the MCU 128 can calculate "1 / minimum time" as the baud rate.

[0140] When performing operation S816, the MCU 128 can initialize the CAN baud rate to the baud rate in the baud rate table stored in the memory 122 that is most similar to the calculated baud rate (S818).

[0141] When performing operation S818, the MCU 128 receives a CAN message frame from the external device 10 at the initialized CAN baud rate and checks whether an error is detected in the received CAN message frame (S820).

[0142] As a result of the check in operation S820, when an error is detected in the CAN message frame, the MCU 128 performs operation S814.

[0143] As a result of the check in operation S820, when no error is detected in the CAN message frame, the MCU 128 stores the initialized CAN baud rate as the final CAN baud rate (S822).

[0144] As a result of the determination in operation S808, when an abnormality occurs in the battery pack 100, the MCU 128 turns off the switch 130 (S824).

[0145] As described above, according to the present invention, when one type of battery pack is used for multiple models of external devices (e.g., LEV, x electric vehicle (xEV), or ESS), the battery management device automatically detects the baud rate of the external device and automatically sets the baud rate to be suitable for the external device. Therefore, there is no need to provide a separate device for setting the baud rate and operator errors can be prevented.

[0146] The term "unit" used in this specification may include a unit configured by hardware, software, or firmware, and may be used compatibly with terms such as, for example, logic, logic block, component, or circuit. A "unit" may be an overall configured component or may be the smallest unit or part of a component that performs one or more functions. For example, according to one embodiment, a "unit" may be implemented in the form of an application specific integrated circuit (ASIC).

[0147] The embodiments described in this specification can be implemented, for example, in a method or process, a device, a software program, a data stream, or a signal. Although discussed only in the context of a single form of the embodiment (e.g., only as a method), the embodiments of the features discussed can also be implemented in other forms (e.g., a device or a program). The device can be implemented with suitable hardware, software, firmware, etc. The method can be implemented in a device such as a processor, which generally refers to a computer, a microprocessor, an integrated circuit, or a processing device including a programmable logic device, etc. The processor also includes communication devices such as a computer, a mobile phone, a portable / personal digital assistant (“PDA”), and other devices that facilitate the communication of information between end users.

[0148] According to the present invention, when a type of battery pack is used for multiple models of external devices (e.g., LEV, x electric vehicle (xEV), or ESS), since the battery management device automatically detects the baud rate of the external device and automatically sets the baud rate to be suitable for the external device, there is no need to provide a separate device for setting the baud rate and operator errors can be prevented.

[0149] However, the effects that can be obtained by the present invention are not limited to the effects described above, and those skilled in the art can clearly understand other technical effects not described from the description of the present invention described above.

[0150] Although the present invention has been described with reference to the embodiments shown in the drawings, it is only an example. Those skilled in the art will understand that various modifications and other equivalent exemplary embodiments are possible according to the present invention. Therefore, the true technical scope of the present invention should be determined by the spirit of the claims.

Claims

1. A battery management device, comprising: An interface unit configured to perform CAN communication with an external device via a controller area network (CAN) bus; as well as The microcontroller unit MCU is configured to set a CAN baud rate based on whether an error is detected in a CAN message frame received from the external device through the interface unit.

2. The battery management device according to claim 1, wherein: When the battery management device wakes up, the MCU initializes the CAN baud rate to the most recently used CAN baud rate, and checks whether the error is detected in the CAN message frame received from the external device at the initialized CAN baud rate, and sets the initialized CAN baud rate to the final CAN baud rate when no error is detected.

3. The battery management device according to claim 2, wherein: When the error is detected in the CAN information frame, the MCU counts the number of the detected errors, and when the counted number of the errors is greater than or equal to a preset threshold, the MCU changes the initialized CAN baud rate to a different CAN baud rate, and checks whether the error is detected in the CAN message frame received from the external device at the changed CAN baud rate and sets the changed CAN baud rate to the final CAN baud rate when no error is detected.

4. The battery management device according to claim 3, wherein: The MCU acquires a CAN baud rate different from the initialized CAN baud rate from a baud rate table in which a plurality of different CAN baud rates are set, and changes the initialized CAN baud rate to the acquired different CAN baud rate.

5. The battery management device according to claim 4, wherein: When the error is detected in the CAN message frame received from the external device at the changed CAN baud rate, the MCU counts the number of the detected errors, and when the counted number of the errors is greater than or equal to the threshold, the MCU acquires an unused CAN baud rate in the baud rate table and continues to change the baud rate to the acquired CAN baud rate until no error is detected.

6. The battery management device according to claim 1, wherein: When the CAN receive pin is set to the external interrupt mode, the MCU calculates the interruption occurrence time interval each time an interruption occurs, calculates the baud rate based on the interruption occurrence time interval for a preset specific time period, obtains the baud rate most similar to the calculated baud rate from the baud rate table and initializes the CAN baud rate to the baud rate, and checks whether the error is detected in the CAN message frame received from the external device at the initialized CAN baud rate and sets the initialized CAN baud rate to the final CAN baud rate when no error is detected.

7. The battery management device according to claim 6, wherein: The MCU uses a timer to calculate the interruption occurrence time interval whenever the interruption occurs at a rising edge and a falling edge.

8. The battery management device according to claim 6, wherein: The MCU selects a minimum time among the interruption occurrence time intervals for the preset specific time period as 1-bit time, and calculates the baud rate using a reciprocal of the selected minimum time.

9. The battery management device according to claim 6, wherein: When the error is detected in the CAN message frame, the MCU selects the minimum time among the interruption occurrence time intervals for the preset specific time period as the 1-bit time, and uses the selected minimum time to calculate the baud rate, and obtains the baud rate most similar to the calculated baud rate from the baud rate table to change the CAN baud rate.

10. The battery management device according to claim 1, further comprising: a detection unit configured to detect battery status data including at least one of a voltage, a current and a temperature of a battery module, and transmit the detected battery status data to the MCU, The MCU determines whether an abnormality occurs in the battery pack based on the battery status data, and turns on a switch when no abnormality occurs in the battery pack to receive the CAN message frame from the external device through the CAN bus.

11. The battery management device according to any one of claims 1 to 10, wherein: When no error is detected in the CAN message frame, the MCU determines that the CAN baud rate is the same as the baud rate of the external device, and When the error is detected in the CAN message frame, the MCU determines that the CAN baud rate is different from the baud rate of the external device and changes the preset CAN baud rate to a different CAN baud rate.

12. A method for setting a controller area network (CAN) baud rate, comprising: When the battery management device wakes up, the CAN baud rate is initialized to the most recently used CAN baud rate through the microcontroller unit MCU; Determining whether an abnormality occurs in the battery pack based on the battery status data by the MCU; When no abnormality occurs in the battery pack, turning on a switch through the MCU to receive a CAN message frame from an external device through a CAN bus; and The MCU checks whether an error is detected in the CAN message frame, and sets the initialized CAN baud rate as a final CAN baud rate when no error is detected.

13. The method according to claim 12, wherein: In the process of setting the initialized CAN baud rate to the final CAN baud rate, when the error is detected in the CAN information frame, the MCU counts the number of the detected errors, and when the counted number of the errors is greater than or equal to a preset threshold, the MCU changes the initialized CAN baud rate to a different CAN baud rate, and checks whether the error is detected in the CAN message frame received from the external device at the changed CAN baud rate and sets the changed CAN baud rate to the final CAN baud rate when no error is detected.

14. The method according to claim 13, wherein: In the process of setting the initialized CAN baud rate as the final CAN baud rate, the MCU obtains a CAN baud rate different from the initialized CAN baud rate from a baud rate table in which a plurality of different CAN baud rates are set, and changes the initialized CAN baud rate to the obtained different CAN baud rate.

15. The method according to claim 14, wherein: In the process of setting the initialized CAN baud rate to the final CAN baud rate, when the error is detected in the CAN message frame received from the external device at the changed CAN baud rate, the MCU counts the number of the detected errors, and when the counted number of errors is greater than or equal to the threshold, the MCU obtains an unused CAN baud rate in the baud rate table and continues to change the baud rate to the obtained CAN baud rate until no error is detected.

16. A method for setting a controller area network (CAN) baud rate, comprising: By means of the microcontroller unit MCU, judging whether an abnormality occurs in the battery pack based on the battery status data; When no abnormality occurs in the battery pack, turning on a switch through the MCU to receive a CAN message frame from an external device through a CAN bus; By means of the MCU, according to the reception of the CAN message frame, calculating the interruption occurrence time interval whenever an interruption occurs; Calculating a baud rate based on the interruption occurrence time interval for a preset specific time period by the MCU; By means of the MCU, a baud rate most similar to the calculated baud rate is obtained from a baud rate table, and the CAN baud rate is initialized to the obtained baud rate; and By means of the MCU, it is checked whether the error is detected in the CAN message frame received from the external device at the initialized CAN baud rate, and when no error is detected, the initialized CAN baud rate is set as a final CAN baud rate.

17. The method according to claim 16, wherein: In the calculation of the interruption occurrence time interval, the MCU sets the CAN receiving pin to an external interruption mode and calculates the interruption occurrence time interval.

18. The method according to claim 17, wherein: In the calculation of the interruption occurrence time interval, whenever the interruption occurs at a rising edge and a falling edge, the MCU uses a timer to calculate the interruption occurrence time interval.

19. The method according to claim 16, wherein: In the calculation of the baud rate based on the interruption occurrence time interval, the MCU selects a minimum time among the interruption occurrence time intervals for the preset specific time period as 1-bit time, and calculates the baud rate using the selected minimum time.

20. The method according to claim 16, wherein: In the process of setting the initialized CAN baud rate to the final CAN baud rate, when the error is detected in the CAN message frame, the MCU selects the minimum time among the interruption occurrence time intervals for the preset specific time period as the 1-bit time, calculates the baud rate using the selected minimum time, and obtains the baud rate most similar to the calculated baud rate from the baud rate table to change the CAN baud rate.

Citation Information

Patent Citations

  • Calibration method of tiltrotator for construction machine

    KR1020230159970A