01.06.2013 Views

IPC@CHIP Documentation - SC12 @CHIP-RTOS V1.10

IPC@CHIP Documentation - SC12 @CHIP-RTOS V1.10

IPC@CHIP Documentation - SC12 @CHIP-RTOS V1.10

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Return Value<br />

Comments<br />

Success: Carry flag cleared<br />

Failure: Carry flag set due to not enough memory available and the size of the largest free block is<br />

returned in BX (paragraph count).<br />

A paragraph is 16 bytes in length.<br />

This call may fail if a user tries in their application to increase a memory block, allocated with int21h<br />

0x48. In that case it is only possible to decrease the size of the allocated memory block.<br />

Related Topics<br />

Top of list<br />

Index page<br />

Allocate memory<br />

Free memory<br />

Interrupt 0x21 service 0x4B: EXEC<br />

Load and/or execute a program. This function loads the program and builds its PSP (Program Segment<br />

Prefix) based on a parameter block that you provide.<br />

Parameters<br />

AH<br />

AL<br />

0x4B<br />

Type of load:<br />

00h - Load and execute<br />

01h - Load but do not execute<br />

DS:DX<br />

Null terminated program name (must include extension)<br />

ES:BX<br />

parameter block<br />

Offset Size Description 00h WORD Segment of environment to copy<br />

for child process<br />

(copy caller's environment if 0000h)<br />

02h DWORD Pointer to command tail to be copied into child's PSP<br />

06h DWORD Pointer to first FCB to be copied into child's PSP<br />

0Ah DWORD Pointer to second FCB to be copied into child's PSP<br />

0Eh DWORD (AL=01h) will hold subprogram's initial SS:SP on return<br />

12h DWORD (AL=01h) will hold entry point (CS:IP) on return<br />

Return Value<br />

Success:<br />

Carry flag cleared<br />

Page 272 / 400

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!