OK, I have another problem. I have looked at this error message and cannot find out what is wrong.
Error:
flyingfisch@flyingfisch-Office-Computer:~/Desktop/PrizmSDK-0.3/projects/chess-timer$ make
/usr/local/cross/bin/sh3eb-elf-gcc -MMD -MP -MF /home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/build/chess-timer.d -Os -Wall -mb -m4a-nofpu -mhitachi -nostdlib -I/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/build -I/home/flyingfisch/Desktop/PrizmSDK-0.3/include -std=c99 -c /home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c -o chess-timer.o
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c: In function 'main':
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:21:3: warning: pointer targets in passing argument 1 of 'RTC_GetTime' differ in signedness [-Wpointer-sign]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/RTC_syscalls.h:4:6: note: expected 'unsigned int *' but argument is of type 'int *'
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:21:3: warning: pointer targets in passing argument 2 of 'RTC_GetTime' differ in signedness [-Wpointer-sign]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/RTC_syscalls.h:4:6: note: expected 'unsigned int *' but argument is of type 'int *'
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:21:3: warning: pointer targets in passing argument 3 of 'RTC_GetTime' differ in signedness [-Wpointer-sign]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/RTC_syscalls.h:4:6: note: expected 'unsigned int *' but argument is of type 'int *'
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:21:3: warning: pointer targets in passing argument 4 of 'RTC_GetTime' differ in signedness [-Wpointer-sign]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/RTC_syscalls.h:4:6: note: expected 'unsigned int *' but argument is of type 'int *'
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:25:3: warning: implicit declaration of function 'strcpy' [-Wimplicit-function-declaration]
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:25:3: warning: incompatible implicit declaration of built-in function 'strcpy' [enabled by default]
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:26:3: warning: pointer targets in passing argument 2 of 'itoa' differ in signedness [-Wpointer-sign]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/CONVERT_syscalls.h:6:6: note: expected 'unsigned char *' but argument is of type 'char *'
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:26:10: error: void value not ignored as it ought to be
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:27:3: warning: passing argument 3 of 'PrintXY' makes pointer from integer without a cast [enabled by default]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/display.h:28:6: note: expected 'char *' but argument is of type 'int'
make[1]: *** [chess-timer.o] Error 1
make: *** [build] Error 2
Code:
Code:
Error:
flyingfisch@flyingfisch-Office-Computer:~/Desktop/PrizmSDK-0.3/projects/chess-timer$ make
/usr/local/cross/bin/sh3eb-elf-gcc -MMD -MP -MF /home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/build/chess-timer.d -Os -Wall -mb -m4a-nofpu -mhitachi -nostdlib -I/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/build -I/home/flyingfisch/Desktop/PrizmSDK-0.3/include -std=c99 -c /home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c -o chess-timer.o
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c: In function 'main':
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:21:3: warning: pointer targets in passing argument 1 of 'RTC_GetTime' differ in signedness [-Wpointer-sign]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/RTC_syscalls.h:4:6: note: expected 'unsigned int *' but argument is of type 'int *'
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:21:3: warning: pointer targets in passing argument 2 of 'RTC_GetTime' differ in signedness [-Wpointer-sign]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/RTC_syscalls.h:4:6: note: expected 'unsigned int *' but argument is of type 'int *'
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:21:3: warning: pointer targets in passing argument 3 of 'RTC_GetTime' differ in signedness [-Wpointer-sign]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/RTC_syscalls.h:4:6: note: expected 'unsigned int *' but argument is of type 'int *'
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:21:3: warning: pointer targets in passing argument 4 of 'RTC_GetTime' differ in signedness [-Wpointer-sign]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/RTC_syscalls.h:4:6: note: expected 'unsigned int *' but argument is of type 'int *'
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:25:3: warning: implicit declaration of function 'strcpy' [-Wimplicit-function-declaration]
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:25:3: warning: incompatible implicit declaration of built-in function 'strcpy' [enabled by default]
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:26:3: warning: pointer targets in passing argument 2 of 'itoa' differ in signedness [-Wpointer-sign]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/CONVERT_syscalls.h:6:6: note: expected 'unsigned char *' but argument is of type 'char *'
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:26:10: error: void value not ignored as it ought to be
/home/flyingfisch/Desktop/PrizmSDK-0.3/projects/chess-timer/src/chess-timer.c:27:3: warning: passing argument 3 of 'PrintXY' makes pointer from integer without a cast [enabled by default]
/home/flyingfisch/Desktop/PrizmSDK-0.3/include/display.h:28:6: note: expected 'char *' but argument is of type 'int'
make[1]: *** [chess-timer.o] Error 1
make: *** [build] Error 2
Code:
Code:
#include <display_syscalls.h>
#include <keyboard_syscalls.h>
#include <display_syscalls.h>
#include <display.h>
#include <keyboard.hpp>
#include <color.h>
#include <RTC_syscalls.h>
#include <CONVERT_syscalls.h>
int PRGM_GetKey(void);
int main() {
int key;
int hour, minute, second, ms;
int done = 0;
while (!done) {
Bdisp_AllClr_VRAM();
RTC_GetTime(&hour, &minute, &second, &ms);
second = 10*(second&0xf0)+(second&0x0f);
char buffer[10];
strcpy(buffer," ");
second = itoa(second, buffer+2);
PrintXY(1, 1, second, TEXT_MODE_NORMAL, TEXT_COLOR_BLACK);
Bdisp_PutDisp_DD();
key = PRGM_GetKey();
if (key == KEY_PRGM_MENU) {
done = 1;
}
}
return 1;
}
int PRGM_GetKey(void) {
unsigned char buffer[12];
PRGM_GetKey_OS( buffer );
return ( buffer[1] & 0x0F ) * 10 + ( ( buffer[2] & 0xF0 ) >> 4 );
}