KR101144502B1 - Method for scheduling Time Triggered Controller Area Network - Google Patents

Method for scheduling Time Triggered Controller Area Network Download PDF

Info

Publication number
KR101144502B1
KR101144502B1 KR1020090037344A KR20090037344A KR101144502B1 KR 101144502 B1 KR101144502 B1 KR 101144502B1 KR 1020090037344 A KR1020090037344 A KR 1020090037344A KR 20090037344 A KR20090037344 A KR 20090037344A KR 101144502 B1 KR101144502 B1 KR 101144502B1
Authority
KR
South Korea
Prior art keywords
message
messages
time
time slots
transmission
Prior art date
Application number
KR1020090037344A
Other languages
Korean (ko)
Other versions
KR20100118475A (en
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 한양대학교 산학협력단
Priority to KR1020090037344A priority Critical patent/KR101144502B1/en
Publication of KR20100118475A publication Critical patent/KR20100118475A/en
Application granted granted Critical
Publication of KR101144502B1 publication Critical patent/KR101144502B1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L12/40143Bus networks involving priority mechanisms
    • H04L12/4015Bus networks involving priority mechanisms by scheduling the transmission of messages at the communication node
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L12/40143Bus networks involving priority mechanisms
    • H04L12/40156Bus networks involving priority mechanisms by using dedicated slots associated with a priority level
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L2012/40208Bus networks characterized by the use of a particular bus standard
    • H04L2012/40215Controller Area Network CAN

Abstract

본 발명은 TTCAN 스케줄링 방법을 개시한다. 본 발명은 TTCAN(Time-Triggered Controller Area Network) 스케줄링 방법으로서, 주기적 메시지를 미리 설정된 알고리즘을 이용하여 하나 이상의 하위 메시지 집합으로 분류하는 단계-상기 하위 메시지 집합 각각은 전송 시간이 유사한 복수의 메시지를 포함함- 및 각 하위 메시지 집합에 포함된 메시지를 동일한 전송 열에 매핑하는 단계를 포함한다. 본 발명에 따르면 배타 윈도우의 최대 구간을 최소화하여 비주기적 메시지의 전송 지연을 방지할 수 있다. The present invention discloses a TTCAN scheduling method. The present invention relates to a Time-Triggered Controller Area Network (TTCAN) scheduling method, comprising: classifying a periodic message into one or more lower message sets using a predetermined algorithm, each of the lower message sets including a plurality of messages having similar transmission times. And mapping a message included in each sub-message set to the same transmission string. According to the present invention, it is possible to minimize the maximum interval of the exclusive window to prevent the transmission delay of the aperiodic message.

Description

TTCAN 스케줄링 방법{Method for scheduling Time Triggered Controller Area Network}Method for scheduling Time Triggered Controller Area Network

본 발명은 TTCAN 스케줄링 방법에 관한 것으로서, 보다 상세하게는 주기적 메시지가 할당되는 배타 윈도우 구간을 최소화하여 비주기적 메시지의 전송 지연을 방지할 수 있는 방법에 관한 것이다.The present invention relates to a TTCAN scheduling method, and more particularly, to a method of preventing transmission delay of an aperiodic message by minimizing an exclusive window section to which a periodic message is allocated.

TTCAN(Time Triggered Controller Area Network)은 복수의 노드들이 직렬 버스(serial bus)에 연결되어 통신하는 방법으로서, 버스에 실리는 메시지들을 타임 마스터(time master)가 스케줄링하게 함으로써 주기적인 메시지의 전달을 보장한다. TTCAN (Time Triggered Controller Area Network) is a method in which a plurality of nodes are connected and communicated on a serial bus, which ensures periodic delivery of messages by having a time master schedule messages on the bus. do.

TTCAN은 미리 지정된 스케줄에 따라 메시지를 전송하기 때문에 CAN(Controller Area Network)에 비해 높은 예측성(predictability) 및 결정성(deterministic behavior)을 제공할 수 있다. Since TTCAN transmits a message according to a predetermined schedule, TTCAN can provide higher predictability and deterministic behavior than a controller area network (CAN).

이러한 특징으로 인해, TTCAN은 차량용 네트워크는 물론 의료 장비, 산업, 자동차 시스템 등과 같이 실시간성이 요구되는 다양한 어플리케이션에 널리 사용되고 있다. Because of these features, TTCAN is widely used in a variety of applications that require real-time, such as automotive networks, medical equipment, industrial, automotive systems.

TTCAN을 실시간 통신 시스템에 적용하기 위해서는 시스템 행렬(system matrix)이라고 불리는 메시지 스케줄을 만드는 것이 중요한 이슈가 된다. In order to apply TTCAN to a real-time communication system, creating a message schedule called a system matrix becomes an important issue.

기존의 연구에서는 이러한 TTCAN 스케줄링을 두 가지 관점에서 다루고 있다. 첫 번째 관점은 주어진 메시지들의 주기(period)와 종료시한(deadline)을 모두 충족할 수 있는 시스템 행렬을 찾는 것이다. Existing studies deal with this TTCAN scheduling from two perspectives. The first point is to find a system matrix that can satisfy both the period and deadline of a given message.

이는 NP-hard(Non-deterministic Polynomial-time hard)로 추정되는 문제이지만 RMS(rate monotonic scheduling) 또는 LST(least slack time)와 같은 전통적인 실시간 스케줄링 알고리즘을 적용하면 효과적인 스케줄을 찾는 것이 가능한 것으로 알려져 있다. This problem is presumed to be non-deterministic polynomial-time hard (NP-hard), but it is known that it is possible to find an effective schedule by applying a traditional real-time scheduling algorithm such as rate monotonic scheduling (RMS) or last slack time (LST).

두 번째 관점은 이미 만들어진 시스템 행렬을 특정 목적에 맞게 최적화하는 것이다. 최적화의 대상으로 지터(jitter)의 최소화, 타임 트리거 (time trigger) 개수의 최소화, 대역폭(bandwidth) 사용량의 최소화 등을 포함하며,이에 대해 다수의 연구가 수행된 바 있다.The second aspect is to optimize the system matrix that has already been created for a particular purpose. Optimization targets include minimizing jitter, minimizing the number of time triggers, minimizing bandwidth usage, and many studies have been conducted.

일반적으로, TTCAN에서 정의하는 베이직 사이클은 주기적 메시지가 배치되는 배타 윈도우(Exclusive Window)와 비주기적 메시지가 배치되는 중재 윈도우(Arbitration Window)를 포함할 수 있다. 일반적으로 실시간 어플리케이션은 주기적 메시지뿐만 아니라, 비주기적 메시지를 포함하며, TTCAN은 상기한 두 종류의 메시지를 모두 지원할 수 있도록 설계된다.In general, the basic cycle defined by the TTCAN may include an exclusive window in which periodic messages are arranged and an arbitration window in which acyclic messages are arranged. In general, real-time applications include aperiodic messages as well as periodic messages, and TTCAN is designed to support both types of messages.

그러나 종래의 스케줄링 방법은 주로 주기적 메시지의 성능에만 집중해왔으며 비주기적 메시지의 성능을 간과하기 때문에, 소정 베이직 사이클에서 배타 윈도 우의 최대 구간이 매우 커지는 경우에 비주기적 메시지의 최악의 전송 지연이 발생하는 문제점이 있다.However, the conventional scheduling method mainly concentrates on the performance of periodic messages and overlooks the performance of aperiodic messages. Therefore, the worst-case transmission delay of aperiodic messages occurs when the maximum period of the exclusive window becomes very large in a given basic cycle. There is a problem.

본 발명에서는 상기한 바와 같은 종래기술의 문제점을 해결하기 위해, 비주기적 메시지의 전송 지연을 최소화할 수 있는 TTCAN 스케줄링 방법을 제안하고자 한다In the present invention, to solve the problems of the prior art as described above, we propose a TTCAN scheduling method that can minimize the transmission delay of aperiodic messages.

상기한 목적을 달성하기 위해 본 발명의 바람직한 일 실시예에 따르면, TTCAN(Time-Triggered Controller Area Network) 스케줄링 방법으로서, 주기적 메시지 중 요구되는 타임 슬롯 개수가 베이직 사이클(Basic cycle) 개수보다 작은 것으로 탐색된 메시지를 미리 설정된 알고리즘을 이용하여 하나 이상의 하위 메시지 집합으로 분류하는 단계; 및 각 하위 메시지 집합에 포함된 메시지를 동일한 전송 열에 매핑하는 단계를 포함하는 TTCAN 스케줄링 방법이 제공된다. According to a preferred embodiment of the present invention to achieve the above object, as a time-triggered controller area network (TTCAN) scheduling method, the number of time slots required in the periodic messages is less than the number of basic cycles (Basic cycle) Classifying the classified messages into one or more lower message sets using a preset algorithm; And mapping a message included in each lower message set to the same transmission column.

본 발명의 다른 측면에 따르면, TTCAN(Time-Triggered Controller Area Network) 스케줄링 방법으로서, 비율 단조 스케줄링을 이용하여 모든 주기적 메시지에 대한 제1 시스템 행렬을 생성하는 단계; 상기 제1 시스템 행렬에서 부분 사용 전송 열을 탐색하는 단계; 및 미리 설정된 알고리즘에 따라 상기 탐색된 전송 열에 포함된 복수의 메시지를 재배치하여 배타 윈도우의 최대 구간이 최소화된 제2 시스템 행렬을 생성하는 단계를 포함하는 TTCAN 스케줄링 방법이 제공된다. According to another aspect of the present invention, there is provided a time-triggered controller area network (TCCAN) scheduling method, comprising: generating a first system matrix for all periodic messages using ratio monotonic scheduling; Searching for a partial use transmission column in the first system matrix; And relocating a plurality of messages included in the searched transmission column according to a preset algorithm to generate a second system matrix having a minimum maximum window of an exclusive window.

본 발명의 다른 측면에 따르면, TTCAN(Time-Triggered Controller Area Network) 스케줄링 방법으로서, 주기적 메시지를 미리 설정된 알고리즘을 이용하여 하나 이상의 하위 메시지 집합으로 분류하는 단계-상기 하위 메시지 집합 각각은 전송 시간이 유사한 복수의 메시지를 포함함-; 및 각 하위 메시지 집합에 포함된 메시지를 동일한 전송 열에 매핑하는 단계를 포함하는 TTCAN 스케줄링 방법이 제공된다.According to another aspect of the present invention, a time-triggered controller area network (TCCAN) scheduling method, comprising: classifying a periodic message into one or more sub message sets using a predetermined algorithm, each of which has a similar transmission time Includes a plurality of messages; And mapping a message included in each lower message set to the same transmission column.

본 발명에 따르면, 베이직 사이클에서 배타 윈도우의 최대 구간이 최소화되도록 주기적 메시지를 재배치하기 때문에 비주기적 메시지의 전송 지연을 방지할 수 있는 장점이 있다.According to the present invention, since the periodic messages are rearranged to minimize the maximum period of the exclusive window in the basic cycle, there is an advantage of preventing the transmission delay of the aperiodic message.

본 발명은 다양한 변경을 가할 수 있고 여러 가지 실시예를 가질 수 있는 바, 특정 실시예들을 도면에 예시하고 상세한 설명에 상세하게 설명하고자 한다. 그러나, 이는 본 발명을 특정한 실시 형태에 대해 한정하려는 것이 아니며, 본 발명의 사상 및 기술 범위에 포함되는 모든 변경, 균등물 내지 대체물을 포함하는 것으로 이해되어야 한다. 각 도면을 설명하면서 유사한 참조부호를 유사한 구성요소에 대해 사용하였다. As the invention allows for various changes and numerous embodiments, particular embodiments will be illustrated in the drawings and described in detail in the written description. However, this is not intended to limit the present invention to specific embodiments, it should be understood to include all modifications, equivalents, and substitutes included in the spirit and scope of the present invention. Like reference numerals are used for like elements in describing each drawing.

어떤 구성요소가 다른 구성요소에 "연결되어" 있다거나 "접속되어" 있다고 언급된 때에는, 그 다른 구성요소에 직접적으로 연결되어 있거나 또는 접속되어 있을 수도 있지만, 중간에 다른 구성요소가 존재할 수도 있다고 이해되어야 할 것이다. 반면에, 어떤 구성요소가 다른 구성요소에 "직접 연결되어" 있다거나 "직접 접속되어" 있다고 언급된 때에는, 중간에 다른 구성요소가 존재하지 않는 것으로 이 해되어야 할 것이다. When a component is referred to as being "connected" or "connected" to another component, it may be directly connected to or connected to that other component, but it may be understood that other components may be present in between. Should be. On the other hand, when a component is said to be "directly connected" or "directly connected" to another component, it should be understood that there is no other component in between.

본 출원에서 사용한 용어는 단지 특정한 실시예를 설명하기 위해 사용된 것으로, 본 발명을 한정하려는 의도가 아니다. 단수의 표현은 문맥상 명백하게 다르게 뜻하지 않는 한, 복수의 표현을 포함한다. 본 출원에서, "포함하다" 또는 "가지다" 등의 용어는 명세서상에 기재된 특징, 숫자, 단계, 동작, 구성요소, 부품 또는 이들을 조합한 것이 존재함을 지정하려는 것이지, 하나 또는 그 이상의 다른 특징들이나 숫자, 단계, 동작, 구성요소, 부품 또는 이들을 조합한 것들의 존재 또는 부가 가능성을 미리 배제하지 않는 것으로 이해되어야 한다.The terminology used herein is for the purpose of describing particular example embodiments only and is not intended to be limiting of the present invention. Singular expressions include plural expressions unless the context clearly indicates otherwise. In this application, the terms "comprise" or "have" are intended to indicate that there is a feature, number, step, operation, component, part, or combination thereof described in the specification, and one or more other features. It is to be understood that the present invention does not exclude the possibility of the presence or the addition of numbers, steps, operations, components, components, or a combination thereof.

다르게 정의되지 않는 한, 기술적이거나 과학적인 용어를 포함해서 여기서 사용되는 모든 용어들은 본 발명이 속하는 기술 분야에서 통상의 지식을 가진 자에 의해 일반적으로 이해되는 것과 동일한 의미를 가지고 있다. 일반적으로 사용되는 사전에 정의되어 있는 것과 같은 용어들은 관련 기술의 문맥 상 가지는 의미와 일치하는 의미를 가지는 것으로 해석되어야 하며, 본 출원에서 명백하게 정의하지 않는 한, 이상적이거나 과도하게 형식적인 의미로 해석되지 않는다.Unless defined otherwise, all terms used herein, including technical or scientific terms, have the same meaning as commonly understood by one of ordinary skill in the art. Terms such as those defined in the commonly used dictionaries should be construed as having meanings consistent with the meanings in the context of the related art and shall not be construed in ideal or excessively formal meanings unless expressly defined in this application. Do not.

이하, 본 발명의 바람직한 실시예를 첨부한 도면들을 참조하여 상세히 설명하기로 한다. 본 발명을 설명함에 있어 전체적인 이해를 용이하게 하기 위하여 도면 번호에 상관없이 동일한 수단에 대해서는 동일한 참조 번호를 사용하기로 한다.Hereinafter, preferred embodiments of the present invention will be described in detail with reference to the accompanying drawings. In order to facilitate a thorough understanding of the present invention, the same reference numerals are used for the same means regardless of the number of the drawings.

본 발명은 TTCAN의 스케줄러가 주기적 메시지의 실시간성을 보장하면서 비주기적 메시지의 전송 효율을 높일 수 있는 스케줄을 제공하는 것이다. The present invention provides a schedule that the scheduler of the TTCAN can improve the transmission efficiency of the aperiodic message while ensuring the real-time of the periodic message.

본 발명에 따른 방법을 설명하기에 앞서, TTCAN 시스템에서의 베이직 사이클 구조를 간단하게 살펴본다. Prior to describing the method according to the invention, a brief review of the basic cycle structure in a TTCAN system is given.

도 1은 본 발명이 적용되는 TTCAN 베이직 사이클의 기본 구조를 도시한 도면이다.1 is a view showing the basic structure of the TTCAN basic cycle to which the present invention is applied.

도 1에 도시된 바와 같이, 베이직 사이클은 레퍼런스 메시지(Reference Message), 배타 윈도우(Exclusive Window), 중재 윈도우(Arbitration Window) 및 자유 윈도우(Free Window)를 포함할 수 있다. As illustrated in FIG. 1, the basic cycle may include a reference message, an exclusive window, an arbitration window, and a free window.

레퍼런스 메시지는 베이직 사이클의 시작을 나타내며, 베이직 사이클의 타이밍을 제어한다. The reference message indicates the start of the basic cycle and controls the timing of the basic cycle.

배타 윈도우는 전송될 메시지와 데이터를 수용할 수 있는 길이를 가진 시간 조각을 의미한다. 이와 같은 배타 윈도우에는 주기적 메시지가 배치된다. An exclusive window is a piece of time with a length that can accommodate the message and data to be sent. In such an exclusive window, periodic messages are placed.

중재 윈도우는 비주기적 메시지가 배치되는 영역으로서, 중재 윈도우에서 수많은 노드들이 비주기적으로 메시지 전송을 시도한다. 중재 윈도우에서 버스 액세스를 원하는 많은 노드들은 일반적으로 비-파괴 비트-와이즈(bitwise) 중재 방법에 의해 경쟁한다. The arbitration window is an area in which an aperiodic message is placed. In the arbitration window, many nodes attempt to transmit the message aperiodically. Many nodes that want bus access in an arbitration window generally compete by non-destructive bitwise arbitration methods.

자유 윈도우는 TTCAN 시스템의 향후 확장을 위한 예비적인 영역이다. Free windows are a preliminary area for future expansion of the TTCAN system.

상기한 바와 같이, TTCAN 베이직 사이클에서, 주기적 메시지들은 배타 윈도우에 배치되며, 비주기적 메시지들은 배타 윈도우에 뒤따르는 중재 윈도우에 배치된다. As noted above, in the TTCAN basic cycle, periodic messages are placed in an exclusive window, and aperiodic messages are placed in an arbitration window following the exclusive window.

여기서, TTCAN 스케줄링은 주기적 메시지들을 적절히 배치하는 과정이다. Here, TTCAN scheduling is a process of properly placing periodic messages.

주기적 메시지 집합을 M= {M1, M2, ... } 라 할 때, 메시지 M i (M i ∈ M)의 주기를

Figure 112009025918884-pat00001
, 전송 시간을
Figure 112009025918884-pat00002
로 표기할 수 있으며,TTCAN에서 이러한 메시지 집합을 스케줄링 하기 위해서는, 모든 주기적 메시지들을 시스템 행렬 S 에 적절하게 매핑해야 한다. When the periodic message set M = {M1, M2, ...} , the period of the message M i (M i ∈ M)
Figure 112009025918884-pat00001
, Transfer time
Figure 112009025918884-pat00002
In order to schedule such a message set in TTCAN, all periodic messages must be properly mapped to the system matrix S.

여기서, 시스템 행렬 S 는

Figure 112009025918884-pat00003
개의 베이직 사이클(basic cycle)과
Figure 112009025918884-pat00004
개의 전송 열(transmission column)로 구성된다. Where the system matrix S is
Figure 112009025918884-pat00003
Basic cycles
Figure 112009025918884-pat00004
It consists of four transmission columns.

메시지의 집합

Figure 112009025918884-pat00005
을 시스템 행렬
Figure 112009025918884-pat00006
에 매핑하기 위해서는 반드시 TTCAN 표준문서에 규정된 제약사항을 고려해야 한다. 첫째, 베이직 사이클의 개수는 2의 지수 승이다. 둘째, 시스템 행렬 내의 모든 베이직 사이클의 크기(
Figure 112009025918884-pat00007
)는 동일하다. 셋째, 동일한 전송 열 내의 모든 타임 슬롯 (time slot)의 크기는 같다. 또한, 구현된 하드웨어에 따라 타임 트리거(time trigger) 개수에 제한이 있다.Set of messages
Figure 112009025918884-pat00005
System matrix
Figure 112009025918884-pat00006
In order to map the data, the constraints specified in the TTCAN standard document must be taken into account. First, the number of basic cycles is an exponential power of two. Second, the magnitude of every basic cycle in the system matrix (
Figure 112009025918884-pat00007
) Is the same. Third, all time slots in the same transmission string have the same size. In addition, there is a limit on the number of time triggers according to the implemented hardware.

본 발명은 상기와 같은 제약 사항을 기반으로, 스케줄링 가능한 시스템 행렬 S (제1 시스템 행렬)에서 주기적 메시지를 재배치하여 배타 윈도우 최대 구간이 최소화된 시스템 행렬 S' (제2 시스템 행렬)를 생성한다.The present invention generates a system matrix S ' (second system matrix) in which the exclusive window maximum interval is minimized by rearranging the periodic messages in the schedulable system matrix S (first system matrix) based on the above constraints.

본 발명에서, 배타 윈도우 최대 구간이 최소화되도록 주기적 메시지를 재배치하기 위한 알고리즘을 TTCP(Transmission Time Cohesive Partitioning) 알고리즘 으로 정의된다.In the present invention, an algorithm for relocating a periodic message to minimize the maximum window interval is defined as a Transmission Time Cohesive Partitioning (TTCP) algorithm.

여기서, 제1 시스템 행렬은 기존 RMS에 의한 시스템 행렬 등과 같은 통상적인 스케줄링 방법에 따른 시스템 행렬을 의미하며, 제2 시스템 행렬은 본 발명에 따른 스케줄링 방법의 적용에 의해 생성되는 시스템 행렬을 의미한다. Here, the first system matrix refers to a system matrix according to a conventional scheduling method such as a system matrix based on an existing RMS, and the second system matrix refers to a system matrix generated by applying a scheduling method according to the present invention.

하기에서는 설명의 편의를 위해 제1 시스템 행렬이 RMS에 의한 시스템 행렬인 것으로 가정하여 설명한다.In the following description, it is assumed that the first system matrix is a system matrix based on RMS.

RMS(Rate-Monotonic Scheduling: 비율 단조 스케줄링)은 수행 주기가 짧은 순으로 노드에 높은 우선순위를 부여하는 방식을 의미한다. Rate-Monotonic Scheduling (RMS) refers to a method of giving high priority to nodes in order of shortest execution period.

도 2는 본 발명에 따른 제1 시스템 행렬 및 제2 시스템 행렬을 개략적으로 도시한 것으로서, 각 시스템 행렬이 2개의 베이직 사이클로 구성된다고 가정한 것이다. Figure 2 schematically shows a first system matrix and a second system matrix according to the present invention, assuming that each system matrix is composed of two basic cycles.

도 2a에 도시된 바와 같이, 제1 시스템 행렬에서 제1 베이직 사이클에서는 배타 윈도우의 길이가

Figure 112009025918884-pat00008
, 제2 베이직 사이클에서의 배타 윈도우 길이가
Figure 112009025918884-pat00009
이다. 본 발명은 제1 시스템 행렬에서, 주기적 메시지들을 미리 설정된 알고리즘에 따라 재배치하여 도 2b와 같은 제2 시스템 행렬을 생성한다.As shown in FIG. 2A, the length of the exclusive window in the first basic cycle in the first system matrix is
Figure 112009025918884-pat00008
, The exclusive window length in the second basic cycle
Figure 112009025918884-pat00009
to be. In the first system matrix, periodic messages are rearranged according to a predetermined algorithm to generate a second system matrix as shown in FIG. 2B.

도 2b에 도시된 바와 같이, 제2 시스템 행렬에서, 제1 베이직 사이클에서는 배타 윈도우의 길이가

Figure 112009025918884-pat00010
, 제2 베이직 사이클에서의 배타 윈도우 길이가
Figure 112009025918884-pat00011
이다. As shown in FIG. 2B, in the second system matrix, the length of the exclusive window in the first basic cycle is
Figure 112009025918884-pat00010
, The exclusive window length in the second basic cycle
Figure 112009025918884-pat00011
to be.

여기서, 제1 시스템 행렬에서 배타 윈도우의 최대 구간은 T 1 이며, 제2 시스템 행렬에서 배타 윈도우의 최대 구간은 T 1 '이다.Here, the maximum interval of the exclusive window in the first system matrix is T 1 , and the maximum interval of the exclusive window in the second system matrix is T 1 .

본 발명은 도 2b에 도시된 바와 같이, 어느 하나의 베이직 사이클에서 배타 윈도우의 최대 구간이 다른 것에 비해 지나치게 커지지 않도록 주기적 메시지들을 적절히 재배치한다. The present invention properly rearranges the periodic messages in one basic cycle so that the maximum interval of the exclusive window does not become too large as compared to the other in one basic cycle.

상기와 같은 재배치는 주기적 메시지의 실시간성을 보장하는 것과 동시에 비주기적 메시지의 최악 스케줄링 지연(worst-case scheduling delay)을 방지하기 위한 것이다. Such relocation is to prevent the worst-case scheduling delay of the aperiodic message while ensuring the real time of the periodic message.

제1 시스템 행렬에서 소정 비주기적 메시지가 버스의 사용을 요구하는 경우, 최대 T 1 만큼의 시간을 대기해야 하나, 제2 시스템 행렬에 따르면 비주기적 메시지는 T 1 보다 작은 최대 T 1 '만큼의 대기시간만이 요구되기 때문에 본 발명은 비주기적 메시지의 최악의 전송 지연을 방지할 수 있다. In the case that requires the use of certain non-periodic message bus in the first system matrix, one must wait for a time of as long as up to T 1, the second, according to the system matrix aperiodic messages waiting for as little up to T 1 'than T 1 Since only time is required, the present invention can prevent the worst transmission delay of aperiodic messages.

하기에서는 도 3을 참조하여 본 발명에 따른 스케줄링 방법을 상세하게 살펴본다. Hereinafter, a scheduling method according to the present invention will be described in detail with reference to FIG. 3.

도 3은 본 발명의 바람직한 일 실시예에 따른 스케줄러가 TTCAN 스케줄링하는 과정을 개략적으로 도시한 도면이다.3 is a diagram schematically illustrating a process of scheduling TTCAN by a scheduler according to an exemplary embodiment of the present invention.

도 3을 참조하면, RMS에 따른 제1 시스템 행렬을 생성한다(단계 300).Referring to FIG. 3, a first system matrix is generated according to RMS (step 300).

제1 시스템 행렬에서 주기가 짧은 메시지가 앞쪽 전송 열에 배치된다. In the first system matrix, a shorter period of time message is placed in the forward transmission column.

이후, 스케줄러는 본 발명에 따른 알고리즘(이하, ‘TTCP 알고리즘’이라 함)을 적용할 메시지를 분류한다(단계 302).Thereafter, the scheduler classifies the message to which the algorithm according to the present invention (hereinafter, referred to as 'tTCP algorithm') is applied (step 302).

단계 302는 제1 시스템 행렬이 전체 사용(fully utilized) 전송 열과 부분 사용(non-fully utilized) 전송 열을 포함하는 경우, 부분 사용 전송 열에 포함되는 주기적 메시지를 탐색하고, 이를 본 발명에 따른 알고리즘을 적용할 메시지로 결정한다. Step 302, if the first system matrix includes a fully utilized transport column and a non-fully utilized transport column, searches for a periodic message included in the partially used transport column and replaces the algorithm according to the present invention. Decide on the message to apply.

여기서, 전체 사용 전송 열은 제1 시스템 행렬의 배타 윈도우에서 비어있는 타임 슬롯이 없는 전송 열을 의미하며, 부분 사용 전송 열은 비어 있는 타임 슬롯이 존재하는 전송 열을 의미한다. Here, the total used transmission column refers to a transmission column without an empty time slot in the exclusive window of the first system matrix, and the partial use transmission column refers to a transmission column in which an empty time slot exists.

만일 RMS에 의한 제1 시스템 행렬에서 N R 개의 베이직 사이클로 구성되는 경우, 모든 베이직 사이클에서 반복적으로 전송되는 메시지가 포함된 전송 열이 전체 사용 전송 열이 되며, 모든 베이직 사이클에서 반복적으로 전송되지 않은 메시지가 포함된 전송 열은 부분 사용 전송 열이 된다. If it consists of N R basic cycles in the first system matrix by RMS, the transmission column containing the message transmitted repeatedly in all the basic cycles becomes the total used transmission column, and the message not transmitted repeatedly in all the basic cycles. The transmission string containing is a partial use transmission string.

단계 302는 부분 사용 전송 열에 포함된 메시지를 탐색하는 과정으로서, TTCP 알고리즘이 적용될 메시지는 각 주기적 메시지의 타임 슬롯 개수와 베이직 사이클의 개수(N R )의 비교에 의해 결정될 수 있다. Step 302 is a process of searching for a message included in the partial use transmission column. The message to which the TTCP algorithm is to be applied may be determined by comparing the number of time slots of each periodic message and the number of basic cycles N R.

즉, 타임 슬롯 개수가 베이직 사이클 개수와 같다면 해당 주기적 메시지는 모든 베이직 사이클에 포함되어야 하기 때문에 전체 사용 전송 열에 포함되는 메시지가 되며, 타임 슬롯 개수가 베이직 사이클 개수보다 작은 주기적 메시지가 부분 사용 전송 열에 포함되는 메시지가 된다. In other words, if the number of time slots is equal to the number of basic cycles, then the corresponding periodic message must be included in all basic cycles, so that is the message included in the total usage transport column. This is the message that is included.

상기한 바와 같이, 스케줄러는 전체 주기적 메시지 중 타임 슬롯 개수가 베이직 사이클 개수보다 작은 메시지를 탐색하게 된다. As described above, the scheduler searches for a message in which the number of time slots is smaller than the number of basic cycles.

본 발명에 따르면, 타임 슬롯 개수는 메시지의 주기와 베이직 사이클의 크기 및 개수에 따라 다음과 같이 결정된다.According to the present invention, the number of time slots is determined as follows according to the period of the message and the size and number of basic cycles.

Figure 112009025918884-pat00012
Figure 112009025918884-pat00012

여기서,

Figure 112009025918884-pat00013
M i 에 요구되는 타임 슬롯 개수,
Figure 112009025918884-pat00014
은 베이직 사이클의 크기,
Figure 112009025918884-pat00015
은 베이직 사이클의 개수,
Figure 112009025918884-pat00016
Figure 112009025918884-pat00017
의 주기here,
Figure 112009025918884-pat00013
Is the number of time slots required for M i ,
Figure 112009025918884-pat00014
Is the size of the basic cycle,
Figure 112009025918884-pat00015
Is the number of basic cycles,
Figure 112009025918884-pat00016
Is
Figure 112009025918884-pat00017
Cycle of

예를 들어, 소정 메시지의 주기가 40000이고, 베이직 사이클의 개수가 8, 베이직 사이클의 크기가 10000인 경우에는 해당 메시지의 타임 슬롯 개수는 2로 계산될 수 있다. For example, when a period of a predetermined message is 40000, the number of basic cycles is 8, and the size of the basic cycles is 10000, the number of time slots of the corresponding message may be calculated as 2.

상기한 바와 같이, 주기적 메시지의 타임 슬롯 개수는 해당 메시지의 주기에 의해 결정되기 때문에 타임 슬롯 개수와 베이직 사이클 개수의 비교는 각 주기적 메시지의 주기와 베이직 사이클의 크기(W R )를 비교하는 것과 동일한 개념일 수 있다. As described above, since the number of time slots of a periodic message is determined by the period of the corresponding message, the comparison of the number of time slots and the number of basic cycles is the same as comparing the period of each periodic message and the size of the basic cycle ( W R ). It may be a concept.

이후, 스케줄러는 제1 시스템 행렬의 부분 사용 전송 열에 포함된 주기적 메시지에 대해 TTCP 알고리즘을 적용하여 복수의 주기적 메시지를 하나 이상의 하위 메시지 집합으로 분류한다(단계 304).Thereafter, the scheduler applies the TTCP algorithm to the periodic messages included in the partial use transmission column of the first system matrix to classify the plurality of periodic messages into one or more lower message sets (step 304).

본 발명의 바람직한 일 실시예에 따르면, 단계 304는 베이직 사이클의 개수, 부분 사용 전송 열에 포함된 각 주기적 메시지의 전송 시간 및 타임 슬롯 개수와 같은 정보를 이용하여 하위 메시지 집합을 분류한다. According to a preferred embodiment of the present invention, step 304 classifies the lower message set using information such as the number of basic cycles, the transmission time of each periodic message included in the partial use transmission column, and the number of time slots.

바람직하게, 단계 304에서, 각 주기적 메시지의 전송 시간에 따라 전송 시간이 유사한 하나 이상의 메시지가 동일한 하위 메시지 집합에 속하게 된다.Preferably, in step 304, one or more messages having similar transmission times according to the transmission time of each periodic message belong to the same lower message set.

전술한 바와 같이, TTCAN 스케줄링 제약 조건 중 세 번째는 "동일한 전송 열 내의 모든 타임 슬롯의 크기는 같다."는 것이다. 즉, 전송 열의 크기는 같은 전송 열에 스케줄링 되는 메시지들 중 전송 시간이 가장 큰 것으로 결정된다. 이러한 제약 조건 하에서는, 부분 사용 전송 열 내의 메시지들을 비슷한 크기의 전송 시간을 갖는 메시지들로 묶어 동일한 전송 열 내에 재배치하는 것이 효과적인 방법일 수 있다. As mentioned above, the third of the TTCAN scheduling constraints is that "the size of all time slots in the same transmission column is the same." That is, the size of the transmission column is determined to be the largest transmission time among the messages scheduled in the same transmission column. Under these constraints, it may be an effective way to group the messages in the partial use transport sequence into messages with similar size transfer times and rearrange them within the same transport sequence.

예를 들면, 부분 사용 전송 열에 포함되는 주기적 메시지 집합

Figure 112009025918884-pat00018
의 전송 시간이 각각 10, 30, 20, 40 일 때, 메시지들을
Figure 112009025918884-pat00019
으로 분류하고, 각각 두 개의 전송 열에 배치하면, 즉
Figure 112009025918884-pat00020
,
Figure 112009025918884-pat00021
를 제1 전송 열에,
Figure 112009025918884-pat00022
,
Figure 112009025918884-pat00023
를 제2 전송 열에 배치하면, 세 번째 제약사항에 따라 전체 전송 시간은 70 (=30 + 40 = 제1 전송 열 전송 시간 + 제2 전송 열 전송 시간)으로 결정된다. 반면 메시지 집합을 전송 시간이 유 사한
Figure 112009025918884-pat00024
로 분류하면 전체의 전송 시간은 60 (=20 + 40) 이 되어 이전의 분류보다 효율적인 전송 열을 얻을 수 있다.For example, a periodic set of messages included in the partial use transport column.
Figure 112009025918884-pat00018
When the transmission times of 10, 30, 20, and 40 are respectively,
Figure 112009025918884-pat00019
Classified into two columns of transfer, i.e.
Figure 112009025918884-pat00020
,
Figure 112009025918884-pat00021
In the first transfer column,
Figure 112009025918884-pat00022
,
Figure 112009025918884-pat00023
If is placed in the second transmission column, the total transmission time is determined to be 70 (= 30 + 40 = first transmission column transmission time + second transmission column transmission time) according to the third constraint. In contrast, message sets have similar transfer times.
Figure 112009025918884-pat00024
In this case, the total transmission time is 60 (= 20 + 40), which is more efficient than the previous classification.

본 발명에 따르면, 여기서, 각 하위 메시지 집합은 소정 전송 열에 대응되며, 만일 제1 내지 제4 전송 열이 전체 사용 전송 열인 경우, 제1 하위 메시지 집합은 제5 전송 열, 제2 하위 메시지 집합은 제6 전송 열에 대응될 수 있다. According to the present invention, each sub message set corresponds to a predetermined transmission column, and if the first to fourth transmission strings are all used transmission columns, the first sub message set is a fifth transmission column and the second sub message set is It may correspond to the sixth transmission string.

또한 단계 304는 각 베이직 사이클에서 배타 윈도우의 최대 구간은 최소화하기 위한 메시지 배치를 결정하는 것으로서, 바람직하게, 단계 304는 각 하위 메시지 집합에 포함된 주기적 메시지의 타임 슬롯 개수의 합이 베이직 사이클의 개수와 동일하게 하위 메시지 집합을 분류한다. In addition, in step 304, a message arrangement is determined to minimize the maximum interval of the exclusive window in each basic cycle. Preferably, in step 304, the sum of the number of time slots of periodic messages included in each sub-message set is the number of basic cycles. Categorize the lower message set as

이는 소정 전송 열에서 비어 있는 슬롯을 최소화하면서 메시지를 배치하기 위한 것이다. This is to place a message while minimizing an empty slot in a given transmission column.

단계 304를 통해 하위 메시지 집합의 분류가 완료되는 경우, 스케줄러는 하나 이상의 하위 메시지 집합을 기반으로 각 주기적 메시지를 재배치하여 제2 시스템 행렬을 생성한다(단계 306).When the classification of the lower message set is completed in step 304, the scheduler rearranges each periodic message based on the one or more lower message sets to generate a second system matrix (step 306).

본 발명에 따른 TTCP 알고리즘은 다음과 같으며, 하기에서는 TTCP 알고리즘 및 도 4를 참조하여 상기한 단계 304에서 수행되는 과정을 보다 상세하게 설명한다. The TTCP algorithm according to the present invention is as follows. Hereinafter, the TTCP algorithm and the process performed in step 304 will be described in more detail with reference to FIG. 4.

Figure 112009025918884-pat00025
Figure 112009025918884-pat00025

여기서, Ψ은 부분 사용 전송 열에 배치된 전체 주기적 메시지 집합이고, TTCP는 Ψ 내의 메시지, 즉 부분 사용 전송 열에 배치된 전체 주기적 메시지를 개별 하위 메시지 집합으로 분류한다({Ψ 1 , Ψ 2 , ,.. , Ψ m}∈ Ψ). R(x) 은 어떤 메시지 x 또는 메시지 집합 x가 전체 시스템 행렬의 크기 N R W R 내에서 필요로 하는 타임 슬롯의 개수를 표기한다. 따라서, M i 를 포함하는 Ψ( M i ∈ Ψ )에 대해서, R(M i )은 다음 식 R(M i ) = N R W R / P i 을 통해 얻을 수 있다. Here, Ψ is the entire set of periodic messages placed in the partial use transport column, and TTCP classifies the messages in Ψ, that is, the entire periodic messages arranged in the partial use transport column into individual sub-message sets ({ Ψ 1 , Ψ 2 , , .., Ψ m } ∈Ψ). R ( x ) denotes the number of time slots a message x or message set x needs within the size N R W R of the entire system matrix. Therefore, with respect to the Ψ (M i ∈ Ψ) containing M i, R (M i) can be obtained through the following formula: R (M i) = N R W R / P i.

F(x)는 메시지가 부분 사용 전송 열에 배치될 수 있는 비어있는 타임 슬롯의 개수를 나타낸다. F ( x ) represents the number of empty time slots in which a message can be placed in the partial use transport column.

도 4는 본 발명에 따른 하위 메시지 집합을 분류하는 상세 과정을 도시한 순서도이며, 도 4는 하나의 하위 메시지 집합에 속하는 주기적 메시지를 결정하는 과정을 중심으로 도시한 것이다. 4 is a flowchart illustrating a detailed process of classifying a lower message set according to the present invention, and FIG. 4 illustrates a process of determining a periodic message belonging to one lower message set.

도 4를 참조하면, 단계 302에서 부분 사용 전송 열에 포함되는 것으로 탐색된 메시지를 전송 시간에 따라 내림차순으로 정렬한다(단계 400).Referring to FIG. 4, in step 302, a message found to be included in the partial use transmission column is sorted in descending order according to the transmission time (step 400).

이후, 제1 하위 메시지 집합(Ψ 1 )을 생성하고(단계 402), 이와 함께 제1 하위 메시지 집합에 포함되는 메시지를 결정하기 위한 설정값(F(Ψ 1 )=N R )을 설정한다(단계 404).Thereafter, a first lower message set Ψ 1 is generated (step 402), and together with the setting value F ( Ψ 1 ) = N R for determining a message included in the first lower message set (step 402). Step 404).

