C + Linux + Periodic function
I want to write a function that shall execute periodic. means if i set time 1 sec that function should execute in each 1 sec. let us call that function func1. But i dnt want to wait inside the func1 for that 1 sec. Meanwhile i want to run another function say func2 in background . some thing like less priority function. Whnever the time come to execute the periodic function func1 it has to go to func1 and then again in the waiting time , the second function func2 will resume.
I wanted to know how to do it.. Can somebody tell me is it possible using signal in linux.