OSDev.org

The Place to Start for Operating System Developers
It is currently Sun Nov 18, 2018 5:12 pm

All times are UTC - 6 hours




Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: Port of NuttX to x86
PostPosted: Tue Mar 15, 2011 8:56 am 
Offline

Joined: Fri Aug 27, 2010 7:29 am
Posts: 13
I've tried with the help of the author, (who is not an x86 expert) to port this to x86. We haven't used any of the MMU features, just setup GDT/IDT and a timer interrupt with the help of the James Molloy tutorials. 99% of the work has been done in terms of setting everything up, but the timer interrupt only seems to fire once and that's it. If anyone wants to help they'd be more than welcome but for the moment we're scratching our heads as to what the problem may be.

For NuttX features please checkout http://nuttx.sourceforge.net/. In brief:

- C microkernel
- Preemptable
- (Some) Posix compatibility
- BSD License
- In-memory file system
- Character devices and block drivers
- FAT 12/16/32 support
- Networking
- BSD socket layer
- Bash-like shell.

thanks,
Biff.


Top
 Profile  
 
 Post subject: Re: Port of NuttX to x86
PostPosted: Tue Mar 15, 2011 12:27 pm 
Offline
Member
Member

Joined: Thu Jul 05, 2007 8:58 am
Posts: 214
Does the interrupt handler send an end of interrupt command to the PIC when it's done? your timer interrupt problem sounds like that might not be the case.


Top
 Profile  
 
 Post subject: Re: Port of NuttX to x86
PostPosted: Tue Mar 15, 2011 3:15 pm 
Offline

Joined: Fri Aug 27, 2010 7:29 am
Posts: 13
davidv1992 wrote:
Does the interrupt handler send an end of interrupt command to the PIC when it's done?

It certainly seems so:
http://nuttx.svn.sourceforge.net/viewvc ... iew=markup

cheers,
Biff.


Top
 Profile  
 
 Post subject: Re: Port of NuttX to x86
PostPosted: Tue Mar 15, 2011 3:47 pm 
Offline
Member
Member

Joined: Tue Jun 15, 2010 9:27 am
Posts: 255
Location: Flyover State, United States
I actually had the same problem with the timer in my OS. The problem was that I was masking flags incorrectly and basically sending the incorrect values to the PIT. The end result was that timer 0 was initialized to a mode that required sending the reload value on each interrupt, instead of the rate generator or square wave I desired.

In short, step through your code and make sure the values you are sending to whatever timer to initialize it are correct.
If the timer requires any special commands on every interrupt, make sure to do this.
Always make sure you are sending an EOI as well, and that you properly configured the PIC.

_________________
Getting_Started on the wiki
x86 technical information
Interrupt Jump Table
Real Programmers Don't Use Pascal
My open-source projects


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 5 guests


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 post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group