Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

bios reset in dos?

bios reset in dos?

bios reset in dos?

Okay, I have a simple piece of assembly code...now I want to jump to the bios reset area and reset the pc to a cold restart if that makes sense.

I think memory location 0472 should be 1234h, and the bios offset is at FFFF0h...

So how would I perform a reset in asm...only new to assembly...but its in a different segment so its sort of complicated.

Thanx for any help..

(i'm using the masm assembler)

RE: bios reset in dos?

To reset PC you can use INT 19h...

RE: bios reset in dos?

yup...but I want to do it the other way..... I'm just learning to master asm, and wanted to see how you do it this way, instead of using int 19

RE: bios reset in dos?

now I have a masm assembler...but how come this line gives me an error:

jmp far    0100:0000

As this will allow me to change CS and IP...but I get the error:

"Left operand must have segment"

Thanks for any help on this


RE: bios reset in dos?

IIRC it would be like this:

mov    ax, 40h
mov    ds, ax
mov    bx, 72h
mov    word ptr [bx], 1234h

mov    ax, 0FFFFh
push    ax
xor    ax,ax
push    ax

Good luck

RE: bios reset in dos?

Thanx AirCon,
  thats fantastic...thats just what I wanted to know how to do....

Brilliant....couldn't work out how to do that for ages...but you've solved my problem :)

Thanx again AirCon.


RE: bios reset in dos?

Yes it is DOS-only. Windows works differently. You have to know what is the limitation in windows

RE: bios reset in dos?

the retf seems a bit long winded to me

when ever i want to perform a hard coded far jump i always use the following

this is 16bit code so the address after the opcode is a word and not a dword.

my ASM code would look something like:

db    0EAh ;Opcode for JMP FAR Immediate
dw    0h,0FFFFh

personally i use it all the time because the assemblers wont let me do it conventionally. but its alot shorter than friging the stack for a retf.


"There are 10 types of people in this world, those who know binary and those who don't!"

RE: bios reset in dos?

Hi adholioshake,
Windows disables the bios routine. Instead you could use the Windows API function 'ExitWindowsEx(...)'

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close