ATA标准规范文件说明及下载

ATA-5标准规范文档(下文简称ATA-5文档)是我工作以后用到的第一份比较全面而复杂的标准文档。这份文档,在我第一份工作近三年的时间内被我反复的阅读和使用。在它的指导下,我完成了一款ATA设备端产品的维护、升级和另一款新产品的开发。正如对自己的第一份工作怀有深厚的感情一样,对 ATA协议,我也一直在关注着它的发展变化。 riple
    最近看到有网友说看了ATA标准规范文档后不知道从何入手,这一困惑我也曾经有过。在这篇文章里,我就尝试着把ATA-5文档的大致结构捋一下,把文档中 我熟悉的重点和难点部分标示出来。 riple

    ATA-5文档共分10个条款:
 
条款1 描述了文档内容涉及的范围。 riple
条款2 提供了文档参考的其他规范。 riple
条款3 提供了文档中用到的名词定义、缩写定义和文档格式约定。 riple
条款4 包括了PATA接口的电气和机械特性。 riple
条款5 包括了PATA接口的信号描述。 riple
条款6 描述了ATA接口的概要的操作要求。 riple
条款7 包括了ATA接口的寄存器描述。 riple
条款8 包括了ATA接口的命令描述。 riple
条款9 包括了ATA接口的协议描述。 riple
条款10 包括了接口的时序图。 riple
    条款4、5是物理规范部分,描述了PATA设备的接口特性,是进行物理设计的参考;条款的7、8、9、10是逻辑规范部分,描述了ATA设备的行为特性,是进行逻辑设计的参考;条款6是对ATA设备特征的一个概述,为后面4个章节做了铺垫。 riple

    ATA-5文档是从规范性和兼容性角度描述PATA协议的,内容是详细完整而自洽的。文档的内容包含了完成主机端或设备端硬件和软件设计的所有规范。但是,从设计实现的角度看,文档的结构并不适合顺序地逐章阅读,原因是每一个条款的内容都很丰富,对于初次接触文档的读者来说,由于对协议的整体框架和 ATA接口要实现的功能没有整体的把握,很难理解每一个条款对于设计实现的意义所在,很难把文档的具体内容与设计实现过程中的各个主题联系起来,很容易看了前面,忘记了后面,反复多次通读文档才能逐渐有所收获。 riple

    如果按照如下的顺序阅读ATA-5文档,就比较容易掌握文档的结构:
    0. 在网络上查找对ATA接口的通俗解释和说明,弄清ATA接口的基本用途和功能。 riple
    1. 通读条款3,不要求对内容记忆深刻,只要求掌握条款3的结构,记得条款3都说过哪些内容即可。这么说,并不代表条款3的内容不重要;相反,条款3是最重要的,在对文档整体熟悉后,进行设计实现时,必须按照条款3的要求对后续条款字斟字酌。由于条款3是为后续条款服务的,所以只有在阅读后续条款时它才有意义。在阅读后续条款的过程中遇到问题时再返回条款3来查找,几次之后就烂熟于心了。 riple
    2. 精读条款6,选读条款8。精读条款6的目的是明确ATA设备都具备哪些功能,为后续条款的阅读做准备。精读要根据自己的设计实现要求有侧重点地进行。比如只要求实现PIO,那么就可以略过DMA的相关内容;比如只要求兼容ATA,那么就可以略过ATAPI相关的Packet命令。初次阅读略过的内容,可以在基本协议实现后,返回来阅读。可以不阅读6.7以后的各个小节。 riple
    精读条款6的6.4小节,就可以确定设计实现必须要实现的基本命令集,明确设计目标,也明确了后续条款的阅读目标。在此过程中,要参考条款8中各条命令的描述部分,以明确各条命令的意义。在阅读完6.4小节之后,需要生成一个列表,该列表包括了要实现的所有命令及其对应的协议。命令和协议的对应关系可以通过附录中的表格F.3获得。 riple
    3. 精读条款4和5。这两章,对PCB设计和FPGA引脚约束(位置、电平、电流强度)是至关重要的。这是整个板级设计成功的保证。没有稳定的物理接口这个基础,FPGA实现和调试是不可能顺利的。这两个条款不要求反复阅读,只要求在PCB设计确定前读透读明白。对于FPGA设计者来说,UDMA相关的内容可以在初次阅读时略去,在实现MDMA基本功能后返回来阅读;对PCB设计者来说,出于兼容性设计的考虑,UDMA相关的内容应该尽量读明白。 riple
    4. 精读条款9、8、7。 要按照“先协议、后命令、最后寄存器”的逆序进行。协议是一类命令的共同行为特性,掌握了一个协议,就可以掌握一类命令;明白了命令的输入和输出,就可以弄明白为什么要设置这些寄存器和寄存器的位意义。 要打破条款的自然章节划分,按照协议及相关的命令和寄存器纵向阅读。比如9.4小节的non-data命令协议对应了28条命令,所有这些命令都遵循同一个协议规定的简单行为;8.37小节的SET FEATURES命令属于non-data协议,8.37.8给出了该命令的描述,8.37.9 - 8.37.20给出了该命令的子命令介绍,8.37.4和8.37.5给出了该命令对应的输入输出寄存器;大部分寄存器的内容都是命令相关的,所以条款7 必须结合着条款8阅读才有意义;附录中的表格F.4给出了寄存器与物理引脚之间的关系。 riple
    明确了协议-命令-寄存器-引脚之间的关系,就可以着手进行逻辑实现了。 riple
    5. 通读条款10。这是对第一次阅读文档的要求。在进行逻辑实现时,必须详细阅读这一条款,明确主机与设备之间的物理握手,并明确各个时序参数该如何在具体设计中得以实现。 riple

    条款1、2没有什么实际内容,可以略去不读;附录的6个小节中包含了重要的信息和表格,需要深入阅读和反复参考。

