Compare commits

...

6 Commits

Author SHA1 Message Date
Nobuhiro Hatano c337c22071
Merge pull request #5 from nobuh/msgbuf-format-not-a-string
Msgbuf format not a string
2023-06-07 23:34:27 +09:00
nobuh e36276fce7 Remove install instruction for cygwin 2023-06-07 23:30:49 +09:00
nobuh c0f43127cc msgbuf.c format not a string warning during make 2023-06-07 23:24:44 +09:00
Nobuhiro Hatano 2e17ed5e27
Merge pull request #4 from nobuh/multiple-difinition-error
Multiple definition error at make
2023-06-07 23:21:39 +09:00
nobuh d47be2dd9e fix make: multiple definition of nrow and ncol
make fail by the error

/usr/bin/ld: main.o:(.bss+0x0): multiple definition of `nrow'; memory.o:(.bss+0x0): first defined here
/usr/bin/ld: main.o:(.bss+0x4): multiple definition of `ncol'; memory.o:(.bss+0x4): first defined here

fix definition of the global variables nrow and ncol.
2023-06-07 23:08:33 +09:00
nobuh 4be07cb2ee chmod -x on src files 2023-06-07 15:17:25 +09:00
19 changed files with 10 additions and 12 deletions

0
AUTHORS Executable file → Normal file
View File

0
CHANGELOG Executable file → Normal file
View File

0
COPYING Executable file → Normal file
View File

16
README Executable file → Normal file
View File

@ -1,21 +1,17 @@
napple1 is an Apple 1 emulator using ncurses, ported from the SDL version napple1 is an Apple 1 emulator using ncurses, ported from the SDL version
Pom1 emulafor. If you have some questions, please report it as an issue. Pom1 emulafor. If you have some questions, please report it as an issue.
How to install on cygwin How to install on Ubuntu (ex. Ubuntu 22.04)
========================= ===========================================
0. Setup cygwin (base) and make, gcc4, libncurses-dev 1. sudo apt install make gcc libncurses-dev
and follow Linux procedure.
How to install on Linux 2. git clone https://github.com/nobuh/napple1.git
========================
1. Download latest source package nappple1-<n>.<n>.tar.gz
and extract it.
2. Build 3. Build
cd napple1/src cd napple1/src
make make
cd .. cd ..
3. Run 4. Run
./napple1 ./napple1
ROM Directory ROM Directory

0
SAMPLE_PROGRAMS Executable file → Normal file
View File

0
src/keyboard.c Executable file → Normal file
View File

0
src/keyboard.h Executable file → Normal file
View File

0
src/m6502.c Executable file → Normal file
View File

0
src/m6502.h Executable file → Normal file
View File

0
src/main.c Executable file → Normal file
View File

0
src/makefile Executable file → Normal file
View File

0
src/memory.c Executable file → Normal file
View File

0
src/memory.h Executable file → Normal file
View File

2
src/msgbuf.c Executable file → Normal file
View File

@ -45,7 +45,7 @@ void print_msgbuf(char *s)
"%-40s", "%-40s",
s); s);
werase(msgbuf); werase(msgbuf);
wprintw(msgbuf, msg); wprintw(msgbuf, "%s", msg);
wrefresh(msgbuf); wrefresh(msgbuf);
} }

0
src/msgbuf.h Executable file → Normal file
View File

0
src/pia6820.c Executable file → Normal file
View File

0
src/pia6820.h Executable file → Normal file
View File

2
src/screen.c Executable file → Normal file
View File

@ -36,6 +36,8 @@ static int indexX, indexY;
static WINDOW *screen; static WINDOW *screen;
static long long interval_start; /* interval start time in u sec */ static long long interval_start; /* interval start time in u sec */
int nrow, ncol;
char getch_screen(void) char getch_screen(void)
{ {
return (char)wgetch(screen); return (char)wgetch(screen);

2
src/screen.h Executable file → Normal file
View File

@ -25,5 +25,5 @@ void outputDsp(unsigned char dsp);
char getch_screen(void); char getch_screen(void);
void select_screen(void); void select_screen(void);
int nrow, ncol; extern int nrow, ncol;