KR100622943B1 - Controller for automatically controlling timing specification and the timing specification controlling method thereof - Google Patents

Controller for automatically controlling timing specification and the timing specification controlling method thereof Download PDF

Info

Publication number
KR100622943B1
KR100622943B1 KR1020050054492A KR20050054492A KR100622943B1 KR 100622943 B1 KR100622943 B1 KR 100622943B1 KR 1020050054492 A KR1020050054492 A KR 1020050054492A KR 20050054492 A KR20050054492 A KR 20050054492A KR 100622943 B1 KR100622943 B1 KR 100622943B1
Authority
KR
South Korea
Prior art keywords
control signal
edge
clock
set value
valid data
Prior art date
Application number
KR1020050054492A
Other languages
Korean (ko)
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 KR1020050054492A priority Critical patent/KR100622943B1/en
Application granted granted Critical
Publication of KR100622943B1 publication Critical patent/KR100622943B1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/42Bus transfer protocol, e.g. handshake; Synchronisation
    • G06F13/4282Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus
    • G06F13/4291Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus using a clocked protocol
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/04Generating or distributing clock signals or signals derived directly therefrom
    • G06F1/08Clock generators with changeable or programmable clock frequency

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Systems (AREA)

Abstract

자동적으로 타이밍 스펙 제어가 가능한 컨트롤러 및 그 타이밍 스펙 제어방법이 개시된다. 본 컨트롤러는 한 주기에 포함될 메인 클럭의 수인 설정값에 따라 메인 클럭을 카운팅하는 카운터, 카운터가 설정값의 절반을 카운팅하면 컨트롤 신호를 생성하는 FSM(Finite State Machine), 생성된 컨트롤 신호를 기준으로 유효 데이터 판별 에지에 따라 동기 클럭을 생성하는 동기클럭생성부, 및 생성된 컨트롤 신호를 기준으로 데이터를 생성하는 데이터생성부를 구비한다. 이에 의해, 최소의 소프트웨어적으로 제어 가능한 레지스터만을 사용하는 컨트롤러에 의해 중앙처리장치의 부담이 감소될 뿐만 아니라, 정확한 타이밍 제어에 의해 설정시간 및 보유시간에 마진을 확보하여 통신이 안정화된다.A controller capable of automatically controlling timing specifications and a method of controlling timing specifications thereof are disclosed. This controller is based on a counter that counts the main clock according to the set value, which is the number of main clocks to be included in one cycle, and a finite state machine (FSM) that generates a control signal when the counter counts half of the set value. And a data generator for generating data on the basis of the generated control signal. This not only reduces the burden on the central processing unit by the controller using the minimum software controllable registers, but also secures a margin at the setting time and holding time by accurate timing control, thereby stabilizing communication.

타이밍 스펙, setup time, hold time Timing specifications, setup time, hold time

Description

자동적으로 타이밍 스펙 제어가 가능한 컨트롤러 및 그 타이밍 스펙 제어방법{Controller for automatically controlling timing specification and the timing specification controlling method thereof}Controller for automatically controlling timing specification and the timing specification controlling method

도 1은 일반적인 I2C 버스의 통신 프로토콜에 따른 타이밍 다이아그램을 도시한 도면,1 is a timing diagram according to a communication protocol of a general I2C bus,

도 2는 본 발명의 일 실시예에 따른 I2C 버스 컨트롤러를 구비하는 전자장치의 블럭도, 2 is a block diagram of an electronic device including an I 2 C bus controller according to an embodiment of the present invention;

도 3은 본 발명의 일 실시예에 따른 I2C 버스 컨트롤러의 타이밍 다이아그램을 도시한 도면, 그리고3 is a timing diagram of an I2C bus controller according to an embodiment of the present invention; and

도 4는 본 발명의 일 실시예에 따른 I2C 버스 컨트롤러의 타이밍 스펙 제어방법의 설명에 제공되는 흐름도이다.4 is a flowchart provided to explain a timing specification control method of an I2C bus controller according to an embodiment of the present invention.

* 도면의 주요 부분에 대한 부호의 설명 *Explanation of symbols on the main parts of the drawings

100 : 메인 프로세서 200 : I2C 버스 컨트롤러100: main processor 200: I2C bus controller

210 : 주기선택레지스터 220 : 에지선택레지스터210: period selection register 220: edge selection register

230 : 카운터 240 : FSM230: Counter 240: FSM

