KR100505600B1 - Programmable microcontroller including a serial interface circuit and data writing/reading method thereof - Google Patents

Programmable microcontroller including a serial interface circuit and data writing/reading method thereof Download PDF

Info

Publication number
KR100505600B1
KR100505600B1 KR1019980013118A KR19980013118A KR100505600B1 KR 100505600 B1 KR100505600 B1 KR 100505600B1 KR 1019980013118 A KR1019980013118 A KR 1019980013118A KR 19980013118 A KR19980013118 A KR 19980013118A KR 100505600 B1 KR100505600 B1 KR 100505600B1
Authority
KR
South Korea
Prior art keywords
data
address
memory unit
clock
output
Prior art date
Application number
KR1019980013118A
Other languages
Korean (ko)
Other versions
KR19990080113A (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 KR1019980013118A priority Critical patent/KR100505600B1/en
Publication of KR19990080113A publication Critical patent/KR19990080113A/en
Application granted granted Critical
Publication of KR100505600B1 publication Critical patent/KR100505600B1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/30181Instruction operation extension or modification
    • G06F9/30189Instruction operation extension or modification according to execution mode, e.g. mode flag
    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C7/00Arrangements for writing information into, or reading information out from, a digital store
    • G11C7/10Input/output [I/O] data interface arrangements, e.g. I/O data control circuits, I/O data buffers
    • G11C7/1015Read-write modes for single port memories, i.e. having either a random port or a serial port
    • G11C7/1036Read-write modes for single port memories, i.e. having either a random port or a serial port using data shift registers

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Microcomputers (AREA)

Abstract

기입 및 독출동작시 필요한 핀수를 감소시킬 수 있는 프로그래머블 마이크로 콘트롤러와 이의 데이터 기입방법 및 데이터 독출방법이 개시된다. 상기 데이터 기입방법 및 데이터 독출방법을 수행하는 상기 프로그래머블 마이크로 콘트롤러는, 기입동작시 외부에서 입출력핀을 통해 인가되는 시어리얼 데이터를 클락핀을 통해 인가되는 쉬프트 클락에 동기시켜 시어리얼하게 수신하여 패러렐하게 상기 메모리부에 전달하고, 독출동작시 상기 메모리부로부터 패러렐하게 전달되는 데이터를 상기 쉬프트 클락에 동기시켜 상기 입출력핀을 통해 시어리얼하게 외부로 송신하는 시어리얼 인터페이스 회로를 구비하는 것을 특징으로한다. 따라서 상기 프로그래머블 마이크로 콘트롤러는, 상기 시어리얼 인터페이스 회로를 구비함으로써 기입 및 독출동작시 하나의 데이터 입출력핀과 하나의 클락핀만이 필요하므로 핀수가 감소된다. Disclosed are a programmable microcontroller capable of reducing the number of pins required during write and read operations, a data writing method thereof, and a data reading method thereof. The programmable microcontroller, which performs the data writing method and the data reading method, serially receives and serially receives serial data applied through an input / output pin externally in synchronization with a shift clock applied through a clock pin during a write operation. And a serial interface circuit configured to transmit the data transferred to the memory unit and parallelly transmitted from the memory unit during a read operation to the outside through the input / output pin in synchronization with the shift clock. Therefore, the programmable microcontroller includes the serial interface circuit, so that only one data input / output pin and one clock pin are required for write and read operations, thereby reducing the number of pins.

Description

시어리얼 인터페이스 회로를 구비하는 프로그래머블 마이크로 콘트롤러와 이의 데이터 기입 및 독출방법{Programmable microcontroller including a serial interface circuit and data writing/reading method thereof}Programmable microcontroller including a serial interface circuit and data writing / reading method

본 발명은 프로그래머블 마이크로 콘트롤러(Programmable Microcontroller)에 관한 것으로, 특히 시어리얼 인터페이스(Serial Interface) 회로를 구비하는 프로그래머블(Programmable) 마이크로 콘트롤러와 이의 데이터 기입 및 독출방법에 관한 것이다.The present invention relates to a programmable microcontroller, and more particularly, to a programmable microcontroller having a serial interface circuit and a method of writing and reading data thereof.

마이크로 콘트롤러에는 마스크롬 형(Mask ROM Type) 마이크로 콘트롤러와 프로그래머블 형 마이크로 콘트롤러가 있다. 마스크롬 형 마이크로 콘트롤러는 응용 프로그램이 코드화되어 내장되는 롬이 마스크롬 형으로서 주로 대량생산을 목적으로 사용된다. 반면에 프로그래머블 마이크로 콘트롤러는 내장 롬으로 OTP(One Time Programmable) 형의 EPROM이나 MTP(Multiple Time Programmable) 형의 EEPROM 또는 플래쉬(Flash) 롬을 사용한다. 따라서 응용 프로그램 개발시 프로그래머블 마이크로 콘트롤러를 사용하면 응용 프로그램의 코드를 충분히 검증할 수 있는 장점이 있으며 또한 소규모 물량의 씨스템을 생산하고자 할 경우 프로그래머블 마이크로 콘트롤러를 사용하면 원가가 다소 높아지는 단점이 있지만 빠른 시간에 생산이 가능하다는 장점이 있다.Microcontrollers include Mask ROM Type microcontrollers and Programmable microcontrollers. The mask ROM type microcontroller is a ROM ROM type in which an application program is coded and embedded, and is mainly used for mass production. Programmable microcontrollers, on the other hand, use either an OTP (One Time Programmable) type EPROM, MTP (Multiple Time Programmable) type EEPROM or Flash ROM. Therefore, the use of a programmable microcontroller in the development of an application has the advantage of sufficiently verifying the code of the application. In addition, the cost of using a programmable microcontroller is slightly higher if you want to produce a small quantity of systems. The advantage is that production is possible.

특히 프로그래머블 마이크로 콘트롤러에서는 응용 프로그램의 코드를 내장 롬에 기입하기 위해 어드레스와 데이터가 다수개의 핀들을 통해 병렬로 동시에 인가되는 패러렐 인터페이스(Parallel Interface) 방법이 사용된다. 그런데 패러렐 인터페이스 방법이 사용되는 프로그래머블 마이크로 콘트롤러에서는 다수개의 어드레스 핀들, 데이터 핀들, 및 제어핀들이 필요하므로 핀수가 증가되는 단점이 있으며 이에 따라 대략 30핀 이하의 패키지에는 사용되기 어렵다. 또한 프로그래머블 마이크로 콘트롤러들이 동일한 핀수의 패키지를 갖더라도, 즉 정상모드에서는 핀수가 동일하더라도 프로그램 모드에서는 내장 롬의 용량에 따라 어드레스 핀, 데이터 핀, 및 제어핀의 수가 다르고 또한 핀의 위치가 다르므로, 프로그램용 소켓이 공용되기 어려운 단점이 있다. In particular, in a programmable microcontroller, a parallel interface method is used in which an address and data are simultaneously applied in parallel through a plurality of pins to write an application program code to an embedded ROM. However, the programmable microcontroller using the parallel interface method requires a plurality of address pins, data pins, and control pins, so that the number of pins is increased. In addition, even if the programmable microcontrollers have the same pin count package, that is, even if the pin count is the same in the normal mode, the number of address pins, data pins, and control pins are different according to the capacity of the internal ROM in the program mode, and the pin positions are different. Program sockets are difficult to share.

따라서 본 발명이 이루고자하는 기술적 과제는, 기입 및 독출동작시 필요한 핀수를 감소시킬 수 있는 프로그래머블 마이크로 콘트롤러를 제공하는 데 있다.Accordingly, an object of the present invention is to provide a programmable microcontroller capable of reducing the number of pins required for write and read operations.

본 발명이 이루고자하는 다른 기술적 과제는, 기입동작시 필요한 핀수를 감소시킬 수 있는 프로그래머블 마이크로 콘트롤러의 데이터 기입방법을 제공하는 데 있다. Another object of the present invention is to provide a data writing method of a programmable microcontroller capable of reducing the number of pins required for a writing operation.

본 발명이 이루고자하는 또 다른 기술적 과제는, 독출동작시 필요한 핀수를 감소시킬 수 있는 프로그래머블 마이크로 콘트롤러의 데이터 독출방법을 제공하는 데 있다. Another object of the present invention is to provide a data reading method of a programmable microcontroller capable of reducing the number of pins required during a read operation.

상기 기술적 과제를 달성하기 위한 본 발명에 따른 프로그래머블 마이크로 콘트롤러는, 메모리부와, 상기 메모리부로부터 데이터를 읽어내어 연산 및 제어기능들을 수행하는 중앙처리부와, 특히 기입동작시 외부에서 입출력핀을 통해 인가되는 시어리얼 데이터를 클락핀을 통해 인가되는 쉬프트 클락에 동기시켜 시어리얼하게 수신하여 패러렐하게 상기 메모리부에 전달하고, 독출동작시 상기 메모리부로부터 패러렐하게 전달되는 데이터를 상기 쉬프트 클락에 동기시켜 상기 입출력핀을 통해 시어리얼하게 외부로 송신하는 시어리얼 인터페이스 회로를 구비하는 것을 특징으로한다.Programmable microcontroller according to the present invention for achieving the above technical problem, the memory unit, the central processing unit for performing the operation and control functions by reading data from the memory unit and, in particular during the write operation is applied through the input and output pins from the outside The serial data is synchronized with the shift clock applied through the clock pin to serially receive and parallelly transfer the serial data to the memory unit, and during the read operation, the data transmitted parallelly from the memory unit is synchronized with the shift clock. And a serial interface circuit for serially transmitting to the outside through an input / output pin.

상기 시어리얼 인터페이스 회로는, 어드레스 필드 검출기와, 쉬프트 레지스터와, 어드레스 레지스터부, 및 기입/독출버퍼를 구비하여 구성된다.The serial interface circuit includes an address field detector, a shift register, an address register section, and a write / read buffer.

상기 어드레스 필드 검출기는, 상기 시어리얼 데이터 및 상기 쉬프트 클락으로부터 어드레스 필드 조건을 검출하여 어드레스 플래그를 발생한다. 상기 쉬프트 레지스터는, 기입동작시에는 상기 시어리얼 데이터를 상기 쉬프트 클락에 동기되어 우측으로 이동시켜 저장한 다음 패러렐하게 출력하고, 독출동작시에는 패러렐하게 입력되는 독출데이터를 우측으로 이동시켜 시어리얼하게 외부로 출력한다. 상기 어드레스 레지스터부는, 상기 어드레스 플래그가 엑티브되는 동안에 상기 쉬프트 레지스터로부터 패러렐하게 출력되는 데이터를 저장하여 상기 메모리부의 첫 번째 어드레스로서 출력한다. 상기 기입/독출버퍼는, 상기 어드레스 플래그가 넌엑티브되는 동안에 기입모드일 경우에는 상기 쉬프트 레지스로부터 패러렐하게 출력되는 데이터를 버퍼링하여 상기 메모리부에 기입될 기입데이터로서 출력하고, 독출모드일 경우에는 상기 메모리부로부터 독출되는 데이터를 버퍼링하여 상기 독출데이터로서 출력한다. The address field detector detects an address field condition from the serial data and the shift clock to generate an address flag. The shift register shifts the serial data to the right in synchronization with the shift clock to store and then outputs the parallel data. In the read operation, the shift register is moved to the right and parallel to the read data. Output to the outside. The address register section stores data output in parallel from the shift register while the address flag is activated, and outputs the data as the first address of the memory section. The write / read buffer buffers data output from the shift register in parallel when the address flag is non-active, and outputs the buffered data as write data to be written to the memory unit. The data read from the memory unit is buffered and output as the read data.

특히 상기 어드레스 필드 검출기는, 상기 쉬프트 클락이 논리"하이"인 상태에서 상기 데이터가 논리"로우"에서 논리"하이"로 천이할 때 상기 어드레스 플래그를 엑티브시키고 이후 시어리얼하게 입력되는 상기 데이터중 M바이트(M은 정수)를 어드레스 필드로 인식하여 상기 어드레스 플래그의 엑티브 상태를 유지하며, 그 다음에 입력되는 N바이트(N은 정수)를 데이터 필드로 인식하여 상기 어드레스 플래그를 넌엑티브시킨다. 상기 어드레스 레지스터부는 상기 첫 번째 어드레스를 출력한 다음 자동으로 증가되는 어드레스를 발생시킨다.In particular, the address field detector activates the address flag when the data transitions from logic "low" to logic "high" while the shift clock is logic "high", and then M of the data which is serially input. By recognizing a byte (M is an integer) as an address field, the active state of the address flag is maintained, and then inputting N bytes (N is an integer) as a data field to non-activate the address flag. The address register section outputs the first address and then generates an address that is automatically incremented.

상기 다른 기술적 과제를 달성하기 위한 본 발명에 따른 프로그래머블 마이크로 콘트롤러의 데이터 기입방법은, 외부에서 입출력핀을 통해 인가되는 시어리얼 데이터를 클락핀을 통해 인가되는 쉬프트 클락에 동기시켜 시어리얼하게 수신하여 패러렐하게 메모리부에 기입하는 단계를 구비하는 것을 특징으로 한다.According to another aspect of the present invention, there is provided a data writing method of a programmable microcontroller according to an embodiment of the present invention, in which serial data applied through an input / output pin is externally synchronized in parallel with a shift clock applied through a clock pin. And writing to the memory unit.

상기 단계는, 상기 시어리얼 데이터 및 상기 쉬프트 클락으로부터 어드레스 필드 조건을 검출하여 어드레스 플래그를 발생시키는 (1)단계와, 상기 시어리얼 데이터를 상기 쉬프트 클락의 첫 번째부터 8번째 클락에 순차적으로 동기시켜 우측으로 이동시켜 1바이트씩 저장한 다음 9번째 클락에 동기시켜 패러렐하게 1바이트씩 출력시키는 (2)단계와, 상기 어드레스 플래그가 엑티브되는 동안에 상기 1바이트씩 패러렐하게 출력되는 M바이트의 데이터를 순차적으로 저장하여 상기 메모리부의 첫 번째 어드레스로서 출력시키는 (3)단계, 및 상기 어드레스 플래그가 넌엑티브되는 동안에 상기 N바이트의 데이터 이후에 출력되는 N바이트의 데이터를 순차적으로 저장하고 버퍼링하여 상기 메모리부에 기입될 기입데이터들로서 출력시키는 (4)단계로 이루어진다. (1) generating an address flag by detecting an address field condition from the serial data and the shift clock, and sequentially synchronizing the serial data to the first to eighth clocks of the shift clock. (2) shifting to the right to store one byte and outputting one byte in parallel in synchronization with the ninth clock; and M-byte data output in parallel by one byte while the address flag is activated. (3) storing the data as the first address of the memory unit, and sequentially storing and buffering the N-byte data output after the N-byte data while the address flag is non-active. And outputting as write data to be written (4).

상기 단계는, 상기 (3) 단계후에 상기 쉬프트 클락의 9번째 클락마다 상기 어드레스를 자동으로 증가시키는 단계를 더 구비한다. 또한 상기 (1) 단계의 어드레스 플래그는, 상기 쉬프트 클락이 논리"하이"인 상태에서 상기 시어리얼 데이터가 논리"로우"에서 논리"하이"로 천이할 때 엑티브되고 상기 (3) 단계에서 상기 M바이트의 데이터를 순차적으로 저장할 때 까지 계속 엑티브 상태를 유지한다.The step further includes the step of automatically incrementing the address every ninth clock of the shift clock after step (3). Further, the address flag of step (1) is activated when the serial data transitions from logic "low" to logic "high" while the shift clock is logic "high" and the M in step (3). It remains active until you store bytes of data sequentially.

상기 또 다른 기술적 과제를 달성하기 위한 본 발명에 따른 프로그래머블 마이크로 콘트롤러의 데이터 독출방법은, 메모리부로부터 패러렐하게 독출되는 데이터를 클락핀을 통해 인가되는 쉬프트 클락에 동기시켜 입출력핀을 통해 시어리얼하게 외부로 송신하는 단계를 구비하는 것을 특징으로 한다.According to another aspect of the present invention, there is provided a data read method of a programmable microcontroller according to an embodiment of the present invention, wherein a data read parallel from a memory unit is synchronized with a shift clock applied through a clock pin to externally output through a input / output pin. Characterized in that it comprises the step of transmitting.

상기 단계는, 상기 시어리얼 데이터 및 상기 쉬프트 클락으로부터 어드레스 필드 조건을 검출하여 어드레스 플래그를 발생시키는 (1)단계와, 상기 시어리얼 데이터를 상기 쉬프트 클락의 첫 번째부터 8번째 클락에 순차적으로 동기시켜 우측으로 이동시켜 1바이트씩 저장한 다음 9번째 클락에 동기시켜 패러렐하게 1바이트씩 M바이트를 출력시키는 (2)단계와, 상기 어드레스 플래그가 엑티브되는 동안에 상기 1바이트씩 패러렐하게 출력되는 M바이트의 데이터를 순차적으로 저장하여 상기 메모리부의 첫 번째 어드레스로서 출력시키는 (3)단계와, 상기 어드레스 플래그가 넌엑티브되는 동안에 상기 메모리부로부터 1바이트씩 패러럴하게 독출되는 데이터를 순차적으로 저장하고 버퍼링하는 (4)단계, 및 상기 1바이트씩 버퍼링된 독출데이터를 받아 상기 쉬프트 클락의 첫 번째부터 8번째 클락에 순차적으로 동기시켜 우측으로 이동시켜 상기 입출력핀을 통해 시어리얼하게 외부로 출력하는 (5)단계로 이루어진다.(1) generating an address flag by detecting an address field condition from the serial data and the shift clock, and sequentially synchronizing the serial data to the first to eighth clocks of the shift clock. (2) shifting to the right to store one byte and then outputting M bytes in parallel one byte in synchronization with the ninth clock; and M bytes output in parallel one by one while the address flag is activated. (3) storing data sequentially and outputting the data as a first address of the memory unit; and sequentially storing and buffering data read in parallel from the memory unit one byte from the memory unit while the address flag is non-active (4). Step) and the read data buffered by 1 byte From the first bit of the clock it is made in synchronization with 8 to sequentially move to the right on the second clock (5) for a real shear outputted to the outside via the input-output pins step.

