Hey, I've looked around and searched a bit, but haven't been able to find any answers (found a few similar questions, but they didn't really post their solutions). Is there a (preferably simple) way to get the epoch time? I'm trying to implement a simple timer into a program, but can't find much relevant to this.
I've tried using the datatype time_t, but I can't figure out how to convert that to an integer... It's probably a very simple question -- sorry about that (I'm new to C).
Epoch Time?
Arg. Don't you hate it when you post stupid questions and then figure it out right after you post?
Here's what worked:
The problem was apparently that I was using the wrong modifiers in my printf statement :-\
Here's what worked:
Code: Select all
time_t startTime = sceKernelLibcTime(NULL);
time_t curTime;
int i=0;
while(i < 10000) {
i++;
curTime = sceKernelLibcTime(NULL);
printf("Time (%d): %ld\n", i, curTime - startTime);
}