It is currently Fri Nov 24, 2017 5:20 pm

All times are UTC - 7 hours





Post new topic Reply to topic  [ 11 posts ] 
Author Message
PostPosted: Mon Oct 28, 2013 10:52 pm 
Offline

Joined: Tue Jun 28, 2011 2:39 pm
Posts: 152
Ok, I've started to learn assembly with nerdy nights, but developing using NESICIDE (by the way, NESICIDE's wiki is down, mysql connection error). But when I try to compile first code:

Code:
.org $C000
.org $0000
.incbin "mario.chr"
.org $FFFA     ;first of the three vectors starts here
RESET:
   SEI
   CLD
   LDA %11000000
   STA $2001
   JMP Forever
.org $C000
Forever:
   JMP Forever


(the background color one)

no matter what I do, I get following error:

Code:
sh: C:\Program: No such file or directory
ld65: Error: Input file `nes.lib' not found
make: *** [nerdynights1.prg] Error 1
Build failed while processing Source.


I've got all dependencies from NESICIDE's download site (installed MSI with dependencies), but it can't compile.

The only thing I was able to compile was Alter Ego C demo by Shiru converted into NESICIDE projects, all ASM projects fail.

//edit:

This is from About/Versions window. It may be helpful:
NESICIDE Application version:
V1.038 RELEASE

NES Emulator Library version:
V1.004 RELEASE

Commodore 64 (VICE Interface) Library version:
V1.000 RELEASE

Versions of external dependencies:
cc65:
cc65 V2.13.9
SVN version: unknown

ca65
ca65 V2.13.9 - (C) Copyright 1998-2011 Ullrich von Bassewitz
ca65: No input files

ld65
ld65 V2.13.9 - (C) Copyright 1998-2009, Ullrich von Bassewitz
ld65: Error: No object files to link

make
GNU Make 3.81
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
This program built for i386-pc-mingw32


Top
 Profile  
 
PostPosted: Tue Oct 29, 2013 4:08 am 
Offline
User avatar

Joined: Mon Jan 03, 2005 10:36 am
Posts: 2981
Location: Tampere, Finland
darkhog wrote:
But when I try to compile first code:

Code:
.org $C000
.org $0000
.incbin "mario.chr"
.org $FFFA     ;first of the three vectors starts here
RESET:
   SEI
   CLD
   LDA %11000000
   STA $2001
   JMP Forever
.org $C000
Forever:
   JMP Forever


Where did you get this code? It's wayyyyy broken, especially if it's supposed to target ca65 (the assembler that NESICIDE uses).

_________________
Download STREEMERZ for NES from fauxgame.com! — Some other stuff I've done: kkfos.aspekt.fi


Top
 Profile  
 
PostPosted: Tue Oct 29, 2013 4:15 am 
Offline

Joined: Tue Jun 28, 2011 2:39 pm
Posts: 152
From nerdy nights. And also no project compiles, even those on download page (like russian roulette), only C projects (like Alter Ego) can be compiled. Every asm project I've tried fail with that nes.lib error.


Top
 Profile  
 
PostPosted: Tue Oct 29, 2013 4:22 am 
Offline
User avatar

Joined: Mon Jan 03, 2005 10:36 am
Posts: 2981
Location: Tampere, Finland
darkhog wrote:
From nerdy nights. And also no project compiles, even those on download page (like russian roulette), only C projects (like Alter Ego) can be compiled. Every asm project I've tried fail with that nes.lib error.

It's definitely not from http://www.nintendoage.com/forum/messag ... eadid=4440

_________________
Download STREEMERZ for NES from fauxgame.com! — Some other stuff I've done: kkfos.aspekt.fi


Top
 Profile  
 
PostPosted: Tue Oct 29, 2013 4:30 am 
Offline

Joined: Tue Jun 28, 2011 2:39 pm
Posts: 152
Original code didn't want to compile, so I've cut it until it could. Then at linking, nes.lib error.

//edit: But nes.lib thing is in every assembly project for NESICIDE I find and try to compile, only C projects works.


Top
 Profile  
 
PostPosted: Tue Oct 29, 2013 6:56 am 
Offline
User avatar

Joined: Sat Feb 12, 2005 9:43 pm
Posts: 10119
Location: Rio de Janeiro - Brazil
Sorry if I can't help with the compiler-specific stuff (ASM6 user here), but your "first code" example is pretty messed up. The CHR should be at the end of the ROM, not the beginning. Also, only the vectors (which are pointers to the NMI, RESET and IRQ labels) are supposed to be at $FFFA, but you put code there. The structure should be more like this:

Code:
   .org $c000

RESET:
   ;RESET CODE HERE
   ;FOREVER LOOP HERE

NMI:
   ;NMI CODE HERE
   rti ;return from interrupt

IRQ:
   ;IRQ CODE HERE
   rti ;return from interrupt

   .org $fffa

   .dw NMI ;points to the NMI routine
   .dw RESET ;points to the RESET routine
   .dw IRQ ;points to the IRQ routine

   .incbin "mario.chr"

This is the bare minimum you need to get a functioning ROM. The syntax may differ depending on the assembler, but you definitely need this basic structure for your program to run without crashing.

Again, sorry if this doesn't help with not being able to compile the project, but once you do manage to compile you'll definitely have to fix the program's structure.


Top
 Profile  
 
PostPosted: Mon Nov 04, 2013 7:39 pm 
Offline
Site Admin
User avatar

Joined: Mon Sep 20, 2004 6:04 am
Posts: 3484
Location: Indianapolis
I had that problem with NESICIDE as well, I think what I ended up doing was just copying the nes.lib file from elsewhere (probably Alter Ego source) and put it into my program's folder. I was writing a C program though, but seems to be the same issue anyways.

(edit: whoops, saw your edit that you tried other asm projects, but did you try copying the nes.lib into your project's source anyways?)


Top
 Profile  
 
PostPosted: Mon Nov 11, 2013 5:08 am 
Offline

Joined: Tue Jun 28, 2011 2:39 pm
Posts: 152
Sorry. Yes, copying nes.lib works. I was helped by cpow himself on NESICIDE's IRC, just forgot to update thread. Chris assured me that it will be fixed in next version though.

Anyway, anyone knows any nerdy nights-like tutorial that deals with NESICIDE? Translating NESASM into ca65 will be hard for beginner like me and I refuse to use NESASM as it doesn't have many good features that make writing maintainable code easier.


Top
 Profile  
 
PostPosted: Mon Nov 11, 2013 7:58 am 
Offline
User avatar

Joined: Mon Jan 03, 2005 10:36 am
Posts: 2981
Location: Tampere, Finland
Somebody has already translated Nerdy Nights to ca65: https://bitbucket.org/ddribin/nerdy-nights/src

_________________
Download STREEMERZ for NES from fauxgame.com! — Some other stuff I've done: kkfos.aspekt.fi


Top
 Profile  
 
PostPosted: Mon Nov 11, 2013 9:00 am 
Offline

Joined: Tue Jun 28, 2011 2:39 pm
Posts: 152
Yeah, but those are just sources. It's not as nicely wrapped into tutorials as in NN (great benefit of NN is that it shows some ASM code then explain what it does and how), so reading NN and then substituting NESASM code for ca65 one would be painful. Unless someone translated code in tutorials of course (and adjusted parts of tutorials that refers to how nesasm is doing things and aren't valid for ca65).


Top
 Profile  
 
PostPosted: Mon Nov 11, 2013 10:24 am 
Offline
NESICIDE developer
User avatar

Joined: Mon Oct 13, 2008 7:55 pm
Posts: 1049
Location: Minneapolis, MN
darkhog wrote:
Yeah, but those are just sources. It's not as nicely wrapped into tutorials as in NN (great benefit of NN is that it shows some ASM code then explain what it does and how), so reading NN and then substituting NESASM code for ca65 one would be painful. Unless someone translated code in tutorials of course (and adjusted parts of tutorials that refers to how nesasm is doing things and aren't valid for ca65).

You should now be able to compile stuff and have it find nes.lib properly. Let me know.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 11 posts ] 

All times are UTC - 7 hours


Who is online

Users browsing this forum: No registered users and 8 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group