WO2023223940A1 - In-vehicle device, program, and information processing method - Google Patents

In-vehicle device, program, and information processing method Download PDF

Info

Publication number
WO2023223940A1
WO2023223940A1 PCT/JP2023/017775 JP2023017775W WO2023223940A1 WO 2023223940 A1 WO2023223940 A1 WO 2023223940A1 JP 2023017775 W JP2023017775 W JP 2023017775W WO 2023223940 A1 WO2023223940 A1 WO 2023223940A1
Authority
WO
WIPO (PCT)
Prior art keywords
vehicle
communication
interrupt
control unit
vehicle ecu
Prior art date
Application number
PCT/JP2023/017775
Other languages
French (fr)
Japanese (ja)
Inventor
将史 大場
和弘 平野
Original Assignee
住友電装株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 住友電装株式会社 filed Critical 住友電装株式会社
Publication of WO2023223940A1 publication Critical patent/WO2023223940A1/en

Links

Images

Classifications

    • BPERFORMING OPERATIONS; TRANSPORTING
    • B60VEHICLES IN GENERAL
    • B60RVEHICLES, VEHICLE FITTINGS, OR VEHICLE PARTS, NOT OTHERWISE PROVIDED FOR
    • B60R16/00Electric or fluid circuits specially adapted for vehicles and not otherwise provided for; Arrangement of elements of electric or fluid circuits specially adapted for vehicles and not otherwise provided for
    • B60R16/02Electric or fluid circuits specially adapted for vehicles and not otherwise provided for; Arrangement of elements of electric or fluid circuits specially adapted for vehicles and not otherwise provided for electric constitutive elements
    • B60R16/023Electric or fluid circuits specially adapted for vehicles and not otherwise provided for; Arrangement of elements of electric or fluid circuits specially adapted for vehicles and not otherwise provided for electric constitutive elements for transmission of signals between vehicle parts or subsystems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance

Definitions

  • the present disclosure relates to an in-vehicle device, a program, and an information processing method.
  • This application claims priority based on Japanese Application No. 2022-082589 filed on May 19, 2022, and incorporates all the contents described in the said Japanese application.
  • the wiper drive device of Patent Document 1 includes a vehicle-mounted ECU (body ECU) and is driven by a control program applied to the vehicle-mounted ECU.
  • An in-vehicle device is an in-vehicle device that is installed in a vehicle and is communicably connected to an in-vehicle ECU using a CAN communication protocol, and includes a control unit that performs control regarding communication with the in-vehicle ECU.
  • the control unit detects an interrupt process that occurs after data is transmitted to the in-vehicle ECU, and determines whether communication with the in-vehicle ECU is being performed normally based on the detection result.
  • FIG. 1 is a schematic diagram illustrating the configuration of an in-vehicle system including an in-vehicle device and the like according to a first embodiment
  • FIG. 2 is a block diagram illustrating the internal configuration of an on-vehicle device.
  • FIG. 3 is an explanatory diagram regarding detection of interrupt processing by the control unit of the in-vehicle device. 3 is a flowchart illustrating processing of a control unit of an in-vehicle device.
  • Patent Document 1 has a problem in that it does not take into account the determination of whether processing related to communication with other devices is being performed normally.
  • An object of the present disclosure is to provide an in-vehicle device or the like that can determine whether processing related to communication with other devices is being performed normally.
  • An in-vehicle device is an in-vehicle device that is installed in a vehicle and is communicably connected to an in-vehicle ECU using a CAN communication protocol, and controls control regarding communication with the in-vehicle ECU.
  • the control unit detects an interrupt process that occurs after data is transmitted to the in-vehicle ECU, and determines whether communication with the in-vehicle ECU is being performed normally based on the detection result. judge.
  • each of the in-vehicle device and the in-vehicle ECUs function as a CAN node.
  • a process of transmitting data (CAN frame) from the vehicle-mounted device to the CAN bus via a communication unit such as a CAN transceiver is performed, the control unit of the vehicle-mounted device attempts to detect an interrupt process that occurs after the transmission.
  • the interrupt process is defined in the specifications of the CAN communication process so that it occurs after the data is transmitted when the data is transmitted by the CAN.
  • the control unit of the in-vehicle device determines whether communication between the in-vehicle device and the in-vehicle ECU is being performed normally based on the detection result of the interrupt process, that is, whether or not an interrupt process is detected. It is possible to efficiently determine whether processing related to communication with other devices is being performed normally. In this way, the control unit of the in-vehicle device performs communication processing related to data transmission and reception with the in-vehicle ECU using CAN, and monitors the presence or absence of interrupt processing in parallel with the communication processing, thereby increasing the reliability of CAN communication. It is possible to guarantee gender.
  • the interrupt processing includes a transmission completion interrupt and an error interrupt, and when the control unit detects the transmission completion interrupt, the control unit communicates with the in-vehicle ECU. is determined to be normal, and if neither the transmission completion interrupt nor the error interrupt is detected, the communication with the in-vehicle ECU is determined to be abnormal, and the initialization processing of the control unit is performed. conduct.
  • interrupt processing that may occur in response to the transmission of data (CAN frame) from the in-vehicle device that is the source node includes a transmission completion interrupt and an error interrupt.
  • a transmission completion interrupt is an interrupt process that occurs when data (CAN frame) is successfully transmitted.
  • An error interrupt is an interrupt process that occurs when transmitted data is received by, for example, loopback processing, and a difference occurs between the received data and the transmitted data. Such data differences occur, for example, due to a failure in a communication unit such as a CAN transceiver, or a failure such as a short circuit (ground fault) in a communication line such as a CAN bus.
  • an error interrupt occurs when a bit error (bit inversion) in data (CAN frame) or physical bus error occurs due to an event that occurs in the physical layer that is lower than the communication unit such as a CAN transceiver. becomes.
  • the error interrupt may include, for example, an ACK error or an error such as arbitration lost.
  • the control unit operates to generate an interrupt process such as a transmission completion interrupt or an error interrupt each time data is transmitted by executing a CAN communication control program.
  • the control unit also periodically, regularly, or constantly monitors the occurrence of the interrupt process, and if it detects a transmission completion interrupt, it indicates that the communication with the in-vehicle ECU is normal (communication has completed normally). ).
  • the control unit does not detect either a transmission completion interrupt or an error interrupt, an abnormality occurs in the execution state of the CAN communication control program (data cannot be sent due to a stuck state), and communication with the in-vehicle ECU is disabled. It is determined that there is an abnormality (the in-vehicle device is abnormal). In other words, if the process that executes the CAN communication control program is in a hung state, for example, and data transmission is not possible due to state fixation in software processing, both the transmission completion interrupt and error interrupt processing will not be detected. What is not done becomes.
  • the control unit determines that a communication abnormality has occurred due to an abnormality in the process that executes the communication control program, and performs recovery processing for the communication abnormality in order to initialize its own unit (control unit).
  • the initialization process of the control unit includes, for example, restarting the CAN communication control program, resetting (restarting) the control unit itself, or resetting (restarting) the in-vehicle device itself, that is, software reset ( Initialization), hardware reset (initialization), or both software and hardware reset (initialization) may be performed.
  • software reset Initialization
  • hardware reset initialization
  • recovery processing is performed. This allows the actuator to be efficiently restarted.
  • data is transmitted to the in-vehicle ECU at a predetermined transmission cycle, and the control unit transmits data to the in-vehicle ECU at a predetermined period based on the transmission cycle. If neither the transmission completion interrupt nor the error interrupt is detected, it is determined that the communication with the in-vehicle ECU is abnormal.
  • an in-vehicle device that is a transmission source node transmits data (CAN frame) at a predetermined transmission cycle to a plurality of in-vehicle ECUs that are destination nodes. Matters regarding the transmission cycle are stored in the storage unit of the in-vehicle device, and the CAN-ID (message ID), transmission order, and transmission time interval (transmission cycle) of the data to be transmitted (CAN frame) are defined. It is (included).
  • the information regarding the transmission cycle may be stored in the storage unit of the vehicle-mounted device in a table format (transmission cycle table), such as the transmission cycle for each CAN-ID.
  • the control unit of the in-vehicle device refers to the transmission cycle information stored in the storage unit, and detects either a transmission completion interrupt or an error interrupt in a predetermined period according to the defined transmission cycle. Determine whether or not.
  • the predetermined period corresponds to a detection unit period when detecting an interrupt process, and is calculated as a value (T x n) obtained by multiplying the transmission cycle (T) by a predetermined number (n), for example. It may be something.
  • the predetermined number (n) is set to 3 if any interrupt processing cannot be detected over three cycles (number of cycles: 3), it can be determined that there is an abnormality.
  • the detection unit period (predetermined) when detecting interrupt processing corresponds to multiple transmission cycles. By setting the period), it is possible to prevent erroneous judgments due to such omissions. Further, the detection unit period (predetermined period) when detecting an interrupt process may be set by taking into account a tolerance with respect to the transmission period (T).
  • the tolerance for the transmission cycle (T) is a difference that occurs within the allowable range according to the product specifications of the in-vehicle device. For example, it is set as ⁇ 10% with respect to the design value of the transmission cycle (T). It may be.
  • the detection unit period may be set as transmission cycle (T) x predetermined number (number of cycles: n) x (1.01).
  • the control unit of the in-vehicle device continues transmitting until a detection unit period (predetermined period) set based on the transmission cycle elapses, starting from the point in time when the transmission completion interrupt or error interrupt detected immediately before is detected (starting point). If neither a completion interrupt nor an error interrupt is detected, it may be determined that the communication with the on-vehicle ECU is abnormal.
  • a predetermined period corresponding to the transmission cycle of data (CAN frame) from the in-vehicle device (source node) to the in-vehicle ECU (destination node) is set as the period for making the determination (detection unit period). Accordingly, the determination accuracy can be improved.
  • the predetermined period is determined based on the number of types and the transmission cycle. It will be done.
  • the type may be determined by, for example, CAN-ID (message ID). That is, the data (CAN frame) transmitted from the in-vehicle device to the in-vehicle ECU includes a plurality of types of data (CAN frames) with different CAN-IDs, for example, two types of CAN-IDs such as 101 and 102.
  • the detection unit period (predetermined period) when detecting interrupt processing is the number of types of data (CAN frame) (number of types of CAN-ID) and the data for each type (for each CAN-ID).
  • the detection unit period (predetermined period) may be derived (T ⁇ n/k) by dividing the multiplied value by the number of data types (k).
  • the value may be a value (T ⁇ n ⁇ (1+D/100)/k) in which a tolerance (D%: for example, ⁇ 10%, etc.) during transmission is added to the value.
  • the in-vehicle device communicates with the in-vehicle ECU via a CAN bus, and includes a communication unit to which the CAN bus is connected, and the control unit is configured to respond to the error interrupt. If detected, it is determined that the communication with the vehicle-mounted ECU is abnormal, and initialization processing of the communication unit is performed.
  • control unit of the in-vehicle device when the control unit of the in-vehicle device detects an error interrupt, it determines that communication with the in-vehicle ECU is abnormal (communication has ended abnormally) due to a failure of a communication unit such as a CAN transceiver, Performs initialization processing of the communication unit (CAN transceiver).
  • the initialization process of the communication unit may include, for example, performing a hardware reset (initialization) by cutting off and restarting power to the communication unit. Thereby, the communication unit can be brought into a normal state, and communication with the vehicle-mounted ECU can be restored to a normal state.
  • control unit of the in-vehicle device If the control unit of the in-vehicle device continues to detect error interrupts even though the initialization process of the communication unit has been performed a predetermined number of times or more, the control unit of the in-vehicle device detects a short circuit (ground) in the communication line such as the CAN bus. It may be determined that a failure (physical bus error) such as a physical bus error has occurred, and the determination result may be stored in a storage unit and output to an HMI (Human Machine Interface) device such as a display.
  • HMI Human Machine Interface
  • An information processing method includes a computer that is installed in a vehicle, is communicably connected to an in-vehicle ECU using a CAN communication protocol, and controls communication with the in-vehicle ECU.
  • An interrupt process that occurs after data is transmitted to an on-vehicle ECU is detected, and based on the detection result, a process is executed to determine whether communication with the on-vehicle ECU is being performed normally.
  • a program according to an aspect of the present disclosure is installed in a vehicle, is communicably connected to an in-vehicle ECU using a CAN communication protocol, and is transmitted to a computer that controls communication with the in-vehicle ECU.
  • An interrupt process that occurs after data is transmitted to the ECU is detected, and based on the detection result, a process is executed to determine whether communication with the in-vehicle ECU is being performed normally.
  • FIG. 1 is a schematic diagram illustrating the configuration of an in-vehicle system S including an in-vehicle device 1 and the like according to the first embodiment.
  • FIG. 2 is a block diagram illustrating the internal configuration of the in-vehicle device 1.
  • the in-vehicle system S is composed of an in-vehicle device 1 mounted on a vehicle C and a plurality of in-vehicle ECUs 2, and these in-vehicle devices 1 and each of the plurality of in-vehicle ECUs 2 (Electronic Control Units) are connected to a communication line 4 (CAN bus). communicably connected.
  • CAN bus CAN bus
  • the in-vehicle device 1 and the in-vehicle ECU 2 are configured to transmit and receive data (CAN frames) using a CAN (Controller Area Network) communication protocol, and the in-vehicle device 1 and the in-vehicle ECU 2 function as CAN nodes.
  • CAN Controller Area Network
  • An on-vehicle load 3 such as a lamp, a door mirror, or a wiper is communicably connected to each of the on-vehicle ECUs 2.
  • These in-vehicle ECUs 2 receive data (CAN frames) transmitted from the in-vehicle device 1, and depending on the received data, control the in-vehicle loads 3 (actuators) directly connected to their own ECU (in-vehicle ECU 2 itself). Performs drive control.
  • the in-vehicle device 1 is configured to detect a transmission completion interrupt or an error interrupt each time after transmitting data to the in-vehicle ECU 2. Although the details will be described later, if the in-vehicle device 1 does not detect any interrupt processing, such as a transmission completion interrupt or an error interrupt, after transmitting data to the in-vehicle ECU 2 until a predetermined period has elapsed, the state will be fixed in the software processing. It is determined that a communication abnormality has occurred due to, etc., and the software and hardware related to CAN communication are initialized.
  • the in-vehicle device 1 includes a control section 11, a storage section 12, and a communication section 13.
  • the in-vehicle device 1 may function, for example, as a body ECU that performs overall control of body-related actuators.
  • the in-vehicle device 1 may be configured with a central control device such as a vehicle computer, and may function as an integrated ECU that performs integrated control of the entire vehicle C.
  • the control unit 11 is composed of a CPU (Central Processing Unit), an MPU (Micro Processing Unit), etc., and performs various controls by reading and executing programs (program products) and data stored in advance in the storage unit 12. Performs processing, arithmetic processing, etc.
  • the control unit 11 may be configured by being packaged with a microcomputer or the like together with the storage unit 12 and the like.
  • the control unit 11 is not limited to a software processing unit such as a CPU that performs software processing, but may also be a hardware processing unit such as an FPGA (Field Programmable Gate Array), an ASIC (Application Specific Integrated Circuit), or an SOC (System on Chip). It may include a hardware processing unit that performs various control processing, calculation processing, and the like.
  • the storage unit 12 is composed of a volatile memory element such as a RAM (Random Access Memory), or a nonvolatile memory element such as a ROM (Read Only Memory), an EEPROM (Electrically Erasable Programmable ROM), or a flash memory.
  • a program P (program product) or data of the in-vehicle device 1 is stored.
  • the program P (program product) stored in the storage unit 12 may be a program P (program product) read from a recording medium M readable by the in-vehicle device 1.
  • the program P (program product) may be downloaded from an external computer (not shown) connected to a communication network (not shown) and stored in the storage unit 12.
  • the storage unit 12 stores items related to the transmission cycle including various parameters used when performing CAN communication, such as the CAN-ID (message ID) to be transmitted, the order of transmission, and the time interval for transmission (transmission cycle). ing.
  • the matters related to the transmission cycle may be stored in the storage unit 12 in a table format (transmission cycle table) including the transmission cycle and the like as management items.
  • the communication unit 13 is composed of a CAN transceiver, which is an input/output interface using a communication protocol such as CAN.
  • a communication line 4 (CAN bus) having a bus configuration is connected to the communication unit 13 (CAN transceiver), and CAN communication is performed between the in-vehicle device 1 and the in-vehicle ECU 2 via the communication line 4.
  • each of the in-vehicle ECUs 2 includes a control section, a storage section, and a communication section (CAN transceiver).
  • a vehicle load 3 (actuator) such as a wiper is directly connected to each of these vehicle ECUs 2 via a serial cable or the like.
  • the on-vehicle ECU 2 drives an on-vehicle load 3 (actuator) directly connected to its own ECU (on-vehicle ECU 2 itself) based on data received from the on-vehicle device 1 through CAN communication.
  • FIG. 3 is an explanatory diagram regarding detection of interrupt processing by the control unit 11 of the in-vehicle device 1.
  • This explanatory diagram shows the states of the communication line 4 and the vehicle-mounted device 1 during the elapsed time indicated by the horizontal axis.
  • transmission completion interrupts, error interrupts, and time monitoring monitoring processing that involves time measurement
  • time monitoring monitoring processing that involves time measurement
  • Interrupt processing that occurs after transmitting data includes transmission completion interrupts and error interrupts, and is defined in the specifications of communication processing by CAN to occur after transmitting data when transmitting data by CAN. ing.
  • the control unit 11 the process that executes the CAN communication control program of the in-vehicle device 1 receives the transmitted data through loopback processing, etc., and if a difference occurs between the received data and the transmitted data ( If a bit error occurs), an error interrupt is generated, and if no difference occurs, a transmission completion interrupt is generated.
  • An error interrupt may be generated not only when a bit error occurs, but also when an ACK error, arbitration lost, or the like occurs. In this way, if no bit error, ACK error, arbitration lost, etc. occur, the CAN communication is determined to be normal, and if a difference occurs, the CAN communication is determined to be abnormal (a communication error has occurred). be done.
  • the vehicle-mounted device 1 detects a transmission completion interrupt (indicated by a solid line) each time after transmitting data to the vehicle-mounted ECU 2.
  • the in-vehicle device 1 performs a process of re-measuring the time (predetermined period) for determining an abnormality (re-measuring the time due to the occurrence of the transmission completion interrupt) using the detected transmission completion interrupt as a starting point. That is, upon detection of a transmission completion interrupt, the elapsed time for time monitoring is set to 0 (0 cleared: timer reset).
  • the in-vehicle device 1 detects an error interrupt when the communication line 4 becomes temporarily abnormal, such as when noise or the like occurs on the communication line 4. In this case, the transmission completion interrupt that would normally be detected is not detected (does not occur). In this explanatory diagram, the transmission completion interrupt that was not detected (did not occur) is indicated by a broken line.
  • the in-vehicle device 1 performs a process of re-measuring the time (predetermined period) for determining an abnormality (re-measuring the time due to the occurrence of an error) using the time of detection of the detected error interrupt as a starting point. That is, upon detection of an error interrupt, the elapsed time for time monitoring is set to 0 (0 cleared: timer reset).
  • the in-vehicle device 1 sets a predetermined period according to the transmission cycle to the in-vehicle ECU 2 as a period for making a determination (detection unit period), and generates a transmission completion interrupt and an error interrupt in the predetermined period (detection unit period). If not detected, it is determined that transmission failure (abnormality) due to state fixation or the like has occurred.
  • the period (detection unit period) for performing the determination corresponds to the expiration time from the start of measuring the passage of time in a timer used when performing the determination process.
  • the expiration time of the timer defines the time from the occurrence of a failure to the execution of recovery processing.
  • the predetermined period (detection unit period) may be set by taking into account the tolerance ( ⁇ D%) for the transmission cycle (T) of data (CAN frame). Furthermore, the predetermined period (detection unit period) may be set corresponding to a plurality of periods (n). Furthermore, the predetermined period (detection unit period) may be set depending on the number (k) of types of data (CAN frames). At this time, if the transmission period (T) is the same for all types of data regardless of the data type, the predetermined period (detection unit period) is calculated using the formula ⁇ T ⁇ n ⁇ (1+D/100) ⁇ /k. It may also be calculated by
  • the type of data (CAN frame) transmitted by the in-vehicle device 1 is determined (classified) by, for example, CAN-ID (message ID).
  • CAN-ID messages ID
  • the number of CAN-IDs corresponds to the number of data types (number of types). For example, if the CAN-ID of the CAN frame transmitted by the in-vehicle device 1 consists of 101 and 102, the number of data types (number of types) is two (two types).
  • the transmission cycle of the CAN frame for each of these different CAN-IDs may be the same cycle (T), or may be different for each CAN-ID (for each type of data).
  • the in-vehicle device 1 executes a recovery process (reset) in order to resolve the inability to transmit (abnormality) due to a stuck state or the like.
  • the recovery process (reset) includes a process of initializing software and hardware related to CAN communication.
  • the in-vehicle device 1 is restarted by executing the recovery process, and recovers (transitions) from an abnormal state to a normal state.
  • FIG. 4 is a flowchart illustrating the processing of the control unit 11 of the in-vehicle device 1.
  • the control unit 11 of the in-vehicle device 1 monitors interrupt processing by performing the following processing, for example, when the vehicle C is activated or stopped.
  • the control unit 11 of the in-vehicle device 1 regularly performs communication processing regarding transmission and reception of data (CAN frames) with the in-vehicle ECU 2 using the CAN communication protocol. Then, the control unit 11 of the in-vehicle device 1 performs processing such as monitoring of the interrupt processing that occurs due to the CAN communication processing.
  • CAN frames transmission and reception of data
  • FIG. 4 is a flowchart illustrating the processing of the control unit 11 of the in-vehicle device 1.
  • the control unit 11 of the in-vehicle device 1 determines whether a transmission completion interrupt has been detected (S101). In determining whether or not a transmission completion interrupt has been detected, the control unit 11 of the in-vehicle device 1 determines whether or not an interrupt signal indicating a transmission completion interrupt has been transmitted from the process that executes the CAN communication control program. It may also be something that makes a determination. That is, in the control unit 11 of the in-vehicle device 1, a process that executes a CAN communication control program and a process that executes a monitoring process are generated, and the process that executes the monitoring process executes the CAN communication control program.
  • transmission completion interrupt signal When a signal (transmission completion interrupt signal) sent by the executing process is received, it may be determined that a transmission completion interrupt has been detected.
  • the control unit 11 of the in-vehicle device 1 when transmitting data (CAN frame), the control unit 11 of the in-vehicle device 1 performs post-processing to attempt to obtain data or a signal regarding whether or not a transmission completion interrupt has occurred, and based on the result of the post-processing, , it may be determined whether or not a transmission completion interrupt has been detected.
  • the control unit 11 of the in-vehicle device 1 determines that communication with the in-vehicle ECU 2 has been successfully completed (S102).
  • the transmission completion interrupt is an interrupt process that occurs when data is normally transmitted from the in-vehicle device 1.
  • the control unit 11 of the in-vehicle device 1 determines that the CAN communication with the in-vehicle ECU 2 has been successfully completed.
  • the control unit 11 of the in-vehicle device 1 stores time information such as a timestamp or time indicating the time when the transmission completion interrupt was detected (the transmission completion interrupt detection time) in the storage unit 12.
  • the transmission completion interrupt detection time information (transmission completion interrupt detection time) stored in the storage unit 12 is used as the starting point (timer reset) of the transmission cycle when transmitting the next data (CAN frame).
  • the control unit 11 of the in-vehicle device 1 performs a process of re-measuring time such as a transmission cycle upon detection (occurrence) of a transmission completion interrupt.
  • the control unit 11 of the vehicle-mounted device 1 determines whether or not an error interrupt has been detected (S103).
  • the error interrupt is an interrupt process that occurs when data is not transmitted normally from the in-vehicle device 1, and the transmitted data is received by loopback processing, etc., and the received data and the transmitted data are This is an interrupt process that occurs when a difference (bit error) occurs between the two, an ACK error, arbitration lost, or the like occurs.
  • the control unit 11 of the vehicle-mounted device 1 determines that an error interrupt has been detected, it determines that the CAN communication with the vehicle-mounted ECU 2 is abnormal (a communication error has occurred).
  • the control unit 11 of the in-vehicle device 1 makes the determination based on whether or not an interrupt signal indicating an error interrupt has been transmitted from the process that executes the CAN communication control program. It may be something you do. That is, in the control unit 11 of the in-vehicle device 1, a process that executes a CAN communication control program and a process that executes a monitoring process are generated, and the process that executes the monitoring process executes the CAN communication control program.
  • a signal (error interrupt signal) sent by the executing process it may be determined that an error interrupt has been detected.
  • the control unit 11 of the in-vehicle device 1 performs post-processing to attempt to obtain data or signals regarding the occurrence of an error interrupt, and based on the result of the post-processing, It may be determined whether or not an error interrupt has been detected.
  • the control unit 11 of the in-vehicle device 1 determines that communication with the in-vehicle ECU 2 has ended abnormally (S104).
  • a failure such as noise generation or a short circuit (ground fault) has occurred in the communication line 4 (fault) or the communication unit 13 (CAN transceiver).
  • the communication with the in-vehicle ECU 2 is abnormal.
  • the control unit 11 of the vehicle-mounted device 1 stores time information such as a timestamp or time indicating the time when the error interrupt was detected (the time of error interrupt detection) in the storage unit 12.
  • the error interrupt detection time information (error interrupt detection time) stored in the storage unit 12 is used as the starting point (timer reset) of the transmission cycle when transmitting the next data (CAN frame), and is used as the starting point (timer reset) for transmitting the next data (CAN frame).
  • the control unit 11 performs a process of re-measuring time such as a transmission cycle upon detection (occurrence) of an error interrupt.
  • the control unit 11 of the in-vehicle device 1 initializes the communication unit 13 (S105).
  • the control unit 11 of the in-vehicle device 1 detects an error interrupt, it performs an initialization process for the communication unit 13 (CAN transceiver).
  • the initialization process for the communication unit 13 may include, for example, performing a hardware reset (initialization) by cutting off and restarting power to the communication unit 13. By resetting the communication unit 13 in this manner, the communication unit 13 can be transitioned to a normal state, and communication with the in-vehicle ECU 2 can be restored to a normal state.
  • the control unit 11 of the in-vehicle device 1 may store history information including the date and time when the communication unit 13 was initialized in the storage unit 12. After executing the process in S105, the control unit 11 of the in-vehicle device 1 performs a loop process to execute the process from S101 again.
  • control unit 11 of the in-vehicle device 1 initializes the communication unit 13 each time an error interrupt is detected in step S105, but the invention is not limited to this.
  • the control unit 11 of the in-vehicle device 1 may continue monitoring the interrupt processing without initializing the communication unit 13 even when an error interrupt is detected. Error interrupts can also occur when noise occurs in the communication line 4 or when a temporary failure occurs due to accumulation of electric charge in the communication section 13. It is possible that it will be restored. Therefore, the control unit 11 of the in-vehicle device 1 may initialize the communication unit 13 when error interrupts continue to be detected, such as when error interrupts are detected a plurality of times in succession.
  • the control unit 11 of the in-vehicle device 1 determines whether a predetermined period of time has elapsed (S1031). When determining that no error interrupt has been detected, the control unit 11 of the vehicle-mounted device 1 determines whether a predetermined period of time has elapsed since the most recently detected transmission completion interrupt or error interrupt.
  • the predetermined period is a predetermined period according to the transmission cycle of data transmitted from the in-vehicle device 1 to the in-vehicle ECU 2, and corresponds to a period for making a determination (detection unit period).
  • the period for making the determination may be set (derived) based on the data transmission cycle, the number of cycles, the tolerance of the transmission cycle, and the number of types of data.
  • the detection unit period may be defined in a configuration file or the like stored in the storage unit 12. If it is determined that the predetermined period has not elapsed (S1031: NO), the control unit 11 of the in-vehicle device 1 performs a loop process to execute the process from S101 again.
  • the control unit 11 of the vehicle-mounted device 1 determines that the vehicle-mounted device 1 is abnormal (S1032). This process is executed when a transmission completion interrupt is not detected in the branch process of S101 (S101: NO), so if it is determined that an error interrupt is not detected within a predetermined period, an error interrupt is executed. In addition, the transmission completion interrupt is also not detected.
  • the control unit 11 of the in-vehicle device 1 determines that neither the transmission completion interrupt nor the error interrupt has been detected in the predetermined period (detection unit period) corresponding to multiple cycles. do.
  • control unit 11 of the in-vehicle device 1 does not detect any interrupt processing, either a transmission completion interrupt or an error interrupt, an abnormality occurs in the execution state of the CAN communication control program (data transmission is not possible due to a stuck state), and the in-vehicle device Device 1 is determined to be abnormal. In other words, the control unit 11 of the in-vehicle device 1 is unable to send data due to a hang state in the process that executes the CAN communication control program, a stuck state in software processing, and a transmission completion interrupt and an error interrupt. It is determined that none of the interrupt processing has occurred.
  • the control unit 11 of the in-vehicle device 1 initializes the control unit 11 (S1033).
  • the control unit 11 of the in-vehicle device 1 initializes the communication unit 13 (S1034).
  • the control unit 11 of the in-vehicle device 1 initializes the control unit 11 by restarting the CAN communication control program, restarting the control unit 11 itself, or restarting the in-vehicle device 1 itself including the communication unit 13, for example. conduct.
  • the control unit 11 of the in-vehicle device 1 may perform each of these resets (restarts) in stages.
  • the control unit 11 of the in-vehicle device 1 may perform software reset (initialization), hardware reset (initialization), or both software and hardware reset (initialization).
  • the control unit 11 of the in-vehicle device 1 may initialize the communication unit 13 after initializing the control unit 11 or simultaneously with the initialization.
  • the initialization of the communication unit 13 in this process (S1034) may be the same process as S105. If the restart of the in-vehicle device 1 itself described as an example of initialization of the control unit 11 includes initialization of both the control unit 11 and the communication unit 13, the processes of S1033 and S1034 are performed at substantially the same timing. It will be held in
  • control unit 11 of the in-vehicle device 1 may store history information including the date and time when the control unit 11 was initialized in the storage unit 12. After executing the process of S1033, the control unit 11 of the vehicle-mounted device 1 performs a loop process to execute the process from S101 again.
  • the claims may include multiple dependent claims that are dependent on multiple claims. Multiple dependent claims may be written that are dependent on multiple dependent claims. Even if a multiple dependent claim that is dependent on a multiple dependent claim is not written, this does not limit the writing of the multiple dependent claim that is dependent on the multiple dependent claim.
  • Vehicle S Vehicle-mounted system 1 Vehicle-mounted device 11 Control unit 12 Storage unit M Recording medium P Program (program product) 13 Communication department (CAN transceiver) 2 In-vehicle ECU 3 On-vehicle load 4 Communication line (CAN bus)

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Mechanical Engineering (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)
  • Small-Scale Networks (AREA)

