[go: up one dir, main page]

CN1198196C - Versatile compact memory card interface compatible with USB interface - Google Patents

Versatile compact memory card interface compatible with USB interface Download PDF

Info

Publication number
CN1198196C
CN1198196C CN 02132090 CN02132090A CN1198196C CN 1198196 C CN1198196 C CN 1198196C CN 02132090 CN02132090 CN 02132090 CN 02132090 A CN02132090 A CN 02132090A CN 1198196 C CN1198196 C CN 1198196C
Authority
CN
China
Prior art keywords
memory card
interface
data
pin
signal
Prior art date
Legal status (The legal status 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 status listed.)
Expired - Fee Related
Application number
CN 02132090
Other languages
Chinese (zh)
Other versions
CN1482526A (en
Inventor
陈加立
谢祥安
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Carry Computer Engineering Co Ltd
Original Assignee
Carry Computer Engineering Co Ltd
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 Carry Computer Engineering Co Ltd filed Critical Carry Computer Engineering Co Ltd
Priority to CN 02132090 priority Critical patent/CN1198196C/en
Publication of CN1482526A publication Critical patent/CN1482526A/en
Application granted granted Critical
Publication of CN1198196C publication Critical patent/CN1198196C/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Credit Cards Or The Like (AREA)

Abstract

A multifunctional small memory card is used for storing digital information function and supporting other IO functions, and comprises a memory card I/O function module for storing digital information; a memory for storing digital information, and a main controller connected between the memory card I/O function module and the memory; the multifunctional small-sized memory card has the design of 4-pin position and 8-pin position at the same time; the 4-pin design is used for a basic USB interface; the 8-pin design is called SFMI interface, and is composed of 4-bit bidirectional instruction/data/state bus, clock synchronous signal, system interface and memory card insertion detection signal, and power supply and grounding, wherein the power supply and grounding are the same as the power supply and grounding pin in USB interface.

Description

可适用于USB接口的多功能小型存储卡接口Versatile compact memory card interface compatible with USB interface

技术领域technical field

本发明是有关于存储卡接口装置尤其是一种可接收多功能小型存储卡接口及USB接口的多功能小型存储卡接口。The invention relates to a memory card interface device, in particular to a multifunctional small memory card interface capable of receiving a multifunctional small memory card interface and a USB interface.

背景技术Background technique

小型存储卡(Small-Form-Factor Memory Card)是采用具备大量储存空间,且可重复擦写的矽晶片作为储存媒体,并内建一微控制器,作为控制矽晶片读取及擦写作业,并连接应用小型存储卡的电子应用装置接口,接受其指令进行相应读写作业等用途。The Small-Form-Factor Memory Card (Small-Form-Factor Memory Card) uses a rewritable silicon chip with a large storage space as the storage medium, and has a built-in microcontroller to control the read and write operations of the silicon chip. It is also connected to an interface of an electronic application device using a small memory card, and accepts its instructions to perform corresponding read and write operations.

采用矽晶片作为储存媒体的小型存储卡,因具备体积小、重量轻、读写速度快、省电等优点,广泛应用于数字化的资讯产业与资讯家电产业,作为储存与交换数字信息之用。目前市场上常见的小型存储卡可分为CompactFlash卡(CF卡)、Smart Media卡(SM卡)、Multi Media卡(MMC卡)、Memory Stick卡(MS卡)、Secure Digital卡(SD卡)等不同种类。各种小型存储卡,其外观尺寸、机械构装、电气接触位置、通讯协定、软件指令代码、控制流程等各有不同,亦各有其优劣点。Small memory cards using silicon chips as storage media are widely used in the digitized information industry and home appliance industry for storing and exchanging digital information due to their advantages of small size, light weight, fast reading and writing speed, and power saving. Common small memory cards in the market can be divided into CompactFlash card (CF card), Smart Media card (SM card), Multi Media card (MMC card), Memory Stick card (MS card), Secure Digital card (SD card), etc. Different types. All kinds of small memory cards are different in appearance size, mechanical structure, electrical contact position, communication protocol, software instruction code, control process, etc., and each has its own advantages and disadvantages.

小型存储卡广泛应用于各种可携式数字装置,涵盖移动电话、数字相机、数字音乐随身听、可携式数字随身助理(PDA)等。为拓展其应用领域,除储存功能外,亦有开拓其他应用领域的产品出现。例如:CF接口的数据机卡、网络卡;Memory Stick接口的数字相机卡、Blue Tooth通讯卡;SD接口的Blue Tooth通讯卡等。为有别于仅具储存功能的存储卡,一般均将上述其他功能的应用泛称为IO卡。Small memory cards are widely used in various portable digital devices, including mobile phones, digital cameras, digital music players, portable digital assistants (PDAs), etc. In order to expand its application fields, in addition to the storage function, there are also products that open up other application fields. For example: modem card and network card with CF interface; digital camera card with Memory Stick interface, Blue Tooth communication card; Blue Tooth communication card with SD interface, etc. In order to be different from memory cards that only have storage functions, the applications of the above-mentioned other functions are generally referred to as IO cards.

上述各种小型存储卡接口,虽可适用于各式可携式数字装置,与不同应用,然而却因各有其缺失,而有遗珠之憾。就其规格的缺失而言,今略举数例分别予以说明:Although the above-mentioned various small memory card interfaces are applicable to various portable digital devices and different applications, they are regrettable because each has its own shortcomings. As far as the lack of specifications is concerned, here are a few examples to illustrate:

就Compact Flash卡而言,其接口需50组接点,机构采插针、插孔结合式,电气接口采8位元、16位元并存的并列式资料总线、具11组信号的位址总线,及多组各种不同用途的控制信号线。As far as the Compact Flash card is concerned, its interface requires 50 sets of contacts. The mechanism adopts a combination of pins and jacks. The electrical interface adopts a parallel data bus with 8-bit and 16-bit coexistence, and an address bus with 11 sets of signals. And multiple sets of control signal lines for various purposes.

Compact Flash接口的缺点为:一、机构上须具备50组连接端子,数量最多,造成连接器成本较高,亦较占空间。二、探用插针、插孔结合式连接设计,造成插入、退出需较高力度。三、插针耦合插孔定位不准确时,容易造成插针歪斜偏离损坏。四、采用并列式总线设计,连接多卡时,电子应用装置必须分别提供启动选择信号,无法迳行并连多卡。五、未具备防写保护设计,无法确保记忆内容不受毁损。The disadvantages of the Compact Flash interface are as follows: 1. The mechanism must have 50 sets of connection terminals, which is the largest number, resulting in higher cost of the connector and taking up more space. 2. The combination design of pin and jack for probes requires high force for insertion and withdrawal. 3. When the positioning of the pin coupling jack is inaccurate, it is easy to cause the pins to be skewed and damaged. 4. The parallel bus design is adopted. When multiple cards are connected, the electronic application device must provide a start selection signal separately, and multiple cards cannot be connected in parallel. 5. There is no anti-write protection design, which cannot ensure that the memory content will not be damaged.

就Smart Media卡而言,其接口需22组接点,机构采簧片与平面接触端子接触式。另需两组簧片分别作为侦测存储卡是否插入定位,以及是否黏贴防写导电贴纸之用。As far as the Smart Media card is concerned, its interface needs 22 groups of contacts, and the mechanism adopts the contact type of reeds and flat contact terminals. Another two sets of reeds are required to detect whether the memory card is inserted and positioned, and whether to paste the anti-write conductive sticker.

Smart Media接口的缺点为:一、机构上须具备22组连接端子,另须具备侦测定位与防写导电贴纸的簧片造成连接器成本较高,亦较占空间。二、连接端子采前后双排设置,於插置或退出时,第一排接触位置会先连接第二排连接端子,造成插置时不稳定的现象。三、电源连接信号VCC与GND均于两排连接端子之间,横断整组连接位置,亦容易端子间短路等不稳定现象。四、采用贴标签方式区别存储卡是否防写,需额外供应特殊导电的防写标签,且其防写功能并非直接保护存储卡内容,而需仰赖电子应用装置侦测识别防写状态。五、采实体定址方式,不能直接支援一般系统采用的线性逻辑定址方式,增加电子应用装置的成本与开发困难度。六、因采实体定址方式,每逢储存媒体扩增容量,即需因应矽晶片规划的格式,修订新版规格以支援容量更大的可擦写式矽晶片。The disadvantages of the Smart Media interface are as follows: 1. The mechanism must have 22 sets of connecting terminals, as well as reeds for detection and positioning and anti-write conductive stickers, resulting in higher cost of the connector and taking up more space. 2. The connection terminals are arranged in front and back double rows. When inserting or withdrawing, the first row of contact positions will be connected to the second row of connection terminals first, resulting in instability during insertion. 3. The power supply connection signals VCC and GND are located between the two rows of connection terminals, which traverse the entire group of connection positions, and are prone to unstable phenomena such as short circuits between terminals. 4. Labeling is used to distinguish whether the memory card is write-proof or not. A special conductive write-proof label is required, and the write-proof function does not directly protect the contents of the memory card, but relies on the electronic application device to detect and identify the write-proof state. 5. The physical addressing method cannot directly support the linear logic addressing method adopted by general systems, which increases the cost and development difficulty of electronic application devices. 6. Due to the physical addressing method, whenever the capacity of the storage medium is increased, it is necessary to adapt to the planned format of the silicon chip and revise the new version of the specification to support the rewritable silicon chip with a larger capacity.

就MMC卡而言,其接口需7组接点,机构采簧片与平面接触端子接触式。另需一组簧片作为侦测存储卡是否插入定位。As far as the MMC card is concerned, its interface needs 7 groups of contacts, and the mechanism adopts the contact type of reed and flat contact terminal. Another set of reeds is needed to detect whether the memory card is inserted or not.

MMC接口的缺点为:一、采串列通讯传输模式,每一时脉周期仅传输1位元,传输速率低。二、采用软件防写保护模式,需特殊软件控制,防护功能实用性较差。The disadvantages of the MMC interface are: 1. The serial communication transmission mode is adopted, and only 1 bit is transmitted in each clock cycle, and the transmission rate is low. 2. The software anti-write protection mode is adopted, which requires special software control, and the protection function is less practical.

就SD卡而言,其接口需9组接点,机构采簧片与平面接触端子接触式。另需两组簧片作为侦测存储卡是否插入定位,及侦测防写保护滑块位置的用途。As far as the SD card is concerned, its interface needs 9 groups of contacts, and the mechanism adopts the contact type between the reed and the flat contact terminal. Another two sets of reeds are needed to detect whether the memory card is inserted and positioned, and to detect the position of the write protection slider.

SD卡接口的缺点为:防写保护滑块需电子应用装置侦测其位置,并支援防写功能。The disadvantage of the SD card interface is that the anti-write protection slider requires the electronic application device to detect its position and support the anti-write function.

就MS卡而言,其接口共需10组接点,机构采簧片与平面接触端子接触式。连接接口具备插卡侦测信号,且存储卡本身具备防写开关,存储卡本身即可支援防写功能为其优点。As far as the MS card is concerned, its interface requires a total of 10 sets of contacts, and the mechanism adopts the contact type of reeds and flat contact terminals. The connection interface has a card detection signal, and the memory card itself has a write-protection switch, so the memory card itself can support the write-protection function as an advantage.

MS卡接口的缺点为:一、采串列通讯传输模式,每一时脉周期仅能传输1位元,传输速率低。二、采实体定址方式,不能支援一般系统采用的线性逻辑定址方式,增加电子应用装置的成本及开发困难度。三、因采实体定址方式,每逢储存媒体扩增容量,即需因应矽晶片规划的格式,修订新版规格以支援容量更大的可擦写式矽晶片。The disadvantages of the MS card interface are: 1. The serial communication transmission mode is adopted, and only 1 bit can be transmitted per clock cycle, and the transmission rate is low. 2. The physical addressing method cannot support the linear logic addressing method adopted by general systems, which increases the cost and development difficulty of electronic application devices. 3. Due to the physical addressing method, whenever the capacity of the storage medium increases, it is necessary to adapt to the planned format of the silicon chip and revise the new version of the specification to support the rewritable silicon chip with a larger capacity.

有鉴于众多存储卡标准各自相异,亦各具优缺点,且个人电脑需扩充配备额外的USB接口、PCMCIA接口或IDE接口的存储卡电子应用装置,方能达到与存储卡沟通交换数字信息的目的,本发明人乃有提出一更先进新颖的标准,一举克服上述诸多缺失,并发展出:一、体积更小,速度更快,更适合可携式数字装置应用;二、无须额外扩充电子应用装置即能轻易连接个人电脑系统;三、兼顾IO应用扩充性等优点的新颖标准接口,并称之为多功能小型存储卡接口。In view of the fact that many memory card standards are different, each has its own advantages and disadvantages, and the personal computer needs to be expanded with an additional USB interface, PCMCIA interface or IDE interface memory card electronic application device, in order to achieve the ability to communicate and exchange digital information with the memory card Purpose, the present inventor has proposed a more advanced and novel standard, overcomes above-mentioned many deficiencies in one fell swoop, and develops: 1, volume is smaller, faster, more suitable for portable digital device application; The application device can be easily connected to the personal computer system; 3. A novel standard interface that takes into account the advantages of IO application expandability, etc., and is called a multi-functional small memory card interface.

发明内容Contents of the invention

本发明的目的为提供一种多功能小型存储卡,其中该多功能小型存储卡同时具有4脚位及8脚位的设计,可同时支援传统的USB接口,及本发明中所定义的SFMI接口,因此可适用于电脑设备及多种电子应用装置。而目前所使用的电子应用装置可以应用本发明的多功能小型存储卡接口与电脑装置进行数据转换,而毋需如传统的存储卡一般须经由一转接器转换数据格式。The purpose of the present invention is to provide a multi-functional small memory card, wherein the multi-functional small memory card has the design of 4 pins and 8 pins at the same time, and can support the traditional USB interface and the SFMI interface defined in the present invention at the same time , so it can be applied to computer equipment and various electronic application devices. However, the currently used electronic application device can use the multifunctional small memory card interface of the present invention to perform data conversion with the computer device, without the need to convert the data format through an adapter like the traditional memory card.

为达到上述目的本发明提供一种多功能小型存储卡,用于储存数字信息功能支援其他IO功能,包含一存储卡I/O功能模组提供储存数字信息功能,一存储器提供储存数字信息功能,及一主控制器是连接于该存储卡I/O功能模组及该存储器之间。该多功能小型存储卡同时具有4脚位及8脚位的设计。4脚位的设计是用于于基本的USB接口。8脚位的设计称为SFMI接口,由4-bit双向指令/资料/状态总线、时脉同步信号、系统接口及存储卡插置侦测信号,以及电源与接地所组成,其中电源与接地,同于USB接口中的电源与接地接脚。In order to achieve the above object, the present invention provides a multifunctional small memory card for storing digital information and supporting other IO functions, including a memory card I/O function module for storing digital information, and a memory for storing digital information. And a main controller is connected between the memory card I/O function module and the memory. The multifunctional compact memory card has both 4-pin and 8-pin designs. The 4-pin design is used for basic USB interface. The 8-pin design is called the SFMI interface, which consists of a 4-bit bidirectional command/data/status bus, a clock synchronization signal, a system interface, a memory card insertion detection signal, and power and ground. Same as the power and ground pins in the USB interface.

本发明还提供一种多功能小型存储卡插槽,具有4脚位及8脚位的设计,其中4脚位的设计是用于于基本的USB接口,8脚位的设计用于SFMI接口,8脚位的SFMI接口有四个插脚同于USB接口的4脚位,另四个插脚则分布在该USB接口的四脚位之间。该插槽分为公插槽及母插槽。The present invention also provides a multifunctional small memory card slot, which has a design of 4 pins and 8 pins, wherein the design of 4 pins is used for the basic USB interface, and the design of 8 pins is used for the SFMI interface. The 8-pin SFMI interface has four pins that are the same as the 4-pin of the USB interface, and the other four pins are distributed between the four pins of the USB interface. The slot is divided into a male slot and a female slot.

附图说明Description of drawings

图1是本发明的多功能小型存储卡接口及对接的读写装置的基本架构Fig. 1 is the basic structure of the interface of the multifunctional small memory card of the present invention and the docking read-write device

图2是本发明中SDM接口的各个插脚的定义及功能;Fig. 2 is the definition and the function of each pin of SDM interface among the present invention;

图3是本发明中主控制器的基本结构;Fig. 3 is the basic structure of main controller among the present invention;

图4A是本发明侦测电路为对接SDM接口的状态的元件配置图;FIG. 4A is a component configuration diagram of a state where the detection circuit of the present invention is connected to the SDM interface;

图4B是本发明侦测电路为对接USB接口的状态的元件配置图;FIG. 4B is a component configuration diagram of a state where the detection circuit of the present invention is connected to a USB interface;

图5是本发明中封包识别码的内容;Fig. 5 is the content of packet identification code among the present invention;

图6是本发明中封包识别码的资料结构及该资料结构与时脉的关系图;Fig. 6 is the data structure of packet identification code among the present invention and the relationship figure of this data structure and clock;

图7是本发明中通信端点的资料结构及该资料结构与时脉的关系图;Fig. 7 is the data structure of communication end point among the present invention and the relationship diagram of this data structure and clock;

图8是本发明中资料长度的资料结构及该资料结构与时脉的关系图;Fig. 8 is the data structure of data length among the present invention and the relationship diagram of this data structure and clock;

图9是本发明中资料传输顺序的资料结构及该资料结构与时脉的关系图;Fig. 9 is the data structure of the data transmission sequence in the present invention and the relationship diagram between the data structure and the clock;

图10是本发明中错误检查码的资料结构及该资料结构与时脉的关系图;Fig. 10 is a data structure of an error check code in the present invention and a relationship diagram between the data structure and a clock;

图11是本发明中封包状态码的资料结构及该资料结构与时脉的关系图。FIG. 11 is a diagram showing the data structure of the packet status code and the relationship between the data structure and the clock in the present invention.

具体实施方式Detailed ways

本发明的多功能小型存储卡,主要区分为两种,第一种以储存数字信息功能为主,第二种以支援其他IO功能为主。两种功能均须具备:一、支援多功能小型存储卡接口的主控制器220,提供储存数字信息功能,其主控制器220另须具备可重复擦写式非挥发性存储器的控制接口;提供IO功能,其主控制器220另须具备可支援IO功能模组的控制接口。二、提供储存数字信息功能,须具备一大容量重复擦写式非挥发性存储器储存模组,以储存数字信息;提供IO功能,须具备一支援IO功能的IO功能模组。The multifunctional compact memory card of the present invention is mainly divided into two types, the first type is mainly used for storing digital information, and the second type is mainly used for supporting other IO functions. Both functions must be possessed: 1. The main controller 220 supporting the interface of the multifunctional small memory card provides the function of storing digital information, and its main controller 220 must also have a control interface of rewritable non-volatile memory; For the IO function, the main controller 220 must also have a control interface that can support the IO function module. 2. To provide the function of storing digital information, it must have a large-capacity rewritable non-volatile memory storage module to store digital information; to provide IO functions, it must have an IO function module that supports IO functions.

本发明的多功能小型存储卡如图1中所示,其中该多功能小型存储卡200包含一存储卡I/O功能模组210,一主控制器220,及一存储器230。经整合装置于印刷电路板上后,于印刷电路板上并提供多功能小型存储卡接口端子,裸露于外,以连接装置电子100。最后并于此己具完整电气功能的电路板外加塑胶射出成型的外壳,组装成为完整的多功能存储卡或IO卡。与该多功能小型存储卡对接的电子应用装置100包合装置模组110。格式转换器120,装置I/O 130。The multifunctional compact memory card of the present invention is shown in FIG. 1 , wherein the multifunctional compact memory card 200 includes a memory card I/O function module 210 , a main controller 220 , and a memory 230 . After the device is integrated on the printed circuit board, a multifunctional small memory card interface terminal is provided on the printed circuit board, which is exposed outside to connect the device electronics 100 . Finally, a circuit board with complete electrical functions is added with a plastic injection-molded shell to assemble a complete multi-function memory card or IO card. The electronic application device 100 docked with the multi-function compact memory card includes a device module 110 . Format Converter 120, Device I/O 130.

该存储卡I/O功能模组210是用于存储卡的数据输入及输出的功能模组及其包含连结端子及相关的电路结构。本发明的多功能小型存储卡可以同时支援USB接口及本发明定义的SFMI接口。其中该端子具有4脚位及8脚位的设计。4脚位的设计是用于于基本的USB接口,其包含一VCC脚位是由对接的装置端提供直流电源予本发明的多功能小型存储卡的脚位,以对多功能小型存储卡赋能,一GND(接地脚位),是对于本发明的设计提供接地保护及参考电位之用,另两个脚位分别为D+及D-脚位,为数据传输脚位。The memory card I/O function module 210 is a function module for data input and output of the memory card and includes connection terminals and related circuit structures. The multi-functional compact memory card of the present invention can simultaneously support the USB interface and the SFMI interface defined in the present invention. Wherein the terminal has a design of 4 pins and 8 pins. The design of 4 pins is used for the basic USB interface, which includes a VCC pin which provides DC power to the pins of the multi-functional compact memory card of the present invention from the docked device end, so as to give the multi-functional compact memory card Can, a GND (grounding pin), is to provide grounding protection and reference potential for the design of the present invention, and the other two pins are respectively D+ and D-pins, which are data transmission pins.

本发明的多功能小型存储卡接口为一8脚位的设计,由4-bit双向指令/资料/状态总线(D0-D3)、时脉同步信号(CLK)、系统接口及存储卡插置侦测信号(CD),以及电源脚位(VCC)与接地脚位(GND)所组成,总共仅需8组接点。防写保护功能由多功能小型存储卡内建的防写保护开关切换位置选择,并且通过接口通讯通知电子应用装置100。其中该VCC为一DC电源接点,是用于提供DC电流予多功能小型存储卡,以赋能该多功能小型存储卡;GND为接地接点,是用于提供接点保护及参考电位;CLK同步时脉信号,对于输出及输入数据提供同步时脉,以便于数据信号的时序重建及信号对齐之用,BD_CD为系统接口及存储卡插置侦测信号,是用于侦测输入及输出数据是为USB接口信号,亦或SFMI接口信号。D0为双向指令/资料/状态总线信号bit0,于USB模式工作中,为D-信号线;D1为双向指令/资料/状态总线信号bit1,于USB模式工作中,为D+信号线;D2为双向指令/资料/状态总线信号bit2,于USB模式工作中,不存在此信号线;且D3为双向指令/资料/状态总线信号bit3,于USB模式工作中,不存在此信号线The multi-functional small memory card interface of the present invention is an 8-pin design, which consists of 4-bit bidirectional command/data/status bus (D0-D3), clock synchronization signal (CLK), system interface and memory card insertion detection The test signal (CD), and the power pin (VCC) and the ground pin (GND), only need 8 sets of contacts in total. The anti-write protection function is selected by switching the position of the anti-write protection switch built in the multi-function compact memory card, and notifies the electronic application device 100 through interface communication. Wherein the VCC is a DC power contact, which is used to provide DC current to the multi-function compact memory card to empower the multi-function compact memory card; GND is a ground contact, which is used to provide contact protection and reference potential; when CLK is synchronized Pulse signal, which provides synchronous clock pulse for output and input data, so as to facilitate the timing reconstruction and signal alignment of data signals. BD_CD is a detection signal for system interface and memory card insertion, which is used to detect whether input and output data are for USB interface signal, or SFMI interface signal. D0 is the bidirectional command/data/status bus signal bit0, which is the D- signal line in the USB mode; D1 is the bidirectional command/data/status bus signal bit1, which is the D+ signal line in the USB mode; D2 is the bidirectional Instruction/data/status bus signal bit2, this signal line does not exist in USB mode; and D3 is bidirectional command/data/status bus signal bit3, in USB mode, this signal line does not exist

由上文中的说明可以了解本发明的SFMI接口与基本上的USB接口共用四个接点。即VCC,GND,D-(D0)及D+(D1)。另外本发明还包含CLK,BD_CD,D2及D3四个接点。所以在插接结构(包含插入端子及插槽)的设计上,可以在原来USB接口的四个接点之间另安排四个接点,而使得本发明SFMI接口的插接结构可以与USB接口的插接结构共用,而毋需另行配置不同的插接结构。It can be understood from the above description that the SFMI interface of the present invention shares four contacts with the basic USB interface. Namely VCC, GND, D-(D0) and D+(D1). In addition, the present invention also includes four contacts of CLK, BD_CD, D2 and D3. Therefore, in the design of the plug-in structure (including the plug-in terminal and the slot), four contacts can be arranged between the four contacts of the original USB interface, so that the plug-in structure of the SFMI interface of the present invention can be compared with the plug-in structure of the USB interface. The connection structure is shared, and there is no need to configure different plug structures.

本接口的另一特点,则在于4位元双向总线中D0及D1两组信号线,于电子应用装置100采用USB接口连接存储卡时,改采USB接口动作模式。而成为USB接口所需的D+与D-信号线。并支援标准USB接口的通讯模式,得以无须任何额外电子应用装置100,即可装置于个人电脑或支援USB系统接口的数字装置。Another feature of this interface is that two sets of signal lines D0 and D1 in the 4-bit bidirectional bus, when the electronic application device 100 uses the USB interface to connect to the memory card, the USB interface operation mode is adopted. And become the D+ and D- signal lines required by the USB interface. It also supports the communication mode of the standard USB interface, so that it can be installed on a personal computer or a digital device supporting the USB system interface without any additional electronic application device 100 .

请参见图3,本发明的主控制器220包含四个组件,一I/O控制器221,一存储器控制器222,一格式器223,及一解格式器224。其中该I/O控制器221是用于控制存储卡I/O功能模组210,包含决定该存储卡I/O功能模组210是以输入模式操作或以输出模式操作,或以SFMI接口或USB接口模式操作等。该存储器控制器222则用于控制存储器230,而格式器223,及一解格式器224则进行USB接口信号及SFMI接口信号的格式转换,以配合存储卡I/O功能模组210的操作模式。有关于格式器223,及解格式器224的动作此将于下文中加以说明。Referring to FIG. 3 , the main controller 220 of the present invention includes four components, an I/O controller 221 , a memory controller 222 , a formatter 223 , and a deformatter 224 . Wherein the I/O controller 221 is used to control the memory card I/O function module 210, including determining whether the memory card I/O function module 210 operates in an input mode or an output mode, or uses an SFMI interface or USB interface mode operation, etc. The memory controller 222 is used to control the memory 230, and the formatter 223 and a deformatter 224 perform format conversion of the USB interface signal and the SFMI interface signal to match the operation mode of the memory card I/O function module 210 . The actions of the formatter 223 and the de-formatter 224 will be described below.

系统接口与存储卡插置侦测信号:System interface and memory card insertion detection signal:

存储卡插置侦测信号于存储卡内部连接至控制晶片的多功能输出入控制信号,于支援多功能小型存储卡接口的电子应用装置100端则经一电阻连接至电源。于支援USB系统端的接口则不连接此信号,以达成多功能存储卡可借由此信号侦测电子应用装置100采用的系统接口,而电子应用装置100亦可利用此信号达成侦测小型存储卡是否插置定位的功能。The memory card insertion detection signal is connected to the multi-function I/O control signal of the control chip inside the memory card, and connected to the power supply through a resistor at the end of the electronic application device 100 supporting the multi-function small memory card interface. This signal is not connected to the interface supporting the USB system side, so that the multi-function memory card can use this signal to detect the system interface adopted by the electronic application device 100, and the electronic application device 100 can also use this signal to realize the detection of the small memory card Whether to insert the positioning function.

该存储卡I/O功能模组的接口侦测电路包含一电源310,一BD输入侦测端320,一CD输出侦测端330,一第一二极管360,一第二二极管370,一第一电阻340,及一第二电阻350。The interface detection circuit of the memory card I/O function module includes a power supply 310, a BD input detection terminal 320, a CD output detection terminal 330, a first diode 360, and a second diode 370 , a first resistor 340, and a second resistor 350.

该存储卡I/O功能模组的功能是经由侦测系统接口及存储卡插置侦测信号(BD_CD)的出现与否而决定插入端为USB接口或SFMI接口。The function of the memory card I/O function module is to determine whether the insertion port is a USB interface or an SFMI interface by detecting the presence or absence of the system interface and the memory card insertion detection signal (BD_CD).

小型存储卡插置于支援小型存储卡接口的电子应用装置100,由于电子应用装置100不论小型存储卡是否插置均持续供应电源,小型存储卡于启动时,应首先维持CD信号为高阻抗状态,以免影响BD_CD信号侦测检查动作。然后随即检查BD_CD信号的状态。若BD_CD信号状态为高电位,即代表系统端支援小型存储卡接口,而进入小型存储卡接口动作模式,并随即驱动输出CD信号为低电位,通知电子应用装置100小型存储卡已插置定位;反之,若BD_CD信号为低电伉,则表示系统端未将BD_CD信号透过电阻连接到电源,代表支援USB接口,而进入USB接口动作模式。The small memory card is inserted into the electronic application device 100 that supports the small memory card interface. Since the electronic application device 100 continues to supply power regardless of whether the small memory card is inserted, the small memory card should first maintain the CD signal in a high impedance state when starting the small memory card. , so as not to affect the BD_CD signal detection check action. Then immediately check the state of the BD_CD signal. If the state of the BD_CD signal is a high potential, it means that the system side supports the small memory card interface, and enters the small memory card interface operation mode, and then drives the output CD signal to a low potential, notifying the electronic application device 100 that the small memory card has been inserted and positioned; Conversely, if the BD_CD signal is low, it means that the system does not connect the BD_CD signal to the power supply through a resistor, which means it supports the USB interface and enters the USB interface operation mode.

在图4A、图4B所示的电路中,VCC接点连结电源310,系统接口及存储卡插置侦测信号BD_CD经顺向连结的第一二极管360连结BD输入侦测端320,且经逆个连结的第二二极管370连结该CD输出侦测端,而系统接口及存储卡插置侦测信号BD_CD以一第二电阻连结接地端GND,该VCC与系统接口及存储卡插置侦测信号之间连结该第一电阻。在图中第一电阻为10KΩ且第二电阻为100KΩ,其是本发明的一较佳的实施例,其他适当的数值也可以应用在本发明中,而不受限于图式中的较佳实施例。该第一电阻及第二电阻的功能在于将BD_CD及VCC升压以提供所需要的电路动作。In the circuit shown in FIG. 4A and FIG. 4B, the VCC contact is connected to the power supply 310, the system interface and memory card insertion detection signal BD_CD is connected to the BD input detection terminal 320 through the first diode 360 connected in the forward direction, and is connected to the BD input detection terminal 320 through The second diode 370 connected in reverse is connected to the CD output detection terminal, and the system interface and memory card insertion detection signal BD_CD is connected to the ground terminal GND through a second resistor, and the VCC is connected to the system interface and memory card insertion The first resistor is connected between the detection signals. In the figure, the first resistance is 10KΩ and the second resistance is 100KΩ, which is a preferred embodiment of the present invention. Other appropriate values can also be applied in the present invention, and are not limited to the preferred ones in the drawings. Example. The function of the first resistor and the second resistor is to boost BD_CD and VCC to provide the required circuit operation.

当USB接口插入该多功能小型存储卡时,参考图4A,则第一二极管360将导通而使得BD输入端320导通,因此可以知道插入的接口为SFMI接口。反之当系统接口及存储卡插置侦测信号BD_CD没有输入时,第一二极管360不导通,所以得知输入的信号为USB接口信号。When the USB interface is inserted into the multifunctional compact memory card, referring to FIG. 4A , the first diode 360 will be turned on and the BD input terminal 320 will be turned on, so it can be known that the inserted interface is an SFMI interface. Conversely, when the system interface and the memory card insertion detection signal BD_CD are not input, the first diode 360 is not turned on, so it is known that the input signal is a USB interface signal.

反之在输出模式下,当输出的信号为SFMI接口信号时,第二二极管370导通,输出的信号为SFMI接口信号,反之为USB接口信号。当此多功能小型存储卡在侦测到插置接口为SFMI接口时,随即将BD_CD信号转为输出模式,并输出低电位以通知读写装置该卡已插置定位。On the contrary, in the output mode, when the output signal is the SFMI interface signal, the second diode 370 is turned on, and the output signal is the SFMI interface signal, otherwise it is the USB interface signal. When the multi-functional compact memory card detects that the insertion interface is an SFMI interface, it immediately turns the BD_CD signal into an output mode, and outputs a low potential to notify the read-write device that the card has been inserted and positioned.

多功能小型存储卡通讯协定说明:Description of the communication protocol of the multi-function compact memory card:

多功能小型存储卡接口,采用半双工,4位元串流方式,以CLK信号为基准,每一时脉可传输4位元资讯。资讯传输方式由电子应用装置主控,下达传输指令及传输长度后,决定资料阶段传输长度。为提高本接口的应用性,及简化整体系统设计,接口传输以资料封包(packet)为单位。且其通讯协定以存储卡内模拟的通讯端点(endpoint)为资讯传输的来源(source)或目标(sink)。The multi-functional small memory card interface adopts half-duplex, 4-bit serial mode, with CLK signal as the reference, and each clock can transmit 4-bit information. The information transmission method is controlled by the electronic application device, and the transmission length of the data phase is determined after the transmission command and the transmission length are issued. In order to improve the applicability of this interface and simplify the overall system design, the unit of interface transmission is data packet (packet). And the communication protocol uses the simulated communication endpoint (endpoint) in the memory card as the source (source) or target (sink) of information transmission.

所有支援“功能小型存储卡接口”的存储卡或IO卡,均至少需支援一组通讯端点,称为“控制端点”(Control Endpoint),其端点位址为0。电子应用装置得以透过此一控制端点取得存储卡或IO卡的详细描述,知其功能及其他通讯端点的设定。并进行适当的设置后,启动其功能,并进行资料的传输。All memory cards or IO cards that support the "functional small memory card interface" must support at least one set of communication endpoints, called "control endpoints" (Control Endpoint), whose endpoint address is 0. The electronic application device can obtain the detailed description of the memory card or IO card through this control endpoint, know its function and the settings of other communication endpoints. And after making appropriate settings, start its function and carry out data transmission.

(1)起始位元/结束位元-Start bit/End bit(1) Start bit/end bit-Start bit/End bit

电子应用装置与存储卡于启动资料传输时,均须于资料封包最前端产生一个时脉周期D0-D3均为0的起始位元,于资料封包最末端附加两个时脉周期D0-D3均为1的结束位元。When the electronic application device and the memory card start data transmission, they must generate a start bit of clock cycle D0-D3 at the beginning of the data packet, and add two clock cycles D0-D3 at the end of the data packet. All end bits are 1.

(2)封包识别码-Packet Identifier(PID)(2) Packet identification code - Packet Identifier (PID)

请参考图5,通讯封包自封包识别码(PID)开始,并视识别码种类不同,得应用于不同场合。每一组资料封包含有:1.封包识别码:标示封包传输资料的方向,传输端点位址,及资料长度;2.酬载资料,内含一组CRC资料错误侦测代码;3.封包状态码,接收酬载资料的一方,传回接收状态确认资料是否正确收到。封包识别码0001标示电子应用装置将进行资料输出的传输。封包识码1001标示电子应用装置将进行资料输入的传输。封包识码1101标示电子应用装置将针对控制端点进行设置或取得相关资讯。封包识码0010标示资讯接受端确认资料封包收妥。封包识码1010标示资讯接受端暂时无法接收资讯,或传出端暂时无法传出资讯。封包识码1110标示通讯端点停止工作,或控制端点不支援该控制指令。Please refer to FIG. 5 , the communication packet starts with a Packet Identification Code (PID), and depending on the type of the PID, it must be used in different occasions. Each group of data packets includes: 1. Packet identification code: indicating the direction of data transmission in the packet, the address of the transmission end point, and the length of the data; 2. Payload data, including a set of CRC data error detection codes; 3. Packet status code, the party receiving the payload data will return the receiving status to confirm whether the data is received correctly. The PID 0001 indicates that the electronic application device will perform data output transmission. The packet ID 1001 indicates that the electronic application device will transmit data input. The packet ID 1101 indicates that the electronic application device will set or obtain relevant information for the control endpoint. The packet identification code 0010 indicates that the information receiving end confirms that the data packet has been received. The packet ID 1010 indicates that the information receiving end cannot receive information temporarily, or the sending end cannot send information temporarily. The packet ID 1110 indicates that the communication endpoint is out of work, or the control endpoint does not support the control command.

PID识别码合计4位元,为防通讯失误,予以反向附加4位元,形成合计8位元以升幂方式排列,分两次于两组时脉中完成传输。如图6中所示。接收端收到正确完整的PID及PID’,且PID=(PID’)’即确认所收到PID正确无误。The PID identification code has a total of 4 bits. In order to prevent communication errors, 4 bits are added in reverse to form a total of 8 bits arranged in ascending powers, and the transmission is completed in two sets of clocks. As shown in Figure 6. When the receiving end receives the correct and complete PID and PID', and PID=(PID')', it confirms that the received PID is correct.

