Looking for an easy to use Timer api for userspace. - Linux

This is a discussion on Looking for an easy to use Timer api for userspace. - Linux ; Hi everybody, Does anyone know of a good users-pace timer api providing me functions similar to add_timer, init_timer, mod_timer and del_timer ?. [Similar to the kernel timer api]. Such an api would manage a number of one shot timers, wherein ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: Looking for an easy to use Timer api for userspace.

  1. Looking for an easy to use Timer api for userspace.

    Hi everybody,

    Does anyone know of a good users-pace timer api providing me functions
    similar to add_timer, init_timer, mod_timer and del_timer ?. [Similar
    to the kernel timer api]. Such an api would manage a number of one shot
    timers, wherein a timer is basically an (time_when_to_fire,
    function_to_be_called). Such a library might use the SIGALRM signal
    internally. But I want something which can handle multiple timers for
    me.

    I looked at the Posix timers specification, but that looks way to
    complex for my needs. I don't need real time or high resolution timing.
    I would prefer using a preexisting api for this, instead of
    implementing one myself using pthreads or such.

    Any pointers to this in the form of links, usenet articles would be
    greatly appreciated. This may sound like a stupid query to some, but I
    did a fair amount of searching on it and surprisingly enough, I
    couldn't find such a thing implemented for userspace applications.

    Eagerly awaiting your feedback.

    Thanks,

    Yours Sincerely,
    Devesh Agrawal


  2. Re: Looking for an easy to use Timer api for userspace.

    devesh wrote:
    > Hi everybody,
    >
    > Does anyone know of a good users-pace timer api providing me functions
    > similar to add_timer, init_timer, mod_timer and del_timer ?


    I don't know what kind of program you're writing, but SDL (libsdl.org)
    has easy to use timers. But it's quite likely that you don't want to
    link to SDL ;-)

    Greetings,
    Aaron

  3. Re: Looking for an easy to use Timer api for userspace.

    Hi,
    Thanks for replying. SDL is more for game programming. But anyhow I
    will check it out. I am writing some kind of a userspace network
    protocol which needs to use multiple timers.

    Yours Sincerely,
    Devesh Agrawal

    Aaron Isotton wrote:
    > devesh wrote:
    > > Hi everybody,
    > >
    > > Does anyone know of a good users-pace timer api providing me functions
    > > similar to add_timer, init_timer, mod_timer and del_timer ?

    >
    > I don't know what kind of program you're writing, but SDL (libsdl.org)
    > has easy to use timers. But it's quite likely that you don't want to
    > link to SDL ;-)
    >
    > Greetings,
    > Aaron



+ Reply to Thread