{"id":219,"date":"2015-07-21T14:26:54","date_gmt":"2015-07-21T18:26:54","guid":{"rendered":"http:\/\/72.167.111.237\/wpecsdump\/?page_id=219"},"modified":"2020-12-06T23:57:19","modified_gmt":"2020-12-06T23:57:19","slug":"devhlp_readfile","status":"publish","type":"page","link":"https:\/\/www.ecsdump.net\/?page_id=219","title":{"rendered":"DevHlp_ReadFile"},"content":{"rendered":"<p><strong>Description<\/strong><\/p>\n<p>This devhlp is used to read from a file opened with DevHlp_OpenFile.<\/p>\n<p><strong>Calling convention<\/strong><\/p>\n<ul>\n<li>ES:DI = point to a&nbsp;<a class=\"missingpage\" title=\"Create this page\" href=\"http:\/\/www.mgreene.org\/wikka\/SYIReadFile\/edit\">SYIReadFile<\/a>&nbsp;structure<\/li>\n<li>DL = 081h<\/li>\n<\/ul>\n<p><strong>Returns<\/strong><\/p>\n<ul>\n<li>CY=0, AX = 0: read okay<\/li>\n<li>CY=1, AX = ERROR_BAD_LENGTH: packet is invalid<\/li>\n<li>CY=1, AX = &lt;&gt;0: other filesystem related errors<\/li>\n<\/ul>\n<p><strong>Data structures<\/strong><\/p>\n<p><span style=\"font-family: Menlo, Consolas, monaco, monospace; font-size: 15px; white-space: pre-wrap;\">; assembler structure<\/span><\/p>\n<div class=\"code\">\n<pre>SYIReadFile\tstruc\nlength\t\tdw\t8\t; length of structure (must be 8)\nbuffer\t\tdd\t?\t; 16:16 address of a read buffer\nsize\t\tdd\t?\t; number of bytes to read\nSYIReadFile\tends<\/pre>\n<\/div>\n<p><strong>Restrictions<\/strong><\/p>\n<p>Valid at INIT time only. Although the size argument of the data structure implies, I&#8217;d recommend to better not read more than 32K at a time. Note that the buffer itself is segmented, so DMA overrun and other effects might apply, depending on the quality of the miniIFS in use.<\/p>\n<p><strong>Bugs<\/strong><\/p>\n<p>IMHO, the length of structure should be 10, not 8.<\/p>\n<div class=\"center\"><strong>Republished without permission from Holger Veit&#8217;s long gone webpages &#8211; MKG<\/strong><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Description This devhlp is used to read from a file opened with DevHlp_OpenFile. Calling convention ES:DI = point to a&nbsp;SYIReadFile&nbsp;structure DL = 081h Returns CY=0, AX = 0: read okay CY=1, AX = ERROR_BAD_LENGTH: packet is invalid CY=1, AX = &lt;&gt;0: other filesystem related errors Data structures ; assembler structure SYIReadFile struc length dw 8&hellip;<\/p>\n<p><a class=\"more-link\" href=\"https:\/\/www.ecsdump.net\/?page_id=219\" title=\"Continue reading &lsquo;DevHlp_ReadFile&rsquo;\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"parent":836,"menu_order":2,"comment_status":"open","ping_status":"open","template":"page-templates\/info_static.php","meta":{"footnotes":""},"categories":[13,10],"tags":[21,28],"wf_page_folders":[76],"class_list":["post-219","page","type-page","status-publish","hentry","category-devhelp","category-os2","tag-devhelp","tag-os2"],"jetpack_sharing_enabled":true,"jetpack-related-posts":[],"_links":{"self":[{"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=\/wp\/v2\/pages\/219","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=219"}],"version-history":[{"count":0,"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=\/wp\/v2\/pages\/219\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=\/wp\/v2\/pages\/836"}],"wp:attachment":[{"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=219"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=219"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=219"},{"taxonomy":"wf_page_folders","embeddable":true,"href":"https:\/\/www.ecsdump.net\/index.php?rest_route=%2Fwp%2Fv2%2Fwf_page_folders&post=219"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}