(3)通讯端点-Endpoint(3) Communication endpoint-Endpoint

通讯端点是支援小型存储卡接口的小型存储卡或IO卡与电子应用装置进行资料传输的基本单位。对应个别通讯端点,于小型存储卡或IO卡中,具备特定容量大小的资料缓冲区,作为暂时存储电子应用装置与小型存储卡之间通讯封包所酬载资料之用。A communication endpoint is a basic unit for data transmission between a small memory card or an IO card supporting a small memory card interface and an electronic application device. Corresponding to individual communication endpoints, there is a data buffer with a specific capacity in the small memory card or IO card, which is used to temporarily store the data carried in the communication packet between the electronic application device and the small memory card.

支援小型存储卡接口的小型存储卡或IO卡,最高可支援16组通讯端点,分别以通讯封包中的通讯端点位址指定封包传输的对象。The small memory card or IO card that supports the small memory card interface can support up to 16 groups of communication endpoints, and the communication endpoint addresses in the communication packets are used to specify the object to be transmitted by the packet.

支援小型存储卡接口的小型存储卡或IO卡,至少须具备一组通讯端点,其位址设定为0。电子应用装置透过小型存储卡接口侦测到小型存储卡插置后,即可透过通讯端点0取得有关小型存储卡的识别码、功能形式、支援通讯端点数量、各通讯端点位址及通讯端点形式等相关资讯。A small memory card or an IO card supporting the small memory card interface must have at least one set of communication endpoints, whose address is set to 0. After the electronic application device detects the insertion of the small memory card through the small memory card interface, it can obtain the identification code, function type, number of supported communication endpoints, addresses of each communication endpoint and communication information of the small memory card through the communication endpoint 0. Endpoint form and other related information.

