anyone can help me how to implement the timer on AIX?
I tried with 'setitimer' and its related functions, but it does not work correctly,the program exited each time.
thanks (2 Replies)
Dear All,
i want to implement vookup function which is there in excel into Unix. Suppose i have 2 files. The files are given below.
File1:
MSC Cell SDCA
Patna-1 12 Bihar
Patna-2 45 Ranchi
Bhopal-1 85 Raigarh
Bhopal-2 ... (8 Replies)
Hi all,
I have a directory where some process is keeping incremental/new log files. I need to code a program which will periodically poll this directory and if it founds a new file arrived then copy that new file to some other specific directory.
We are OK with this polling approach. I just... (3 Replies)
Hi!
Im trying to make a program that polls a mysqlDB every 5 minutes.
the poll checks a scheduletable in the dB and exicutes a function if
there was a "go" in the scheduletable, and if it retrives a "no go" from the table
it should just wait for another 5 minutes before re polling the DB,
... (1 Reply)
Hi Guys,
we are planning to enable polling target on our SG in reference to this link
MC/ServiceGuard: Subnet Goes Down when one of the Cluster Node is Down - HP Customer Care (United States - English)
since our server is already in production can we apply the changes with ex. "cmapplyconf... (1 Reply)
Hello, I'm currently implementing the && function in a shell using C. For example, if we input cmd1 && cmd2, then cmd2 executes only when cmd1 exits successfully. I'm thinking about:
int main() {
int i;
char **args;
while(1) {
printf("yongfeng's shell:~$ ");
args =... (5 Replies)
Can anyone give me a clue why this code doesn't work as expected? The function count_collatz_step() take one parameter which a number that need to calculate collatz until it reaches 1. The func should return steps it takes.
#
# Count steps of collatz conjecture takes, until the number reach 1.... (8 Replies)
HI
I need some help on this below one
Have summuary file coming on daily basis with list of file names and count ,if the summuary file not exist ,pool it for every 5 mins till it arrives .Once arrived remove first and last line from the file and check all the files in respective director all... (12 Replies)
Discussion started by: mohan705
12 Replies
LEARN ABOUT SUSE
sdl_addtimer
SDL_AddTimer(3) SDL API Reference SDL_AddTimer(3)NAME
SDL_AddTimer - Add a timer which will call a callback after the specified number of milliseconds has elapsed.
SYNOPSIS
#include "SDL.h"
SDL_TimerID SDL_AddTimer(Uint32 interval, SDL_NewTimerCallback callback, void *param);
CALLBACK
/* type definition for the "new" timer callback function */
typedef Uint32 (*SDL_NewTimerCallback)(Uint32 interval, void *param);
DESCRIPTION
Adds a callback function to be run after the specified number of milliseconds has elapsed. The callback function is passed the current
timer interval and the user supplied parameter from the SDL_AddTimer call and returns the next timer interval. If the returned value from
the callback is the same as the one passed in, the periodic alarm continues, otherwise a new alarm is scheduled.
To cancel a currently running timer call SDL_RemoveTimer with the timer ID returned from SDL_AddTimer.
The timer callback function may run in a different thread than your main program, and so shouldn't call any functions from within itself.
You may always call SDL_PushEvent, however.
The granularity of the timer is platform-dependent, but you should count on it being at least 10 ms as this is the most common number. This
means that if you request a 16 ms timer, your callback will run approximately 20 ms later on an unloaded system. If you wanted to set a
flag signaling a frame update at 30 frames per second (every 33 ms), you might set a timer for 30 ms (see example below). If you use this
function, you need to pass SDL_INIT_TIMER to SDL_Init.
RETURN VALUE
Returns an ID value for the added timer or NULL if there was an error.
EXAMPLES
my_timer_id = SDL_AddTimer((33/10)*10, my_callbackfunc, my_callback_param);
SEE ALSO
SDL_RemoveTimer, SDL_PushEvent
SDL Tue 11 Sep 2001, 23:01 SDL_AddTimer(3)