Pumpkin User Forums
  PICmicro MCUs
  Problem building tu5 (MPLABv7.01 && MCC18v2.4 && SALVOLITEv3.2.3 )

Post New Topic  Post A Reply
profile | register | preferences | faq | search

UBBFriend: Email This Page to Someone! next newest topic | next oldest topic
Author Topic:   Problem building tu5 (MPLABv7.01 && MCC18v2.4 && SALVOLITEv3.2.3 )
david1024
Junior Member
posted May 26, 2005 09:42     Click Here to See the Profile for david1024     Edit/Delete Message   Reply w/Quote
Thanks for your reply.

I just put a "#define TMR0 TMR0L" below the "#if defined(USE_INTERRUPTS)" to fix the problem.

Although I suppose it should be in an #if defined(SYSE)....

Compiles fine now.

IP:

aek
Moderator
posted May 25, 2005 02:38     Click Here to See the Profile for aek     Edit/Delete Message   Reply w/Quote
Yes.

Tu5 (and tu6) use interrupts and isr.c in order to implement delays via Salvo' timer services.

TMR0 is referenced in the ISR (in isr.c) and in Init() (to initialize the timer).

IIRC, thre is an issue surround the use of the term "TMR0" (as opposed to TMR0L and TMR0H) with the MPLAB-C18 compiler.

The best way to solve this in your case is to modify the Init() macro and the ISR so that you end up with an ISR that calls OSTimer() at a 10Hz rate.

The problem in your Build Results is simply that MPLAB-C18 doesn't know what TMR0 is -- it only knows about TMR0L and TMR0H.

------------------

IP:

david1024
Junior Member
posted May 23, 2005 12:34     Click Here to See the Profile for david1024     Edit/Delete Message   Reply w/Quote
Below is how tutorial 5 fails to compile for me. I have done the '$BINDIR-browse...' to get TU1-4 built, but when I use \salvo\tut\tu5\syse\tu5lite.mcp, tu5 will not build.

Any idea on why this won't build?


Clean: Deleting intermediary and output files.
Clean: Deleted file "C:\salvo\tut\tu5\main.o".
Clean: Done.
Executing: "C:\mcc18\bin\mcc18.exe" -p=18C452 "main.c" -fo="main.o" /i"C:\salvo\tut\tu5\syse" /i"C:\salvo\tut\tu5\syse\..\..\tu1" /i"C:\salvo\tut\tu5\syse\..\..\..\inc" -DSYSE -DMAKE_WITH_FREE_LIB -DUSE_INTERRUPTS -Opa-
MPLAB C18 v2.40 (demo)
Copyright 1999-2004 Microchip Technology Inc.
Days remaining until demo becomes feature limited: 41
Executing: "C:\mcc18\bin\mcc18.exe" -p=18C452 "isr.c" -fo="isr.o" /i"C:\salvo\tut\tu5\syse" /i"C:\salvo\tut\tu5\syse\..\..\tu1" /i"C:\salvo\tut\tu5\syse\..\..\..\inc" -DSYSE -DMAKE_WITH_FREE_LIB -DUSE_INTERRUPTS -Opa-
MPLAB C18 v2.40 (demo)
Copyright 1999-2004 Microchip Technology Inc.
Days remaining until demo becomes feature limited: 41
C:\salvo\tut\tu1\isr.c:48:Error [1105] symbol 'TMR0' has not been defined
C:\salvo\tut\tu1\isr.c:48:Error [1101] lvalue required
Halting build on first failure as requested.
BUILD FAILED: Mon May 23 14:24:36 2005

IP:

All times are ET

next newest topic | next oldest topic

Administrative Options: Close Topic | Archive/Move | Delete Topic
Post New Topic  Post A Reply
Hop to:

Contact Us | Pumpkin Home Page

2000-2008 Pumpkin, Inc. All Rights Reserved. Pumpkin and the Pumpkin logo, Salvo and the Salvo logo, The RTOS that runs in tiny places, CubeSat Kit and the CubeSat Kit logo are all trademarks of Pumpkin, Inc. All other trademarks are the properties of their respective owners.


Ultimate Bulletin Board 5.46a