250 : 동기클럭생성부 260 : 데이터생성부250: synchronization clock generation unit 260: data generation unit

270 : 제어부 300 : SCL270 control unit 300 SCL

350 : SDA 400 : 슬레이브 디바이스350: SDA 400: Slave Device

본 발명은 컨트롤러 및 그 타이밍 스펙(timing specification) 제어방법에 관한 것으로, 더욱 상세하게는, 동기 클럭에 맞춰 데이터 통신하는 슬레이브 장치들의 타이밍 스펙을 자동으로 조절할 수 있는 컨트롤러 및 그 타이밍 스펙 제어방법에 관한 것이다.The present invention relates to a controller and a method of controlling a timing specification thereof, and more particularly, to a controller capable of automatically adjusting timing specifications of slave devices performing data communication according to a synchronous clock and a method of controlling the timing specification thereof. will be.

일반적으로, 대부분의 시스템에서 컨트롤러는 시스템 제어를 위해 슬레이브 장치들을 구비하며, 컨트롤러와 슬레이브 장치들은 컨트롤러가 제공하는 동기 클럭에 맞춰 통신한다. 동기 클럭에 맞춰 통신하는 대료적인 예로는 I2C가 있다.In general, in most systems, the controller has slave devices for system control, and the controller and slave devices communicate with the synchronous clock provided by the controller. An alternative example of communicating on a synchronous clock is I2C.

I2C는 집적회로들 간의 통신 링크를 제공하는 두 가닥 선의 양방향 직렬 버스이며, 인터-IC(Inter-IC)라고도 불리운다. 구체적으로, I2C는 다수의 슬레이브 장치와 통신이 가능한 직렬버스 프로토콜로서, 다수의 슬레이브 장치를 전원선과 두 가닥의 선(SCL, SDA)만으로 제어가 가능하다. SCL(Serial Clock Line)은 클럭 전송을 위한 라인이고, SDA(Serial DAta line)는 데이터를 직렬로 전송하기 위한 라인으로 클럭에 따라 한 비트씩 데이터 라인에 데이터가 송수신된다. 그러므로, 슬레이브 장치와의 안정적인 통신을 위해서는 클럭과 데이터 간의 타이밍 스펙을 제어하는 것이 중요시 된다.I2C is a two-wire, bi-directional serial bus that provides a communication link between integrated circuits, also called Inter-IC. Specifically, I2C is a serial bus protocol capable of communicating with a plurality of slave devices, and can control a plurality of slave devices using only a power line and two lines SCL and SDA. The SCL (Serial Clock Line) is a line for clock transmission, and the SDA (Serial DAta line) is a line for transmitting data serially. Data is transmitted and received on the data line by one bit according to the clock. Therefore, it is important to control the timing specifications between the clock and the data for stable communication with the slave device.

도 1은 일반적인 I2C 버스의 통신 프로토콜에 따른 타이밍 다이아그램을 도 시한 도면이다. 1 illustrates a timing diagram according to a communication protocol of a general I2C bus.

도 1를 참조하면, SCL이 로우일때만 SDA의 상태가 바뀐다. 따라서, SCL이 하이인 구간에서만 유효한 데이터이다. 이러한 I2C 프로토콜의 타이밍 스펙을 만족시키기 위해서는 시작조건의 보유시간인 tHD:STA, 데이터 보유시간인 tHD:DAT, 시작조건의 설정시간인 tSU;STA, 데이터 설정시간인 tSU;DAT 등과 같은 타이밍 파라미터들의 제어가 요구된다.Referring to FIG. 1, the state of SDA is changed only when SCL is low. Therefore, the data is valid only in a section where SCL is high. In order to satisfy the timing specification of the I2C protocol, t HD: STA , which is a start time, t HD: DAT , which is a data retention time, t SU; STA , a time when the start condition is set, t SU; DAT , a data setting time, etc. Control of the same timing parameters is required.

그런데, 종래의 타이밍 스펙 제어방법은 타이밍 스펙을 제어하기 위해 전용의 컨트롤러를 구비하거나 소프트웨어적으로 제어하는 방법을 이용하였다.However, the conventional timing spec control method uses a method of providing a dedicated controller or controlling in software to control the timing spec.

