I can make programs who uses input and video options with arm9, and run this programs at nds and at emulators
but when I use touch with arm7 the program only works at emulators...

I tryied to use differents programs form arm7 and arm9, but it doesn't worked:
TouchARM9.pas
TouchARM7.pas

In toucharm7 the program has 2functions:
TouchX():Integer //take the X position of touch
and TouchY():Integer //take Y position of touch

And in toucharm9 I tryied to use the functions of the touch7 and print in the screen where was touched

In .bat file I used
ppcarmnds -g --gc-sections -Tnds toucharm7.pas
ppcarmnds -g --gc-sections -Tnds toucharm9.pas
ndstool -c TouchTest.nds -9 toucharm9.arm9.bin -7 toucharm7.arm7.bin
dsbuild TouchTest.nds -o TouchTest.nds.gba
pause

The compiler showed these Errors on toucharm9
The function touchX doesn't exists
The function touchY doesn't exists

I tryied to declare toucharm7 on the uses and the compiler showed these errors on Jtypes.inc
Can't find INTERFACE
Can't find IMPLEMENTATION


How can I make homebrews for NDS using the FPC4NDS?
I have the R4DS

Sry for my bad english