Abstract

Provided is an in-vehicle device, which is mounted on a vehicle and is communicably connected to an in-vehicle ECU using a CAN communication protocol, wherein the in-vehicle device comprises a control unit that performs control relating to communications with the in-vehicle ECU, the control unit detecting interrupt processing that occurs after transmission of data to the in-vehicle ECU and determining whether or not communication with the in-vehicle ECU is performed normally on the basis of the result of detection.

Description

車載装置、プログラム及び情報処理方法In-vehicle device, program and information processing method
 本開示は、車載装置、プログラム及び情報処理方法に関する。
 本出願は、2022年5月19日出願の日本出願第2022-082589号に基づく優先権を主張し、前記日本出願に記載された全ての記載内容を援用するものである。
The present disclosure relates to an in-vehicle device, a program, and an information processing method.
This application claims priority based on Japanese Application No. 2022-082589 filed on May 19, 2022, and incorporates all the contents described in the said Japanese application.
 車両には、例えば、ワイパー駆動装置、車両の内外の灯火装置、ドアロック装置、パワーウインドウ等のボディ系の装置の制御を統括して行う車載ECUであるボディECUが搭載されている(例えば特許文献1)。特許文献1のワイパー駆動装置は、車載ECU(ボデーECU)を含み、車載ECUに適用されている制御プログラムにより駆動される。 Vehicles are equipped with a body ECU, which is an in-vehicle ECU that centrally controls body-related devices such as a wiper drive device, lighting devices inside and outside the vehicle, door lock devices, and power windows. Reference 1). The wiper drive device of Patent Document 1 includes a vehicle-mounted ECU (body ECU) and is driven by a control program applied to the vehicle-mounted ECU.
特開2017-224926号公報JP2017-224926A
 本開示の一態様に係る車載装置は、車両に搭載され、CANの通信プロトコルを用いて車載ECUと通信可能に接続される車載装置であって、前記車載ECUとの通信に関する制御を行う制御部を備え、前記制御部は、前記車載ECUへのデータの送信後に発生する割込み処理を検出し、前記検出結果に基づき、前記車載ECUとの通信が正常に行われているか否かを判定する。 An in-vehicle device according to an aspect of the present disclosure is an in-vehicle device that is installed in a vehicle and is communicably connected to an in-vehicle ECU using a CAN communication protocol, and includes a control unit that performs control regarding communication with the in-vehicle ECU. The control unit detects an interrupt process that occurs after data is transmitted to the in-vehicle ECU, and determines whether communication with the in-vehicle ECU is being performed normally based on the detection result.
実施形態1に係る車載装置等を含む車載システムの構成を例示する模式図である。1 is a schematic diagram illustrating the configuration of an in-vehicle system including an in-vehicle device and the like according to a first embodiment; FIG. 車載装置の内部構成を例示するブロック図である。FIG. 2 is a block diagram illustrating the internal configuration of an on-vehicle device. 車載装置の制御部による割込み処理の検出に関する説明図である。FIG. 3 is an explanatory diagram regarding detection of interrupt processing by the control unit of the in-vehicle device. 車載装置の制御部の処理を例示するフローチャートである。3 is a flowchart illustrating processing of a control unit of an in-vehicle device.
[本開示が解決しようとする課題]
 特許文献1の車載ECUにおいては、他装置との通信に関する処理が正常に行われているかを判定する点に関し考慮されていないという問題点がある。
[Problems that this disclosure seeks to solve]
The in-vehicle ECU of Patent Document 1 has a problem in that it does not take into account the determination of whether processing related to communication with other devices is being performed normally.
 本開示は、他装置との通信に関する処理が正常に行われているかを判定することができる車載装置等を提供することを目的とする。 An object of the present disclosure is to provide an in-vehicle device or the like that can determine whether processing related to communication with other devices is being performed normally.
[本開示の効果]
 本開示の一態様によれば、他装置との通信に関する処理が正常に行われているかを判定する車載装置等を提供することができる。
[Effects of this disclosure]
According to one aspect of the present disclosure, it is possible to provide an in-vehicle device or the like that determines whether processing related to communication with other devices is being performed normally.
[本開示の実施形態の説明]
 最初に本開示の実施態様を列挙して説明する。また、以下に記載する実施形態の少なくとも一部を任意に組み合わせてもよい。
[Description of embodiments of the present disclosure]
First, embodiments of the present disclosure will be listed and described. Furthermore, at least some of the embodiments described below may be combined arbitrarily.
(1)本開示の一態様に係る車載装置は、車両に搭載され、CANの通信プロトコルを用いて車載ECUと通信可能に接続される車載装置であって、前記車載ECUとの通信に関する制御を行う制御部を備え、前記制御部は、前記車載ECUへのデータの送信後に発生する割込み処理を検出し、前記検出結果に基づき、前記車載ECUとの通信が正常に行われているか否かを判定する。 (1) An in-vehicle device according to an aspect of the present disclosure is an in-vehicle device that is installed in a vehicle and is communicably connected to an in-vehicle ECU using a CAN communication protocol, and controls control regarding communication with the in-vehicle ECU. The control unit detects an interrupt process that occurs after data is transmitted to the in-vehicle ECU, and determines whether communication with the in-vehicle ECU is being performed normally based on the detection result. judge.
 本態様にあたっては、CAN(Controller Area Network)の通信プロトコルを用いて、車載装置と複数の車載ECUとが通信する場合、車載装置及び車載ECUそれぞれは、CANノードとして機能する。車載装置の制御部は、車載装置からCANトランシーバ等の通信部を介してCANバスにデータ(CANフレーム)を送信する処理が行われた場合、当該送信後に発生する割込み処理の検出を試みる。当該割込み処理は、CANによるデータ送信を行った際、当該データ送信後に発生するようにCANによる通信処理の仕様上、定義されている。車載装置の制御部は、割込み処理の検出結果、すなわち割込み処理を検出したか否かに基づき、車載装置と車載ECUとの通信が正常に行われているか否かを判定するため、車載ECU等の他装置との通信に関する処理が正常に行われているかを効率的に判定することができる。このように車載装置の制御部は、CANを用いた車載ECUとのデータの送受信に関する通信処理を行いつつ、当該通信処理に並行して割込み処理の有無等を監視することにより、CAN通信における信頼性を担保することができる。 In this aspect, when an in-vehicle device and a plurality of in-vehicle ECUs communicate using a CAN (Controller Area Network) communication protocol, each of the in-vehicle device and the in-vehicle ECUs function as a CAN node. When a process of transmitting data (CAN frame) from the vehicle-mounted device to the CAN bus via a communication unit such as a CAN transceiver is performed, the control unit of the vehicle-mounted device attempts to detect an interrupt process that occurs after the transmission. The interrupt process is defined in the specifications of the CAN communication process so that it occurs after the data is transmitted when the data is transmitted by the CAN. The control unit of the in-vehicle device determines whether communication between the in-vehicle device and the in-vehicle ECU is being performed normally based on the detection result of the interrupt process, that is, whether or not an interrupt process is detected. It is possible to efficiently determine whether processing related to communication with other devices is being performed normally. In this way, the control unit of the in-vehicle device performs communication processing related to data transmission and reception with the in-vehicle ECU using CAN, and monitors the presence or absence of interrupt processing in parallel with the communication processing, thereby increasing the reliability of CAN communication. It is possible to guarantee gender.