상기 단계는, 상기 (3)단계후에 상기 쉬프트 클락의 9번째 클락마다 상기 어드레스를 자동으로 증가시키는 단계를 더 구비한다. 상기 (1)단계의 어드레스 플래그는, 상기 쉬프트 클락이 논리"하이"인 상태에서 상기 시어리얼 데이터가 논리"로우"에서 논리"하이"로 천이할 때 엑티브되고 상기 (3) 단계에서 상기 M바이트의 데이터를 순차적으로 저장할 때 까지 계속 엑티브 상태를 유지한다.The step further includes the step of automatically incrementing the address every ninth clock of the shift clock after step (3). The address flag of step (1) is activated when the serial data transitions from logic " low " to logic " high " while the shift clock is logic " high " and the M bytes in step (3). It stays active until you save the data sequentially.

이하 본 발명에 따른 프로그래머블 마이크로 콘트롤러의 구성 및 동작과 이 회로에서 수행되는 데이터 기입 및 독출방법을 첨부도면을 참조하여 상세히 설명하겠다.도 1은 본 발명에 따른 프로그래머블 마이크로 콘트롤러의 바람직한 일실시예의 블락도이다.도 1을 참조하면, 상기 본 발명에 따른 프로그래머블 마이크로 콘트롤러는, 중앙처리부(11), 메모리부(13), 및 시어리얼 인터페이스 회로(15)를 구비한다.Hereinafter, the configuration and operation of a programmable microcontroller according to the present invention and a method of writing and reading data in the circuit will be described in detail with reference to the accompanying drawings. Referring to FIG. 1, the programmable microcontroller according to the present invention includes a central processing unit 11, a memory unit 13, and a serial interface circuit 15.

