예제 #1
0
파일: rtc.c 프로젝트: HomerSp/pspautotests
void checkDayOfWeek() {
	printf("Checking sceRtcGetDayOfWeek\n");
	printf("sceRtcGetDayOfWeek:2010, 4, 27\n");
	printf("%d\n", sceRtcGetDayOfWeek(2010, 4, 27));

	//A game does this: sceRtcGetDayOfWeek(166970016, 1024, 0)

	
	printf("sceRtcGetDayOfWeek:166970016, 1024, 0\n");
	printf("%d\n", sceRtcGetDayOfWeek(166970016, 1024, 0));
}
예제 #2
0
파일: main.c 프로젝트: sum2012/JPCSP-Mirror
void printGetDayOfWeek()
{
    int i;

    printf("sceRtcGetDayOfWeek, 2008-01-07 is a monday (yyyy-mm-dd)\n");
    for (i = 0; i < 7; i++)
    {
        int number = sceRtcGetDayOfWeek(2008, 1, 7 + i);
        printf("2008-01-%02d: day = %d\n", (7 + i), number);
    }
}
예제 #3
0
파일: main.c 프로젝트: yne/js-psp
int get(u64 tick,int elem,int local){//1=year ... 7:ms
	pspTime t;
	if(local)sceRtcTickAddMinutes(&tick,&tick,timeZone);
	sceRtcSetTick(&t,&tick);
	switch(elem){
		case 1 :return t.year;
		case 2 :return t.month;
		case 3 :return t.day;
		case 4 :return sceRtcGetDayOfWeek(t.year,t.month,t.day);
		case 5 :return t.hour;
		case 6 :return t.minutes;
		case 7 :return t.seconds;
		case 8 :return t.microseconds/1000;
		default:return 0;
	}
	return 0;
}