The first answer will technically allow you to set a timer that will fire every 2.5 seconds, however, the original poster asked for a solution that will fire at a specific time. To do this, you need to use the following NSTimer method:
- (id)initWithFireDate:(NSDate *)date interval:(NSTimeInterval)seconds target:(id)target selector:(SEL)aSelector userInfo:(id)userInfo repeats:(BOOL)repeats
The first argument is an NSDate , indicating when the timer should fire.
The original poster did not indicate, but if this is an iOS application, it is important to understand that the timers scheduled to start at a distant date / time will not work if your application is not a priority application. Itβs actually not possible to schedule such an event when your application is in the background on iOS, so you should consider this.
source share