下载ATA协议,就要到T13的官网上。T13是什么意思?我不知道。只知道有一个T10是管SCSI的,还有一个T11是管FC的,T13是管ATA的。这三个Technical Committee都是与存储技术有关的。 riple

T13上面有两类文档:标准(Standards)和草稿(Drafts)。标准都是要收费的,草稿是免费下载的。我们进行设计就可以参考草稿。下载草稿的页面可以从主页上如下的链接进入:Projects -> Last Drafts riple


 

ATA协议最新的版本是ATA-8ATA-1ATA-3都是废弃的老版本了,ATA-4以后的版本都是有效的。ATA-5应该是一个稳定的,得到广泛应用的版本,许多兼容设计都可以以此版本为参考。ATA-6及之前的版本中,ATA协议就等于PATA协议,各个版本协议的格式基本一致。从ATA-7开始,协议中加入了SATA部分,为了总结SATAPATA协议的异同点,ATA-7协议分成了三卷,卷一、卷二的内容覆盖了以前版本的内容,卷三是针对SATA相关内容而增加的。从ATA-8开始,协议进一步细化为4部分:ATA8-AAMATA8-APTATA8-ASTATA8-ACS。其中,ATA8-ACS相当于ATA-7的卷一(具体协议部分移到了ATA8-AAM中),ATA8-APT相当于ATA-7的卷二,ATA8-AST相当于ATA-7的卷三。ATA8-AAMATA-8中提纲挈领的一卷,在这一文档中,总结了所有ATA实现形式的共性内容,首次提出了ATA协议的分层概念(这有点像是以太网的分层概念),首次提出了ATA协议的“客户端-服务器”模型。 riple

个人认为,ATA8-AAM在ATA协议发展史上具有里程碑意义。有了AAMATA协议的实现形式就更容易多样化,既有P-ATA,也有S-ATA,还有ATAoE,任何一种实现形式都可以在兼容AAM的前提下自由发展,任何一种实现形式发展到了尽头都可以被抛弃。ATA协议由于抽象出了AAM而得以长葆青春,获得了更广阔的发展空间。 riple

下表拷贝自下载页面,略去了所有与ATA协议主要版本无关的内容。 riple
 