通讯端点区分为下列四种,分别适用于电子应用装置与小型存储卡或IO卡之间进行不同型态的资料传输。The communication endpoints are divided into the following four types, which are respectively suitable for different types of data transmission between the electronic application device and the small memory card or IO card.

控制端点-小型存储卡与IO卡必须具备一组端点位址为0的控制端点。控制端点的功能是容许电子应用装置于启动小型存储卡时,取得小型存储卡的识别码、功能形式、支援通讯端点数量、各通讯端点位址及通讯端点形式等相关资讯。Control endpoints - small memory cards and IO cards must have a set of control endpoints whose endpoint address is 0. The function of the control endpoint is to allow the electronic application device to obtain relevant information such as the identification code, function type, number of supported communication endpoints, address of each communication endpoint, and communication endpoint form of the small memory card when the small memory card is activated.

资料输入端点-用于容许电子应用装置自小型存储卡或IO卡输入大量资料。Data input endpoint - used to allow electronic application devices to input large amounts of data from compact memory cards or IO cards.

资料输出端点-用于容许电子应用装置将大量资料输出至小型存储卡。Data output endpoint - used to allow electronic applications to output large amounts of data to a small memory card.

状态中断输入端点-用于容许小型存储卡或IO卡设定要求电子应用装置以设定的间隔周期,重复自小型存储卡或IO卡输入状态中断输入资讯。Status interrupt input terminal-used to allow the compact memory card or IO card to be configured to require the electronic application device to repeatedly input status interrupt input information from the compact memory card or IO card at a set interval.