상기 중앙처리부(11)은 상기 메모리부(13)에 저장되는 데이터를 읽어내어 연산 및 제어기능들을 수행하고, 상기 메모리부(13)은 내장 롬(ROM)으로서 OTP 형의 EPROM이나 MTP 형의 EEPROM 또는 플래쉬 롬으로 구성되며 외부에서 응용 프로그램이 코드화되어 인가되는 상기 데이터를 저장한다. 상기 시어리얼 인터페이스 회로(15)는, 기입동작시 외부에서 입출력핀(17)을 통해 인가되는 시어리얼 데이터(SDAT), 즉 상기 메모리부(13)의 어드레스 및 데이터를 클락핀(19)를 통해 인가되는 쉬프트 클락(SCLK)에 동기시켜 시어리얼하게 수신하여 패러렐하게 상기 메모리부(13)에 전달한다. 또한 상기 시어리얼 인터페이스 회로(15)는, 독출동작시 상기 메모리부(13)으로부터 패러렐하게 전달되는 데이터를 상기 쉬프트 클락(SCLK)에 동기시켜 상기 입출력핀(17)을 통해 시어리얼하게 외부로 송신한다.The central processing unit 11 reads data stored in the memory unit 13 to perform arithmetic and control functions. The memory unit 13 is a built-in ROM, which is an OTP type EPROM or an MTP type EEPROM. Or it consists of a flash ROM and stores the data that is applied to the application coded from the outside. The serial interface circuit 15 transmits the serial data SDAT, ie, the address and data of the memory unit 13, which are externally applied through the input / output pin 17 during a write operation, through the clock pin 19. In synchronism with the applied shift clock SCLK, the signal is serially received and transferred to the memory unit 13 in parallel. In addition, the serial interface circuit 15 serially transmits data transmitted in parallel from the memory unit 13 to the external clock through the input / output pin 17 in synchronization with the shift clock SCLK during a read operation. do.

특히 상기 시어리얼 인터페이스 회로(15)는, 어드레스 필드 검출기(15a)와, 쉬프트 레지스터(15b)와, 어드레스 레지스터부(15c), 및 기입/독출버퍼(15d)를 포함하여 구성된다. In particular, the serial interface circuit 15 includes an address field detector 15a, a shift register 15b, an address register section 15c, and a write / read buffer 15d.

상기 어드레스 필드 검출기(15a)는, 상기 시어리얼 데이터(SDAT) 및 상기 쉬프트 클락(SCLK)을 수신하여 상기 시어리얼 데이터(SDAT) 내의 어드레스 필드 조건을 검출하여 어드레스 플래그(FLAG)를 발생한다. The address field detector 15a receives the serial data SDAT and the shift clock SCLK, detects an address field condition in the serial data SDAT, and generates an address flag FLAG.