이후, 내림차순으로 정렬에 의해 가장 전송 시간이 큰 제1 주기적 메시지의 타임 슬롯 개수와 단계 404에서의 설정값(F(Ψ 1 ))을 비교한다(단계 406).Then, the number of time slots of the first periodic message having the largest transmission time by sorting in descending order is compared with the set value F ( Ψ 1 ) in step 404 (step 406).

만일, R(x)가 설정값보다 작거나 같은 경우, 해당 주기적 메시지는 제1 하위 메시지 집합에 포함되는 것으로 결정된다(단계 408).If R ( x ) is less than or equal to the set value, it is determined that the periodic message is included in the first lower message set (step 408).

한편, 제1 주기적 메시지가 제1 하위 메시지 집합에 포함되는 것으로 결정되는 경우, 단계 404의 설정값(F(Ψ 1 ))은 N R - R(M 1 )로 갱신된다(단계 410).On the other hand, when it is determined that the first periodic message is included in the first lower message set, the set value F ( Ψ 1 ) of step 404 is updated to N R -R ( M 1 ) (step 410).

단계 410은 초기 설정값에서 제1 주기적 메시지의 타임 슬롯 개수를 차감한 값으로 설정값을 갱신하는 과정이다. 여기서 갱신된 설정값은 제1 하위 메지지 집합에 대한 잔여 슬롯 개수를 의미한다. Step 410 is a process of updating the setting value by subtracting the number of time slots of the first periodic message from the initial setting value. Herein, the updated setting value means the number of remaining slots for the first lower set of messages.

