settable codepage() on RP6502

This commit is contained in:
rumbledethumps
2025-06-29 20:16:07 -07:00
parent 407a31eeaa
commit 77e325507e
2 changed files with 3 additions and 2 deletions

View File

@@ -121,7 +121,7 @@ int __cdecl__ xregn (char device, char channel, unsigned char address, unsigned
...); ...);
int __cdecl__ xreg (char device, char channel, unsigned char address, ...); int __cdecl__ xreg (char device, char channel, unsigned char address, ...);
int phi2 (void); int phi2 (void);
int codepage (void); int codepage (int);
long lrand (void); long lrand (void);
int __fastcall__ stdin_opt (unsigned long ctrl_bits, unsigned char str_length); int __fastcall__ stdin_opt (unsigned long ctrl_bits, unsigned char str_length);
int __fastcall__ read_xstack (void* buf, unsigned count, int fildes); int __fastcall__ read_xstack (void* buf, unsigned count, int fildes);

View File

@@ -1,6 +1,7 @@
#include <rp6502.h> #include <rp6502.h>
int __fastcall__ codepage (void) int __fastcall__ codepage (int cp)
{ {
ria_set_ax (cp);
return ria_call_int (RIA_OP_CODEPAGE); return ria_call_int (RIA_OP_CODEPAGE);
} }