(2)本開示の一態様に係る車載装置は、前記割込み処理は、送信完了割込みと、エラー割込みとを含み、前記制御部は、前記送信完了割込みを検出した場合、前記車載ECUとの通信は正常であると判定し、前記送信完了割込み及び前記エラー割込みのいずれの割込み処理を検出しなかった場合、前記車載ECUとの通信は異常であると判定し、前記制御部の初期化処理を行う。 (2) In the in-vehicle device according to one aspect of the present disclosure, the interrupt processing includes a transmission completion interrupt and an error interrupt, and when the control unit detects the transmission completion interrupt, the control unit communicates with the in-vehicle ECU. is determined to be normal, and if neither the transmission completion interrupt nor the error interrupt is detected, the communication with the in-vehicle ECU is determined to be abnormal, and the initialization processing of the control unit is performed. conduct.
 本態様にあたっては、送信元ノードである車載装置からのデータ(CANフレーム)の送信に対し、発生し得る割込み処理は、送信完了割込みと、エラー割込みとを含む。送信完了割込みは、データ(CANフレーム)の送信が正常に送信された場合に発生する割込み処理である。エラー割込みは、送信されたデータを、例えばループバック処理等にて受信し、当該受信したデータと、送信したデータとにおいて、差異が生じた場合に発生する割込み処理である。このようなデータ間差異は、例えば、CANトランシーバ等の通信部の故障、又はCANバス等の通信線のショート(地絡)等の故障等にて発生する。すなわち、CANトランシーバ等の通信部よりも下位となる物理層にて発生した事象により、データ(CANフレーム)におけるビットエラー(ビット反転)又はフィジカルバスエラー等が発生した場合、エラー割込みが発生するものとなる。更に、エラー割込みは、例えば、ACKエラー、又はアービトレーションロスト等のエラーを含むものであってもよい。制御部は、CANの通信制御プログラムを実行することにより、データを送信する都度、送信完了割込み又はエラー割込み等のいずれかの割込み処理を発生するように動作する。制御部は、更に、当該割込み処理の発生を周期的、定期的、又は定常的に監視しており、送信完了割込みを検出した場合、車載ECUとの通信は正常である(通信は正常完了した)と判定する。制御部は、送信完了割込み及びエラー割込みのいずれの割込み処理を検出しなかった場合、CANの通信制御プログラムの実行状態に異常(状態固着によるデータ送信不可)が発生し、車載ECUとの通信は異常(車載装置は異常)であると判定する。すなわち、CANの通信制御プログラムを実行するプロセスが例えばハング状態となり、ソフトウェア処理における状態固着が発生してデータ送信が不可となっている場合、送信完了割込み及びエラー割込みのいずれの割込み処理も、検出されないものなる。この場合、制御部は、通信制御プログラムを実行するプロセスの異常に起因して、通信異常が発生したと判定し、自部(制御部)の初期化処理を行うため、当該通信異常に対する復旧処理を効率的に行うことができる。制御部の初期化処理は、例えば、CANの通信制御プログラムを再起動、制御部自体のリセット(再起動)、又は車載装置自体のリセット(再起動)を含むものであり、すなわちソフトウェア的リセット(初期化)、ハードウェア的リセット(初期化)又は、ソフトウェア及びハードウェアの双方のリセット(初期化)を行うものであってもよい。このように、通信異常の発生により、データ(CANフレーム)の送信先となる複数の車載ECUに接続されるワイパー等のアクチュエータが一時的に動作しなくなった場合であっても、復旧処理を行うことにより当該アクチュエータの駆動を効率的に再開することができる。 In this aspect, interrupt processing that may occur in response to the transmission of data (CAN frame) from the in-vehicle device that is the source node includes a transmission completion interrupt and an error interrupt. A transmission completion interrupt is an interrupt process that occurs when data (CAN frame) is successfully transmitted. An error interrupt is an interrupt process that occurs when transmitted data is received by, for example, loopback processing, and a difference occurs between the received data and the transmitted data. Such data differences occur, for example, due to a failure in a communication unit such as a CAN transceiver, or a failure such as a short circuit (ground fault) in a communication line such as a CAN bus. In other words, an error interrupt occurs when a bit error (bit inversion) in data (CAN frame) or physical bus error occurs due to an event that occurs in the physical layer that is lower than the communication unit such as a CAN transceiver. becomes. Further, the error interrupt may include, for example, an ACK error or an error such as arbitration lost. The control unit operates to generate an interrupt process such as a transmission completion interrupt or an error interrupt each time data is transmitted by executing a CAN communication control program. The control unit also periodically, regularly, or constantly monitors the occurrence of the interrupt process, and if it detects a transmission completion interrupt, it indicates that the communication with the in-vehicle ECU is normal (communication has completed normally). ). If the control unit does not detect either a transmission completion interrupt or an error interrupt, an abnormality occurs in the execution state of the CAN communication control program (data cannot be sent due to a stuck state), and communication with the in-vehicle ECU is disabled. It is determined that there is an abnormality (the in-vehicle device is abnormal). In other words, if the process that executes the CAN communication control program is in a hung state, for example, and data transmission is not possible due to state fixation in software processing, both the transmission completion interrupt and error interrupt processing will not be detected. What is not done becomes. In this case, the control unit determines that a communication abnormality has occurred due to an abnormality in the process that executes the communication control program, and performs recovery processing for the communication abnormality in order to initialize its own unit (control unit). can be done efficiently. The initialization process of the control unit includes, for example, restarting the CAN communication control program, resetting (restarting) the control unit itself, or resetting (restarting) the in-vehicle device itself, that is, software reset ( Initialization), hardware reset (initialization), or both software and hardware reset (initialization) may be performed. In this way, even if actuators such as wipers connected to multiple in-vehicle ECUs to which data (CAN frames) are sent temporarily stop working due to a communication error, recovery processing is performed. This allows the actuator to be efficiently restarted.
(3)本開示の一態様に係る車載装置は、前記車載ECUへのデータの送信は、所定の送信周期にて行われ、前記制御部は、前記送信周期に基づく所定の期間にて、前記送信完了割込み及び前記エラー割込みのいずれの割込み処理を検出しなかった場合、前記車載ECUとの通信は異常であると判定する。 (3) In the in-vehicle device according to one aspect of the present disclosure, data is transmitted to the in-vehicle ECU at a predetermined transmission cycle, and the control unit transmits data to the in-vehicle ECU at a predetermined period based on the transmission cycle. If neither the transmission completion interrupt nor the error interrupt is detected, it is determined that the communication with the in-vehicle ECU is abnormal.
 本態様にあたっては、送信元ノードである車載装置は、送信先ノードである複数の車載ECUに対し、予め定められた所定の送信周期にて、データ(CANフレーム)を送信する。送信周期に関する事項は、車載装置の記憶部に記憶されており、送信するデータ(CANフレーム)における、CAN-ID(メッセージID)、送信の順番、及び送信する時間間隔(送信周期)が定義されて(含まれて)いる。当該送信周期に関する事項は、各CAN-ID毎の送信周期等をテーブル形式(送信周期テーブル)にて、車載装置の記憶部に記憶されているものであってもよい。車載装置の制御部は、記憶部に記憶されている送信周期に関する事項を参照し、定義されている送信周期に応じた所定の期間にて、送信完了割込み及びエラー割込みのいずれの割込み処理を検出したか否かを判定する。当該所定の期間は、割込み処理の検出を行う際の検出単位期間に相当するものであり、送信周期(T)に対し、例えば所定数(n)を乗算した値(T×n)として算出するものであってもよい。所定数(n)を3と設定した場合、3周期(周期数:3)に亘って、いずれの割込み処理の検出ができなかった場合、異常と判定することができる。これにより、偶発的な事象により割込み処理を検出できなかった場合(取りこぼした場合)であっても、複数回の送信周期に対応させて、割込み処理の検出を行う際の検出単位期間(所定の期間)を設定することにより、当該取りこぼし等による誤判定を防止することができる。又、割込み処理の検出を行う際の検出単位期間(所定の期間)は、送信周期(T)に対する公差を加味して、設定するものであってもよい。送信周期(T)に対する公差は、車載装置の製品仕様上、許容される範囲にて発生する差異であり、例えば、設計値である送信周期(T)に対し、±10%として設定されるものであってもよい。この場合、検出単位期間(所定の期間)は、送信周期(T)×所定数(周期数:n)×(1.01)として設定されるものであってもよい。車載装置の制御部は、直前に検出した送信完了割込み又はエラー割込みの検出時点を基準(起算点)として、送信周期に基づき設定される検出単位期間(所定の期間)が経過する時点まで、送信完了割込み及びエラー割込みのいずれの割込み処理を検出しなかった場合、車載ECUとの通信は異常であると判定するものであってもよい。このように車載装置(送信元ノード)から車載ECU(送信先ノード)へのデータ(CANフレーム)の送信周期に応じた所定の期間を、判定を行うための期間(検出単位期間)とすることにより、判定精度を向上させることができる。 In this aspect, an in-vehicle device that is a transmission source node transmits data (CAN frame) at a predetermined transmission cycle to a plurality of in-vehicle ECUs that are destination nodes. Matters regarding the transmission cycle are stored in the storage unit of the in-vehicle device, and the CAN-ID (message ID), transmission order, and transmission time interval (transmission cycle) of the data to be transmitted (CAN frame) are defined. It is (included). The information regarding the transmission cycle may be stored in the storage unit of the vehicle-mounted device in a table format (transmission cycle table), such as the transmission cycle for each CAN-ID. The control unit of the in-vehicle device refers to the transmission cycle information stored in the storage unit, and detects either a transmission completion interrupt or an error interrupt in a predetermined period according to the defined transmission cycle. Determine whether or not. The predetermined period corresponds to a detection unit period when detecting an interrupt process, and is calculated as a value (T x n) obtained by multiplying the transmission cycle (T) by a predetermined number (n), for example. It may be something. When the predetermined number (n) is set to 3, if any interrupt processing cannot be detected over three cycles (number of cycles: 3), it can be determined that there is an abnormality. As a result, even if interrupt processing cannot be detected (missed) due to an accidental event, the detection unit period (predetermined) when detecting interrupt processing corresponds to multiple transmission cycles. By setting the period), it is possible to prevent erroneous judgments due to such omissions. Further, the detection unit period (predetermined period) when detecting an interrupt process may be set by taking into account a tolerance with respect to the transmission period (T). The tolerance for the transmission cycle (T) is a difference that occurs within the allowable range according to the product specifications of the in-vehicle device. For example, it is set as ±10% with respect to the design value of the transmission cycle (T). It may be. In this case, the detection unit period (predetermined period) may be set as transmission cycle (T) x predetermined number (number of cycles: n) x (1.01). The control unit of the in-vehicle device continues transmitting until a detection unit period (predetermined period) set based on the transmission cycle elapses, starting from the point in time when the transmission completion interrupt or error interrupt detected immediately before is detected (starting point). If neither a completion interrupt nor an error interrupt is detected, it may be determined that the communication with the on-vehicle ECU is abnormal. In this way, a predetermined period corresponding to the transmission cycle of data (CAN frame) from the in-vehicle device (source node) to the in-vehicle ECU (destination node) is set as the period for making the determination (detection unit period). Accordingly, the determination accuracy can be improved.
(4)本開示の一態様に係る車載装置は、前記車載ECUに前記送信周期にて送信されるデータの種類は複数あり、前記所定の期間は、前記種類の数及び前記送信周期に基づき定められる。 (4) In the in-vehicle device according to one aspect of the present disclosure, there are multiple types of data transmitted to the in-vehicle ECU at the transmission cycle, and the predetermined period is determined based on the number of types and the transmission cycle. It will be done.
 本態様にあたっては、車載装置(送信元ノード)から、車載ECU(送信先ノード)に送信されるデータ(CANフレーム)の種類は、複数となる。当該種類は、例えば、CAN-ID(メッセージID)により決定されるものであってもよい。すなわち、車載装置から車載ECUに送信されるデータ(CANフレーム)は、例えば、CAN-IDが101及び102など2種類から成る、異なるCAN-IDによる複数種類のデータ(CANフレーム)を含む。この場合、割込み処理の検出を行う際の検出単位期間(所定の期間)は、データ(CANフレーム)の種類の数(CAN-IDの種類数)、及び種類毎(CAN-ID毎)のデータそれぞれにおける送信周期(T)に基づき定められるものであってもよい。例えば、いずれかの種類のデータ(CANフレーム)における複数周期(n周期)に対応して、検出単位期間(所定の期間)を設定する場合、送信周期(T)に周期数(n周期)を乗算した値を、データの種類の数(k)で除算することにより、検出単位期間(所定の期間)は導出(T×n/k)されるものであってもよい。更に、当該値に対し、送信時の公差(D%:例えば、±10%等)を加味した値(T×n×(1+D/100)/k)であってもよい。このように車載装置(送信元ノード)から車載ECU(送信先ノード)へのデータ(CANフレーム)の種類の数、及びデータの種類毎の送信周期に応じた所定の期間を、判定を行うための期間(検出単位期間)とすることにより、判定精度を向上させることができる。 In this aspect, there are multiple types of data (CAN frames) transmitted from the in-vehicle device (source node) to the in-vehicle ECU (destination node). The type may be determined by, for example, CAN-ID (message ID). That is, the data (CAN frame) transmitted from the in-vehicle device to the in-vehicle ECU includes a plurality of types of data (CAN frames) with different CAN-IDs, for example, two types of CAN-IDs such as 101 and 102. In this case, the detection unit period (predetermined period) when detecting interrupt processing is the number of types of data (CAN frame) (number of types of CAN-ID) and the data for each type (for each CAN-ID). It may be determined based on the transmission period (T) in each. For example, when setting a detection unit period (predetermined period) corresponding to multiple periods (n periods) in any type of data (CAN frame), set the number of periods (n periods) to the transmission period (T). The detection unit period (predetermined period) may be derived (T×n/k) by dividing the multiplied value by the number of data types (k). Furthermore, the value may be a value (T×n×(1+D/100)/k) in which a tolerance (D%: for example, ±10%, etc.) during transmission is added to the value. In this way, in order to determine the number of types of data (CAN frames) sent from the in-vehicle device (source node) to the in-vehicle ECU (destination node), and the predetermined period depending on the transmission cycle for each type of data. By setting the period (detection unit period) to , it is possible to improve the determination accuracy.