이후, 단계 410에서 갱신된 설정값이 0인지 여부를 판단하며(단계 412), 갱신된 설정값이 0이 아닌 경우, 전송 시간이 제1 주기적 메시지와 동일하거나 또는 다음 차순에 해당하는 제2 주기적 메시지에 대해 단계 406이 진행된다. Thereafter, it is determined whether the updated set value is 0 in step 410 (step 412), and if the updated set value is not 0, the second periodicity in which the transmission time is equal to the first periodic message or corresponds to the next sequence is determined. Step 406 proceeds with respect to the message.

제2 주기적 메시지의 타임 슬롯 개수가 갱신된 설정값보다 작거나 같은 경우에는 단계 408 내지 410 단계가 반복 수행된다. When the number of time slots of the second periodic message is less than or equal to the updated setting value, steps 408 to 410 are repeatedly performed.

반면 제2 주기적 메시지의 타임 슬롯 개수가 갱신된 설정값보다 큰 경우에는 단계 410으로 진행한다. On the other hand, if the number of time slots of the second periodic message is larger than the updated setting value, the flow proceeds to step 410.

여기서, 갱신된 설정값이 0이 아니면 전송 시간이 제2 주기적 메시지와 동일하거나 작은 값을 갖는 제3 주기적 메시지에 대해 단계 406이 수행되나, 갱신된 설정값이 0인 경우에는 제2 하위 메시지 집합에 대해 단계 402 내지 412 과정이 순차적으로 수행된다(단계 414). Here, if the updated set value is not 0, step 406 is performed on the third periodic message whose transmission time is equal to or less than the second periodic message, but if the updated set value is 0, the second lower message set Processes 402 to 412 are performed sequentially (step 414).

