19.6.140. ToPLD(创建 _PLD Buffer 对象)
语法 :
ToPLD (PLDKeywordList) => \_PLD Buffer Object
参数
PLDKeywordList 是 PLDKeyword 类型的列表,这些类型描述了可赋值的物理层描述(_PLD)buffer 中的元素。下表显示了可用的 PLDKeyword 类型及其可赋值类型。有关 _PLD 方法对象的描述,请参见 _PLD 章节。
表 19.39 PLD 关键字和赋值类型
| PLDKeyword | 赋值类型 |
|---|---|
| PLD_Revision | Integer |
| PLD_IgnoreColor | Integer |
| PLD_Red | Integer |
| PLD_Green | Integer |
| PLD_Blue | Integer |
| PLD_Width | Integer |
| PLD_Height | Integer |
| PLD_UserVisible | Integer |
| PLD_Dock | Integer |
| PLD_Lid | Integer |
| PLD_Panel | Integer 或 String |
| PLD_VerticalPosition | Integer 或 String |
| PLD_HorizontalPosition | Integer 或 String |
| PLD_Shape | Integer 或 String |
| PLD_GroupOrientation | Integer |
| PLD_GroupToken | Integer |
| PLD_GroupPosition | Integer |
| PLD_Bay | Integer |
| PLD_Ejectable | Integer |
| PLD_EjectRequired | Integer |
| PLD_CabinetNumber | Integer |
| PLD_CardCageNumber | Integer |
| PLD_Reference | Integer |
| PLD_Rotation | Integer |
| PLD_Order | Integer |
| PLD_VeriticalOffset | Integer |
| PLD_HorizontalOffset | Integer |
为了提高可读性,部分 PLDKeyword 类型可以赋予字符串值。这些类型及其可赋值如下表所示。
表 19.40 PLD 关键字和可赋值字符串值
| PLDKeyword | 可赋值字符串值 |
|---|---|
| PLD_Panel | “TOP”, “BOTTOM”,”LEFT”, “RIGHT”,”FRONT”,”BACK”,”UNKNOWN” |
| PLD_VerticalPosition | “UPPER”,”CENTER”,”LOWER” |
| PLD_HorizontalPosition | “LEFT”,”CENTER”,”RIGHT” |
| PLD_Shape | “ROUND”,”OVAL”,”SQUARE”, “VERTICALRECTANGLE”, “HORIZONTALRECTANGLE”, “VERTICALTRAPEZOID”, “HORIZONTALTRAPEZOID”, “UNKNOWN” |
描述
ToPLD 宏将 PLDKeyword 类型列表转换为 _PLD buffer 对象。
示例
下面的 ASL 展示了一个使用 ToPLD 来构造 _PLD buffer/package object 的示例:
Name (_PLD, Package (0x01) // \_PLD: Physical Location of Device
{
ToPLD (
PLD_Revision = 0x2,
PLD_IgnoreColor = 0x1,
PLD_Red = 0x37,
PLD_Green = 0x44,
PLD_Blue = 0xFF,
PLD_Width = 0x4,
PLD_Height = 0x19,
PLD_UserVisible = 0x1,
PLD_Dock = 0x0,
PLD_Lid = 0x1,
PLD_Panel = "TOP",
PLD_VerticalPosition = "CENTER",
PLD_HorizontalPosition = "RIGHT",
PLD_Shape = "VERTICALRECTANGLE",
PLD_GroupOrientation = 0x1,
PLD_GroupToken = 0xA,
PLD_GroupPosition = 0x21,
PLD_Bay = 0x1,
PLD_Ejectable = 0x0,
PLD_EjectRequired = 0x1,
PLD_CabinetNumber = 0x1E,
PLD_CardCageNumber = 0x17,
PLD_Reference = 0x0,
PLD_Rotation = 0x7,
PLD_Order = 0x3,
PLD_VerticalOffset = 0x141,
PLD_HorizontalOffset = 0x2C
)
}
)