(5)本開示の一態様に係る車載装置は、前記車載ECUとの通信は、CANバスを介して行われ、前記CANバスが接続される通信部を備え、前記制御部は、前記エラー割込みを検出した場合、前記車載ECUとの通信は異常であると判定し、前記通信部の初期化処理を行う。 (5) The in-vehicle device according to one aspect of the present disclosure communicates with the in-vehicle ECU via a CAN bus, and includes a communication unit to which the CAN bus is connected, and the control unit is configured to respond to the error interrupt. If detected, it is determined that the communication with the vehicle-mounted ECU is abnormal, and initialization processing of the communication unit is performed.
 本態様にあたっては、車載装置の制御部は、エラー割込みを検出した場合、CANトランシーバ等の通信部の故障等により、車載ECUとの通信は異常である(通信は異常終了した)と判定し、通信部(CANトランシーバ)の初期化処理を行う。当該通信部(CANトランシーバ)の初期化処理は、例えば、通信部への電力の遮断及び再開によるハードウェア的リセット(初期化)を行うものであってもよい。これにより、通信部を正常な状態に遷移させ、車載ECUとの通信を正常な状態に復旧させることができる。車載装置の制御部は、通信部の初期化処理を、予め定められている所定回数以上行ったにもかかわらず、エラー割込みを継続して検出した場合、CANバス等の通信線のショート(地絡)等の故障(フィジカルバスエラー)が発生したと判定し、当該判定結果を記憶部に記憶し、ディスプレイ等のHMI(Human Machine Interface)装置に出力するものであってもよい。 In this aspect, when the control unit of the in-vehicle device detects an error interrupt, it determines that communication with the in-vehicle ECU is abnormal (communication has ended abnormally) due to a failure of a communication unit such as a CAN transceiver, Performs initialization processing of the communication unit (CAN transceiver). The initialization process of the communication unit (CAN transceiver) may include, for example, performing a hardware reset (initialization) by cutting off and restarting power to the communication unit. Thereby, the communication unit can be brought into a normal state, and communication with the vehicle-mounted ECU can be restored to a normal state. If the control unit of the in-vehicle device continues to detect error interrupts even though the initialization process of the communication unit has been performed a predetermined number of times or more, the control unit of the in-vehicle device detects a short circuit (ground) in the communication line such as the CAN bus. It may be determined that a failure (physical bus error) such as a physical bus error has occurred, and the determination result may be stored in a storage unit and output to an HMI (Human Machine Interface) device such as a display.
(6)本開示の一態様に係る情報処理方法は、車両に搭載され、CANの通信プロトコルを用いて車載ECUと通信可能に接続され、前記車載ECUとの通信に関する制御を行うコンピュータに、前記車載ECUへのデータの送信後に発生する割込み処理を検出し、前記検出結果に基づき、前記車載ECUとの通信が正常に行われているか否かを判定する処理を実行させる。 (6) An information processing method according to an aspect of the present disclosure includes a computer that is installed in a vehicle, is communicably connected to an in-vehicle ECU using a CAN communication protocol, and controls communication with the in-vehicle ECU. An interrupt process that occurs after data is transmitted to an on-vehicle ECU is detected, and based on the detection result, a process is executed to determine whether communication with the on-vehicle ECU is being performed normally.
 本態様にあたっては、コンピュータを、他装置との通信に関する処理が正常に行われているかを判定する車載装置として機能させる情報処理方法を提供することができる。 In this aspect, it is possible to provide an information processing method that causes a computer to function as an in-vehicle device that determines whether processing related to communication with other devices is being performed normally.
(7)本開示の一態様に係るプログラムは、車両に搭載され、CANの通信プロトコルを用いて車載ECUと通信可能に接続され、前記車載ECUとの通信に関する制御を行うコンピュータに、前記車載ECUへのデータの送信後に発生する割込み処理を検出し、前記検出結果に基づき、前記車載ECUとの通信が正常に行われているか否かを判定する処理を実行させる。 (7) A program according to an aspect of the present disclosure is installed in a vehicle, is communicably connected to an in-vehicle ECU using a CAN communication protocol, and is transmitted to a computer that controls communication with the in-vehicle ECU. An interrupt process that occurs after data is transmitted to the ECU is detected, and based on the detection result, a process is executed to determine whether communication with the in-vehicle ECU is being performed normally.
 本態様にあたっては、コンピュータを、他装置との通信に関する処理が正常に行われているかを判定する車載装置として機能させるプログラムを提供することができる。 In this aspect, it is possible to provide a program that causes a computer to function as an in-vehicle device that determines whether processing related to communication with other devices is being performed normally.
[本開示の実施形態の詳細]
 本開示をその実施の形態を示す図面に基づいて具体的に説明する。本開示の実施形態に係る車載装置1等を、以下に図面を参照しつつ説明する。なお、本開示はこれらの例示に限定されるものではなく、請求の範囲によって示され、請求の範囲と均等の意味及び範囲内での全ての変更が含まれることが意図される。
[Details of embodiments of the present disclosure]
The present disclosure will be specifically described based on drawings showing embodiments thereof. An in-vehicle device 1 and the like according to an embodiment of the present disclosure will be described below with reference to the drawings. Note that the present disclosure is not limited to these examples, but is indicated by the scope of the claims, and is intended to include all changes within the meaning and scope equivalent to the scope of the claims.
(実施形態1)
 以下、実施の形態について図面に基づいて説明する。図1は、実施形態1に係る車載装置1等を含む車載システムSの構成を例示する模式図である。図2は、車載装置1の内部構成を例示するブロック図である。車載システムSは、車両Cに搭載された車載装置1、及び複数の車載ECU2により構成され、これら車載装置1と、複数の車載ECU2(Electronic Control Unit)それぞれとは、通信線4(CANバス)によって通信可能に接続される。車載装置1及び車載ECU2は、CAN(Controller Area Network)の通信プロトコルを用いてデータ(CANフレーム)を送受信するように構成されており、車載装置1及び車載ECU2はCANノードとして機能する。