T13: Last Drafts
Doc. Number Title Author Sub. Date
791Dr4c
791D: AT Attachment Interface for Disk Drives (ATA-1) (Withdrawn 1999)

 

 
Larry Llamers 01/01/94

 
943Dr4c
948D: AT Attachment Interface with Extensions (ATA-2) (Withdrawn 2001)

 

 
Stephen G. Finch 03/18/96

 
2008Dr7b
2008D: AT Attachment - 3 Interface (ATA-3) (Withdrawn 2002)

 

 
Pete McLean 01/17/97

 
1153Dr18
INCITS 317-1998 (1153D): AT Attachment - 4 with Packet Interface Extension (ATA/ATAPI - 4)

This standard specifies the AT Attachment Interface between host systems and storage devices. It provides a common attachment interface for systems manufacturers, systems integrators, and suppliers of intelligent storage devices. It includes the Packet Command feature known as the AT Attachment Packet Interface (ATAPI). This standard maintains a high degree of compatibility with the AT Attachment - 3 Interface (ATA-3), X3.298-1996, and earlier definitions of the AT Attachment Packet (ATAPI), and while providing additional functions, is not intended to require changes to presently installed devices or existing software.

 
Pete McLean 08/19/98

 
1321Dr3
INCITS 340 (1321D): AT Attachment - 5 with Packet Interface (ATA/ATAPI - 5)

This standard specifies the AT Attachment Interface between host systems and storage devices. It provides a common attachment interface for systems manufacturers, systems integrators, and suppliers of intelligent storage devices. It includes the Packet Command feature known as the AT Attachment Packet Interface (ATAPI). This standard maintains a high degree of compatibility with the AT Attachment - 4 with Packet Interface Extension (ATA/ATAPI-4), 1153D, and while providing additional functions, is not intended to require changes to presently installed devices or existing software.

 
Pete McLean 02/29/00

 
1410Dr3b
INCITS 361-2002 (1410D): AT Attachment - 6 with Packet Interface (ATA/ATAPI - 6)

This standard specifies the AT Attachment Interface between host systems and storage devices. It provides a common attachment interface for systems manufacturers, systems integrators, and suppliers of intelligent storage devices. It includes the Packet Command feature known as the AT Attachment Packet Interface (ATAPI). This standard maintains a high degree of compatibility with the AT Attachment - 5 with Packet Interface (ATA/ATAPI-5), 1321D, and while providing additional functions, is not intended to require changes to presently installed devices or existing software.

 
Pete McLean 02/26/02

 
D1532v1r4b
INCITS 397-2005 (1532D): AT Attachment with Packet Interface - 7 Volume 1

This standard specifies the AT Attachment Interface between host systems and storage devices. It provides a common attachment interface for systems manufacturers, systems integrators, and suppliers of intelligent storage devices. It includes the Packet Command feature known as the AT Attachment Packet Interface (ATAPI). This standard maintains a high degree of compatibility with the AT Attachment - 6 with Packet Interface (ATA/ATAPI-6), 1410D, and while providing additional functions, is not intended to require changes to presently installed devices or existing software.

 
John Masiewicz 04/21/04

 
D1532v2r4b
INCITS 397-2005 (1532D): AT Attachment with Packet Interface - 7 Volume 2

This standard specifies the AT Attachment Interface between host systems and storage devices. It provides a common attachment interface for systems manufacturers, systems integrators, and suppliers of intelligent storage devices. It includes the Packet Command feature known as the AT Attachment Packet Interface (ATAPI). This standard maintains a high degree of compatibility with the AT Attachment - 6 with Packet Interface (ATA/ATAPI-6), 1410D, and while providing additional functions, is not intended to require changes to presently installed devices or existing software.

 
John Masiewicz 04/21/04

 
D1532v3r4b
INCITS 397-2005 (1532D): AT Attachment with Packet Interface - 7 Volume 3

This standard specifies the AT Attachment Interface between host systems and storage devices. It provides a common attachment interface for systems manufacturers, systems integrators, and suppliers of intelligent storage devices. It includes the Packet Command feature known as the AT Attachment Packet Interface (ATAPI). This standard maintains a high degree of compatibility with the AT Attachment - 6 with Packet Interface (ATA/ATAPI-6), 1410D, and while providing additional functions, is not intended to require changes to presently installed devices or existing software.

 
John Masiewicz 04/21/04

 
d1700r3
ATA8-AAM

