- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi all forumers !!
I'm totally new to fpgas and I'm trying to get my best !! But now I really need some suggestions.. I'm implementing a routine in C with quartus that uses a timer but I cannot find how to get it... I need to implement something like that:#include<time.h>
..... some code here .....
time_t start,now;
time(&start);
seconds = 0;
while seconds < 1 {
... do something...
time(&now);
seconds=(uint8_t) difftime(now,start);
}
by the way it seems not working... i always get seconds==0. There is a better way to get it works ?? Thank you for your support !! Have a nice day !
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Solved it.
It was sufficient to add and configure "interval timer" in my qsys. I have called it sys_clck_timer. Than, in eclipse, I have added the sys_clck_timer in the bsp editor of my project.
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