(Embodiment 1)
Hereinafter, embodiments will be described based on the drawings. FIG. 1 is a schematic diagram illustrating the configuration of an in-vehicle system S including an in-vehicle device 1 and the like according to the first embodiment. FIG. 2 is a block diagram illustrating the internal configuration of the in-vehicle device 1. As shown in FIG. The in-vehicle system S is composed of an in-vehicle device 1 mounted on a vehicle C and a plurality of in-vehicle ECUs 2, and these in-vehicle devices 1 and each of the plurality of in-vehicle ECUs 2 (Electronic Control Units) are connected to a communication line 4 (CAN bus). communicably connected. The in-vehicle device 1 and the in-vehicle ECU 2 are configured to transmit and receive data (CAN frames) using a CAN (Controller Area Network) communication protocol, and the in-vehicle device 1 and the in-vehicle ECU 2 function as CAN nodes.
 車載ECU2それぞれには、ランプ、ドアミラー又はワイパー等の車載負荷3(アクチュエータ)が通信可能に接続されている。これら車載ECU2は、車載装置1から送信されたデータ(CANフレーム)を受信し、当該受信したデータに応じて、自ECU(車載ECU2自身)に直接、接続されている車載負荷3(アクチュエータ)の駆動制御を行う。 An on-vehicle load 3 (actuator) such as a lamp, a door mirror, or a wiper is communicably connected to each of the on-vehicle ECUs 2. These in-vehicle ECUs 2 receive data (CAN frames) transmitted from the in-vehicle device 1, and depending on the received data, control the in-vehicle loads 3 (actuators) directly connected to their own ECU (in-vehicle ECU 2 itself). Performs drive control.
 車載装置1は、車載ECU2にデータを送信後、都度、送信完了割込み又はエラー割込みを検出するように構成されている。詳細は後述するが、車載装置1は、車載ECU2にデータを送信し所定期間が経過するまでの間、送信完了割込み及びエラー割込みのいずれの割込み処理も検出しなかった場合、ソフトウェア処理における状態固着等による通信異常が発生したと判定し、CAN通信に関するソフトウェア及びハードウェアを初期化する。 The in-vehicle device 1 is configured to detect a transmission completion interrupt or an error interrupt each time after transmitting data to the in-vehicle ECU 2. Although the details will be described later, if the in-vehicle device 1 does not detect any interrupt processing, such as a transmission completion interrupt or an error interrupt, after transmitting data to the in-vehicle ECU 2 until a predetermined period has elapsed, the state will be fixed in the software processing. It is determined that a communication abnormality has occurred due to, etc., and the software and hardware related to CAN communication are initialized.
 車載装置1は、制御部11、記憶部12、及び通信部13を含む。車載装置1は、例えば、ボディ系アクチュエータの全体制御を行うボディECUとして機能するものであってもよい。又は、車載装置1は、例えばヴィークルコンピュータ等の中央制御装置にて構成され、車両C全体の統合制御を行う統合ECUとして機能するものであってもよい。 The in-vehicle device 1 includes a control section 11, a storage section 12, and a communication section 13. The in-vehicle device 1 may function, for example, as a body ECU that performs overall control of body-related actuators. Alternatively, the in-vehicle device 1 may be configured with a central control device such as a vehicle computer, and may function as an integrated ECU that performs integrated control of the entire vehicle C.
 制御部11は、CPU(Central Processing Unit)又はMPU(Micro Processing Unit)等により構成してあり、記憶部12に予め記憶されたプログラム(プログラム製品)及びデータを読み出し実行することにより、種々の制御処理及び演算処理等を行う。制御部11は、記憶部12等と共に、マイコン等によりパッケージ化されて構成されているものであってもよい。制御部11は、CPU等のソフトウェア処理を行うソフトウェア処理部のみに限定されず、FPGA(Field Programmable Gate Array)、ASIC(Application Specific Integrated Circuit)又はSOC(System on Chip)等のハードウェア処理にて種々の制御処理及び演算処理等を行うハードウェア処理部を含むものであってもよい。 The control unit 11 is composed of a CPU (Central Processing Unit), an MPU (Micro Processing Unit), etc., and performs various controls by reading and executing programs (program products) and data stored in advance in the storage unit 12. Performs processing, arithmetic processing, etc. The control unit 11 may be configured by being packaged with a microcomputer or the like together with the storage unit 12 and the like. The control unit 11 is not limited to a software processing unit such as a CPU that performs software processing, but may also be a hardware processing unit such as an FPGA (Field Programmable Gate Array), an ASIC (Application Specific Integrated Circuit), or an SOC (System on Chip). It may include a hardware processing unit that performs various control processing, calculation processing, and the like.
 記憶部12は、RAM(Random Access Memory)等の揮発性のメモリ素子又は、ROM(Read Only Memory)、EEPROM(Electrically Erasable Programmable ROM)もしくはフラッシュメモリ等の不揮発性のメモリ素子により構成してあり、車載装置1のプログラムP(プログラム製品)又はデータが記憶されている。記憶部12に記憶されたプログラムP(プログラム製品)は、車載装置1が読み取り可能な記録媒体Mから読み出されたプログラムP(プログラム製品)を記憶したものであってもよい。また、図示しない通信網に接続されている図示しない外部コンピュータからプログラムP(プログラム製品)をダウンロードし、記憶部12に記憶させたものであってもよい。記憶部12には、送信するCAN-ID(メッセージID)、送信の順番、及び送信する時間間隔(送信周期)等、CAN通信を行う際に用いられる各種パラメータを含む送信周期に関する事項が記憶されている。当該送信周期に関する事項は、送信周期等を管理項目として含むテーブル形式(送信周期テーブル)にて、記憶部12に記憶されているものであってもよい。 The storage unit 12 is composed of a volatile memory element such as a RAM (Random Access Memory), or a nonvolatile memory element such as a ROM (Read Only Memory), an EEPROM (Electrically Erasable Programmable ROM), or a flash memory. A program P (program product) or data of the in-vehicle device 1 is stored. The program P (program product) stored in the storage unit 12 may be a program P (program product) read from a recording medium M readable by the in-vehicle device 1. Alternatively, the program P (program product) may be downloaded from an external computer (not shown) connected to a communication network (not shown) and stored in the storage unit 12. The storage unit 12 stores items related to the transmission cycle including various parameters used when performing CAN communication, such as the CAN-ID (message ID) to be transmitted, the order of transmission, and the time interval for transmission (transmission cycle). ing. The matters related to the transmission cycle may be stored in the storage unit 12 in a table format (transmission cycle table) including the transmission cycle and the like as management items.
 通信部13は、CAN等の通信プロトコルを用いた入出力インターフェイスであるCANトランシーバにて構成される。通信部13(CANトランシーバ)には、バス構成による通信線4(CANバス)が接続され、当該通信線4を介して、車載装置1と車載ECU2との間でCAN通信が行われる。 The communication unit 13 is composed of a CAN transceiver, which is an input/output interface using a communication protocol such as CAN. A communication line 4 (CAN bus) having a bus configuration is connected to the communication unit 13 (CAN transceiver), and CAN communication is performed between the in-vehicle device 1 and the in-vehicle ECU 2 via the communication line 4.
 車載ECU2それぞれにおいても、車載装置1と同様に制御部、記憶部、及び通信部(CANトランシーバ)を含む。これら車載ECU2それぞれには、シリアルケーブル等を介してワイパー等の車載負荷3(アクチュエータ)が直接、接続されている。車載ECU2は、CAN通信により車載装置1から受信したデータに基づき、自ECU(車載ECU2自身)に直接、接続されている車載負荷3(アクチュエータ)を駆動する。 Similarly to the in-vehicle device 1, each of the in-vehicle ECUs 2 includes a control section, a storage section, and a communication section (CAN transceiver). A vehicle load 3 (actuator) such as a wiper is directly connected to each of these vehicle ECUs 2 via a serial cable or the like. The on-vehicle ECU 2 drives an on-vehicle load 3 (actuator) directly connected to its own ECU (on-vehicle ECU 2 itself) based on data received from the on-vehicle device 1 through CAN communication.
 図3は、車載装置1の制御部11による割込み処理の検出に関する説明図である。本説明図は、横軸にて示される経過時間における、通信線4及び車載装置1の状態を示す。その上で、車載装置1に実装されるマイコン等の制御部11が行う処理である、送信完了割込み、エラー割込み、及びこれら割込み処理を検出するための時間監視(時間計測を伴う監視処理)についても、模式的に説明する。 FIG. 3 is an explanatory diagram regarding detection of interrupt processing by the control unit 11 of the in-vehicle device 1. This explanatory diagram shows the states of the communication line 4 and the vehicle-mounted device 1 during the elapsed time indicated by the horizontal axis. On top of that, we will discuss transmission completion interrupts, error interrupts, and time monitoring (monitoring processing that involves time measurement) for detecting these interrupt processes, which are processes performed by the control unit 11 such as a microcomputer installed in the in-vehicle device 1. will also be schematically explained.
 データ(CANフレーム)の送信後に発生する割込み処理は、送信完了割込み及びエラー割込みを含み、CANによるデータ送信を行った際、当該データ送信後に発生するようにCANによる通信処理の仕様上、定義されている。車載装置1の制御部11(CANの通信制御プログラムを実行するプロセス)は、送信したデータをループバック処理等にて受信し、当該受信したデータと、送信したデータとにおいて、差異が生じた(ビットエラーが発生)場合はエラー割込みを発生させ、差異が生じなかった場合は送信完了割込みを発生させる。エラー割込みは、ビットエラーが発生した場合のみならず、ACKエラー、又はアービトレーションロスト等が発生した場合においても、発生されるものであってもよい。このようにビットエラー、ACKエラー又はアービトレーションロスト等が生じなかった場合は、CAN通信は正常であると判定され、差異が生じた場合は、CAN通信は異常である(通信エラーが発生)と判定される。 Interrupt processing that occurs after transmitting data (CAN frame) includes transmission completion interrupts and error interrupts, and is defined in the specifications of communication processing by CAN to occur after transmitting data when transmitting data by CAN. ing. The control unit 11 (the process that executes the CAN communication control program) of the in-vehicle device 1 receives the transmitted data through loopback processing, etc., and if a difference occurs between the received data and the transmitted data ( If a bit error occurs), an error interrupt is generated, and if no difference occurs, a transmission completion interrupt is generated. An error interrupt may be generated not only when a bit error occurs, but also when an ACK error, arbitration lost, or the like occurs. In this way, if no bit error, ACK error, arbitration lost, etc. occur, the CAN communication is determined to be normal, and if a difference occurs, the CAN communication is determined to be abnormal (a communication error has occurred). be done.
 通信線4及び車載装置1が共に正常な状態(場合)においては、車載装置1は、車載ECU2へデータを送信後、都度、送信完了割込み(実線で記載)を検出する。車載装置1は、検出した送信完了割込みの検出時点を起算点として、異常判定を行うための時間(所定期間)の再計測(送信完了割込み発生による時間再計測)を行う処理を行う。すなわち、送信完了割込みの検出により、時間監視を行うにあたっての経過時間が0に設定(0クリア:タイマーリセット)される。 When both the communication line 4 and the vehicle-mounted device 1 are in a normal state (case), the vehicle-mounted device 1 detects a transmission completion interrupt (indicated by a solid line) each time after transmitting data to the vehicle-mounted ECU 2. The in-vehicle device 1 performs a process of re-measuring the time (predetermined period) for determining an abnormality (re-measuring the time due to the occurrence of the transmission completion interrupt) using the detected transmission completion interrupt as a starting point. That is, upon detection of a transmission completion interrupt, the elapsed time for time monitoring is set to 0 (0 cleared: timer reset).
 車載装置1は、例えば通信線4にノイズ等が発生した場合等、通信線4が一時的に異常な状態となった際、エラー割込みを検出する。この場合、本来なら検出される送信完了割込みは、検出されない(発生しない)ものとなる。本説明図において、当該検出されなかった(発生しなかった)送信完了割込みは、破線にて示す。車載装置1は、検出したエラー割込みの検出時点を起算点として、異常判定を行うための時間(所定期間)の再計測(エラー発生による時間再計測)を行う処理を行う。すなわち、エラー割込みの検出により、時間監視を行うにあたっての経過時間が0に設定(0クリア:タイマーリセット)される。 The in-vehicle device 1 detects an error interrupt when the communication line 4 becomes temporarily abnormal, such as when noise or the like occurs on the communication line 4. In this case, the transmission completion interrupt that would normally be detected is not detected (does not occur). In this explanatory diagram, the transmission completion interrupt that was not detected (did not occur) is indicated by a broken line. The in-vehicle device 1 performs a process of re-measuring the time (predetermined period) for determining an abnormality (re-measuring the time due to the occurrence of an error) using the time of detection of the detected error interrupt as a starting point. That is, upon detection of an error interrupt, the elapsed time for time monitoring is set to 0 (0 cleared: timer reset).
 本説明図にて、車載装置1が送信完了割込み(実線で記載)を検出した後、車載装置1にて、例えばソフトウェア処理における異常(状態固着で送信不可)が発生した場合、送信完了割込み及びエラー割込みが共に非発生(非検出)な期間が生じる。当該期間において、本来(通信線4及び車載装置1が正常)なら、複数回の送信完了割込み(破線で記載)が検出されるところ、これら送信完了割込みのみならず、エラー割込みも、検出されないものとなる。 In this explanatory diagram, after the in-vehicle device 1 detects a transmission completion interrupt (indicated by a solid line), if, for example, an abnormality occurs in software processing (unable to transmit due to stuck state), the in-vehicle device 1 detects a transmission completion interrupt and There is a period in which neither error interrupt occurs (is not detected). During this period, if the communication line 4 and in-vehicle device 1 were normal, multiple transmission completion interrupts (indicated by broken lines) would be detected, but not only these transmission completion interrupts but also error interrupts are not detected. becomes.
 車載装置1は、車載ECU2への送信周期に応じた所定の期間を、判定を行うための期間(検出単位期間)とし、当該所定の期間(検出単位期間)にて送信完了割込み及びエラー割込みを検出しなかった場合、状態固着等による送信不可(異常)が発生したと判定する。当該判定を行うための期間(検出単位期間)は、判定処理を行う際に用いるタイマーにおける、時間経過の計測開始からの満了時間に相当する。当該タイマーの満了時間は、故障発生から復旧処理実行までの時間を規定するものとなる。当該規定に基づき、車載装置1(自装置)の故障を、他の車載ECU2が検出する前に復旧処理を行うことが可能となる。又、車載装置1の故障が発現する前に復旧処理を行うことが可能となる。又、データの送信周期の誤差を吸収して、判定することができる。又、送信周期の1回分(1周期分)をタイマーの満了時間(検出単位期間)の下限値とすることにより、誤判定が発生することを抑制することができる。 The in-vehicle device 1 sets a predetermined period according to the transmission cycle to the in-vehicle ECU 2 as a period for making a determination (detection unit period), and generates a transmission completion interrupt and an error interrupt in the predetermined period (detection unit period). If not detected, it is determined that transmission failure (abnormality) due to state fixation or the like has occurred. The period (detection unit period) for performing the determination corresponds to the expiration time from the start of measuring the passage of time in a timer used when performing the determination process. The expiration time of the timer defines the time from the occurrence of a failure to the execution of recovery processing. Based on the regulations, it becomes possible to perform recovery processing before other in-vehicle ECUs 2 detect a failure in the in-vehicle device 1 (own device). Furthermore, it is possible to perform recovery processing before a failure of the in-vehicle device 1 occurs. Further, it is possible to absorb errors in the data transmission cycle and make a determination. Further, by setting one transmission cycle (one cycle) as the lower limit of the expiration time (detection unit period) of the timer, it is possible to suppress the occurrence of erroneous determination.
 所定の期間(検出単位期間)は、データ(CANフレーム)の送信周期(T)に対する公差(±D%)を加味して、設定するものであってもよい。更に、所定の期間(検出単位期間)は、複数周期(n)に対応して設定するものであってもよい。更に、所定の期間(検出単位期間)は、データ(CANフレーム)の種類数(k)に応じて、設定するものであってもよい。この際、データの種類にかかわらず、全種類のデータにおいて送信周期(T)が同じ場合、所定の期間(検出単位期間)は、{T×n×(1+D/100)}/kの算式にて、算出されるものであってもよい。 The predetermined period (detection unit period) may be set by taking into account the tolerance (±D%) for the transmission cycle (T) of data (CAN frame). Furthermore, the predetermined period (detection unit period) may be set corresponding to a plurality of periods (n). Furthermore, the predetermined period (detection unit period) may be set depending on the number (k) of types of data (CAN frames). At this time, if the transmission period (T) is the same for all types of data regardless of the data type, the predetermined period (detection unit period) is calculated using the formula {T×n×(1+D/100)}/k. It may also be calculated by
 車載装置1が送信するデータ(CANフレーム)の種類は、例えば、CAN-ID(メッセージID)により決定(分類)される。車載装置1が、異なるCAN-IDのCANフレームを送信する場合、当該CAN-IDの個数が、データの種類の数(種類数)に相当する。例えば、車載装置1が送信するCANフレームのCAN-IDが、101及び102から成る場合、データの種類の数(種類数)は、2個(2種類)となる。これら異なるCAN-IDそれぞれのCANフレームの送信周期は、同じ周期(T)であってもよく、又は、各CAN-ID毎(データの種類毎)に異なるものであってもよい。例えば、周期(T)が100ms、周期数を3周期、データの種類数を2種類、送信時の公差を±10%とした場合、割込み処理の検出を行う際の検出単位期間(所定の期間)は、165ms{165=(100×3/2)×(1+0.1)}となる。 The type of data (CAN frame) transmitted by the in-vehicle device 1 is determined (classified) by, for example, CAN-ID (message ID). When the in-vehicle device 1 transmits CAN frames with different CAN-IDs, the number of CAN-IDs corresponds to the number of data types (number of types). For example, if the CAN-ID of the CAN frame transmitted by the in-vehicle device 1 consists of 101 and 102, the number of data types (number of types) is two (two types). The transmission cycle of the CAN frame for each of these different CAN-IDs may be the same cycle (T), or may be different for each CAN-ID (for each type of data). For example, if the period (T) is 100 ms, the number of periods is 3, the number of data types is 2, and the tolerance at the time of transmission is ±10%, the detection unit period (predetermined period ) is 165ms {165=(100×3/2)×(1+0.1)}.
 車載装置1は、状態固着等による送信不可(異常)を解消するため、復旧処理(リセット)を実行する。当該復旧処理(リセット)は、CAN通信に関するソフトウェア及びハードウェアを初期化する処理を含む。車載装置1は、復旧処理の実行を行うことにより再起動され、異常な状態から、正常な状態に復旧(遷移)する。 The in-vehicle device 1 executes a recovery process (reset) in order to resolve the inability to transmit (abnormality) due to a stuck state or the like. The recovery process (reset) includes a process of initializing software and hardware related to CAN communication. The in-vehicle device 1 is restarted by executing the recovery process, and recovers (transitions) from an abnormal state to a normal state.
 図4は、車載装置1の制御部11の処理を例示するフローチャートである。車載装置1の制御部11は、例えば、車両Cの起動状態又は停止状態において、以下の処理を行うことにより、割込み処理に対する監視等を実施する。車載装置1の制御部11は、CANの通信プロトコルを用いて車載ECU2とデータ(CANフレーム)の送受信に関する通信処理を定常的に行っている。その上で、車載装置1の制御部11は、当該CANの通信処理を行うことにより発生する割込み処理に対し、監視等を行う処理を実施する。 FIG. 4 is a flowchart illustrating the processing of the control unit 11 of the in-vehicle device 1. The control unit 11 of the in-vehicle device 1 monitors interrupt processing by performing the following processing, for example, when the vehicle C is activated or stopped. The control unit 11 of the in-vehicle device 1 regularly performs communication processing regarding transmission and reception of data (CAN frames) with the in-vehicle ECU 2 using the CAN communication protocol. Then, the control unit 11 of the in-vehicle device 1 performs processing such as monitoring of the interrupt processing that occurs due to the CAN communication processing.
 車載装置1の制御部11は、送信完了割込みを検出したか否かを判定する(S101)。車載装置1の制御部11は、送信完了割込みを検出したか否かを判定するにあたり、CANの通信制御プログラムを実行するプロセスから、送信完了割込みを示す割込みシグナルが発信されたか否かにより、当該判定を行うものであってもよい。すなわち、車載装置1の制御部11において、CANの通信制御プログラムを実行するプロセスと、監視処理を実行するプロセスとが生成されており、当該監視処理を実行するプロセスが、CANの通信制御プログラムを実行するプロセスが発信したシグナル(送信完了割込みシグナル)を受信した場合、送信完了割込みを検出したと判定するものであってもよい。又は、車載装置1の制御部11は、データ(CANフレーム)を送信した際、後処理として送信完了割込みの発生の有無に関するデータ又はシグナルの取得を試みる処理を行い、当該後処理の結果に基づき、送信完了割込みを検出したか否かを判定するものであってもよい。 The control unit 11 of the in-vehicle device 1 determines whether a transmission completion interrupt has been detected (S101). In determining whether or not a transmission completion interrupt has been detected, the control unit 11 of the in-vehicle device 1 determines whether or not an interrupt signal indicating a transmission completion interrupt has been transmitted from the process that executes the CAN communication control program. It may also be something that makes a determination. That is, in the control unit 11 of the in-vehicle device 1, a process that executes a CAN communication control program and a process that executes a monitoring process are generated, and the process that executes the monitoring process executes the CAN communication control program. When a signal (transmission completion interrupt signal) sent by the executing process is received, it may be determined that a transmission completion interrupt has been detected. Alternatively, when transmitting data (CAN frame), the control unit 11 of the in-vehicle device 1 performs post-processing to attempt to obtain data or a signal regarding whether or not a transmission completion interrupt has occurred, and based on the result of the post-processing, , it may be determined whether or not a transmission completion interrupt has been detected.
 送信完了割込みを検出したと判定した場合(S101:YES)、車載装置1の制御部11は、車載ECU2との通信は正常完了したと判定する(S102)。送信完了割込みは、車載装置1からデータが正常に送信された場合に発生する割込み処理である。車載装置1の制御部11は、送信完了割込みを検出したと判定した場合、車載ECU2とのCAN通信は正常完了したと判定する。 If it is determined that a transmission completion interrupt has been detected (S101: YES), the control unit 11 of the in-vehicle device 1 determines that communication with the in-vehicle ECU 2 has been successfully completed (S102). The transmission completion interrupt is an interrupt process that occurs when data is normally transmitted from the in-vehicle device 1. When determining that the transmission completion interrupt has been detected, the control unit 11 of the in-vehicle device 1 determines that the CAN communication with the in-vehicle ECU 2 has been successfully completed.
 車載装置1の制御部11は、送信完了割込みを検出した時点を示すタイムスタンプ又は時間等の時点情報(送信完了割込み検出時点)を記憶部12に記憶する。記憶部12に記憶した送信完了割込みの検出時点情報(送信完了割込み検出時点)は、次回のデータ(CANフレーム)を送信する際の送信周期の起算点(タイマーリセット)とし用いられるものであり、車載装置1の制御部11は、送信完了割込みの検出(発生)により送信周期等の時間を再計測する処理を行う。 The control unit 11 of the in-vehicle device 1 stores time information such as a timestamp or time indicating the time when the transmission completion interrupt was detected (the transmission completion interrupt detection time) in the storage unit 12. The transmission completion interrupt detection time information (transmission completion interrupt detection time) stored in the storage unit 12 is used as the starting point (timer reset) of the transmission cycle when transmitting the next data (CAN frame). The control unit 11 of the in-vehicle device 1 performs a process of re-measuring time such as a transmission cycle upon detection (occurrence) of a transmission completion interrupt.
 送信完了割込みを検出していないと判定した場合(S101:NO)、車載装置1の制御部11は、エラー割込みを検出したか否かを判定する(S103)。エラー割込みは、車載装置1からデータが正常に送信されなかった場合に発生する割込み処理であり、送信されたデータを、例えばループバック処理等にて受信し、当該受信したデータと、送信したデータとにおいて、差異(ビットエラー)が生じた場合、ACKエラー、又はアービトレーションロスト等が発生した場合に発生する割込み処理である。 If it is determined that a transmission completion interrupt has not been detected (S101: NO), the control unit 11 of the vehicle-mounted device 1 determines whether or not an error interrupt has been detected (S103). The error interrupt is an interrupt process that occurs when data is not transmitted normally from the in-vehicle device 1, and the transmitted data is received by loopback processing, etc., and the received data and the transmitted data are This is an interrupt process that occurs when a difference (bit error) occurs between the two, an ACK error, arbitration lost, or the like occurs.
 車載装置1の制御部11は、エラー割込みを検出したと判定した場合、車載ECU2とのCAN通信は異常である(通信エラーが発生)と判定する。車載装置1の制御部11は、エラー割込みを検出したか否かを判定するにあたり、CANの通信制御プログラムを実行するプロセスから、エラー割込みを示す割込みシグナルが発信されたか否かにより、当該判定を行うものであってもよい。すなわち、車載装置1の制御部11において、CANの通信制御プログラムを実行するプロセスと、監視処理を実行するプロセスとが生成されており、当該監視処理を実行するプロセスが、CANの通信制御プログラムを実行するプロセスが発信したシグナル(エラー割込みシグナル)を受信した場合、エラー割込みを検出したと判定するものであってもよい。又は、車載装置1の制御部11は、データ(CANフレーム)を送信した際、後処理としてエラー割込みの発生の有無に関するデータ又はシグナルの取得を試みる処理を行い、当該後処理の結果に基づき、エラー割込みを検出したか否かを判定するものであってもよい。 When the control unit 11 of the vehicle-mounted device 1 determines that an error interrupt has been detected, it determines that the CAN communication with the vehicle-mounted ECU 2 is abnormal (a communication error has occurred). When determining whether or not an error interrupt has been detected, the control unit 11 of the in-vehicle device 1 makes the determination based on whether or not an interrupt signal indicating an error interrupt has been transmitted from the process that executes the CAN communication control program. It may be something you do. That is, in the control unit 11 of the in-vehicle device 1, a process that executes a CAN communication control program and a process that executes a monitoring process are generated, and the process that executes the monitoring process executes the CAN communication control program. If a signal (error interrupt signal) sent by the executing process is received, it may be determined that an error interrupt has been detected. Alternatively, when transmitting data (CAN frame), the control unit 11 of the in-vehicle device 1 performs post-processing to attempt to obtain data or signals regarding the occurrence of an error interrupt, and based on the result of the post-processing, It may be determined whether or not an error interrupt has been detected.
 エラー割込みを検出したと判定した場合(S103:YES)、車載装置1の制御部11は、車載ECU2との通信は異常終了したと判定する(S104)。車載装置1の制御部11は、エラー割込みを検出したと判定した場合、通信線4(障害)又は通信部13(CANトランシーバ)にてノイズの発生、又はショート(地絡)等の障害が発生し、車載ECU2との通信は異常であると判定するものであってもよい。 If it is determined that an error interrupt has been detected (S103: YES), the control unit 11 of the in-vehicle device 1 determines that communication with the in-vehicle ECU 2 has ended abnormally (S104). When the control unit 11 of the in-vehicle device 1 determines that an error interrupt has been detected, a failure such as noise generation or a short circuit (ground fault) has occurred in the communication line 4 (fault) or the communication unit 13 (CAN transceiver). However, it may be determined that the communication with the in-vehicle ECU 2 is abnormal.
 車載装置1の制御部11は、エラー割込みを検出した時点を示すタイムスタンプ又は時間等の時点情報(エラー割込み検出時点)を記憶部12に記憶する。記憶部12に記憶したエラー割込みの検出時点情報(エラー割込み検出時点)は、次回のデータ(CANフレーム)を送信する際の送信周期の起算点(タイマーリセット)とし用いられるものであり、車載装置1の制御部11は、エラー割込みの検出(発生)により送信周期等の時間を再計測する処理を行う。 The control unit 11 of the vehicle-mounted device 1 stores time information such as a timestamp or time indicating the time when the error interrupt was detected (the time of error interrupt detection) in the storage unit 12. The error interrupt detection time information (error interrupt detection time) stored in the storage unit 12 is used as the starting point (timer reset) of the transmission cycle when transmitting the next data (CAN frame), and is used as the starting point (timer reset) for transmitting the next data (CAN frame). The control unit 11 performs a process of re-measuring time such as a transmission cycle upon detection (occurrence) of an error interrupt.
 車載装置1の制御部11は、通信部13の初期化を行う(S105)。車載装置1の制御部11は、エラー割込みを検出した際、通信部13(CANトランシーバ)の初期化処理を行う。当該通信部13(CANトランシーバ)の初期化処理は、例えば、通信部13への電力の遮断及び再開によるハードウェア的リセット(初期化)を行うものであってもよい。このように通信部13をリセットすることにより、通信部13を正常な状態に遷移させ、車載ECU2との通信を正常な状態に復旧させることができる。車載装置1の制御部11は、通信部13の初期化を行った日時等を含む履歴情報を、記憶部12に記憶するものであってもよい。車載装置1の制御部11は、S105の処理の実行後、再度S101からの処理を実行すべく、ループ処理を行う。 The control unit 11 of the in-vehicle device 1 initializes the communication unit 13 (S105). When the control unit 11 of the in-vehicle device 1 detects an error interrupt, it performs an initialization process for the communication unit 13 (CAN transceiver). The initialization process for the communication unit 13 (CAN transceiver) may include, for example, performing a hardware reset (initialization) by cutting off and restarting power to the communication unit 13. By resetting the communication unit 13 in this manner, the communication unit 13 can be transitioned to a normal state, and communication with the in-vehicle ECU 2 can be restored to a normal state. The control unit 11 of the in-vehicle device 1 may store history information including the date and time when the communication unit 13 was initialized in the storage unit 12. After executing the process in S105, the control unit 11 of the in-vehicle device 1 performs a loop process to execute the process from S101 again.
 本実施形態において、車載装置1の制御部11は、処理S105として、エラー割込みを検出した場合、都度、通信部13の初期化を行うとしたがこれに限定されない。車載装置1の制御部11は、エラー割込みを検出した場合であっても通信部13の初期化を行くことなく、割込み処理の監視を継続するものであってもよい。エラー割込みは、通信線4にノイズが発生した場合、又は通信部13にて電荷が溜まる等による一時的な障害が発生した場合においても、発生し得るものであり、この際、時間経過により自然復旧することもあり得る。従って、車載装置1の制御部11は、エラー割込みを連続して複数回検出した場合等、エラー割込みの検出が継続した際、通信部13の初期化を行うものであってもよい。 In the present embodiment, the control unit 11 of the in-vehicle device 1 initializes the communication unit 13 each time an error interrupt is detected in step S105, but the invention is not limited to this. The control unit 11 of the in-vehicle device 1 may continue monitoring the interrupt processing without initializing the communication unit 13 even when an error interrupt is detected. Error interrupts can also occur when noise occurs in the communication line 4 or when a temporary failure occurs due to accumulation of electric charge in the communication section 13. It is possible that it will be restored. Therefore, the control unit 11 of the in-vehicle device 1 may initialize the communication unit 13 when error interrupts continue to be detected, such as when error interrupts are detected a plurality of times in succession.
 エラー割込みを検出していないと判定した場合(S103:NO)、車載装置1の制御部11は、所定期間、経過したか否かを判定する(S1031)。車載装置1の制御部11は、エラー割込みを検出していないと判定した場合、直前に検出した送信完了割込み又はエラー割込みの検出時点から、所定期間、経過したか否かを判定する。当該所定期間は、車載装置1から車載ECU2へ送信するデータの送信周期に応じた所定の期間であり、判定を行うための期間(検出単位期間)に相当する。当該判定を行うための期間(検出単位期間)は、データの送信周期、周期数、送信周期の公差、及びデータの種類数に基づき、設定(導出)されるものであってもよい。当該検出単位期間は、記憶部12に記憶される設定ファイル等にて定義されているものであってもよい。所定期間、経過していないと判定した場合(S1031:NO)、車載装置1の制御部11は、再度S101からの処理を実行すべく、ループ処理を行う。 If it is determined that an error interrupt has not been detected (S103: NO), the control unit 11 of the in-vehicle device 1 determines whether a predetermined period of time has elapsed (S1031). When determining that no error interrupt has been detected, the control unit 11 of the vehicle-mounted device 1 determines whether a predetermined period of time has elapsed since the most recently detected transmission completion interrupt or error interrupt. The predetermined period is a predetermined period according to the transmission cycle of data transmitted from the in-vehicle device 1 to the in-vehicle ECU 2, and corresponds to a period for making a determination (detection unit period). The period for making the determination (detection unit period) may be set (derived) based on the data transmission cycle, the number of cycles, the tolerance of the transmission cycle, and the number of types of data. The detection unit period may be defined in a configuration file or the like stored in the storage unit 12. If it is determined that the predetermined period has not elapsed (S1031: NO), the control unit 11 of the in-vehicle device 1 performs a loop process to execute the process from S101 again.
 所定期間、経過したと判定した場合(S1031:YES)、車載装置1の制御部11は、車載装置1は異常であると判定する(S1032)。本処理は、S101の分岐処理にて送信完了割込みを検出していない場合(S101:NO)に実行されるものであるため、所定期間にてエラー割込み検出していないと判定した場合、エラー割込みのみならず、送信完了割込みについても、検出していないものとなる。このように所定期間経過した場合、車載装置1の制御部11は、複数周期に対応する所定期間(検出単位期間)にて、送信完了割込み及びエラー割込みのいずれの割込み処理を検出しなかったと判定する。 If it is determined that the predetermined period has elapsed (S1031: YES), the control unit 11 of the vehicle-mounted device 1 determines that the vehicle-mounted device 1 is abnormal (S1032). This process is executed when a transmission completion interrupt is not detected in the branch process of S101 (S101: NO), so if it is determined that an error interrupt is not detected within a predetermined period, an error interrupt is executed. In addition, the transmission completion interrupt is also not detected. When the predetermined period of time has elapsed in this way, the control unit 11 of the in-vehicle device 1 determines that neither the transmission completion interrupt nor the error interrupt has been detected in the predetermined period (detection unit period) corresponding to multiple cycles. do.
 車載装置1の制御部11は、送信完了割込み及びエラー割込みのいずれの割込み処理を検出しなかった場合、CANの通信制御プログラムの実行状態に異常(状態固着によるデータ送信不可)が発生し、車載装置1は異常であると判定する。すなわち、車載装置1の制御部11は、CANの通信制御プログラムを実行するプロセスが例えばハング状態となり、ソフトウェア処理における状態固着が発生してデータ送信が不可となっており、送信完了割込み及びエラー割込みのいずれの割込み処理も発生しなかったと判定する。 If the control unit 11 of the in-vehicle device 1 does not detect any interrupt processing, either a transmission completion interrupt or an error interrupt, an abnormality occurs in the execution state of the CAN communication control program (data transmission is not possible due to a stuck state), and the in-vehicle device Device 1 is determined to be abnormal. In other words, the control unit 11 of the in-vehicle device 1 is unable to send data due to a hang state in the process that executes the CAN communication control program, a stuck state in software processing, and a transmission completion interrupt and an error interrupt. It is determined that none of the interrupt processing has occurred.
 車載装置1の制御部11は、制御部11の初期化を行う(S1033)。車載装置1の制御部11は、通信部13の初期化を行う(S1034)。車載装置1の制御部11は、制御部11の初期化として、例えば、CANの通信制御プログラムの再起動、制御部11自体の再起動、又は、通信部13含む車載装置1自体の再起動を行う。車載装置1の制御部11は、これら各リセット(再起動)を段階的に行うものであってもよい。車載装置1の制御部11は、ソフトウェア的リセット(初期化)、ハードウェア的リセット(初期化)又は、ソフトウェア及びハードウェアの双方のリセット(初期化)を行うものであってもよい。車載装置1の制御部11は、制御部11の初期化を行った上で、もしくは当該初期化と同時に、通信部13の初期化を行うものであってもよい。本処理(S1034)における通信部13の初期化は、S105と同様の処理であってもよい。制御部11の初期化の一例として記載した車載装置1自体の再起動が、制御部11及び通信部13の双方の初期化を含むものである場合、これらS1033及びS1034の処理は、実質的に同じタイミングで行われるものとなる。 The control unit 11 of the in-vehicle device 1 initializes the control unit 11 (S1033). The control unit 11 of the in-vehicle device 1 initializes the communication unit 13 (S1034). The control unit 11 of the in-vehicle device 1 initializes the control unit 11 by restarting the CAN communication control program, restarting the control unit 11 itself, or restarting the in-vehicle device 1 itself including the communication unit 13, for example. conduct. The control unit 11 of the in-vehicle device 1 may perform each of these resets (restarts) in stages. The control unit 11 of the in-vehicle device 1 may perform software reset (initialization), hardware reset (initialization), or both software and hardware reset (initialization). The control unit 11 of the in-vehicle device 1 may initialize the communication unit 13 after initializing the control unit 11 or simultaneously with the initialization. The initialization of the communication unit 13 in this process (S1034) may be the same process as S105. If the restart of the in-vehicle device 1 itself described as an example of initialization of the control unit 11 includes initialization of both the control unit 11 and the communication unit 13, the processes of S1033 and S1034 are performed at substantially the same timing. It will be held in
 このような初期化を行うことにより、例えば極めて小さい不具合ウィンドウ等にて、すなわち比較的に短い期間となる処理単位期間において、複数の処理が重なったことにより発生した偶発的な動作不良により、CAN通信が不通となり、車載ECU2に接続されるワイパー等のアクチュエータ(車載負荷3)等、車両C機能が動作しなくなった場合でも、復旧することができる。車載装置1の制御部11は、制御部11の初期化を行った日時等を含む履歴情報を、記憶部12に記憶するものであってもよい。車載装置1の制御部11は、S1033の処理の実行後、再度S101からの処理を実行すべく、ループ処理を行う。 By performing such initialization, for example, in an extremely small defect window, that is, in a processing unit period that is a relatively short period, CAN Even if communication is interrupted and vehicle C functions such as actuators (on-vehicle loads 3) such as wipers connected to the on-vehicle ECU 2 stop operating, recovery is possible. The control unit 11 of the in-vehicle device 1 may store history information including the date and time when the control unit 11 was initialized in the storage unit 12. After executing the process of S1033, the control unit 11 of the vehicle-mounted device 1 performs a loop process to execute the process from S101 again.
 今回開示された実施形態は全ての点で例示であって、制限的なものではないと考えられるべきである。本発明の範囲は、上記した意味ではなく、請求の範囲によって示され、請求の範囲と均等の意味及び範囲内での全ての変更が含まれることが意図される。 The embodiments disclosed herein are illustrative in all respects and should not be considered restrictive. The scope of the present invention is indicated by the scope of the claims, not the meaning described above, and is intended to include meanings equivalent to the scope of the claims and all changes within the scope.
 請求の範囲に記載されている複数の請求項に関して、引用形式に関わらず、相互に組み合わせることが可能である。請求の範囲では、複数の請求項に従属する多項従属請求項を記載してもよい。多項従属請求項に従属する多項従属請求項を記載してもよい。多項従属請求項に従属する多項従属請求項が記載されていない場合であっても、これは、多項従属請求項に従属する多項従属請求項の記載を制限するものではない。 Multiple claims described in the scope of claims may be combined with each other regardless of the citation format. The claims may include multiple dependent claims that are dependent on multiple claims. Multiple dependent claims may be written that are dependent on multiple dependent claims. Even if a multiple dependent claim that is dependent on a multiple dependent claim is not written, this does not limit the writing of the multiple dependent claim that is dependent on the multiple dependent claim.
 C 車両 
 S 車載システム
 1 車載装置
 11 制御部
 12 記憶部
 M 記録媒体
 P プログラム(プログラム製品)
 13 通信部(CANトランシーバ)
 2 車載ECU
 3 車載負荷
 4 通信線(CANバス)