본 발명에 따른 TTCP 알고리즘은 부분 사용 전송 열에 배치된 메시지를 전송 시간에 따라 내림차순으로 정렬한 후, 두 개의 루프를 통해 전송 열에 배치될 하위 메시지 집합을 형성한다. 두 개의 루프 각각에 대한 최대 반복 횟수는 n 이므로, 본 발명에 따른 알고리즘은 O(n 2 )의 복잡도를 갖는다.The TTCP algorithm according to the present invention sorts the messages arranged in the partial use transmission column in descending order according to the transmission time, and then forms a lower message set to be placed in the transmission column through two loops. Since the maximum number of iterations for each of the two loops is n , the algorithm according to the invention has a complexity of O ( n 2 ).

한편, 본 발명에 따르면, Ψ i 내의 어떤 메시지의 전송시간이 Ψ i+1 내의 메 시지의 전송시간 보다 작게 되는 경우도 발생할 수 있다. 그 이유는 본 발명에 따른 알고리즘이 Ψ 내의 메시지들을 가능한 앞쪽의 비어있는 슬롯에 배치하려 하기 때문이다.On the other hand, according to the present invention, it may also occur if the transmission time of any message in the Ψ i is smaller than the transmission time of the message in the Ψ i + 1. The reason is that the algorithm according to the invention tries to place the messages in Ψ into the empty slot as far forward as possible.