상기 쉬프트 레지스터(15b)는 8비트 쉬프트 레지스터이며, 기입동작시에는 외부에서 1비트씩 시어리얼하게 인가되는 상기 시어리얼 데이터(SDAT)를 상기 쉬프트 클락(SCLK)에 동기되어 우측으로 이동시켜(Shift right) 8비트씩 저장한 다음 저장된 8비트 데이터를 패러렐하게 출력한다. 또한 상기 쉬프트 레지스터(15b)는, 독출동작시에는 상기 메모리부(13)으로부터 상기 기입/독출버퍼(15d)를 통해 패러렐하게 입력되는 8비트 독출데이터를 상기 쉬프트 클락(SCLK)에 동기되어 우측으로 이동시켜 1비트씩 상기 입출력핀(17)을 통해 시어리얼하게 외부로 출력한다. The shift register 15b is an 8-bit shift register. During the write operation, the serial data SDAT, which is externally applied one bit at a time, is moved to the right in synchronization with the shift clock SCLK (Shift). right) After 8 bits are stored, 8-bit data is stored in parallel. In addition, the shift register 15b synchronizes 8-bit read data input parallel from the memory unit 13 through the write / read buffer 15d to the right side in synchronization with the shift clock SCLK during a read operation. It moves and outputs serially to the outside through the input / output pins 17 bit by bit.

상기 어드레스 레지스터부(15c)는 3개의 8비트 어드레스 레지스터, 즉 제1 내지 제3어드레스 레지스터(15c1,15c2,15c3)를 포함하고, 상기 어드레스 플래그(FLAG)가 엑티브되는 동안에 상기 쉬프트 레지스터(15b)로부터 8비트씩 패러렐하게 출력되는 24비트, 즉 3바이트의 어드레스 필드의 데이터를 순차적으로 저장하여 상기 메모리부(13)의 첫 번째 어드레스로서 출력한다. 이후 상기 어드레스 레지스터부(15c)는, 상기 첫 번째 어드레스를 출력한 다음 자동으로 증가되는 어드레스를 발생시킨다.The address register section 15c includes three 8-bit address registers, that is, first through third address registers 15c1, 15c2, and 15c3, and the shift register 15b while the address flag FLAG is activated. 24 bits, that is, three bytes of data of the address field, which are output in parallel from each other by 8 bits are sequentially stored and output as the first address of the memory unit 13. The address register section 15c then outputs the first address and then generates an address that is automatically incremented.

상기 기입/독출버퍼(15d)는 8비트로 구성되며, 상기 어드레스 플래그(FLAG)가 넌엑티브되는 동안에 기입모드일 경우에는 상기 쉬프트 레지스터(15b)로부터 8비트씩 패러렐하게 출력되는 데이터, 즉 상기 3바이트의 어드레스 필드 다음에 입력되는 1바이트 이상의 데이터 필드의 데이터를 버퍼링하여 상기 메모리부(13)에 기입될 기입데이터로서 출력한다. 또한 상기 기입/독출버퍼(15d)는, 독출모드일 경우에는 상기 메모리부(13)으로부터 독출되는 8비트의 데이터를 버퍼링하여 상기 독출데이터로서 출력한다.The write / read buffer 15d is composed of 8 bits, and in the case of the write mode while the address flag FLAG is non-active, data output in parallel from the shift register 15b by 8 bits, that is, the 3 bytes. The data of the data field of one byte or more input after the address field of the buffer is buffered and output as write data to be written to the memory unit 13. In the read mode, the write / read buffer 15d buffers 8 bits of data read from the memory unit 13 and outputs the read data as the read data.

도 2는 도 1에 도시된 시어리얼 데이터(SDAT) 포맷의 프로토콜(Protocol)을 나타내는 도면이다.FIG. 2 is a diagram illustrating a protocol of the serial data (SDAT) format shown in FIG. 1.

도 2를 참조하면, 상기 시어리얼 데이터(SDAT) 포맷의 프로토콜은, 첫부분의 시작조건(21)과, 이후 연속되는 3바이트, 즉 제1 내지 제3어드레스(22,23,24)의 어드레스 필드와, 이후 연속되는 다수의 바이트, 즉 제1 내지 제n데이터(25 내지 28)의 데이터 필드와, 마지막 부분의 종료조건(29)를 포함한다.Referring to FIG. 2, in the serial data (SDAT) format protocol, a start condition 21 of a first part and an address of three consecutive bytes, that is, addresses of first to third addresses 22, 23, and 24, are described. Field, a plurality of consecutive bytes, that is, a data field of first to nth data 25 to 28, and a termination condition 29 of the last part.

도 3은 도 1에 도시된 시어리얼 데이터(SDAT) 및 쉬프트 클락(SCLK)의 파형도이다.FIG. 3 is a waveform diagram of the serial data SDAT and the shift clock SCLK shown in FIG. 1.

이하 도 2 및 도 3을 참조하여 도 1에 도시된 본 발명에 따른 프로그래머블 마이크로 콘트롤러의 동작과 이 회로에서 수행되는 데이터 기입 및 독출방법을 상세히 설명하겠다.Hereinafter, the operation of the programmable microcontroller according to the present invention shown in FIG. 1 and the data writing and reading method performed in the circuit will be described in detail with reference to FIGS. 2 and 3.

먼저 상기 데이터 기입방법은, 외부에서 상기 하나의 입출력핀(17)을 통해 인가되는 상기 시어리얼 데이터(SDAT)를 상기 클락핀(19)를 통해 인가되는 상기 쉬프트 클락(SCLK)에 동기시켜 시어리얼하게 수신하여 패러렐하게 상기 메모리부(13)에 기입하는 단계로 이루어진다. 여기에서 도 2 및 도 3에 도시된 시작조건(21,31) 이후에 연속적으로 입력되는 상기 시어리얼 데이터(SDAT)의 첫 번째 바이트, 즉 제1 어드레스(22)의 최하위 비트(LSB)(도 3에 도시된 A16)가 "0"일 때 기입모드가 된다. First, in the data writing method, the serial data SDAT applied through the one input / output pin 17 is externally synchronized with the shift clock SCLK applied through the clock pin 19. And writing to the memory unit 13 in parallel. Here, the first byte of the serial data SDAT continuously input after the start conditions 21 and 31 shown in FIGS. 2 and 3, that is, the least significant bit LSB of the first address 22 (FIG. When A16) shown in 3 is " 0 ", the write mode is entered.

좀더 상세히 설명하면, 먼저 상기 어드레스 필드 검출기(15a)가 상기 시어리얼 데이터(SDAT) 및 상기 쉬프트 클락(SCLK)을 수신하여 상기 시어리얼 데이터(SDAT) 내의 어드레스 필드 조건을 검출하여 상기 어드레스 플래그(FLAG)를 발생시킨다(제1단계). 이때 상기 어드레스 플래그(FLAG)는 도 2 및 도 3에 도시된 시작조건(21,31), 즉 상기 쉬프트 클락(SCLK)가 논리"하이"인 상태에서 상기 시어리얼 데이터(SDAT)가 논리"로우"에서 논리"하이"로 천이할 때 엑티브된다. 다음에 상기 시작조건(21,31) 이후에 연속적으로 입력되는 상기 시어리얼 데이터(SDAT)의 3바이트, 즉 제1 내지 제3어드레스(22,23,24)(도 3에 도시된 A23 내지 A0)가 어드레스 필드로 인식되어 상기 어드레스 필드 동안에 상기 어드레스 플래그(FLAG)는 엑티브 상태를 계속 유지한다. 이후 상기 3바이트의 어드레스 필드 다음에 입력되는 다수의 바이트, 즉 제1 내지 제n데이터(25 내지 28)는 데이터 필드로 인식되어 상기 어드레스 플래그(FLAG)는 넌엑티브된다. In more detail, first, the address field detector 15a receives the serial data SDAT and the shift clock SCLK to detect an address field condition in the serial data SDAT to detect the address flag FLAG. (Step 1). In this case, the address flag FLAG is set to the logic condition that the serial data SDAT is logic low when the start conditions 21 and 31 shown in FIGS. 2 and 3, that is, the shift clock SCLK is logic "high". Active when transitioning from "logical to high". Next, three bytes of the serial data SDAT continuously inputted after the start conditions 21 and 31, that is, first to third addresses 22, 23 and 24 (A23 to A0 shown in FIG. 3). Is recognized as an address field so that the address flag FLAG remains active during the address field. Thereafter, a plurality of bytes input after the three-byte address field, that is, the first to n-th data 25 to 28 are recognized as data fields, and the address flag FLAG is non-active.