C Vehicle
S Vehicle-mounted system 1 Vehicle-mounted device 11 Control unit 12 Storage unit M Recording medium P Program (program product)
13 Communication department (CAN transceiver)
2 In-vehicle ECU
3 On-vehicle load 4 Communication line (CAN bus)

Claims (7)

  1.  車両に搭載され、CANの通信プロトコルを用いて車載ECUと通信可能に接続される車載装置であって、
     前記車載ECUとの通信に関する制御を行う制御部を備え、
     前記制御部は、
     前記車載ECUへのデータの送信後に発生する割込み処理を検出し、
     前記検出結果に基づき、前記車載ECUとの通信が正常に行われているか否かを判定する
     車載装置。
    An in-vehicle device installed in a vehicle and communicably connected to an in-vehicle ECU using a CAN communication protocol,
    comprising a control unit that controls communication with the in-vehicle ECU,
    The control unit includes:
    detecting an interrupt process that occurs after data is transmitted to the in-vehicle ECU;
    An in-vehicle device that determines whether communication with the in-vehicle ECU is being performed normally based on the detection result.
  2.  前記割込み処理は、送信完了割込みと、エラー割込みとを含み、
     前記制御部は、
      前記送信完了割込みを検出した場合、前記車載ECUとの通信は正常であると判定し、
      前記送信完了割込み及び前記エラー割込みのいずれの割込み処理を検出しなかった場合、前記車載ECUとの通信は異常であると判定し、前記制御部の初期化処理を行う
     請求項1に記載の車載装置。
    The interrupt processing includes a transmission completion interrupt and an error interrupt,
    The control unit includes:
    If the transmission completion interrupt is detected, determining that communication with the in-vehicle ECU is normal;
    The in-vehicle device according to claim 1, wherein if neither the transmission completion interrupt nor the error interrupt is detected, the communication with the in-vehicle ECU is determined to be abnormal, and initialization processing of the control unit is performed. Device.
  3.  前記車載ECUへのデータの送信は、所定の送信周期にて行われ、
     前記制御部は、前記送信周期に基づく所定の期間にて、前記送信完了割込み及び前記エラー割込みのいずれの割込み処理を検出しなかった場合、前記車載ECUとの通信は異常であると判定する
     請求項2に記載の車載装置。
    Transmission of data to the in-vehicle ECU is performed at a predetermined transmission cycle,
    The control unit determines that communication with the in-vehicle ECU is abnormal if it does not detect any of the transmission completion interrupt and the error interrupt during a predetermined period based on the transmission cycle. The in-vehicle device according to item 2.
  4.  前記車載ECUに前記送信周期にて送信されるデータの種類は複数あり、
     前記所定の期間は、前記種類の数及び前記送信周期に基づき定められる
     請求項3に記載の車載装置。
    There are multiple types of data transmitted to the in-vehicle ECU at the transmission cycle,
    The vehicle-mounted device according to claim 3, wherein the predetermined period is determined based on the number of types and the transmission cycle.
  5.  前記車載ECUとの通信は、CANバスを介して行われ、
     前記CANバスが接続される通信部を備え、
     前記制御部は、前記エラー割込みを検出した場合、前記車載ECUとの通信は異常であると判定し、前記通信部の初期化処理を行う
     請求項2から請求項4のいずれか1項に記載の車載装置。
    Communication with the in-vehicle ECU is performed via a CAN bus,
    comprising a communication unit to which the CAN bus is connected,
    The control unit, when detecting the error interrupt, determines that communication with the in-vehicle ECU is abnormal and performs initialization processing of the communication unit. in-vehicle equipment.
  6.  車両に搭載され、CANの通信プロトコルを用いて車載ECUと通信可能に接続され、前記車載ECUとの通信に関する制御を行うコンピュータに、
     前記車載ECUへのデータの送信後に発生する割込み処理を検出し、
     前記検出結果に基づき、前記車載ECUとの通信が正常に行われているか否かを判定する
     処理を実行させる情報処理方法。
    A computer installed in a vehicle, communicably connected to an in-vehicle ECU using a CAN communication protocol, and controlling communication with the in-vehicle ECU;
    detecting an interrupt process that occurs after data is transmitted to the in-vehicle ECU;
    An information processing method that executes a process of determining whether communication with the in-vehicle ECU is being performed normally based on the detection result.
  7.  車両に搭載され、CANの通信プロトコルを用いて車載ECUと通信可能に接続され、前記車載ECUとの通信に関する制御を行うコンピュータに、
     前記車載ECUへのデータの送信後に発生する割込み処理を検出し、
     前記検出結果に基づき、前記車載ECUとの通信が正常に行われているか否かを判定する
     処理を実行させるプログラム。
    A computer installed in a vehicle, communicably connected to an in-vehicle ECU using a CAN communication protocol, and controlling communication with the in-vehicle ECU;
    detecting an interrupt process that occurs after data is transmitted to the in-vehicle ECU;
    A program that executes a process of determining whether communication with the in-vehicle ECU is being performed normally based on the detection result.
