C code rebooting for no reason
Re: C code rebooting for no reason
We can safely assume it's not the code that enables protected mode, since he's using GRUB which handles all of that.
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
Re: C code rebooting for no reason
i changed to GRUB now. And it worked. Also got the bonus of not having to reinstall GRUB (just do the grub-mkrescue step in the Bare Bones tutorial, lol).FusT wrote:We can safely assume it's not the code that enables protected mode, since he's using GRUB which handles all of that.
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
Re: C code rebooting for no reason
I used QEMU on the above picture, and i already got GRUB on the USB (i really have to use grub-mkrescue). It works on real hardware and emulators.ziggyfish2 wrote:So firstly use QEMU as this will give you access to some debugging information, that you can use to identify what the problem is. Use either the qemu -d , or the QEMU monitor to checkout what problems you are facing ( http://wiki.qemu.org/download/qemu-doc.html for more information on how to use it correctly).
Secondly, can you provide the qemu log file so we can tell you exactly what your problem is (I will not detail how to fix it though). Also provide your boot loader, as 0x07E00 address looks suspicious.
From what you have posted it looks like a problem with your interrupts, it seems you haven't disabled interrupts before you jump into protected mode. This needs to be done as the default interrupts that the BIOS provides are only 16bit, and will not work in 32 bit mode.
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
Re: C code rebooting for no reason
If anyone didn't see the image,
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
Re: C code rebooting for no reason
Congratulations. You have configured a GRUB menu.
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
Re: C code rebooting for no reason
Thanks. Now i'm making a I/O keyboard output, and i swear i'll probably use a library for this..iansjack wrote:Congratulations. You have configured a GRUB menu.
- 0x1E = A
0x30 = B
0x2E = C
0x20 = D
0x12 = E
0x21 = F
0x22 = G
0x23 = H
0x17 = I
0x24 = J
0x25 = K
0x26 = L
0x32 = M
0x31 = N
0x18 = O
0x19 = P
0x10 = Q
0x13 = R
0x1F = S
0x14 = T
0x16 = U
0x2F = V
0x11 = W
0x2D = X
0x15 = Y
0x2C = Z
0x02 = 1
0x03 = 2
0x04 = 3
0x05 = 4
0x06 = 5
0x07 = 6
0x08 = 7
0x09 = 8
0x0A = 9
0x0B = 0
0x28 = '
0x34 = .
0x0C = -
0x0D = =
0x35 = /
0x1A = [
0x1B = ]
0x27 = ;
0x33 = ,
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
Re: C code rebooting for no reason
Finally wrote the tty.h file. This is the ending ); parts of my file. Seriously:
Code: Select all
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
-
- Member
- Posts: 1146
- Joined: Sat Mar 01, 2014 2:59 pm
Re: C code rebooting for no reason
This is not your osdev blog to post long code samples on. If you want to brag about how you wrote a "header file" to map keycodes to ASCII characters, get a free blog at WordPress.com or Blogger.
When you start writing an OS you do the minimum possible to get the x86 processor in a usable state, then you try to get as far away from it as possible.
Syntax checkup:
Wrong: OS's, IRQ's, zero'ing
Right: OSes, IRQs, zeroing
Syntax checkup:
Wrong: OS's, IRQ's, zero'ing
Right: OSes, IRQs, zeroing
Re: C code rebooting for no reason
Then I think that you should consider rewriting the code.NunoLava1998 wrote:Finally wrote the tty.h file. This is the ending ); parts of my file. Seriously:Code: Select all
-snip
com.sun.java.swing.plaf.nimbus.InternalFrameInternalFrameTitlePaneInternalFrameTitlePaneMaximizeButtonWindowNotFocusedState
Compiler Development Forum
Compiler Development Forum
- Schol-R-LEA
- Member
- Posts: 1925
- Joined: Fri Oct 27, 2006 9:42 am
- Location: Athens, GA, USA
Re: C code rebooting for no reason
And I think that if you are going to ask us to debug the code you, ah, appropriated from Sewage Overflow and a mélange of several unrelated tutorials, you should at least have the courtesy of creating a cloud repo one GitHub or somewhere like that, which you can link to rather than coredumping this Frankensteinian mess onto the message boards here every time you run into a problem. You know, like I have told you to do at least twice before?
Assuming the mods don't come down on you about the COPPA thing, that is.
Assuming the mods don't come down on you about the COPPA thing, that is.
Rev. First Speaker Schol-R-LEA;2 LCF ELF JAM POEE KoR KCO PPWMTF
Ordo OS Project
Lisp programmers tend to seem very odd to outsiders, just like anyone else who has had a religious experience they can't quite explain to others.
Ordo OS Project
Lisp programmers tend to seem very odd to outsiders, just like anyone else who has had a religious experience they can't quite explain to others.