[an error occurred while processing this directive]
Спасибо. А как этот дескриптор сегмента перевести в указатель на сегмент ???
(«Телесистемы»: Конференция «Микроконтроллеры и их применение»)

миниатюрный аудио-видеорекордер mAVR

Отправлено goshka 24 марта 2003 г. 09:04
В ответ на: Ответ: отправлено trainer 23 марта 2003 г. 10:13

Ну да, такая функция в WatcomC есть...

#include
#if defined(__NT__) || \
( defined(__OS2__) && \
(defined(__386__) || defined(__PPC__)) )
unsigned _dos_allocmem( unsigned size,
void * *segment);
#else
unsigned _dos_allocmem( unsigned size,
unsigned short *segment);
#endif

Description:

The _dos_allocmem function uses system call 0x48 to allocate size paragraphs directly from DOS. The size of a paragraph is 16 bytes. The allocated memory is always paragraph aligned. The segment descriptor for the allocated memory is returned in the word pointed to by segment. If the allocation request fails, the maximum number of paragraphs that can be allocated is returned in this word instead.


Составить ответ  |||  Конференция  |||  Архив

Ответы



Перейти к списку ответов  |||  Конференция  |||  Архив  |||  Главная страница  |||  Содержание  |||  Без кадра

E-mail: info@telesys.ru