PCT/JP2023/017775 2022-05-19 2023-05-11 In-vehicle device, program, and information processing method WO2023223940A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2022082589A JP2023170679A (en) 2022-05-19 2022-05-19 On-vehicle device, program and information processing method
JP2022-082589 2022-05-19

Publications (1)

Publication Number Publication Date
WO2023223940A1 true WO2023223940A1 (en) 2023-11-23

Family

ID=88835415

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2023/017775 WO2023223940A1 (en) 2022-05-19 2023-05-11 In-vehicle device, program, and information processing method

Country Status (2)

Country Link
JP (1) JP2023170679A (en)
WO (1) WO2023223940A1 (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005337017A (en) * 2004-05-24 2005-12-08 Mitsubishi Electric Corp Electronic control device for vehicle
JP2009214830A (en) * 2008-03-12 2009-09-24 Fujitsu Ten Ltd Device, method and system for controlling power generation
JP2014099698A (en) * 2012-11-13 2014-05-29 Toyota Motor Corp Communication system, communication node, and communication method
JP2016126716A (en) * 2015-01-08 2016-07-11 株式会社デンソー Electronic control device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005337017A (en) * 2004-05-24 2005-12-08 Mitsubishi Electric Corp Electronic control device for vehicle
JP2009214830A (en) * 2008-03-12 2009-09-24 Fujitsu Ten Ltd Device, method and system for controlling power generation
JP2014099698A (en) * 2012-11-13 2014-05-29 Toyota Motor Corp Communication system, communication node, and communication method
JP2016126716A (en) * 2015-01-08 2016-07-11 株式会社デンソー Electronic control device

Also Published As

Publication number Publication date
JP2023170679A (en) 2023-12-01

Similar Documents

Publication Publication Date Title
US9524222B2 (en) Method and apparatus for fault detection in a controller area network
CN108427609B (en) Controller and control program update method
US6076172A (en) Monitoting system for electronic control unit
JP2013061863A (en) Electronic control device
US10921871B2 (en) BAS/HVAC control device automatic failure recovery
CN105868060B (en) Method for operating a data processing unit of a driver assistance system and data processing unit
JP2011198205A (en) Redundant system control system
US20220055637A1 (en) Electronic control unit and computer readable medium
Suwatthikul Fault detection and diagnosis for in-vehicle networks
JP3486747B2 (en) Vehicle control device and single processor system incorporated therein
JP2010093676A (en) Gateway device, vehicle network, and one-side breaking detection method
CN110147090A (en) Controller Area Network BUS closing fault processing method and system
WO2023223940A1 (en) In-vehicle device, program, and information processing method
WO2014039032A1 (en) Method and apparatus for isolating a fault-active controller in a controller area network
WO2023182020A1 (en) In-vehicle device, program, and information processing method
US20090177890A1 (en) Method and Device for Forming a Signature
JP6081239B2 (en) Control device abnormality monitoring apparatus and abnormality monitoring method
US11080161B2 (en) Control device, and processing method in event of failure in control device
US10963354B2 (en) Control apparatus and recovery processing method for control apparatus
JP4820679B2 (en) Electronic control device for vehicle
US11726853B2 (en) Electronic control device
JP6365876B2 (en) node
US10514970B2 (en) Method of ensuring operation of calculator
JP2017007539A (en) Control device
JP4613019B2 (en) Computer system

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 23805859

Country of ref document: EP

Kind code of ref document: A1