如图7中所示,传输标示封包借由标示通讯端点,指定后续资料封包或状态封包对应的通讯端点。通讯端点在传输标示封包中,以4位元,紧接着PID后面在一个时脉通期中完成传输。As shown in FIG. 7 , the transmission marker packet designates the communication endpoint corresponding to the subsequent data packet or status packet by marking the communication endpoint. In the transmission identification packet, the communication endpoint completes the transmission with 4 bits followed by the PID in one clock period.

(4)资料长度-Data Length(4) Data Length - Data Length

如图8中所示,在ENDP后,以3个时脉周期内传输12个位元代表DATA长度的DATL。DATL以1个BYTE为单位,0x000代表4096个BYTE,最小值为0x001代表1个BYTEAs shown in FIG. 8, after ENDP, 12 bits of DATL representing the length of DATA are transmitted within 3 clock cycles. DATL takes 1 BYTE as the unit, 0x000 represents 4096 BYTEs, and the minimum value is 0x001 represents 1 BYTE

(5)酬载资料-Payload Data(5) Payload Data-Payload Data

封包实际承载的资料(PDAT),并传输至通讯端点的资讯。DATL设定酬载资料长度。传输时,每一位元组分别于2个时脉周期内传输完毕。传输方向由电子应用装置于封包识别码中指定。如图9中所示,酬载资料最后附加16个时脉周期的CRC16错误检查码。其中,CRC16的演算法为除2求余除法,更进一步可为具有G(X)=X16+X15+X2+1形式的多项式除2求余除法。资料传输顺序如图10中所示。The actual data carried by the packet (PDAT), and the information transmitted to the communication endpoint. DATL sets payload data length. During transmission, each byte is transmitted within 2 clock cycles. The transmission direction is specified by the electronic application device in the PID. As shown in FIG. 9 , CRC16 error checking codes of 16 clock cycles are appended at the end of the payload data. Wherein, the calculation algorithm of CRC16 is division by 2 and remainder division, and further may be polynomial division by 2 and remainder division in the form of G(X)=X16+X15+X2+1. The data transmission sequence is shown in Figure 10.