본 발명에 따른 스케줄러는 Ψ의 내의 메시지들을 각 하위 메시지 집합으로 분류가 끝나면, 각 전송 열에 하위 메시지 집합의 메시지들을 재배치한다. 세 번째 제약사항에 따라 전송열의 크기는 동일 전송 열 내에 배치되는 메시지들 중{T j : M i Ψ i } 전송시간이 가장 큰 것 ( T max (Ψ i ) )으로 결정된다.The scheduler according to the present invention rearranges the messages in the lower message set in each transmission string after the messages in P have been classified into the lower message sets. Three heat transfer size according to the second constraint is that the message {T j being placed in the same heat transfer: M i Ψ i } the largest transmission time Is determined by ( T max ( Ψ i )).

하기에서는 표 1과 도 5 내지 도 6을 참조하여 본 발명에 따른 스케줄링 방법의 결과를 살펴본다. Hereinafter, the results of the scheduling method according to the present invention will be described with reference to Table 1 and FIGS. 5 to 6.

[표 1]은 벤치마크로써 잘 알려진 PSA 메시지 집합을 수정한 표이다. Table 1 is a modified table of the well-known PSA message set as a benchmark.

Figure 112009025918884-pat00026
Figure 112009025918884-pat00026

본래의 PSA 메시지 집합은 비조화(non-harmonic) 주기를 갖고 있으나 예시를 위해, 모든 주기적 메시지는 주기가 가장 작은 메시지의 2의 지수의 배수를 가지는 것을 하여 수정된 메시지 집합을 생성한다. The original PSA message set has a non-harmonic period, but for the sake of illustration, all periodic messages are modified so that the period has a multiple of the exponent of two of the smallest messages, producing a modified message set.

