flat assembler
Message board for the users of flat assembler.
![]() Goto page Previous 1, 2 |
Author |
|
Dex4u 13 Jan 2008, 17:11
I tell you what i will do, i like problems like this, so if we put our heads together we can fix it, so i will do some tests and get back to you
![]() |
|||
![]() |
|
Vov4ik 13 Jan 2008, 17:26
I tried to write a stub to int13 today, as i said earlier. It replaces HDDs, reads MBR from 80h HDD end executes it. But... it hangs. I tried to debug it, stub works correctly, reading of MBR passes well. Debugger hangs when MBR jumps to its copy at 0000:0600, i think because it overwrites some DOS handlers. (DOS handles int13 too, it adds some stub to BIOS handler). This is a source of my program and binary file.
Sorry, i still prefer TASM in ideal mode for DOS.
_________________ MicroSoft? is that some kind of a toilet paper? Sorry for my English . . . |
|||||||||||
![]() |
|
edfed 13 Jan 2008, 17:31
So , it shall restore the original bios before execution.
but how to make it? i suppose it's overwriten by DOS and OSes. |
|||
![]() |
|
LocoDelAssembly 13 Jan 2008, 22:16
Dex, why not just "jmp $FFFF:0"?
|
|||
![]() |
|
edfed 13 Jan 2008, 23:32
because it cannot work for CD, i never tryed to rewrite the boot sector of a CD-R. can you do that?
|
|||
![]() |
|
Dex4u 14 Jan 2008, 03:43
LocoDelAssembly wrote: Dex, why not just "jmp $FFFF:0"? @edfed, From my point of view, when booting from a CD-R, i use a bootable floppy image, as it's set to floppy emulation. |
|||
![]() |
|
LocoDelAssembly 14 Jan 2008, 04:05
I should be more specific
![]() |
|||
![]() |
|
Dex4u 14 Jan 2008, 05:18
LocoDelAssembly wrote: I should be more specific Oh i see ![]() ![]() |
|||
![]() |
|
edfed 14 Jan 2008, 15:13
finally, i think that making a menu on boot sector is the solution to adopt.
this menu then launch the boot we need. |
|||
![]() |
|
Dex4u 14 Jan 2008, 21:53
I have read that calling this will help
Code: mov ah,0Dh ; Disk Reset int 21h ; causes SmartDrv 4.x to write cache mov ax, 40h ; set up segment addressing mov ds,ax or byte [ds:17h],0Ch ; Same as pressing CTRL+ALT mov ax,0x4f53 ; 53h = DEL scan code int 15h ; EMM386 sees this & shuts down See here: http://www.freedos.org/freedos/news/technote/217.html |
|||
![]() |
|
System86 15 Jan 2008, 00:53
The simplest way to reboot, that works for both real mode and protected mode, is to write 0xFE to port 64h. Jumping to 0xFFFF:0x0000 is another way, but only works in real mode. For both cases, if the value at 0040h:0072h is 1234h, a warm boot will occur, if it is 0, a cold boot will occur. Other ways of reseting a CPU include generating a triple fault (by enabling pmode, lidt with size of IDT being 0, and generating an interrupt), using APM, ACPI, and INT 15h/AH=4Fh.
|
|||
![]() |
|
rugxulo 25 Jan 2008, 06:45
|
|||
![]() |
|
bitRAKE 30 Jan 2008, 03:02
INT $18, is the correct way to return to BIOS for next boot device - at least with modern BIOS. I can boot to my USB stick and work with play OS and then INT $18 to boot harddrive.
http://www.phoenix.com/NR/rdonlyres/56E38DE2-3E6F-4743-835F-B4A53726ABED/0/specsbbs101.pdf |
|||
![]() |
|
Goto page Previous 1, 2 < Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.