(6)封包状态码-Packet Status Acknowledge(6) Packet Status Code-Packet Status Acknowledge

由接收资料的一方,于酬载资料接收完毕后,确认检查码是否符合,然后依据接收结果确认接收资料是否正确。若正确完成接收,则传回ACK,若暂时无法完成接收,或检查码显示资料有错误,则传回NAK要求重传,若存储卡内部发生错误,或执行指令结果发生错误,则传回STALL。如图11中所示。The party receiving the data, after receiving the payload data, confirms whether the check code matches, and then confirms whether the received data is correct according to the receiving result. If the reception is completed correctly, ACK will be returned. If the reception cannot be completed temporarily, or the check code shows that the data is wrong, NAK will be returned to request retransmission. If an error occurs inside the memory card, or an error occurs in the execution command result, STALL will be returned. . As shown in Figure 11.

(7)资料格式(7) Data format

所有通讯封包均由电子应用装置(系统端)发动进行传输,资料封包的顺序依序为起始位元,封包识别码,通讯端点,资料长度,酬载资料,封包状态码,资料格式,结束位元。由系统端启动资料传输产生封包识别码、指定通讯端点及资料长度。All communication packets are initiated by the electronic application device (system side) for transmission. The sequence of data packets is start bit, packet identification code, communication endpoint, data length, payload data, packet status code, data format, end bits. The data transmission is initiated by the system to generate a packet identification code, specify the communication endpoint and data length.