여기서 N R W R 은 주기성을 갖고, P i W R 은 조화(harmonic)관계이므로 서로 어느 하나로 나누어떨어진다. 따라서 N R W R P i 로 나누어떨어진다. 본 발명에서는 설명의 편의를 위해 N R W R 의 값을 모든 메시지 주기들의 최소공배수를 갖도록 가정하며, 이에 따라 W R 은 가장 작은 메시지의 주기에 비례한다. Here, N R W R has periodicity, and P i and W R are harmonic, so they are separated from each other. Therefore, N R W R is divided by P i . In the present invention, for the convenience of description, it is assumed that the value of N R W R has a least common multiple of all message periods, whereby W R is proportional to the period of the smallest message.

표 1과 같은 메시지 집합에 대해 RMS을 적용하면 도 5와 같은 시스템 행렬을 얻을 수 있다. Applying the RMS to the message set shown in Table 1 can obtain a system matrix as shown in FIG.

도 5의 시스템 행렬에서, 베이직 사이클의 개수는 8이며, 베이직 사이클의 크기는 10000으로 설정된다. In the system matrix of FIG. 5, the number of basic cycles is 8, and the size of the basic cycles is set to 10000.

도 5와 같이 RMS에 따른 시스템 행렬에서는 특정 베이직 사이클에서 배타 윈도우의 최대 구간이 지나치게 길게 설정될 수 있다. In the system matrix according to RMS as shown in FIG. 5, the maximum section of the exclusive window may be set too long in a specific basic cycle.

즉, 제1 베이직 사이클을 살펴보면, 배타 윈도우의 최대 구간은 9112가 되며, 이에 따라 비주기적 메시지가 버스의 사용을 요구하는 경우 최대 9112만큼의 시간 지연이 발생할 수 있는 것이다. That is, looking at the first basic cycle, the maximum interval of the exclusive window is 9112, and thus a maximum delay of 9112 may occur when an aperiodic message requires the use of a bus.

이에 대해, 본 발명에 따른 알고리즘을 적용하는 경우를 설명한다. On the other hand, the case where the algorithm according to the present invention is applied will be described.

전체 메시지 집합 M 1 내지 M 12 중 부분 사용 전송 열에 배치된 메시지는 주기가 베이직 사이클의 크기보다 큰 메시지에 해당하는 M 5 내지 M 12 이다. The messages placed in the partial use transport column of the entire message set M 1 through M 12 are M 5 through M 12 , which correspond to messages whose period is greater than the size of the basic cycle.

이들 8개의 주기적 메시지를 전송 시간에 따라 내림차순으로 정렬하면 다음과 같은 순서로 정렬된다. 하기에서 괄호안의 숫자는 각 메시지의 타임 슬롯 개수이다. When these eight periodic messages are sorted in descending order according to the transmission time, they are sorted in the following order. In the following, the number in parentheses is the number of time slots in each message.

(1) 전송 시간 968 = {M 11 (1)}(1) transmission time 968 = { M 11 (1)}

(2) 전송 시간 808 = {M 10 (2), M 9 (2), M 8 (2), M 5 (4)}(2) Transmission time 808 = { M 10 (2), M 9 (2) , M 8 (2) , M 5 (4)}

(3) 전송 시간 736 = {M 6 (4)}(3) transmission time 736 = { M 6 (4)}

(4) 전송 시간 656 = {M 7 (4)}(4) Transmission time 656 = { M 7 (4)}

(5) 전송 시간 504 = {M 12 (1)}(5) Transmission time 504 = { M 12 (1)}

상기와 같은 내림차순 정렬에 따라 하위 메시지 집합 분류 과정이 진행된다. The lower message set classification process is performed according to the descending sort as described above.

초기 설정값은 베이직 사이클의 개수인 8로 설정된다. The initial setting value is set to 8, which is the number of basic cycles.

M 11 에 대해 타임 슬롯 개수(1)는, 초기 설정값이 8보다 작으므로 M 11 은 제1 하위 메시지 집합에 속하는 것으로 결정되며, 설정값은 8-1 = 7로 갱신된다. Is the time slot number (1) for the M 11, since the initial setting value is less than 11 8 M are determined to belong to the first sub-set of messages, the set value is updated by 8-1 = 7.

이와 같은 방법으로서, M 10 내지 M 8 이 제1 하위 메시지 집합에 속하는 것으로 결정된다. As such a method, it is determined that M 10 to M 8 belong to the first lower message set.

한편, 다음 차순에 해당하는 M 5 에 대해 비교 과정을 수행하는 경우, 이미 M 8 까지의 알고리즘 수행에 의해 비어있는 잔여 슬롯(갱신된 설정값)이 1개인 반면 M 5 의 타임 슬롯 개수는 4이므로, M 5 은 제1 하위 메시지 집합에 속할 수 없다. On the other hand, when the comparison process is performed on M 5 corresponding to the next sequence, since there is already one empty remaining slot (updated set value) by the algorithm up to M 8 , the number of time slots of M 5 is 4 , M 5 may not belong to the first sub-message set.

이러한 경우, 스케줄러는 전송 시간이 다음 차순에 해당하는 메시지들 중 타임 슬롯 개수가 상기한 계산 과정에서의 잔여 슬롯 개수가 같은 메시지를 탐색하여 해당 메시지를 제1 하위 메시지 집합에 속하는 것으로 결정한다. In this case, the scheduler searches for a message whose time slot number is the same as the number of remaining slots in the calculation process among the messages whose transmission time is next, and determines that the message belongs to the first lower message set.

상기한 예에서는 타임 슬롯 개수가 1인 M 12 가 제1 하위 메시지 집합에 포함될 수 있다. In the above example, M 12 having the number of time slots 1 may be included in the first lower message set.

M 12 까지 제1 하위 메시지 집합에 포함되는 경우, 설정값이 0이 되며, 이에 따라 다음 하위 메시지 집합 분류 과정이 반복적으로 수행된다. When M 12 is included in the first lower message set, the set value becomes 0, and accordingly, the next lower message set classification process is repeatedly performed.

이러한 수행 결과를 통해 결정된 하위 메시지 집합 분류 결과는 다음과 같다. The result of sub-message set classification determined through this execution result is as follows.