전용의 컨트롤러를 이용하여 타이밍 스펙을 제어하는 방법은 정확한 프로토콜과 타이밍 스펙을 구현하기 위해 타이밍 파라미터들을 제어하기 위한 타이밍 파라미터 수만큼의 소프트웨어적으로 제어 가능한 레지스터를 필요로 했다. The method of controlling timing specifications using a dedicated controller required a software controllable register as many as timing parameters to control timing parameters in order to implement accurate protocols and timing specifications.

그리고, 소프웨어적으로 타이밍 스펙을 제어하는 방법은 중앙처리장치의 IO 포트를 통해 제어하며, 중앙처리장치를 통한 일정 시간간격의 제어 방식을 소프트웨어적으로 함수화하는 방식으로 구현하였다.In addition, the method of controlling the timing specifications in software is controlled through the IO port of the central processing unit, and implemented as a method of functionalizing the control method of a predetermined time interval through the central processing unit in software.

따라서, 전용 컨트롤러는 설계에 있어 상당수의 레지스터에 의해 복잡성을 가지게 될 뿐만 아니라 소프트웨어적인 관리 사항 또한 늘어나게 된다. 그리고, IO 포트를 통한 소프트웨어적인 제어 방법은 중앙처리장치의 부담을 증가시키게 되며, 정확한 타이밍 제어가 불가능하므로 타이밍 손실을 초래하게 되어 데이터 깨짐을 유발하는 문제점이 발생할 수 있다.Thus, a dedicated controller is not only complicated by a large number of registers in the design, but also an increase in software management. In addition, the software control method through the IO port increases the burden on the central processing unit, and since accurate timing control is impossible, a loss of timing may occur, which may cause data corruption.

따라서, 본 발명의 목적은, 중앙처리장치에 부담을 주는 소프트웨어적인 제어 방법을 회피하기 위한 전용 컨트롤러를 설계하되, 각각의 파라미터에 대한 별도의 소프트웨어의 제어 없이 자동적으로 타이밍 스펙 제어가 가능한 컨트롤러 및 그 타이밍 스펙 제어방법을 제공함에 있다.Accordingly, an object of the present invention is to design a dedicated controller for avoiding a software control method that burdens the central processing unit, but a controller capable of automatically controlling timing specifications without separate software control for each parameter. To provide a timing specification control method.

상기 목적을 달성하기 위한 본 발명에 따른 컨트롤러는, 한 주기에 포함될 메인 클럭의 수인 설정값에 따라 상기 메인 클럭을 카운팅하는 카운터, 상기 카운터가 상기 설정값의 절반을 카운팅하면 컨트롤 신호를 생성하는 FSM(Finite State Machine), 상기 생성된 컨트롤 신호를 기준으로 유효 데이터 판별 에지에 따라 동기 클럭을 생성하는 동기클럭생성부, 및 상기 생성된 컨트롤 신호를 기준으로 데이터를 생성하는 데이터생성부를 포함한다.A controller according to the present invention for achieving the above object is a counter for counting the main clock according to a set value which is the number of main clocks to be included in one period, FSM for generating a control signal when the counter counts half of the set value (Finite State Machine), a synchronization clock generation unit for generating a synchronization clock according to the valid data determination edge based on the generated control signal, and a data generation unit for generating data based on the generated control signal.

또한, 상기 설정값이 저장되는 주기선택레지스터, 및 상기 유효 데이터 판별 에지가 저장되는 에지선택레지스터를 더 포함하는 것이 바람직하다.The apparatus may further include a period selection register in which the set value is stored, and an edge selection register in which the valid data determination edge is stored.

그리고, 상기 동기클럭생성부는, 상기 유효 데이터 판별 에지가 상승 에지이면 상기 컨트롤 신호 생성 시점까지 상기 동기 클럭을 생성하고, 상기 유효 데이터 판별 에지가 하강 에지이면 상기 컨트롤 신호 생성 시점 후부터 상기 동기 클럭을 생성하는 것이 바람직하다.The sync clock generator generates the sync clock until the control signal generation point when the valid data determination edge is a rising edge, and generates the sync clock after the control signal generation time when the valid data determination edge is a falling edge. It is desirable to.

한편, 본 발명의 컨트롤러의 타이밍 스펙 제어방법은, 한 주기에 포함될 메인 클럭의 수인 설정값에 따라 상기 메인 클럭을 카운팅하는 단계, 상기 설정값의 절반을 카운팅하면 컨트롤 신호를 생성하는 단계, 상기 생성된 컨트롤 신호를 기준으로 유효 데이터 판별 에지에 따라 동기 클럭을 생성하는 단계, 및 상기 생성된 컨트롤 신호를 기준으로 데이터를 생성하는 단계를 포함한다.On the other hand, the timing specification control method of the controller of the present invention, the step of counting the main clock according to the set value which is the number of the main clock to be included in one period, generating a control signal when counting half of the set value, the generation Generating a synchronous clock according to the valid data determination edge based on the generated control signal, and generating data based on the generated control signal.

