seeking help about the IRQ8 RTC programming

Hello all:
This is my first post. Hope I can learn and discuss hot topics As Many Aa Possible.

My server pgm’s structure is: The main thread periodically run a sub thread(server_manager) to do certin work. The stimulation frequency is 40Hz, that is running the subthread /25ms.Although I can realize it using the normal timer fucntions, since the sub thread is also in charge of sending a message to the client process by using a budget timer(15ms after its running), I tend to use the IRQ8 RTC and ISR to realize strict periodic stimulation of the sub thread. My questions are:

1.After reading the post “high-frequency timebase”, some parts are not clear:
1)is the IRQ8 handler complete?
2).the setup and restore part should be put where? the main(), right?
3).how to set the IRQ8’s interrupt frequency to 40hz.
4).where should I declare the timerevent? Is the declaring method the same as one used in normal timer-create/settime functions?

2.according to my requirements on frequency, which type should I prefer, interruptattach() or interruptattachevent()? whats their main differences?

  1. If ok, could some experts give me a complete pgm example which is using the IRQ8 RTC to run a thread periodically? or give me a general structure according to discription on my server pgm?

  2. Are there some classic articles on this topic? I have seen Mr Roben Krten’s book and QNX development support, but there is no. Actually I even could not find a complete example on how to use IRQ8 (and even IRQ).

Since I am only a newuser, too many things need you experts help!!

(Mr steinhoff, I have seen your post and get great help, if ok, could you send me a complete such example?)
Thanks for all very much !!

If you set the timer with an exact multiple of timer clock, there is no need for an IRQ8 interrupt. Check out the two tick-tock articles: … 834_1.html … 826_2.html