[cc65] Help!,does anyone know how to use NES joystick with cc65

From: zhblue (newsclan) <newsclan1gmail.com>
Date: 2009-02-17 13:40:14
i tried to use NES joystick on cc65
#include <conio.h>
#include <stdio.h>
#include <nes.h>
#include <joystick.h>
//.....
void testjoy(){
   char err=0;
   const char * stdjoy="nes-stdjoy.joy";
   err=joy_load_driver(stdjoy);
   cprintf("%u",err);
}
int main (void)
{
   testjoy();
   while(1){
   };
}
======error reported========

D:\zhblue\cc65>ca65 -t nes hello.s

D:\zhblue\cc65>ld65 -t nes hello.o nes.o nes.lib atmos.lib -o hello.nes
Unresolved external `_close' referenced in:
 joy_load.s(18)
Unresolved external `_open' referenced in:
 joy_load.s(16)
Unresolved external `_read' referenced in:
 joy_load.s(17)
ld65.exe: Error: 3 unresolved external(s) found - cannot create output file
======================
Does anyone can help me, or share some working codes on NES joystick in cc65
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Tue Feb 17 13:40:21 2009

This archive was generated by hypermail 2.1.8 : 2009-02-17 13:40:24 CET