그리고, 상기 동기 클럭을 생성하는 단계는, 상기 유효 데이터 판별 에지가 상승 에지이면 상기 컨트롤 신호 생성 시점까지 상기 동기 클럭을 생성하고, 상기 유효 데이터 판별 에지가 하강 에지이면 상기 컨트롤 신호 생성 시점 후부터 상기 동기 클럭을 생성하는 것이 바람직하다.The generating of the synchronization clock may include generating the synchronization clock until the control signal generation time when the valid data determination edge is a rising edge, and generating the synchronization clock after the control signal generation time when the valid data determination edge is a falling edge. It is desirable to generate a clock.

이하에서는 도면을 참조하여 본 발명을 상세하게 설명한다.Hereinafter, with reference to the drawings will be described in detail the present invention.

도 2는 본 발명의 일 실시예에 따른 I2C 버스 컨트롤러를 구비하는 전자장치의 블럭도이다.2 is a block diagram of an electronic device including an I 2 C bus controller according to an embodiment of the present invention.

전자장치는 메인 프로세서(100), I2C 버스 컨트롤러(200), SCL(300), SDA(350), 및 슬레이브 디바이스(400)를 구비하며, 메인 프로세서(100)는 I2C 버스 컨트롤러(200)를 이용해 SCL(Serial Control Line)(300), SDA(Serial DAta line)(350)를 통해 슬레이브 디바이스(400)와 통신한다.The electronic device includes a main processor 100, an I2C bus controller 200, an SCL 300, an SDA 350, and a slave device 400. The main processor 100 uses the I2C bus controller 200. It communicates with the slave device 400 through a serial control line (SCL) 300 and a serial data line (SDA) 350.

본 I2C 버스 컨트롤러(200)는 동기 클럭과 데이터를 가지고 슬레이브 디바이스(400)와 통신함에 있어서 최소의 소프트웨어적으로 제어 가능한 레지스터만을 사용하여 동기 클럭을 기준으로 통신함으로써 자동적으로 동기 클럭과 데이터 간의 타이밍 스펙을 제어하는 컨트롤러의 일 예이다.The I2C bus controller 200 automatically communicates with the slave device 400 with the synchronization clock and data, and uses only the minimum software controllable registers to communicate based on the synchronization clock. An example of a controller that controls the.