상기 제1단계이후, 상기 쉬프트 레지스터(15b)는 외부에서 1비트씩 시어리얼하게 인가되는 상기 시어리얼 데이터(SDAT)를 상기 쉬프트 클락(SCLK)의 첫 번째부터 8번째 클락에 순차적으로 동기되어 우측으로 이동시켜(Shift right) 1바이트씩 저장한 다음 9번째 클락, 즉 더미(Dummy) 클락에 동기시켜 패러렐하게 1바이트씩 3바이트의 데이터, 즉 제1 내지 제3어드레스(22,23,24)를 순차적으로 출력한다(제2단계).After the first step, the shift register 15b sequentially synchronizes the serial data SDAT externally applied one bit at a time to the first to eighth clocks of the shift clock SCLK. (Shift right) stores one byte at a time, and then synchronizes with the ninth clock, that is, the dummy clock, in parallel with three bytes of data of one byte, that is, the first to third addresses (22, 23, 24). Output sequentially (step 2).

상기 제2단계이후, 상기 어드레스 레지스터부(15c)는 상기 어드레스 플래그(FLAG)가 엑티브되는 동안에 상기 쉬프트 레지스터(15b)로부터 1바이트씩 패러렐하게 출력되는 상기 3바이트의 데이터, 즉 제1 내지 제3어드레스(22,23,24)를 순차적으로 저장하여 상기 메모리부(13)의 첫 번째 어드레스로서 출력시킨다(제3단계). 이후 상기 어드레스 레지스터부(15c)는 상기 쉬프트 클락(SCLK)의 9번째 클락, 즉 더미 클락마다 상기 어드레스를 자동으로 증가시켜 다음에 기입할 어드레스를 출력시킨다. After the second step, the address register unit 15c outputs the three bytes of data, which are parallelly outputted one by one from the shift register 15b while the address flag FLAG is activated, that is, the first to third ones. Addresses 22, 23, and 24 are sequentially stored and output as the first address of the memory unit 13 (third step). Thereafter, the address register section 15c automatically increments the address for every ninth clock of the shift clock SCLK, that is, a dummy clock, and outputs an address to be written next.

상기 제3단계후에, 상기 기입/독출버퍼(15d)는 상기 어드레스 플래그(FLAG)가 넌엑티브되는 동안에 상기 3바이트의 데이터 이후에 상기 쉬프트 레지스터(15b)로부터 1바이트씩 패러렐하게 출력되는 다수의 바이트, 즉 제1 내지 제n데이터(25 내지 28)을 순차적으로 버퍼링하여 상기 메모리부(13)에 기입될 기입데이터들로서 출력시킨다(제4단계).After the third step, the write / read buffer 15d is parallelized by one byte from the shift register 15b after the three bytes of data while the address flag FLAG is non-active. That is, the first to n-th data 25 to 28 are sequentially buffered and output as write data to be written to the memory unit 13 (fourth step).

상기와 같은 동작에 의해 상기 첫 번째 어드레스가 상기 어드레스 레지스터부(15c)로부터 출력되고 상기 제1데이터(25)가 상기 기입/독출버퍼(15d)로부터 출력된 후 상기 쉬프트 클락(SCLK)의 9번째 클락, 즉 더미 클락의 하강에지에서 상기 제1데이터(25)가 기입된다. 또한 상기 어드레스 레지스터부(15c)에 의해 순차적으로 증가되는 어드레스에 상기 제2 내지 제n데이터(26 내지 28)이 순차적으로 기입된다. 이후 더미 데이터(FF)가 외부에서 추가로 입력된 후 기입동작이 종료된다.By the above operation, after the first address is output from the address register section 15c and the first data 25 is output from the write / read buffer 15d, the ninth of the shift clock SCLK is performed. The first data 25 is written at the falling edge of the clock, that is, the dummy clock. The second to n-th data 26 to 28 are sequentially written to the addresses sequentially increased by the address register section 15c. Thereafter, after the dummy data FF is further input from the outside, the writing operation is terminated.