若封包属于IN封包,装置端收到上述资讯后,若未能随即产生所需的资料,可回应装置状态码NAK,系统端随即中止后续传输,并可随即重新启动资料传输,再度尝试取得资料封包。若装置端已可回应所需资料,则装置端产生起始位元,并紧接着开始传回装置内部通讯端点内所占存的资讯,待满足系统端要求的资料长度后,随即附加16位元的CRC检查码。系统端收到检查码后,经检查确认无误,即可传回ACK。若资料有误,则传回NAK,并可重新启动封包,以取得正确的资料。If the packet is an IN packet, if the device fails to generate the required data immediately after receiving the above information, it can respond with the device status code NAK, and the system will stop the subsequent transmission immediately, and then restart the data transmission, and try to obtain the data again packet. If the device can respond to the required data, the device will generate a start bit, and then begin to return the information stored in the internal communication endpoint of the device. After the data length required by the system is met, 16 bits will be added. The CRC check code of the element. After receiving the check code, the system can send back ACK after checking and confirming that it is correct. If the data is wrong, NAK will be returned, and the packet can be restarted to obtain the correct data.

若封包属于OUT或SETUP封包,系统端于完成封包识别码、通讯端点位址、资料长度后,随即开始传入拟传入的资料,待达到系统端要求传入的资料长度后,随即附加16位元的CRC检查码。装置端收到检查码后,经检查确认无误,即可传回ACK。若资料有误,则传回NAK,并且由系统端主控决定是否重新启动封包,以取得正确资料。If the packet belongs to OUT or SETUP packet, the system will start to transfer the data to be transferred after completing the packet identification code, communication endpoint address, and data length. After the data length required by the system is reached, it will add 16 Bit CRC check code. After the device side receives the check code, it can send back ACK after checking and confirming that it is correct. If the data is wrong, NAK will be sent back, and the main control of the system will decide whether to restart the packet to obtain the correct data.

(8)控制传输模式(8) Control transmission mode

电子应用装置可透过控制传输模式,自预设的传输端点0取得与多功能存储卡相关的资讯,或设定其相关功能。控制传输模式区分为SETUP阶段、DATA阶段、STATUS阶段,其格式如下:The electronic application device can obtain information related to the multi-function memory card from the default transmission endpoint 0 or set its related functions by controlling the transmission mode. The control transmission mode is divided into SETUP phase, DATA phase, and STATUS phase, and its format is as follows:

在SETUP阶段,系统端送出SETUP封包,包含SETUP封包识别码,通讯端点位址为0,资料长度为8位元组接着由系统装置送出8位元组的SETUP指令代码与参数与2位元组CRC16,最后由装置端传回状态码确认封包是否接收正常。In the SETUP stage, the system sends a SETUP packet, including the SETUP packet identification code, the communication endpoint address is 0, and the data length is 8 bytes. Then the system device sends 8-byte SETUP command code and parameters and 2-byte CRC16, and finally the status code is returned by the device to confirm whether the packet is received normally.