(1) 제1 하위 메시지 집합(Ψ 1 ) = {M 11 , M 10 , M 9 , M 8 , M 12 }(1) first sub-message set ( Ψ 1 ) = { M 11 , M 10 , M 9 , M 8 , M 12 }

(2) 제2 하위 메시지 집합(Ψ 2 ) = {M 5 , M 6 }(2) second sub-message set ( Ψ 2 ) = { M 5 , M 6 }

(3) 제3 하위 메시지 집합(Ψ 3 ) = {M 7 }(3) third sub-message set ( Ψ 3 ) = { M 7 }

여기서, 제1 내지 제2 하위 메시지 집합에 포함된 메시지의 총 타임 슬롯 개수는 베이직 사이클 개수와 동일하다. 이처럼 본 발명은 전체 사용 전송 열 다음에 배치된 전송 열에 대해 빈 슬롯이 없는 상태로 메시지를 재배치하는 것이다. Here, the total number of time slots of the messages included in the first to second lower message sets is equal to the number of basic cycles. As such, the present invention is to rearrange the message with no empty slots for the transmission rows that are located after the total usage transmission columns.

상기한 바와 같은 하위 메시지 집합에 따라 각 주기적 메시지를 재배치하는 경우, 도 6과 같이 베이직 사이클에서 배타 윈도우의 최대 구간이 최소화된 시스템 행렬을 얻을 수 있다. When the periodic messages are rearranged according to the lower message set as described above, as shown in FIG. 6, a system matrix can be obtained in which the maximum interval of the exclusive window is minimized in the basic cycle.

본 발명에 따른 시스템 행렬에 따르면, 베이직 사이클의 배타 윈도우의 최대 구간은 전체 사용 전송 열의 전송 시간(3016)에 재배치된 전송 열의 전송 시간(T max (Ψ 1 )

Figure 112009025918884-pat00027
T 11
Figure 112009025918884-pat00028
968, T max (Ψ 2 )
Figure 112009025918884-pat00029
T 5
Figure 112009025918884-pat00030
808, T max (Ψ 3 )
Figure 112009025918884-pat00031
T 7
Figure 112009025918884-pat00032
656, 총 합은 2512)을 합한 값인 5528이 되며, 이에 따라 비주기적 메시지는 종래에 비해, 약 3584만큼 시간 지연이 감소될 수 있어 비주기적 메시지의 전송 효율이 한층 개선된다. According to the system matrix according to the present invention, the maximum interval of the exclusive window of the basic cycle is the transfer time T max ( Ψ 1 ) of the transfer sequence rearranged to the transfer time 3016 of the total use transfer sequence.
Figure 112009025918884-pat00027
T 11
Figure 112009025918884-pat00028
968, T max ( Ψ 2 )
Figure 112009025918884-pat00029
T 5
Figure 112009025918884-pat00030
808, T max ( Ψ 3 )
Figure 112009025918884-pat00031
T 7
Figure 112009025918884-pat00032
656, the total sum is 5528, which is the sum of 2512). Accordingly, the time delay of the aperiodic message can be reduced by about 3584, compared with the conventional method, thereby further improving the transmission efficiency of the aperiodic message.

상기에서는 RMS에 의한 시스템 행렬을 전제로 제2 시스템 행렬을 새로이 생성하는 것으로 설명하였으나, 이에 한정됨이 없이 베이직 사이클의 개수(또는 크기)와 각 주기적 메시지의 타임 슬롯 개수(또는 주기)를 비교하여 복수의 주기적 메시지를 하나 이상의 하위 메시지 집합으로 분류하고, 이를 이용하여 각 주기적 메시지를 소정 전송 열에 배치하는 것이 본 발명의 범주에 포함될 수 있다는 점은 당업자에게 있어 자명할 것이다. In the above description, the second system matrix is newly generated under the premise of the system matrix based on RMS. However, the present invention is not limited thereto, and the number of basic cycles is compared with the number of time slots of each periodic message. It will be apparent to those skilled in the art that categorizing the periodic messages in to one or more sub-message sets and using them to place each periodic message in a given transmission column may be included in the scope of the present invention.

상기한 본 발명의 바람직한 실시예는 예시의 목적을 위해 개시된 것이고, 본 발명에 대해 통상의 지식을 가진 당업자라면 본 발명의 사상과 범위 안에서 다양한 수정, 변경, 부가가 가능할 것이며, 이러한 수정, 변경 및 부가는 하기의 특허청구범위에 속하는 것으로 보아야 할 것이다. Preferred embodiments of the present invention described above are disclosed for purposes of illustration, and those skilled in the art will be able to make various modifications, changes, and additions within the spirit and scope of the present invention. Additions should be considered to be within the scope of the following claims.

도 1은 본 발명이 적용되는 TTCAN 베이직 사이클의 기본 구조를 도시한 도면. 1 is a view showing the basic structure of the TTCAN basic cycle to which the present invention is applied.

도 2는 본 발명에 따른 제1 시스템 행렬 및 제2 시스템 행렬을 개략적으로 도시한 도면. 2 is a schematic representation of a first system matrix and a second system matrix in accordance with the present invention;

도 3은 본 발명의 바람직한 일 실시예에 따른 스케줄러가 TTCAN 스케줄링하는 과정을 개략적으로 도시한 도면.3 is a diagram schematically illustrating a process of scheduling a TTCAN by a scheduler according to an exemplary embodiment of the present invention.

도 4는 본 발명에 따른 하위 메시지 집합을 분류하는 상세 과정을 도시한 순서도.4 is a flowchart illustrating a detailed process of classifying a lower message set according to the present invention.

도 5는 RMS에 의한 시스템 행렬을 도시한 도면. 5 shows a system matrix by RMS.

도 6은 본 발명에 따른 스케줄 알고리즘을 적용한 시스템 행렬을 도시한 도면.6 is a diagram illustrating a system matrix to which a scheduling algorithm according to the present invention is applied.

Claims (14)