또한 상기 데이터 독출방법은, 상기 메모리부(13)으로부터 패러렐하게 8비트씩 독출되는 데이터를 상기 클락핀(19)를 통해 인가되는 상기 쉬프트 클락(SCLK)에 동기시켜 상기 입출력핀(17)을 통해 시어리얼하게 외부로 송신하는 단계로 이루어진다. 여기에서 도 2 및 도 3에 도시된 시작조건(21,31) 이후에 연속적으로 입력되는 상기 시어리얼 데이터(SDAT)의 첫 번째 바이트, 즉 제1 어드레스(22)의 최하위 비트(LSB)(도 3에 도시된 A16)가 "1"일 때 독출모드가 된다.In addition, the data reading method, through the input and output pin 17 in synchronization with the shift clock (SCLK) applied through the clock pin 19 to the data read out by 8 bits in parallel in the memory unit 13 Serially transmitting to the outside. Here, the first byte of the serial data SDAT continuously input after the start conditions 21 and 31 shown in FIGS. 2 and 3, that is, the least significant bit LSB of the first address 22 (FIG. When A16 shown in 3 is " 1 ", the read mode is entered.

좀더 상세히 설명하면, 상기 기입동작에서와 마찬가지로 먼저 상기 어드레스 필드 검출기(15a)가 상기 시어리얼 데이터(SDAT) 및 상기 쉬프트 클락(SCLK)을 수신하여 상기 시어리얼 데이터(SDAT) 내의 어드레스 필드 조건을 검출하여 상기 어드레스 플래그(FLAG)를 발생시킨다(제1단계).More specifically, as in the writing operation, the address field detector 15a first receives the serial data SDAT and the shift clock SCLK to detect an address field condition in the serial data SDAT. To generate the address flag FLAG (first step).

상기 제1단계이후, 상기 쉬프트 레지스터(15b)는 외부에서 1비트씩 시어리얼하게 인가되는 상기 시어리얼 데이터(SDAT)를 상기 쉬프트 클락(SCLK)의 첫 번째부터 8번째 클락에 순차적으로 동기되어 우측으로 이동시켜(Shift right) 1바이트씩 저장한 다음 9번째 클락, 즉 더미(Dummy) 클락에 동기시켜 패러렐하게 1바이트씩 3바이트의 데이터, 즉 제1 내지 제3어드레스(22,23,24)를 순차적으로 출력한다(제2단계). After the first step, the shift register 15b sequentially synchronizes the serial data SDAT externally applied one bit at a time to the first to eighth clocks of the shift clock SCLK. (Shift right) stores one byte at a time, and then synchronizes with the ninth clock, that is, the dummy clock, in parallel with three bytes of data of one byte, that is, the first to third addresses (22, 23, 24). Output sequentially (step 2).

상기 제2단계이후, 상기 어드레스 레지스터부(15c)는 상기 어드레스 플래그(FLAG)가 엑티브되는 동안에 상기 쉬프트 레지스터(15b)로부터 1바이트씩 패러렐하게 출력되는 상기 3바이트의 데이터, 즉 제1 내지 제3어드레스(22,23,24)를 순차적으로 저장하여 상기 메모리부(13)의 첫 번째 어드레스로서 출력시킨다(제3단계). 이후 상기 어드레스 레지스터부(15c)는 상기 쉬프트 클락(SCLK)의 8번째 클락마다 상기 어드레스를 자동으로 증가시켜 다음에 독출될 어드레스를 출력시킨다. After the second step, the address register unit 15c outputs the three bytes of data, which are parallelly outputted one by one from the shift register 15b while the address flag FLAG is activated, that is, the first to third ones. Addresses 22, 23, and 24 are sequentially stored and output as the first address of the memory unit 13 (third step). Thereafter, the address register section 15c automatically increments the address for every eighth clock of the shift clock SCLK and outputs an address to be read next.

상기 제3단계이후, 상기 기입/독출버퍼(15d)가 상기 어드레스 플래그(FLAG)가 넌엑티브되는 동안에 상기 어드레스에 따라 메모리부(13)으로부터 1바이트씩 패러럴하게 독출되는 데이터를 순차적으로 버퍼링한다(제4단계). After the third step, the write / read buffer 15d sequentially buffers data read-by-byte in parallel from the memory unit 13 according to the address while the address flag FLAG is non-active ( Step 4).

상기 제4단계이후, 상기 쉬프트 레지스터(15b)는 상기 1바이트씩 버퍼링된 독출데이터를 상기 쉬프트 클락(SCLK)의 더미 클락에 동기되어 패러렐하게 받아 상기 쉬프트 클락(SCLK)의 첫 번째부터 8번째 클락에 순차적으로 동기되어 우측으로 이동시켜 상기 입출력핀(17)을 통해 시어리얼하게 1비트씩 외부로 출력한다.After the fourth step, the shift register 15b receives the read data buffered by one byte in parallel in synchronization with the dummy clock of the shift clock SCLK, and includes the first to eighth clocks of the shift clock SCLK. Are sequentially synchronized to the right side and serially output to the outside one by one through the input / output pin 17.

상기와 같은 동작에 따라, 상기 어드레스 레지스터부(15c)에 의해 순차적으로 증가되는 어드레스로부터 독출되는 상기 제1 내지 제n데이터(26 내지 28)이 순차적으로 상기 입출력핀(17)을 통해 시어리얼하게 외부로 출력된다. 이후 상기 쉬프트 클락(SCLK)가 논리"하이"인 상태에서 상기 시어리얼 데이터(SDAT)가 논리"하이"에서 논리"로우"로 천이할 때, 즉 도 2 및 도 3에 도시된 종료조건(29,33)에서 독출동작이 종료된다.According to the operation as described above, the first to n-th data 26 to 28 read out from the address sequentially increased by the address register unit 15c are serially through the input / output pin 17. It is output to the outside. Then, when the serial data SDAT transitions from logic "high" to logic "low" while the shift clock SCLK is logic "high", that is, the termination condition 29 shown in FIGS. At 33, the read operation is terminated.

이상과 같이, 본 발명을 일실시예를 들어 한정적으로 설명하였으나 이에 한정되지 않으며 본 발명의 사상의 범위 내에서 당해 분야의 통상의 지식을 가진 자에 의해 본원 발명에 대한 각종 변형이 가능함은 자명하다. As described above, the present invention has been limited to one embodiment, but not limited thereto. It is obvious that various modifications to the present invention can be made by those skilled in the art within the scope of the spirit of the present invention. .

상술한 바와 같이 본 발명에 따른 데이터 기입 및 독출방법을 수행하는 프로그래머블 마이크로 콘트롤러는, 시어리얼 인터페이스 회로를 구비함으로써 기입 및 독출동작시 하나의 데이터 입출력핀과 하나의 클락핀만이 필요하므로 핀수가 감소된다. 따라서 핀수가 적은 패키지로 조립될 수 있는 장점이 있다. 또한 내장 메모리의 용량에 무관하게 하나의 데이터 입출력핀과 하나의 클락핀만이 필요하므로, 상기 프로그래머블 마이크로 콘트롤러들이 서로 다른 용량의 내장 메모리를 갖더라도 동일한 패키지로 조립될 수 있으며 이에 따라 동일한 프로그램용 소켓이 사용될 수 있는 장점이 있다. As described above, the programmable microcontroller for performing the data writing and reading method according to the present invention includes a serial interface circuit, so that only one data input / output pin and one clock pin are required for writing and reading operations, thereby reducing the number of pins. do. Therefore, there is an advantage that can be assembled in a package with a small number of pins. In addition, since only one data input / output pin and one clock pin are needed regardless of the capacity of the internal memory, even if the programmable microcontrollers have different capacity of internal memory, they can be assembled in the same package. There is an advantage that can be used.

도 1은 본 발명에 따른 프로그래머블 마이크로 콘트롤러의 바람직한 일실시예의 블락도1 is a block diagram of a preferred embodiment of a programmable microcontroller according to the present invention.

도 2는 도 1에 도시된 시어리얼 데이터 포맷의 프로토콜(Protocol)을 나타내는 도면FIG. 2 is a diagram illustrating a protocol of the serial data format shown in FIG. 1. FIG.

도 3은 도 1에 도시된 시어리얼 데이터 및 쉬프트 클락의 파형도FIG. 3 is a waveform diagram of the serial data and shift clock shown in FIG.

Claims (18)

메모리부; A memory unit; 상기 메모리부로부터 데이터를 읽어내어 연산 및 제어기능들을 수행하는 중앙처리부; 및 A central processing unit which reads data from the memory unit and performs arithmetic and control functions; And 기입동작시 외부에서 입출력핀을 통해 인가되는 시어리얼 데이터를 클락핀을 통해 인가되는 쉬프트 클락에 동기시켜 시어리얼하게 수신하여 패러렐하게 상기 메모리부에 전달하고, 독출동작시 상기 메모리부로부터 패러렐하게 전달되는 데이터를 상기 쉬프트 클락에 동기시켜 상기 입출력핀을 통해 시어리얼하게 외부로 송신하는 시어리얼 인터페이스 회로를 구비하고,Serial data applied externally through an input / output pin during a write operation is synchronized with a shift clock applied through a clock pin to serially receive and parallelly transfer the serial data to the memory unit. A serial interface circuit for serially transmitting data to the outside through the input / output pins in synchronization with the shift clock; 상기 시어리얼 인터페이스 회로는, The serial interface circuit, 상기 시어리얼 데이터 및 상기 쉬프트 클럭을 수신하여 상기 시어리얼 데이터 내의 어드레스 필드 조건을 검출하여 어드레스 플래그를 발생하는 어드레스 필드 검출기;An address field detector for receiving the serial data and the shift clock to detect an address field condition in the serial data to generate an address flag; 기입동작시에는 상기 시어리얼 데이터를 상기 쉬프트 클락에 동기되어 우측으로 이동시켜 저장한 다음 패러렐하게 출력하고, 독출동작시에는 패러렐하게 입력되는 독출데이터를 우측으로 이동시켜 시어리얼하게 외부로 출력하는 쉬프트 레지스터;In the write operation, the serial data is shifted to the right in synchronization with the shift clock, stored, and then output in parallel. In the read operation, the parallel data is moved to the right and serially output to the outside. register; 상기 어드레스 플래그가 엑티브되는 동안에 상기 쉬프트 레지스터로부터 패러렐하게 출력되는 데이터를 저장하여 상기 메모리부의 첫 번째 어드레스로서 출력하는 어드레스 레지스터부; 및An address register section for storing data output in parallel from the shift register while the address flag is activated and outputting the first address as the first address of the memory section; And 상기 어드레스 플래그가 넌엑티브되는 동안에 기입모드일 경우에는 상기 쉬프트 레지스로부터 패러렐하게 출력되는 데이터를 버퍼링하여 상기 메모리부에 기입될 기입데이터로서 출력하고, 독출모드일 경우에는 상기 메모리부로부터 독출되는 데이터를 버퍼링하여 상기 독출데이터로서 출력하는 기입/독출버퍼를 구비하는 것을 특징으로하는 프로그래머블 마이크로 콘트롤러. In the write mode while the address flag is non-active, the data output in parallel from the shift register is buffered and output as write data to be written in the memory unit. In the read mode, the data read from the memory unit is read. And a write / read buffer which is buffered and output as the read data. 제1항에 있어서, 상기 메모리부는 EPROM, EEPROM, 및 플레쉬 메모리중 선택되는 어느 하나로 구성되는 것을 특징으로 하는 프로그래머블 마이크로 콘트롤러. The programmable microcontroller of claim 1, wherein the memory unit comprises at least one selected from an EPROM, an EEPROM, and a flash memory. 제1항에 있어서, 상기 어드레스 필드 검출기는, 상기 쉬프트 클락이 논리"하이"인 상태에서 상기 데이터가 논리"로우"에서 논리"하이"로 천이할 때 상기 어드레스 플래그를 엑티브시키고 이후 시어리얼하게 입력되는 상기 데이터중 M바이트(M은 정수)를 어드레스 필드로 인식하여 상기 어드레스 플래그의 엑티브 상태를 유지하며, 그 다음에 입력되는 N바이트(N은 정수)를 데이터 필드로 인식하여 상기 어드레스 플래그를 넌엑티브시키는 것을 특징으로 하는 프로그래머블 마이크로 콘트롤러.The address field detector of claim 1, wherein the address field detector activates the address flag when the data transitions from logic "low" to logic "high" while the shift clock is logic "high" and then serially inputs. Recognizes M bytes (M is an integer) of the data as an address field to maintain an active state of the address flag, and then recognizes N bytes (N is an integer) input as a data field to recognize the address flag. Programmable microcontroller, characterized in that the active. 제3항에 있어서, 상기 M은 3이고 상기 N은 1이상인 것을 특징으로 하는 프로그래머블 마이크로 콘트롤러. 4. The programmable microcontroller according to claim 3, wherein M is 3 and N is at least one. 제1항에 있어서, 상기 쉬프트 레지스터는 8비트 쉬프트 레지스터인 것을 특징으로 하는 프로그래머블 마이크로 콘트롤러.2. The programmable microcontroller of claim 1, wherein the shift register is an 8-bit shift register. 제1항에 있어서, 상기 어드레스 레지스터부는 상기 첫 번째 어드레스를 출력한 다음 자동으로 증가되는 어드레스를 발생시키는 것을 특징으로 하는 프로그래머블 마이크로 콘트롤러.The programmable microcontroller of claim 1, wherein the address register unit generates an address that is automatically incremented after outputting the first address. 제1항에 있어서, 상기 어드레스 레지스터부는 N개의 8비트 어드레스 레지스터를 포함하고 상기 쉬프트 레지스터로부터 패러렐하게 순차적으로 출력되는 N바이트의 데이터를 순차적으로 저장하는 것을 특징으로 하는 프로그래머블 마이크로 콘트롤러.The programmable microcontroller according to claim 1, wherein the address register section includes N 8-bit address registers and sequentially stores N bytes of data sequentially output from the shift register in parallel. 제1항에 있어서, 상기 기입/독출버퍼는 8비트로 구성되는 것을 특징으로 하는 프로그래머블 마이크로 콘트롤러.The programmable microcontroller according to claim 1, wherein the write / read buffer is composed of 8 bits. 메모리부와, 상기 메모리부로부터 데이터를 읽어내어 연산 및 제어기능들을 수행하는 중앙처리부를 구비하는 프로그래머블 마이크로 콘트롤러의 데이터 기입방법에 있어서, A data writing method of a programmable microcontroller having a memory unit and a central processing unit configured to read data from the memory unit and perform arithmetic and control functions. 외부에서 입출력핀을 통해 인가되는 시어리얼 데이터를 클락핀을 통해 인가되는 쉬프트 클락에 동기시켜 시어리얼하게 수신하여 패러렐하게 상기 메모리부에 기입하는 단계를 구비하고,And serially receiving serial data applied through an input / output pin externally and synchronizing with a shift clock applied through a clock pin and writing parallel to the memory unit. 상기 단계는,The step, (1) 상기 시어리얼 데이터 및 상기 쉬프트 클락을 수신하여 상기 시어리얼 데이터 내의 어드레스 필드 조건을 검출하여 어드레스 플래그를 발생시키는 단계;(1) receiving the serial data and the shift clock to detect an address field condition in the serial data to generate an address flag; (2) 상기 시어리얼 데이터를 상기 쉬프트 클락의 첫 번째부터 8번째 클락에 순차적으로 동기시켜 우측으로 이동시켜 1바이트씩 저장한 다음 9번째 클락에 동기시켜 패러렐하게 1바이트씩 출력시키는 단계;(2) sequentially synchronizing the serial data to the first to eighth clocks of the shift clock, moving the serial data to the right to store one byte, and outputting one byte in parallel to the ninth clock; (3) 상기 어드레스 플래그가 엑티브되는 동안에 상기 1바이트씩 패러렐하게 출력되는 M(M는 자연수)바이트의 데이터를 순차적으로 저장하여 상기 메모리부의 첫 번째 어드레스로서 출력시키는 단계; 및(3) sequentially storing data of M (M is a natural number) bytes sequentially outputted in parallel by one byte while the address flag is activated and outputting the data as the first address of the memory unit; And (4) 상기 어드레스 플래그가 넌엑티브되는 동안에 상기 M바이트의 데이터 이후에 출력되는 N(N는 자연수)바이트의 데이터를 순차적으로 저장하고 버퍼링하여 상기 메모리부에 기입될 기입데이터들로서 출력시키는 단계를 구비하는 것을 특징으로 하는 데이터 기입방법. (4) sequentially storing and buffering N (N is a natural number) bytes of data output after the M bytes of data while the address flag is non-active, and outputting them as write data to be written to the memory section. And a data writing method. 제9항에 있어서, 상기 단계는, 상기 (3) 단계후에 상기 쉬프트 클락의 9번째 클락마다 상기 어드레스를 자동으로 증가시키는 단계를 더 구비하는 것을 특징으로 하는 데이터 기입방법.10. The method of claim 9, wherein said step further comprises the step of automatically increasing said address every ninth clock of said shift clock after said step (3). 제9항에 있어서, 상기 (1) 단계의 어드레스 플래그는, 상기 쉬프트 클락이 논리"하이"인 상태에서 상기 시어리얼 데이터가 논리"로우"에서 논리"하이"로 천이할 때 엑티브되고 상기 (3) 단계에서 상기 M바이트의 데이터를 순차적으로 저장할 때 까지 계속 엑티브 상태를 유지하는 것을 특징으로 하는 데이터 기입방법.10. The method according to claim 9, wherein the address flag of step (1) is activated when the serial data transitions from logic "low" to logic "high" while the shift clock is logic "high". And maintaining an active state until the M-bytes of data are sequentially stored in the step S). 제9항에 있어서, 상기 M은 3이고 상기 N은 1이상인 것을 특징으로 하는 데이터 기입방법.10. The method of claim 9, wherein M is 3 and N is at least one. 제9항에 있어서, 상기 메모리부는 EPROM, EEPROM, 및 플레쉬 메모리중 선택되는 어느 하나로 구성되는 것을 특징으로 하는 데이터 기입방법. 10. The method of claim 9, wherein the memory unit is one selected from an EPROM, an EEPROM, and a flash memory. 메모리부와, 상기 메모리부로부터 데이터를 읽어내어 연산 및 제어기능들을 수행하는 중앙처리부를 구비하는 프로그래머블 마이크로 콘트롤러의 데이터 독출방법에 있어서, A data reading method of a programmable microcontroller having a memory unit and a central processing unit configured to read data from the memory unit and perform arithmetic and control functions. 상기 메모리부로부터 패러렐하게 독출되는 데이터를 클락핀을 통해 인가되는 쉬프트 클락에 동기시켜 입출력핀을 통해 시어리얼하게 외부로 송신하는 단계를 구비하고,Synchronizing data read parallel from the memory unit with a shift clock applied through a clock pin and transmitting the data serially to the outside through an input / output pin; 상기 단계는,The step, (1) 상기 시어리얼 데이터 및 상기 쉬프트 클락을 수신하여 상기 시어리얼 데이터 내의 어드레스 필드 조건을 검출하여 어드레스 플래그를 발생시키는 단계;(1) receiving the serial data and the shift clock to detect an address field condition in the serial data to generate an address flag; (2) 상기 시어리얼 데이터를 상기 쉬프트 클락의 첫 번째부터 8번째 클락에 순차적으로 동기시켜 우측으로 이동시켜 1바이트씩 저장한 다음 9번째 클락에 동기시켜 패러렐하게 1바이트씩 M(M는 자연수)바이트를 출력시키는 단계;(2) The serial data is sequentially synchronized with the first to eighth clocks of the shift clock, shifted to the right, and stored by one byte, and then synchronized with the ninth clock, M by one byte in parallel (M is a natural number). Outputting bytes; (3) 상기 어드레스 플래그가 엑티브되는 동안에 상기 1바이트씩 패러렐하게 출력되는 M바이트의 데이터를 순차적으로 저장하여 상기 메모리부의 첫 번째 어드레스로서 출력시키는 단계;(3) sequentially storing M-bytes of data output in parallel by one byte while the address flag is activated and outputting the data as a first address of the memory unit; (4) 상기 어드레스 플래그가 넌엑티브되는 동안에 상기 메모리부로부터 1바이트씩 패러럴하게 독출되는 데이터를 순차적으로 저장하고 버퍼링하는 단계; 및(4) sequentially storing and buffering data read in parallel from the memory unit by one byte while the address flag is non-active; And (5) 상기 1바이트씩 버퍼링된 독출데이터를 받아 상기 쉬프트 클락의 첫 번째부터 8번째 클락에 순차적으로 동기시켜 우측으로 이동시켜 상기 입출력핀을 통해 시어리얼하게 외부로 출력하는 단계를 구비하는 것을 특징으로 하는 데이터 독출방법. (5) receiving the read data buffered by 1 byte and sequentially synchronizing with the first to eighth clocks of the shift clock to the right to serially output to the outside through the input / output pins; Data reading method. 제14항에 있어서, 상기 단계는, 상기 (3) 단계후에 상기 쉬프트 클락의 9번째 클락마다 상기 어드레스를 자동으로 증가시키는 단계를 더 구비하는 것을 특징으로 하는 데이터 독출방법.15. The method of claim 14, wherein the step further comprises, after step (3), automatically increasing the address for every ninth clock of the shift clock. 제14항에 있어서, 상기 (1) 단계의 어드레스 플래그는, 상기 쉬프트 클락이 논리"하이"인 상태에서 상기 시어리얼 데이터가 논리"로우"에서 논리"하이"로 천이할 때 엑티브되고 상기 (3) 단계에서 상기 M바이트의 데이터를 순차적으로 저장할 때 까지 계속 엑티브 상태를 유지하는 것을 특징으로 하는 데이터 독출방법.The address flag of claim 14, wherein the address flag of the step (1) is activated when the serial data transitions from a logic "low" to a logic "high" while the shift clock is logic "high." And keeping the active state until the M-bytes of data are sequentially stored in step). 제14항에 있어서, 상기 M은 3인 것을 특징으로 하는 데이터 독출방법.15. The method of claim 14, wherein M is three. 제14항에 있어서, 상기 메모리부는 EPROM, EEPROM, 및 플레쉬 메모리중 선택되는 어느 하나로 구성되는 것을 특징으로 하는 데이터 독출방법. 15. The method of claim 14, wherein the memory unit comprises one selected from an EPROM, an EEPROM, and a flash memory.
KR1019980013118A 1998-04-13 1998-04-13 Programmable microcontroller including a serial interface circuit and data writing/reading method thereof KR100505600B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1019980013118A KR100505600B1 (en) 1998-04-13 1998-04-13 Programmable microcontroller including a serial interface circuit and data writing/reading method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1019980013118A KR100505600B1 (en) 1998-04-13 1998-04-13 Programmable microcontroller including a serial interface circuit and data writing/reading method thereof

