Changeset 162 in xtideuniversalbios for trunk/Configurator/Src
- Timestamp:
- May 28, 2011, 7:34:42 PM (13 years ago)
- google:author:
- krille_n_@hotmail.com
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Configurator/Src/Libraries/file.asm
r2 r162 1 ; File name : file.asm2 1 ; Project name : File library 3 ; Created date : 19.11.2009 4 ; Last update : 24.11.2009 5 ; Author : Tomi Tilli 6 ; Description : ASM library for DOS file handling. 2 ; Description : ASM library for DOS file handling. 7 3 8 4 ;--------------- Equates ----------------------------- … … 69 65 ; Returns pointer to error string. 70 66 ; Pointer is always valid, even if error code is not. 71 ; 67 ; 72 68 ; File_GetErrStr 73 69 ; Parameters: … … 111 107 ; Opens file for reading and writing. 112 108 ; File must be closed with File_Close when no longer needed. 113 ; 109 ; 114 110 ; File_Open 115 111 ; Parameters: … … 137 133 ;-------------------------------------------------------------------- 138 134 ; Closes file. 139 ; 135 ; 140 136 ; File_Close 141 137 ; Parameters: … … 159 155 ; File position is updated so next read will start where 160 156 ; previous read stopped. 161 ; 157 ; 162 158 ; File_Read 163 159 ; Parameters: … … 191 187 ; File position is updated so next write will start where 192 188 ; previous write stopped. 193 ; 189 ; 194 190 ; File_Write 195 191 ; Parameters: … … 221 217 ;-------------------------------------------------------------------- 222 218 ; Sets current file position to wanted offset. 223 ; 219 ; 224 220 ; File_SetFilePos 225 221 ; Parameters: … … 244 240 ;-------------------------------------------------------------------- 245 241 ; Changes current default drive. 246 ; 242 ; 247 243 ; File_SetDrive 248 244 ; Parameters: … … 263 259 ; Returns current default drive and number of 264 260 ; potentially drive letters available. 265 ; 261 ; 266 262 ; File_GetDrive 267 263 ; Parameters: … … 286 282 287 283 ;-------------------------------------------------------------------- 288 ; Checks are the potentially valid drive letters returned by 284 ; Checks are the potentially valid drive letters returned by 289 285 ; File_SetDrive and File_GetDrive actually valid or not. 290 ; 286 ; 291 287 ; File_IsDrive 292 288 ; Parameters: … … 315 311 ;-------------------------------------------------------------------- 316 312 ; Returns number of valid drive letters. 317 ; 313 ; 318 314 ; File_GetValidDrvCnt 319 315 ; Parameters: … … 337 333 inc dx ; Increment drive number 338 334 loop .LetterLoop ; Loop while drive letters left 339 eMOVZX cx, dh ; Valid drv count to CX335 mov cl, dh ; Valid drv count to CX 340 336 ret 341 337 … … 344 340 ; Return device number for Nth valid drive. 345 341 ; This function does not check if index in CX is valid. 346 ; 342 ; 347 343 ; File_GetNthValidDrv 348 344 ; Parameters: … … 353 349 ; Corrupts registers: 354 350 ; CX 355 ;-------------------------------------------------------------------- 351 ;-------------------------------------------------------------------- 356 352 ALIGN JUMP_ALIGN 357 353 File_GetNthValidDrv: … … 371 367 ;-------------------------------------------------------------------- 372 368 ; Changes current directory. 373 ; 369 ; 374 370 ; File_ChangeDir 375 371 ; Parameters: … … 391 387 ;-------------------------------------------------------------------- 392 388 ; Finds files from wanted path using search wildcard characters. 393 ; 389 ; 394 390 ; File_FindAndCount 395 391 ; Parameters: … … 419 415 ; Finds files from wanted path using search wildcard characters. 420 416 ; Ptr to DTA is returned for wanted file. 421 ; 417 ; 422 418 ; File_GetDTA 423 419 ; Parameters: … … 457 453 ;-------------------------------------------------------------------- 458 454 ; Find first file or directory. 459 ; 455 ; 460 456 ; File_FindFirst 461 457 ; Parameters: … … 482 478 ; Find next file or directory. File_FindFirst must always be called 483 479 ; before calling File_FindNext. 484 ; 480 ; 485 481 ; File_FindNext 486 482 ; Parameters:
Note:
See TracChangeset
for help on using the changeset viewer.