}
regs.h.ah = 0; regs.h.al = cc; int86(0x34,®s,®s);
}
05Set RTS signal of RS-232 port
Entry Parameters: AH = 5
AL = 2
DH = 0 ;set RTS to LOW
1 ;set RTS to HIGH (default)
Returned Values: None
void TC_232_RTS(int rts)
{
regs.h.ah = 5; regs.h.al = 2;
regs.h.dh = (unsigned char)rts; int86(0x34,®s,®s);
}
06Read CTS signal of RS-232 port
Entry Parameters: AH = 6
| AL = | 2 |
|
Returned Values: | DH = | 0 | ;when CTS is LOW |
|
| 1 | ;when CTS is HIGH |
int TC_232_CTS()
{
regs.h.ah = 6; regs.h.al = 2; int86(0x34,®s,®s); return((int)regs.h.dh);
}
NOTE:
1)If the
RS-485 port serial I/O using INT 33H
01 | Input data |
|
| Entry Parameters: | AH = 1 |
| Returned Values: | 1) if a character received |