在8位元组的指令与参数中,自第一位元组开始,分别代表:bmRequestType、bRequest、wValue、wIndex、wLength等,其定义及用途请参阅USB标准。其中各个参数的意义可参见表一中的控制传输资料格式表: 偏移位址     栏位名称 占用空间(位元组) 设定值           说明   0     bmRequestType     1 位元值 指令形式:D7:资料传输方向0=读写装置输出至小型存储卡1=小型存储卡输出至读写装置D6...5:指令种类0=标准指令1=装置类别专属指令2=厂商专属特殊指令3=保留D4...0:指令目标对象0=装置本身1=接口2=通讯端点3=其他4...31=保留   1     bRequest     1 设定值 设定指令代码(代码参阅表二)   2     wValue     2 设定值 依不同指令代码具备不同意义的设定值,长度为两个位元组   4     wIndex     2 设定值 依不同指令代码具备不同意义的设定值,用于指定索引值或偏移值   6     wLength     2 数值 设定资料长度 Among the 8-byte commands and parameters, starting from the first byte, they respectively represent: bmRequestType, bRequest, wValue, wIndex, wLength, etc. Please refer to the USB standard for their definitions and uses. The meaning of each parameter can be found in the control transmission data format table in Table 1: offset address field name Occupied space (bytes) set value illustrate 0 bmRequestType 1 bit value Command form: D7: Data transmission direction 0 = output from read-write device to small memory card 1 = output from small memory card to read-write device D6...5: command type 0 = standard command 1 = device-specific command 2 = manufacturer-specific Special command 3=reserved D4...0: command target object 0=device itself 1=interface 2=communication endpoint 3=others 4...31=reserved 1 bRequest 1 set value Set command code (code refer to Table 2) 2 wValue 2 set value The setting value has different meanings according to different command codes, and the length is two bytes 4 wIndex 2 set value Set values with different meanings according to different instruction codes, used to specify index value or offset value 6 wLength 2 value set data length

表一控制传输资料格式表Table 1 Control transmission data format table

除标准指令码以外,装置类别专属指令与厂商专属特殊指令均由个别装置视其应用,或由厂商自行制定的。支援小型存储卡标准接口的小型存储卡或IO卡均必须支援标准指令码。标准指令码的定义请参阅下表: bmRequestType     bRequest   wValue   wIndex  wLength     Data 00000000B00000001B00000010B  CLEAR_FEATURE  FeatureSelector  0  0 1000000B  GET_CONFIGURATION  0  0  1 组态设定值 1000000B  GET_DESCRIPTOR  描述元种类与索引值  0或语言代码  描述元长度 描述元资料 10000001B  GET_STATUS  0  0接口码端点码  2 取得装置、接口、或传输端点状态 0000000B  SET_ADDRESS  装置位址  0  0 0000000B  SET_CONFIGURATION  组态设定值  0  0 0000000B  SET_DESCRIPTOR  描述元种类与索引码  0或语言代码  描述元长度 描述元 00000000B00000001B00000010B  SET_FEATURE  FeatureSelector  0接口码端点码  0 00000001B  SET_INTERFACE  AlternateSetting  接口码  0 In addition to the standard command codes, device type-specific commands and manufacturer-specific special commands are determined by individual devices or formulated by manufacturers themselves. The small memory card or the IO card that supports the standard interface of the small memory card must support the standard instruction code. Please refer to the table below for the definition of standard script codes: bmRequestType bRequest wValue wIndex wLength Data 00000000B00000001B00000010B CLEAR_FEATURE FeatureSelector 0 0 none 1000000B GET_CONFIGURATION 0 0 1 Configuration setpoint 1000000B GET_DESCRIPTOR Descriptor type and index value 0 or language code descriptor length description metadata 10000001B GET_STATUS 0 0 interface code endpoint code 2 Get device, interface, or transport endpoint status 0000000B SET_ADDRESS device address 0 0 none 0000000B SET_CONFIGURATION Configuration setpoint 0 0 none 0000000B SET_DESCRIPTOR Descriptor type and index code 0 or language code descriptor length Descriptor 00000000B00000001B00000010B SET_FEATURE FeatureSelector 0 interface code endpoint code 0 none 00000001B SET_INTERFACE Alternate Setting interface code 0 none

表二标准指令代码表Table 2 Standard instruction code table

在资料阶段,视bRequest代码及wLength,决定后续资料阶段传输的方向及长度。并由系统端启动依一般资料传输作业进行,传输长度依wLength设定。In the data stage, depending on the bRequest code and wLength, determine the direction and length of the subsequent data stage transmission. It is started by the system side according to the general data transmission operation, and the transmission length is set according to wLength.

在状态阶段,资料阶段完成后,视资料阶段的方向由接收资料的一方传回状态码确认资料传输结果是否正确。In the status phase, after the data phase is completed, depending on the direction of the data phase, the party receiving the data returns a status code to confirm whether the data transmission result is correct.

(9)多功能小型存储卡接口的应用(9) Application of multifunctional small memory card interface

多功能小型存储卡接口可适用于不同用途的应用,前述仅涵盖实体层的定义,并未限制其应用领域。于补充制定适用的指令集与通讯协定,即可应用于储存装置、通讯装置,或其他适用的应用领域。The multifunctional compact memory card interface can be applied to applications of different purposes, and the foregoing only covers the definition of the physical layer, and does not limit its application field. Supplementary development of applicable instruction sets and communication protocols can be applied to storage devices, communication devices, or other applicable application fields.

Claims (12)