TTCAN(Time-Triggered Controller Area Network) 스케줄링 방법으로서, TTCAN (Time-Triggered Controller Area Network) scheduling method, 주기적 메시지 중 요구되는 타임 슬롯 개수가 베이직 사이클(Basic cycle) 개수보다 작은 것으로 탐색된 메시지를 미리 설정된 알고리즘을 이용하여 하나 이상의 하위 메시지 집합으로 분류하는 단계; 및Classifying a message found as having a required number of time slots in a periodic message smaller than a number of basic cycles into one or more lower message sets using a predetermined algorithm; And 각 하위 메시지 집합에 포함된 메시지를 동일한 전송 열에 매핑하는 단계를 포함하되,Mapping the messages contained in each subset of messages to the same transport column, 상기 하나 이상의 하위 메시지 집합 각각은 전송 시간 및 타임 슬롯 개수에 기초하여 분류되며, Each of the one or more lower message sets is classified based on transmission time and number of time slots, 하나의 하위 메시지 집합에는 상기 탐색된 메시지 중 전송 시간이 동일하거나 또는 상기 탐색된 메시지를 전송 시간에 따라 순서대로 정렬하는 경우 서로 인접한 순서의 전송 시간을 갖는 메시지가 배치되는 TTCAN 스케줄링 방법. The TTCAN scheduling method of one of the lower message set is that the transmission time of the searched message is the same or when the searched messages are arranged in order according to the transmission time, the messages having the transmission time of the adjacent order are arranged. 삭제delete 제1항에 있어서, The method of claim 1, 상기 분류 단계는, The classification step, 상기 탐색된 메시지를 전송 시간에 따라 내림차순으로 정렬하는 단계; 및Sorting the searched messages in descending order according to a transmission time; And 상기 내림차순으로 정렬된 메시지 순으로 상기 베이직 사이클의 개수, 각 메시지의 타임 슬롯 개수 및 상기 베이직 사이클의 개수와 상기 타임 슬롯 개수에 따라 갱신되는 설정값 중 적어도 하나를 이용하여 소정 하위 메시지 집합에 속하는 메시지를 결정하는 단계를 포함하는 TTCAN 스케줄링 방법.A message belonging to a predetermined lower message set using at least one of the number of basic cycles, the number of time slots of each message, the number of basic cycles, and a setting value updated according to the number of time slots in the descending order of messages. TTCAN scheduling method comprising the step of determining. 제3항에 있어서, The method of claim 3, 상기 결정 단계는, The determining step, 제1 하위 메시지 집합을 생성하는 단계;Generating a first set of lower messages; 제1 메시지의 타임 슬롯 개수 및 설정값을 비교하는 단계-상기 설정값은 초기에 베이직 사이클 개수로 설정됨-; 및Comparing the number of time slots and a set value of the first message, wherein the set value is initially set to the number of basic cycles; And 상기 제1 메시지의 타임 슬롯 개수가 상기 설정값보다 작거나 같은 경우, 상기 제1 메시지를 상기 제1 하위 메시지 집합에 삽입하는 단계를 포함하는 TTCAN 스케줄링 방법.And inserting the first message into the first lower message set when the number of time slots of the first message is less than or equal to the set value. 제4항에서, In claim 4, 상기 결정 단계는, The determining step, 상기 제1 메시지가 상기 제1 하위 메시지 집합에 삽입되는 경우, 상기 설정값에서 제1 메시지의 타임 슬롯 개수를 차감하여 설정값을 갱신하는 단계; 및Updating the setting value by subtracting the number of time slots of the first message from the setting value when the first message is inserted into the first lower message set; And 상기 갱신된 설정값이 0이 아닌 경우, 제2 메시지의 타임 슬롯 개수와 상기 갱신된 설정값을 비교하는 단계를 더 포함하는 TTCAN 스케줄링 방법. And comparing the updated set value with the number of time slots of a second message when the updated set value is not zero. 제5항에 있어서, The method of claim 5, 상기 결정 단계는, The determining step, 상기 제2 메시지의 타임 슬롯 개수가 상기 갱신된 설정값보다 큰 경우, 소정 하위 메시지 집합에 할당되지 않은 메시지 중 타임 슬롯 개수가 상기 갱신된 설정값과 같은 메시지를 탐색하여 상기 제1 하위 메시지 집합에 삽입하는 단계를 더 포함하는 TTCAN 스케줄링 방법. When the number of time slots of the second message is larger than the updated set value, the message is searched for a message whose number of time slots is equal to the updated set value among the messages not allocated to the predetermined lower message set to the first lower message set. TTCAN scheduling method further comprising the step of inserting. 제6항에 있어서, The method of claim 6, 상기 하위 메시지 집합에 할당되지 않은 메시지 중 타임 슬롯 개수가 상기 갱신된 설정값과 같은 메시지가 복수인 경우, 전송 시간이 가장 큰 메시지가 상기 제1 하위 메시지 집합에 삽입되는 TTCAN 스케줄링 방법. And when the number of timeslots of the messages not allocated to the lower message set is the same as the updated setting value, a message having the largest transmission time is inserted into the first lower message set. 제6항에 있어서, The method of claim 6, 상기 갱신된 설정값이 0인 경우, 제2 하위 메시지 집합을 생성하고, 상기 제2 하위 메시지 집합에 삽입될 메시지를 결정하는 TTCAN 스케줄링 방법. And generating a second lower message set and determining a message to be inserted into the second lower message set when the updated set value is zero. 제1항에 있어서, The method of claim 1, 상기 분류 단계에 선행하여 비율 단조 스케줄링을 이용하여 모든 주기적 메시지에 대한 제1 시스템 행렬을 생성하는 단계를 더 포함하되, Generating a first system matrix for all periodic messages using ratio monotonic scheduling prior to the classifying step, 상기 분류 단계를 통해 상기 제1 시스템 행렬에서 부분 사용 전송 열에 포함된 메시지가 재배치되는 TTCAN 스케줄링 방법. And the message included in the partial use transmission column in the first system matrix is rearranged through the classification step. TTCAN(Time-Triggered Controller Area Network) 스케줄링 방법으로서, TTCAN (Time-Triggered Controller Area Network) scheduling method, 비율 단조 스케줄링을 이용하여 모든 주기적 메시지에 대한 제1 시스템 행렬을 생성하는 단계;Generating a first system matrix for all periodic messages using ratio monotonic scheduling; 상기 제1 시스템 행렬에서 부분 사용 전송 열을 탐색하는 단계; 및Searching for a partial use transmission column in the first system matrix; And 미리 설정된 알고리즘에 따라 상기 탐색된 전송 열에 포함된 복수의 메시지를 재배치하여 배타 윈도우의 최대 구간이 최소화된 제2 시스템 행렬을 생성하는 단계를 포함하는 TTCAN 스케줄링 방법. Relocating a plurality of messages included in the searched transmission column according to a preset algorithm to generate a second system matrix having a minimum maximum window of an exclusive window. 제10항에 있어서, The method of claim 10, 상기 제2 시스템 행렬 생성 단계는, Generating the second system matrix, 상기 탐색된 전송 열에 포함되는 복수의 메시지를 전송 시간에 따라 내림차순으로 정렬하는 단계; 및Sorting a plurality of messages included in the searched transmission column in descending order according to a transmission time; And 상기 내림차순으로 정렬된 메시지에 대해 전송 시간을 고려하여 비어 있는 슬롯이 최소화되도록 각 메시지가 속하는 하나 이상의 하위 메시지 집합을 결정하는 단계를 포함하는 TTCAN 스케줄링 방법. Determining one or more sub-message sets to which each message belongs so that empty slots are minimized in consideration of transmission time for the messages arranged in descending order. 제11항에 있어서,The method of claim 11, 상기 하나 이상의 하위 메시지 집합 각각은 상기 제2 시스템 행렬의 소정 전송 열에 대응되는 TTCAN 스케줄링 방법. And each of the one or more lower message sets corresponds to a predetermined transmission column of the second system matrix. 제11항에 있어서,The method of claim 11, 상기 결정 단계는 베이직 사이클의 개수, 각 메시지의 타임 슬롯 개수 및 상기 베이직 사이클의 개수와 상기 타임 슬롯 개수에 따라 갱신되는 설정값 중 적어도 하나를 이용하여 소정 하위 메시지 집합에 속하는 메시지를 결정하는 TTCAN 스케줄링 방법.The determining may include: TTCAN scheduling for determining a message belonging to a predetermined lower message set by using at least one of the number of basic cycles, the number of time slots of each message, and the setting value updated according to the number of basic cycles and the number of time slots. Way. 삭제delete
KR1020090037344A 2009-04-28 2009-04-28 Method for scheduling Time Triggered Controller Area Network KR101144502B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020090037344A KR101144502B1 (en) 2009-04-28 2009-04-28 Method for scheduling Time Triggered Controller Area Network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020090037344A KR101144502B1 (en) 2009-04-28 2009-04-28 Method for scheduling Time Triggered Controller Area Network

Publications (2)

Publication Number Publication Date
KR20100118475A KR20100118475A (en) 2010-11-05
KR101144502B1 true KR101144502B1 (en) 2012-05-11

Family

ID=43404779

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020090037344A KR101144502B1 (en) 2009-04-28 2009-04-28 Method for scheduling Time Triggered Controller Area Network

Country Status (1)

Country Link
KR (1) KR101144502B1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106383744B (en) * 2016-09-28 2019-11-19 北京润科通用技术有限公司 The dispatching method of periodic message and scheduling system in a kind of bus
EP3790232A1 (en) * 2019-09-09 2021-03-10 TTTech Computertechnik Aktiengesellschaft Method for generating a schedule for mixed critical computer networks

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
논문(2008. 12) *
논문(2008. 12)*

Also Published As

Publication number Publication date
KR20100118475A (en) 2010-11-05

Similar Documents

Publication Publication Date Title
US10585889B2 (en) Optimizing skewed joins in big data
Zhang et al. Minimizing makespan on a single batch processing machine with nonidentical job sizes
Lehoczky et al. The rate monotonic scheduling algorithm: Exact characterization and average case behavior
AU2010336363B2 (en) Managing queries
US10114866B2 (en) Memory-constrained aggregation using intra-operator pipelining
JP2003044296A5 (en)
CN102096599A (en) Multi-queue task scheduling method and related system and equipment
US7920282B2 (en) Job preempt set generation for resource management
CN110058940B (en) Data processing method and device in multi-thread environment
CN108509280B (en) Distributed computing cluster locality scheduling method based on push model
Moreira et al. Buffer sizing for rate-optimal single-rate data-flow scheduling revisited
CN113886034A (en) Task scheduling method, system, electronic device and storage medium
KR101144502B1 (en) Method for scheduling Time Triggered Controller Area Network
TW202044009A (en) Network device, memory system for the network device, and method for operating the network device
US9336058B2 (en) Automated scheduling management of MapReduce flow-graph applications
Nelissen et al. Response-time analysis for non-preemptive periodic moldable gang tasks
CN106020333B (en) Multi-core timer implementing method and multiple nucleus system
Zhang et al. Start time configuration for strictly periodic real-time task systems
US9887928B2 (en) System and method for identifying performance characteristics in asynchronous networks
CN112242919B (en) Fault file processing method and system
CN106484868B (en) Data reordering method and data collator based on LIMIT semanteme
Manolache Schedulability analysis of real-time systems with stochastic task execution times
Manolache Analysis and optimisation of real-time systems with stochastic behaviour
Li et al. Coordinative scheduling of computation and communication in data-parallel systems
Yan et al. QTMS: A quadratic time complexity topology-aware process mapping method for large-scale parallel applications on shared HPC system

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
FPAY Annual fee payment

Payment date: 20160418

Year of fee payment: 5

LAPS Lapse due to unpaid annual fee