C -language calling a function at specified time
===

I'm using the following C code (linux ubuntu) to sample every 5 minutes the broker server and get the bid and ask value:

    int main(int argc, char *argv[])
    {
    struct stock myStock;
    struct stock *myStock_ptr;
    struct timeval t;
    time_t timeNow;


    strcpy(myStock.exchange,"MI");
    strcpy(myStock.market,"EQCON");
    strcpy(myStock.t3Id,"1");
    strcpy(myStock.subscLabel,"");
    strcpy(myStock.status,"0");
    strcpy(myStock.ask,"");
    strcpy(myStock.bid,"");

    buildSubLabel(&myStock);

    while (1) {
        t.tv_sec = 1;
        t.tv_usec = 0;

        select(0, NULL, NULL, NULL, &t);
        time(&timeNow);

        sample(&myStock);

        printf("DataLink on %s\n",myStock.subscLabel);
        printf("Time Now: --- %s",ctime(&timeNow));
        printf("DataLink Status---- %s\n",myStock.status);
        printf("Ask --- %s\n",myStock.ask);
        printf("Bid --- %s\n",myStock.bid);
        printf("###################\n");

    }

    return 0;
    }


What I'm not able to do is to schedule the sample function at specific time.
I'd like to call sample function at 
9.01 the first time
9.05 the second time
9.10 the third time
9.15 ......
9.20 ......
and so on until 17.30
After the 17.30 the process should terminate.

Best regards
Massimo