【问题标题】:setting Timeout byte in LPT在 LPT 中设置超时字节
【发布时间】:2022-01-23 12:33:06
【问题描述】:

我正在阅读我的笔记,我在这里遇到了,

Accessing the Parallel Port Through BIOS Functions
----------------------------
| TIMEOUT BYTE              |
| ------------------------- |
| 0040:0078    | LPT1       |
| 0040:0079    | LPT2       |
| 0040:007A    | LPT3       |
----------------------------

The BIOS service once invoked will try to perform the requested operation on the printer
repeated for a certain time period. In case if the operation is rendered unsuccessful due to
any reason BIOS will not quit trying and will try again and again until the number of tries
specified in the timeout bytes shown above runs out

这里说一段时间,但从未提及尝试了多少或多少次..

这里 78 表示 LPT1,79 表示 LPT2 等等......

尝试次数 在我认为是 40

的超时字节中指定

40 表示它会在 BIOS 退出之前重试 40 次? 还是 10 次? 由于任何打印机错误或其他原因导致的打印尝试?

【问题讨论】:

  • 40 是存储超时字节的段
  • @Sebastian 如何在其中存储超时字节,假设我希望它重试 10 次

标签: assembly emu8086


【解决方案1】:

您可以在此处找到信息:https://www.plantation-productions.com/Webster/www.artofasm.com/DOS/ch21/CH21-2.html,在 Randall Hyde 的《汇编语言的艺术》一书中。

或者作者在这里: https://www.randallhyde.com/AssemblyLanguage/www.artofasm.com/DOS/pdf/ch21.pdf

I/O 端口被访问 65536 x [超时值] 次以查看是否有确认信号。

在其中存储超时值

mov ax, 0x40
mov ds, ax
mov ax, 10
mov byte ptr [0x78], ax

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-11-03
    • 2018-06-24
    • 1970-01-01
    • 2017-06-07
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多