- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello!
I have the following problem. I created simple project by Quartus|| 4.1. And write primitive program in Nios || IDE:int main()
{
int i=0;
while(1)
{
if (i==0)
IOWR_ALTERA_AVALON_PIO_DATA ( PIODIOD_BASE, 1);
else if (i==10000)
IOWR_ALTERA_AVALON_PIO_DATA ( PIODIOD_BASE, 0);
i++;
if (i==20000) i=0;
}
return 0;
}
Then I compiled all project and create *.sof file. Then I download this *.sof file to real deivece and I saw the next picture: my program works during 13 s, then 13 s of reset and again. I didn't do the program reset. How can I resolve this problem? Thank you.
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
What do you exactly mean with 'reset' ? How many pulses do you see on the led? (1 a few or many?) How do you detect this? Is it restarting automatically or do you have to download again? Stefaan- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I don't think it's your code doing this because I see nothing wrong with it. You don't happen to have a watchdog in your system by any chance do you (then this would actually make sense).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Check to see in Quartus if your cpu reset pin is connected preperly and that it has the correct pin assignement. Maybe you haven't put a pin asignement on the reset pin so the P&R has assigned the reset pin to a random pin that happens to toggle periodically.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page