Publications (2)

Publication Number Publication Date
KR19990080113A KR19990080113A (en) 1999-11-05
KR100505600B1 true KR100505600B1 (en) 2005-09-26

Family

ID=37304918

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1019980013118A KR100505600B1 (en) 1998-04-13 1998-04-13 Programmable microcontroller including a serial interface circuit and data writing/reading method thereof

Country Status (1)

Country Link
KR (1) KR100505600B1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100404232B1 (en) * 2002-01-02 2003-11-05 주식회사 하이닉스반도체 micro controller unit
KR102235290B1 (en) * 2019-01-24 2021-04-02 (주)실리콘인사이드 Host and slave apparatus having cascade connection structure

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0628313A (en) * 1992-03-13 1994-02-04 Nec Corp Serial interface circuit

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0628313A (en) * 1992-03-13 1994-02-04 Nec Corp Serial interface circuit

Also Published As

Publication number Publication date
KR19990080113A (en) 1999-11-05

Similar Documents

Publication Publication Date Title
US8046527B2 (en) Apparatus and method for using a page buffer of a memory device as a temporary cache
US5794033A (en) Method and system for in-site and on-line reprogramming of hardware logics with remote loading in a network device
US6763426B1 (en) Cascadable content addressable memory (CAM) device and architecture
US7590027B2 (en) Nonvolatile semiconductor memory device
KR100377708B1 (en) Semiconductor memory device employing pipeline operation with reduced power consumption
KR100505600B1 (en) Programmable microcontroller including a serial interface circuit and data writing/reading method thereof
US7159083B2 (en) Programmable transition state machine
US4747038A (en) Disk controller memory address register
KR100275020B1 (en) Semiconductor logical device capable of circuit switching without being influenced by transitional effects
US6611462B2 (en) Semiconductor integrated circuit
FI87282B (en) ANORDNING I EN SKIVSTYRNING FOER ATT I ETT DATABEHANDLINGSSYSTEM OEVERFOERA DATAENHETSBLOCK.
KR860000596A (en) Slave interface circuit
JP2014071929A (en) Fifo circuit
KR100404232B1 (en) micro controller unit
KR20000046220A (en) Emulation microcontroller with variable sfr address function
CN112445742A (en) Method for automatically identifying address width
SU1509861A2 (en) Channel-to-channel adapter
RU1805496C (en) Memory circuit
JPH09288618A (en) Storage device and memory access control method therefor
JP3254781B2 (en) Semiconductor device
SU1049895A2 (en) Channel-to-channel adapter
RU1817097C (en) Device for interfacing components of microcomputer
JP2001290755A (en) Method for accessing eeprom and electronic device having eeprom
KR200211287Y1 (en) High speed first in, first out memory
RU2024050C1 (en) Channel-to-channel adapter

Legal Events

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