This standard describes the AT Attachment Architectural Model. The purpose of the architecture model is to provide a common basis for the coordination of ATA standards and to define those aspects of ATA system behavior that are independent of a particular technology and common to all implementations.

 
Mark Evans 05/28/06

 
d1698r2
1698D: AT Attachment-8 - Parallel Transport (ATA8-APT)

This standard specifies the AT Attachment Interface between host systems and storage devices using a parallel electrical interface. It provides a common attachment interface for systems manufacturers, system integrators, software suppliers, and suppliers of intelligent storage devices.

 
Mark A. Overby 11/21/07

 
d1697r1
1697D: AT Attachment-8 - Serial Transport (ATA8-AST)

This standard specifies the serial transport for the AT Attachment Interface between host systems and storage devices. It includes the serial transport Protocols and Physical Interconnect for AT Atachment devices commonly known as Serial ATA.

 
Curtis E. Stevens 12/12/07

 
D1699r6a
INCITS 452-2008 (D1699): AT Attachment 8 - ATA/ATAPI Command Set

This standard specifies the AT Attachment command set between host systems and storage devices. It provides a common command set for systems manufacturers, system integrators, software suppliers, and suppliers of intelligent storage devices. It includes the PACKET feature set implemented by devices commonly known as ATAPI devices. This version integrates ANSI Editor and public review comments.

 
Curtis E. Stevens 09/16/08

 

 

 

http://zhuoyue6.365isp.cn/%E5%A6%82%E4%BD%95%E4%B8%8B%E8%BD%BD%E9%98%85%E8%AF%BBATA-5%E5%8D%8F%E8%AE%AE%E6%96%87%E6%A1%A3.htm

IDE架构剖析与发展趋势 Enhanced IDE接口历史(一)
 1. AT ATTACHMENT (ATA):ATA接口是个人电脑上最具有实力的存储接口,ATA接口早先被广泛应用于IBM及其兼容机,它被定义为标准的硬盘接口。
2. ATA-1:ATA硬盘接口的第一代标准ANSI X3.279-1994,也就是早期的IDE接口。
3. ATA-2:ATA硬盘接口的第二代标准ANSI X3.279-1995,就是大家所知道的Fast ATA或者称之为Enhanced IDE(EIDE)接口。
4. Apple-ATA:Apple上使用的ATA接口,当然也是由标准的ATA接口演化而来的,在ANSI的国际标准提案申请为X3T9.2/90-143.Revision 3.1,这一个由标准ATA接口规格演化而来Apple-ATA支持IDE接口的硬盘LBA驱动模式,但是没有支持ATATP。
 5. ATA-3:ATA硬盘接口的第三代标准ANSI X3T13/2008D Revision 7(draft),同样包含在Fast ATA或Enhanced IDE的接口之中,一般使用者大多都知道Fast ATA或是Enhanced IDE接口,而对原来Fast ATA或Enhanced IDE接口居然还包括了ATA-2以及ATA-3两组国际标准。
 6. ATAPI:AT Attachment Packet Interface,这是ATA Protocol的延伸,被定义用来支持CD-ROM光驱以及Tape磁带机,这一个ATAPI Protocol容许硬盘以外的设备使用ATA数据线。
7. ATA/ATAPI-4:ATA硬盘接口的第四代标准ANSI X3T13/D96153(draft),也就是大家所知道的Ultra ATA或是Ultra DMA,这一个版本支持33MB/sec的数据传输率(in burst mode),相信各位读者对ATA-4/Ultra DMA都是比较熟悉的了。
 8. ATA/ATAPI-5:这是目前ATA硬盘接口的比较新的一代标准,这一规格里规定的数据流传输速率(in burst mode)为66MB/sec,并且加强了内部资料的检查与错误修正的算法,强化了资料的完整性和可靠性。
 9. ATA/ATAPI-6:还有更新的一个标准,是ATA/ATAPI-5的改进,这一规格里规定的数据流传输速率(in burst mode)为100MB/sec。

 

评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值