1.一种多功能小型存储卡,用于储存数字信息及支援数据的输入及输出;该多功能小型存储卡接口包含:1. A multifunctional small memory card for storing digital information and supporting data input and output; the multifunctional small memory card interface includes: 一存储卡I/O功能模组,用于支援IO功能;A memory card I/O function module for supporting IO functions; 一存储器,用于储存数字信息功能;以及a memory for the function of storing digital information; and 一主控制器,具备可重复擦写式非挥发性存储器的控制接口和可支援IO功能模组的控制接口,连接于该存储卡I/O功能模组及该存储器之间,从而实现存储数字信息和支援IO的控制;A main controller, equipped with a control interface of a rewritable non-volatile memory and a control interface that can support an IO function module, is connected between the memory card I/O function module and the memory, so as to realize the storage of digital Control of information and supporting IO; 其特征在于:该多功能小型存储卡同时具有4脚位及8脚位的设计,其中4脚位的设计是用于于基本的USB接口,多功能小型存储卡另一接口为一8脚位的设计,称为SFMI接口,由4-bit位元双向指令/资料/状态总线、时脉同步信号、系统接口及存储卡插置侦测信号,以及电源与接地所组成,总共仅需8组接点,其中电源接脚与接地接脚同于USB接口中的电源接脚与接地接脚。It is characterized in that: the multi-functional small memory card has 4-pin and 8-pin designs at the same time, wherein the 4-pin design is used for the basic USB interface, and the other interface of the multi-functional small memory card is an 8-pin The design, called SFMI interface, consists of 4-bit bidirectional command/data/status bus, clock synchronization signal, system interface and memory card insertion detection signal, as well as power supply and grounding. Only 8 groups are needed in total. The contacts, wherein the power pin and the ground pin are the same as the power pin and the ground pin in the USB interface. 2.根据权利要求1所述的多功能小型存储卡,其中主控制器还包含:2. The multifunctional compact memory card according to claim 1, wherein the main controller also includes: 一I/O控制器,是用于控制存储卡I/O功能模组,包含决定该存储卡I/O功能模组是以输入模式操作或以输出模式操作,或以SFMI接口或USB接口模式操作;An I/O controller is used to control the memory card I/O function module, including determining whether the memory card I/O function module operates in input mode or output mode, or operates in SFMI interface or USB interface mode operate; 一存储器主控制器,是用于控制该存储器;a memory master controller for controlling the memory; 一格式器,将来自存储器的输出数据格式化为接收装置可接收的格式;以及a formatter for formatting the output data from the memory into a format receivable by the receiving device; and 一解格式器,是用于将来自接收装置的数据解格式成为存储器所接收的数据予以储存。A deformatter is used for deformatting the data from the receiving device into data received by the memory for storage. 3.根据权利要求1所述的多功能小型存储卡,其特征在于:4-bit双向指令/资料/状态总线中有两个信号总线与USB接口的信号总线相同。3. The multifunctional compact memory card according to claim 1, wherein two signal buses in the 4-bit bidirectional command/data/status bus are the same as the signal buses of the USB interface. 4.根据权利要求3所述的多功能小型存储卡,其特征在于:D0为双向指令/资料/状态总线信号bit0,于USB模式中,为D-信号线;D1为双向指令/资料/状态总线信号bit1,于USB摸式中,为D+信号线;D2为双向指令/资料/状态总线信号bit2,于USB模式工作中,不存在此信号线;且D3为双向指令/资料/状态总线信号bit3,于USB模式工作中,不存在此信号线。4. The multifunctional compact memory card according to claim 3, characterized in that: D0 is a bidirectional command/data/status bus signal bit0, which is a D-signal line in the USB mode; D1 is a bidirectional command/data/status The bus signal bit1 is the D+ signal line in the USB mode; D2 is the bidirectional command/data/status bus signal bit2, which does not exist in the USB mode; and D3 is the bidirectional command/data/status bus signal bit3, in USB mode, this signal line does not exist. 5.根据权利要求1所述的多功能小型存储卡,其特征在于:该存储卡I/O功能模组,主控制器,及存储器整合于电路板后,于电路板上并提供多功能小型存储卡接口端子,裸露于外,以连接电子应用装置。5. The multifunctional small memory card according to claim 1, characterized in that: the memory card I/O function module, main controller, and memory are integrated on the circuit board, and a multifunctional small memory card is provided on the circuit board. The memory card interface terminal is exposed to the outside to connect with the electronic application device. 6.根据权利要求1所述的多功能小型存储卡,其特征在于:该电路板为印刷电路板。6. The multifunctional compact memory card according to claim 1, wherein the circuit board is a printed circuit board. 7.根据权利要求1所述的多功能小型存储卡,其特征在于:该存储卡I/O功能模组的接口包含一侦测电路,是用于侦测耦合的接口为USB接口或SFMI接口。7. The multifunctional compact memory card according to claim 1, characterized in that: the interface of the memory card I/O function module includes a detection circuit, and the interface for detecting coupling is a USB interface or an SFMI interface . 8.根据权利要求7所述的多功能小型存储卡,其特征在于:该侦测电路包含:一电源,一输入侦测端,一输出侦测端,一第一单向电流元件,一第二单向电流元件,一第一电阻,及一第二电阻;8. The multifunctional compact memory card according to claim 7, characterized in that: the detection circuit comprises: a power supply, an input detection terminal, an output detection terminal, a first unidirectional current element, a first Two unidirectional current elements, a first resistor, and a second resistor; 其中VCC接点连结电源,系统接口及存储卡插置侦测信号经顺向连结的第一单向电流元件连结输入侦测端,且经逆向连结的第二单向电流元件连结该输出侦测端,而系统接口及存储卡插置侦测信号以一第二电阻连结接地端,该VCC与系统接口及存储卡插置侦测信号之间连结该第一电阻。The VCC contact is connected to the power supply, the system interface and the memory card insertion detection signal are connected to the input detection terminal through the first unidirectional current element connected in the forward direction, and the output detection terminal is connected to the second unidirectional current element connected in the reverse direction. , and the system interface and the memory card insertion detection signal are connected to the ground terminal through a second resistor, and the first resistor is connected between the VCC and the system interface and the memory card insertion detection signal. 9.根据权利要求8所述的多功能小型存储卡,其特征在于:该单向电流元件为二极管。9. The multifunctional compact memory card according to claim 8, wherein the unidirectional current element is a diode. 10.根据权利要求1所述的多功能小型存储卡,其特征在于:该存储器为一大容量重复擦写式非挥发性存储器储存模组,以储存数字信息。10. The multifunctional compact memory card according to claim 1, wherein the memory is a large-capacity rewritable non-volatile memory storage module for storing digital information. 11.一种多功能小型存储卡插槽,具有4脚位及8脚位的设计,其中4脚位的设计是用于于基本的USB接口,8脚位的设计用于SFMI接口,8脚位的SFMI接口有四个插脚同于USB接口的4脚位,另四个插脚则分布在该USB接口的四脚位之间。11. A multifunctional small memory card slot with 4-pin and 8-pin designs, of which the 4-pin design is used for the basic USB interface, the 8-pin design is used for the SFMI interface, and the 8-pin The 4-pin SFMI interface has four pins that are the same as the 4 pins of the USB interface, and the other four pins are distributed among the four pins of the USB interface. 12.根据权利要求11所述的多功能小型存储卡插槽,其特征在于:该插槽分为公插槽及母插槽。12. The multifunctional compact memory card slot according to claim 11, wherein the slot is divided into a male slot and a female slot.
CN 02132090 2002-09-10 2002-09-10 Versatile compact memory card interface compatible with USB interface Expired - Fee Related CN1198196C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 02132090 CN1198196C (en) 2002-09-10 2002-09-10 Versatile compact memory card interface compatible with USB interface

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 02132090 CN1198196C (en) 2002-09-10 2002-09-10 Versatile compact memory card interface compatible with USB interface

Publications (2)

Publication Number Publication Date
CN1482526A CN1482526A (en) 2004-03-17
CN1198196C true CN1198196C (en) 2005-04-20

Family

ID=34145102

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 02132090 Expired - Fee Related CN1198196C (en) 2002-09-10 2002-09-10 Versatile compact memory card interface compatible with USB interface

Country Status (1)

Country Link
CN (1) CN1198196C (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1331037C (en) * 2004-06-03 2007-08-08 旺玖科技股份有限公司 A memory card with multiple interface functions and its transmission mode selection method
KR20070033714A (en) * 2005-09-22 2007-03-27 삼성전자주식회사 Data transmission line wiring method
CN101916385B (en) * 2010-06-01 2012-10-03 福建新大陆电脑股份有限公司 Memory card type bar code decoding device

Also Published As

Publication number Publication date
CN1482526A (en) 2004-03-17

Similar Documents

Publication Publication Date Title
JP2004078879A (en) Multifunctional compact memory card interface 1 applicable to usb interface
TWI222564B (en) Flashtoaster for reading several types of flash memory cards with or without a PC
US7809866B2 (en) Double interface SD flash memory card
US20050114587A1 (en) ExpressCard with On-Card Flash Memory with Shared Flash-Control Bus but Separate Ready Lines
US8070067B2 (en) Receptacles for removable electrical interface devices
US7171502B2 (en) USB system having card-type USB interface connector
CN101350001A (en) Data sharing and transmission system and method
EP1403814B1 (en) Electronic apparatus, information processing apparatus, adapter apparatus, and information exchange system
US20070145154A1 (en) Interface for a removable electrical card
CN101075299A (en) Multi-task micro memory card and interface detection switching method
CN1198196C (en) Versatile compact memory card interface compatible with USB interface
CN2590061Y (en) A kind of multifunctional small memory card and its slot
CN100426278C (en) Communication method between electronic device and multifunctional small-sized memory card
CN1241096C (en) IDE hard disc interface for supporting hot inserting and startup as inserting memory card
US7137564B2 (en) Communication protocol for multi-functional mini-memory card suitable for small form memory interface and usb interfaces
CN117741404A (en) Multifunctional testing method and device for chip
TWI261788B (en) Small-form-factor memory card interface (II) having multi-functional communication interface, formatter and format converter
US20070174516A1 (en) Adaptor
CN2612995Y (en) Card reader
CN2599661Y (en) Memory card reading device using SATA interface
CN113052288B (en) SD card automatically adapting to upper computer for reading and writing and automatic adapting method thereof
CN100465933C (en) Removable electronic device and method thereof
CN2791748Y (en) Storage card adopter and circuit board thereof
CN1538269A (en) Universal micro memory card
CN2443439Y (en) External 1394 interface flash memory card reader

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
C17 Cessation of patent right
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20050420

Termination date: 20130910