Example
:
int TS_free_mem(unsigned char far *str)
{
unsigned long aa;
regs.h.ah=0x49;
segregs.es=FP_SEG(str);
int86x(0x21,®s,®s,&segregs);
if ((regs.x.cflag & 0x01) == 0) return(1);
else return(-1);
}
4A
Modify Allocated Memory Block
Entry Parameter:
AH = 4AH
ES = segment address of the block to resize
BX = new block size in paragraphs (16 bytes)
Returned Value:
if success , CARRY flag is cleared
if failed , CARRY flag is set
AX = error code
Example
:
int TS_modify_alloc_mem(unsigned int size,unsigned char far *str,int
*free)
{
unsigned long aa;
regs.h.ah=0x4a;
regs.x.bx=size;
segregs.ds = FP_SEG(str);
int86(0x21,®s,®s);
*free = regs.x.bx;
if ((regs.x.cflag & 0x01) == 0) return(1);
else return(-1);
}
4C
End Program
Entry Parameter:
AH = 4CH
AL = program-defined return value
Summary of Contents for PT600
Page 1: ...PT600 Portable Terminal Programming Reference Guide Document number 3506000120...
Page 7: ......
Page 16: ......
Page 20: ...regs h bh 5 regs h al unsigned char type regs h bl unsigned char status int86 0x21 regs regs...
Page 57: ......
Page 66: ...Host Command STX ESC CMD parameters CS1 CS2 ADDR Acknowledgement ACK Negative ACK NAK...