flat assembler
Message board for the users of flat assembler.

Index > MenuetOS > Function 58 - run programms

Author
Thread Post new topic Reply to topic
Fagotus



Joined: 15 May 2004
Posts: 8
Fagotus 26 Jul 2004, 05:03
Hi everyone!
I need help in 58th func. So the standart RUN func. is:
mov eax,58
mov ebx,fileinfo
int 0x40
;=======data=======
fileinfo:
dd 16 ; - exec prg
dd 0x0
dd 0x0 ; - params
dd 0x0
dd 0x10000
db ’/HD/1/MENUET/APPS/FIRE’,0
;=======end of fileinfo

But I need to execute programm, but the path is integer - for example:
path_to_prg db ’/hd/1/meos/apps/fire’
and params too:
parametr dw 0
So the quastion is: What changes do I have to make to fileinfo to make it work Smile (and do I have to add ",0" to the end of path? how?)
Post 26 Jul 2004, 05:03
View user's profile Send private message Reply with quote
Fagotus



Joined: 15 May 2004
Posts: 8
Fagotus 26 Jul 2004, 05:09
Oh, and another quastion Wink
how can i read data from file - string one to integer1 - string two to integer2 ??? I know how to open file and put data to memory, but others?
Post 26 Jul 2004, 05:09
View user's profile Send private message Reply with quote
DennisCGc



Joined: 03 May 2004
Posts: 24
Location: Zoetermeer, The Netherlands
DennisCGc 26 Jul 2004, 11:00
Fagotus wrote:
Hi everyone!

;=======data=======
fileinfo:
dd 16 ; - exec prg
dd 0x0
dd 0x0 ; - params
dd 0x0
dd 0x10000
db ’/HD/1/MENUET/APPS/FIRE’,0
;=======end of fileinfo

But I need to execute programm, but the path is integer - for example:

The path isn't an integer, but a string.....
API reference wrote:
fileinfo:

dd 16 ; 16=START APPLICATION
dd 0x0 ; nop
dd param ; 0 or parameter area ( ASCIIZ )
; receiving application must
; reserve a 256 byte area
dd 0x0 ; nop
dd 0x10000 ; work area for os - 16384 bytes
db '/HD/1/MENUET/APPS/FIRE',0 ; ASCIIZ dir & filename

ret: eax = pid or 0xfffffff0+ for error

According to this, it SHOULD work Smile
See this for more information : http://www.menuetos.org/www/eng/sysfuncs.txt

HTH.
Post 26 Jul 2004, 11:00
View user's profile Send private message MSN Messenger Reply with quote
SPTH



Joined: 24 Jul 2004
Posts: 91
SPTH 27 Jul 2004, 05:50
Fagotus wrote:

According to this, it SHOULD work :)


Maybe you have the same problem as me!
check out is that one works:

Code:

  mov eax, 58
  mov ebx, fileinfo
  int 0x40

     fileinfo:
   
     dd   0                    ; 0=READ    (delete/append)
     dd   0x0                  ; 512 block to read 0+
     dd   0x16                  ; blocks to read (/bytes to write/append)
     dd   0x20000              ; return data pointer
     dd   0x10000              ; work area for os - 16384 bytes
     db   '/HARDDISK/FIRST',0  ; ASCIIZ dir & filename
    


then you check the values at 0x20000 (for instands via a text-box), if there are strange signs, you also have 'my' bug

greets, ...
Post 27 Jul 2004, 05:50
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.