도 2를 참조하면, 본 I2C 버스 컨트롤러(200)는 주기선택레지스터(210), 에지선택레지스터(220), 카운터(230), FSM(240), 동기클럭생성부(250), 데이터생성부 (260), 및 제어부(270)를 포함한다.Referring to FIG. 2, the I2C bus controller 200 includes a period select register 210, an edge select register 220, a counter 230, an FSM 240, a synchronous clock generator 250, and a data generator ( 260, and a controller 270.

메인 프로세서(100)는 메인 클럭 펄스를 발생시킨다.The main processor 100 generates a main clock pulse.

주기선택레지스터(210)에는 메인 클럭 펄스의 한 주기에 대한 설정값이 저장된다. 설정값은 한 주기에 포함될 메인 클럭 펄스의 수를 나타낸다.The period selection register 210 stores a setting value for one period of the main clock pulse. The set value represents the number of main clock pulses to be included in one period.

에지선택레지스터(220)에는 유효한 데이터을 판별하기 위한 시점을 설정하기 위한 동기 클럭의 에지(이하에서는 '유효 데이터 판별 에지'라 함)가 저장된다. The edge selection register 220 stores an edge of a synchronous clock (hereinafter referred to as 'valid data determination edge') for setting a time point for determining valid data.

카운터(230)는 주기선택레지스터(210)에 저장된 설정값 만큼씩 메인 클럭 펄스를 카운팅한다. The counter 230 counts the main clock pulses by the set value stored in the period selection register 210.

FSM(Finite State Machine)(240)는 카운터(230)가 반 주기 즉, 설정값의 반 값을 카운팅하면 기준신호인 컨트롤 신호를 생성한다. 컨트롤 신호는 동기 클럭의 생성 및 데이터 변화의 기준이 되는 신호이다.The finite state machine (FSM) 240 generates a control signal that is a reference signal when the counter 230 counts a half cycle, that is, a half value of the set value. The control signal is a signal that is a reference for generation of a synchronous clock and data change.

동기클럭생성부(250)는 FSM(240)이 생성한 컨트롤 신호를 기준으로 동기 클럭을 생성하여 SCL(300)에 인가한다. 구체적으로, 동기클럭생성부(250)는 에지선택레지스터(220)에 유효 데이터 판별 에지로 상승 에지가 저장되어 있으면 컨트롤 신호의 생성 종료시 동기 클럭의 생성을 종료한다. 반면에, 동기클럭생성부(250)는 에지선택레지스터(220)에 유효 데이터 판별 에지로 하강 에지가 저장되어 있으면 컨트롤 신호의 생성 종료시 동기 클럭을 생성한다.The sync clock generator 250 generates a sync clock based on the control signal generated by the FSM 240 and applies the sync clock to the SCL 300. Specifically, if the rising edge is stored as the valid data determination edge in the edge selection register 220, the synchronization clock generation unit 250 ends the generation of the synchronization clock at the end of generation of the control signal. On the other hand, if the falling edge is stored as the valid data determination edge in the edge selection register 220, the synchronization clock generator 250 generates a synchronization clock at the end of generation of the control signal.

데이터생성부(260)는 컨트롤 신호가 생성된 시점에 데이터가 변화하도록 생성하여 SDA(350)에 인가한다. The data generator 260 generates the data to change at the time when the control signal is generated and applies the data to the SDA 350.

이에 따라, 데이터생성부(260)는 에지선택레지스터(220)에 유효 데이터 판별 에지로 상승 에지(rising edge)가 저장되어 있으면, 동기 클럭의 하강 에지(falling edge)에 해당하는 시점에 데이터를 변화한다. 반면, 에지선택레지스터(220)에 유효 데이터 판별 에지로 하강 에지가 저장되어 있으면, 데이터생성부(260)는 동기 클럭의 상승 에지에 해당하는 시점에 데이터를 변화한다. Accordingly, when the rising edge is stored as the valid data determination edge in the edge selection register 220, the data generator 260 changes the data at a time corresponding to the falling edge of the synchronous clock. do. On the other hand, if the falling edge is stored as the valid data determination edge in the edge selection register 220, the data generator 260 changes the data at the time corresponding to the rising edge of the synchronization clock.

제어부(270)는 I2C 버스 컨트롤러(200)의 기능제어 및 메인 프로세서(100)와의 인터페이스를 담당한다. 그리고, 제어부(270)는 소정의 설정값 및 유효 데이터 판별 에지를 설정한다.The controller 270 is responsible for the function control of the I2C bus controller 200 and the interface with the main processor 100. The control unit 270 sets a predetermined set value and valid data determination edge.

슬레이브 디바이스(400)는 SCL(300)을 통해 인가된 동기 클럭을 기준으로 동작하고, 제어부(270)에 의해 설정된 유효 데이터 판별 에지에 따라 SDA(350)을 통해 인가된 데이터 중 유효 데이터를 판별한다. 동기 클럭의 상승 에지가 유효 데이터 판별 에지로 설정될 경우, 슬레이브 디바이스(400)는 동기 클럭의 상승 에지에 해당하는 데이터를 유효한 값으로 판별한다. 동기 클럭의 하강 에지가 유효 데이터 판별 에지로 설정될 경우, 슬레이브 디바이스(400)는 동기 클럭의 하강 에지에 해당하는 데이터를 유효한 값으로 판별한다.The slave device 400 operates on the basis of the synchronous clock applied through the SCL 300 and determines valid data among data applied through the SDA 350 according to the valid data determination edge set by the controller 270. . When the rising edge of the synchronous clock is set to the valid data determination edge, the slave device 400 determines the data corresponding to the rising edge of the synchronous clock as a valid value. When the falling edge of the synchronous clock is set to the valid data determination edge, the slave device 400 determines the data corresponding to the falling edge of the synchronous clock as a valid value.

도 3은 본 발명의 일 실시예에 따른 I2C 버스 컨트롤러의 타이밍 다이아그램을 도시한 도면이다.3 is a timing diagram of an I2C bus controller according to an embodiment of the present invention.

도 3에 도시된 바와 같이, 유효 데이터 판별 에지가 동기 클럭의 상승 에지로 동기 클럭의 상승 에지에 해당하는 데이터가 유효한 데이터이고, 동기 클럭의 하강 에지에서 데이터의 변화가 발생하는 경우의 타이밍 다이아그램을 나타낸다.As shown in Fig. 3, a timing diagram when the valid data determination edge is the rising edge of the synchronous clock and the data corresponding to the rising edge of the synchronous clock are valid data, and a change in data occurs on the falling edge of the synchronous clock. Indicates.

(a)메인 클럭은 메인 프로세서(100)에 의해 발생되는 신호이다. (a) The main clock is a signal generated by the main processor 100.

(b)Counter_A는 카운터(230)가 설정값 만큼씩 (a)메인 클럭을 카운팅하여 출력한 신호이다. 이때, 일 예로 설정값은 20이다. 카운터(230)는 0에서 19까지 20씩 (a)메인 클럭을 카운팅하여 (b)Counter_A를 출력한다.(b) Counter_A is a signal output by counting the main clock by the counter 230 by the set value. At this time, for example, the set value is 20. The counter 230 counts (a) the main clock by 20 from 0 to 19 and outputs (b) Counter_A.

(c)Control_A는 FSM(240)가 생성한 신호이다. FSM(240)는 카운터(230)가 설정값의 반 값 즉, 0에서 9까지 10을 카운팅하는 순간 기준신호인 (c)Control_A를 생성한다.(c) Control_A is a signal generated by the FSM 240. The FSM 240 generates the reference signal (c) Control_A at the moment when the counter 230 counts half of the set value, that is, 10 from 0 to 9.

(d)동기 클럭은 동기클럭생성부(250)가 생성한 신호이다. 동기클럭생성부(250)는 (c)Control_A의 종료 전까지 즉, 카운터(230)가 설정값의 반 값 10을 카운팅하는 동안 (d)동기 클럭을 출력한다.(d) The synchronous clock is a signal generated by the synchronous clock generator 250. The sync clock generator 250 outputs the sync clock (d) until (c) the end of Control_A, that is, while the counter 230 counts the half value 10 of the set value.

(e)데이터는 데이터생성부(260)가 생성한 신호이다. 데이터생성부(260)는 (c)Control_A를 기준으로 (d)동기 클럭의 하강 에지에 해당하는 시점에 (e)데이터를 변화시킨다. (e) The data is a signal generated by the data generator 260. The data generator 260 changes (e) the data at the time corresponding to the falling edge of the (d) synchronous clock based on (c) Control_A.

마찬가지로, 동기 클럭의 하강 에지에 해당하는 데이터가 유효한 데이터이고, 동기 클럭의 상승 에지에서 데이터의 변화가 발생하는 경우에도 설정값이 20이면 도 3에 도시된 (a)메인 클럭, (b)Counter_A, (c)Control_A, (e)데이터와 동일하다. 동기 클럭만 (c)Control_A을 기준으로 (c)Control_A의 종료시부터 생성된다. 즉, 도 3에서 (d)동기 클럭이 오른쪽으로 10만큼 이동된다. Similarly, if the data corresponding to the falling edge of the synchronous clock is valid data and a change in data occurs on the rising edge of the synchronous clock, if the set value is 20, (a) main clock and (b) Counter_A shown in FIG. Same as (c) Control_A, (e) data. Only the synchronous clock is generated from the end of (c) Control_A based on (c) Control_A. That is, in FIG. 3, (d) the synchronous clock is shifted by 10 to the right.

이로 인해, 자동적으로 타이밍 스펙이 제어되어 설정시간 스펙(Setup time Spec.) 및 보유시간 스펙(Hold time Spec.)을 만족하고도 설정시간에 대한 마진 및 보유시간에 대한 마진의 확보가 가능하다.As a result, timing specifications are automatically controlled to ensure a margin for the setup time and a margin for the retention time while satisfying the setup time specification and the hold time specification.

도 4는 본 발명의 일 실시예에 따른 I2C 버스 컨트롤러의 타이밍 스펙 제어방법의 설명에 제공되는 흐름도이다.4 is a flowchart provided to explain a timing specification control method of an I2C bus controller according to an embodiment of the present invention.

도 4를 참조하면, 제어부(270)는 설정값 및 유효 데이터 판별 에지를 설정한다(S400). 제어부(270)는 설정한 설정값을 주기선택레지스터(210)에, 유효 데이터 판별 에지를 에지선택레지스터(220)에 저장한다.Referring to FIG. 4, the controller 270 sets a set value and valid data determination edge (S400). The control unit 270 stores the set value in the period selection register 210 and the valid data determination edge in the edge selection register 220.

카운터(230)는 설정값에 따라 메인 프로세서(100)에 의해 발생된 메인 클럭을 카운팅한다(S410).The counter 230 counts the main clock generated by the main processor 100 according to the set value (S410).

FSM(240)은 카운터(230)에 의해 카운팅된 값이 설정값의 절반인지 여부를 판단한다(S420). The FSM 240 determines whether the value counted by the counter 230 is half of the set value (S420).

카운팅된 값이 설정값의 절반인 것으로 판단되면, FSM(240)은 컨트롤 신호를 생성한다(S430).If it is determined that the counted value is half of the set value, the FSM 240 generates a control signal (S430).

동기클럭생성부(250)은 생성된 컨트롤 신호를 기준으로 유효 데이터 판별 에지에 따라 동기 클럭을 생성하고, 데이터생성부(260)는 생성된 컨트롤 신호를 기준으로 데이터를 생성한다(S440). The sync clock generator 250 generates a sync clock according to the valid data determination edge based on the generated control signal, and the data generator 260 generates data based on the generated control signal (S440).

이상 설명한 바와 같이, 본 발명에 따르면, 최소의 소프트웨어적으로 제어 가능한 레지스터만을 사용하는 컨트롤러에 의해 중앙처리장치의 부담이 감소된다. 또한, 정확한 타이밍 제어에 의해 설정시간 및 보유시간에 마진을 확보하여 통신이 안정화된다.As described above, according to the present invention, the burden on the central processing unit is reduced by the controller using only the minimum software controllable registers. In addition, accurate timing control ensures a margin at the set time and the hold time, thereby stabilizing communication.

또한, 이상에서는 본 발명의 바람직한 실시예에 대하여 도시하고 설명하였지 만, 본 발명은 상술한 특정의 실시예에 한정되지 아니하며, 청구범위에서 청구하는 본 발명의 요지를 벗어남이 없이 당해 발명이 속하는 기술분야에서 통상의 지식을 가진자에 의해 다양한 변형실시가 가능한 것은 물론이고, 이러한 변형실시들은 본 발명의 기술적 사상이나 전망으로부터 이해되어져서는 안 될 것이다.In addition, while the above has been shown and described with respect to preferred embodiments of the present invention, the present invention is not limited to the specific embodiments described above, the technology to which the invention belongs without departing from the spirit of the invention claimed in the claims Various modifications can be made by those skilled in the art, and these modifications should not be understood from the technical idea or the prospect of the present invention.

Claims (5)

한 주기에 포함될 메인 클럭의 수인 설정값에 따라 상기 메인 클럭을 카운팅하는 카운터;A counter for counting the main clock according to a set value, the number of main clocks to be included in one period; 상기 카운터가 상기 설정값의 절반을 카운팅하면 컨트롤 신호를 생성하는 FSM(Finite State Machine);A finite state machine (FSM) which generates a control signal when the counter counts half of the set value; 상기 생성된 컨트롤 신호를 기준으로 유효 데이터 판별 에지에 따라 동기 클럭을 생성하는 동기클럭생성부; 및A synchronization clock generation unit configured to generate a synchronization clock according to a valid data determination edge based on the generated control signal; And 상기 생성된 컨트롤 신호를 기준으로 데이터를 생성하는 데이터생성부;를 포함하는 것을 특징으로 하는 컨트롤러.And a data generator configured to generate data based on the generated control signal. 제 1항에 있어서,The method of claim 1, 상기 설정값이 저장되는 주기선택레지스터; 및A period selection register for storing the set value; And 상기 유효 데이터 판별 에지가 저장되는 에지선택레지스터;를 더 포함하는 것을 특징으로 하는 컨트롤러.And an edge selection register at which the valid data determination edge is stored. 제 1항에 있어서, The method of claim 1, 상기 동기클럭생성부는,The synchronous clock generation unit, 상기 유효 데이터 판별 에지가 상승 에지이면 상기 컨트롤 신호 생성 시점까지 상기 동기 클럭을 생성하고,If the valid data determination edge is a rising edge, the synchronous clock is generated until the control signal generation point; 상기 유효 데이터 판별 에지가 하강 에지이면 상기 컨트롤 신호 생성 시점 후부터 상기 동기 클럭을 생성하는 것을 특징으로 하는 컨트롤러.And if the valid data determination edge is a falling edge, generating the synchronous clock after the control signal generation point. 한 주기에 포함될 메인 클럭의 수인 설정값에 따라 상기 메인 클럭을 카운팅하는 단계;Counting the main clock according to a set value which is a number of main clocks to be included in one period; 상기 설정값의 절반을 카운팅하면 컨트롤 신호를 생성하는 단계;Generating a control signal when counting half of the set value; 상기 생성된 컨트롤 신호를 기준으로 유효 데이터 판별 에지에 따라 동기 클럭을 생성하는 단계; 및Generating a synchronous clock according to a valid data determination edge based on the generated control signal; And 상기 생성된 컨트롤 신호를 기준으로 데이터를 생성하는 단계;를 포함하는 것을 특징으로 하는 컨트롤러의 타이밍 스펙 제어방법.And generating data on the basis of the generated control signal. 제 4항에 있어서,The method of claim 4, wherein 상기 동기 클럭을 생성하는 단계는,Generating the synchronous clock, 상기 유효 데이터 판별 에지가 상승 에지이면 상기 컨트롤 신호 생성 시점까지 상기 동기 클럭을 생성하고,If the valid data determination edge is a rising edge, the synchronous clock is generated until the control signal generation point; 상기 유효 데이터 판별 에지가 하강 에지이면 상기 컨트롤 신호 생성 시점 후부터 상기 동기 클럭을 생성하는 것을 특징으로 하는 컨트롤러의 타이밍 스펙 제어방법.And generating the synchronous clock after the control signal generation time point when the valid data determination edge is a falling edge.
KR1020050054492A 2005-06-23 2005-06-23 Controller for automatically controlling timing specification and the timing specification controlling method thereof KR100622943B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020050054492A KR100622943B1 (en) 2005-06-23 2005-06-23 Controller for automatically controlling timing specification and the timing specification controlling method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020050054492A KR100622943B1 (en) 2005-06-23 2005-06-23 Controller for automatically controlling timing specification and the timing specification controlling method thereof

Publications (1)

Publication Number Publication Date
KR100622943B1 true KR100622943B1 (en) 2006-09-13

Family

ID=37624697

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020050054492A KR100622943B1 (en) 2005-06-23 2005-06-23 Controller for automatically controlling timing specification and the timing specification controlling method thereof

Country Status (1)

Country Link
KR (1) KR100622943B1 (en)

Similar Documents

Publication Publication Date Title
KR101086426B1 (en) Apparatus and method for controlling the timing of data transition of serial data line in I2C controller
EP2147361B1 (en) Usb based synchronization and timing system
US10129012B2 (en) Tuning circuitry and operations for non-source-synchronous systems
CN101089838A (en) Method for implementing 12C read-write sequence
EP2005308A2 (en) Method and system for i2c clock generation
TW201702894A (en) Independent UART BRK detection
EP1972058B1 (en) Serial data communication system and method
US10977206B2 (en) Data communication device and method for data communication
CN109240130B (en) Programmable pin level control circuit
US20180083800A1 (en) Aggregation Device, System, And Method Thereof
KR100622943B1 (en) Controller for automatically controlling timing specification and the timing specification controlling method thereof
JP2002252606A (en) Synchronization correction circuit
CN102298416A (en) Server system
CN106294260B (en) The method that data are output to synchronous bus from asynchronous bus
JP4190217B2 (en) Clock generation apparatus and audio data processing apparatus
CN111077941B (en) Clock synchronization setting method, device and storage medium
JP5147286B2 (en) Communication device
TW201702895A (en) UART with line activity detector
TWI432940B (en) Timing adjusting module, two line transmission system and timing adjusting method
JP2009272964A (en) Communication system, host, client, phone body of cellular phone, battery and communication method
KR100455340B1 (en) Synchronized signal generation circuit
KR100244682B1 (en) Synchronizing device of system for controlling multiple motor of robot
JP5315882B2 (en) Semiconductor device and communication method
JP2004247856A (en) Data receiving apparatus and data transmission/ reception method
US9129666B1 (en) Robust commands for timing calibration or recalibration

Legal Events

Date Code Title Description
A201 Request for examination
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
LAPS Lapse due to unpaid annual fee