LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 09-01-2004, 08:26 PM   #1
LongName
Member
 
Registered: Aug 2004
Posts: 33

Rep: Reputation: 15
Timed actions


In Linux is it possible to set a timer to execute a function around every 20millisecond?

Thanks in advance!
 
Old 09-02-2004, 03:23 AM   #2
itsme86
Senior Member
 
Registered: Jan 2004
Location: Oregon, USA
Distribution: Slackware
Posts: 1,246

Rep: Reputation: 59
man setitimer

EDIT: Searching the forum for "millisecond timer" returned links to threads that already would have pointed you to the setitimer function. Try to search before asking your question.

Last edited by itsme86; 09-02-2004 at 03:37 AM.
 
Old 09-02-2004, 03:42 AM   #3
cppkid
Member
 
Registered: Jul 2004
Location: Pakistan
Distribution: Ubuntu
Posts: 185

Rep: Reputation: 30
Yes there is a complete timer mechanisim in Linux, and these timers even give more accuracy then in milliseconds. In the begining i found these timers a little difficult so i used the threads to simulate timers, So it is also an option to implement the timers using threads, and nanosleep() function.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
clam av actions branden_burger Linux - Security 1 07-31-2005 02:58 PM
Perl timed actions? Atrocity Programming 7 05-06-2005 07:34 AM
rollback actions DriveMeCrazy AIX 6 05-16-2004 05:16 AM
How do I get the pending actions to upgrade 87stang Linux - General 0 03-09-2004 04:02 PM
how to do the following actions santasballz Linux - Newbie 8 02-20-2004 01:12 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 08:53 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration