I think I've said this about 10 times so far...
if you read my last email I gave two suggestions for
how I would go about doing the install. But you've
forced my hand so I just went and tried a number of
approaches. Do one of these:

1)  Set the danged environment variable.
or
2)  Your make line is incorrect, which explains why the reinstall
     is running the compile line again (but actually doesn't explain
     what make thinks it's doing by re-running the compile...)
     Try this:
         make mica2 reinstall MIB510=COM1

MS

Tony Ling wrote:
How would you go about running the HFS.nc program on your machine?
(\opt\tinyos-1.x\apps\HighFrequencySampling\HFS.nc) ?

I would simply compile it first (command line: make mica2),

Then install it to my mote: (command line: make mica2 reinstall
mib510,com1)

I'm just making sure this is the proper way to do it, and see if anyone
else can run this program using that method.  At least this way I'll
know that my problem isn't in my makefiles, but rather in the commands I
use to run the program

thanks

-----Original Message-----
From: Michael Schippling [mailto:[EMAIL PROTECTED] Sent: Monday, December 11, 2006 3:08 PM
To: Tony Ling
Cc: tinyos-help@Millennium.Berkeley.EDU
Subject: Re: [Tinyos-help] Flash Errors when Loading programs from
anywhere except Contrib Folder

My makefile reading days are far behind the current syntax...

Try two things:

export MIB510=COM1
make ....

or

make .... MIB510=COM1


and as I said, I believe the correct setup is described in one of
the Getting Started type manuals that you should be able to find
on the xbow site...
MS


Tony Ling wrote:
Okay, I think the problem lies in the Makerules file
(\tinyos\cygwin\opt\tinyos-1.x\apps),

specifically lines 151 through 162:


########################################################################
#
# Programming Boards : flags

########################################################################
#
ifeq ($(shell uname),FreeBSD)
        PROGRAMMER_FLAGS=-dlpt=/dev/ppi0 -dprog=dapa $(PROGRAMMER_PART)
$(PROGRAMMER_EXTRA_FLAGS)
        
else
        PROGRAMMER_FLAGS=-dprog=dapa $(PROGRAMMER_PART)
$(PROGRAMMER_EXTRA_FLAGS)
        
endif

PROGRAMMER := DAPA







And then lines 165 through 201:


########################################################################
#
# Programming Boards : command line input
# Command line input for programmers: # none : default to parallel programming board
#   MIB510=<dev> : use mib510 port programming board at port <dev>
#   EPRB=<host>    : use eprb at hostname <host>
#   AVRISP=<dev> : use AVRISP serial programmer at port <dev>

########################################################################
#

### If MIB510 then
MIB5100 := $(subst MIB510=,,$(filter MIB510=%,$(MAKECMDGOALS)))
ifneq ($(MIB510_),)
  MIB510 := $(MIB5100)
endif
MAKECMDGOALS := $(filter-out MIB510=%,$(MAKECMDGOALS))

### If STK is a set environment variable or if STK=xxx appears on the
command
### line, then take it to be a network address and program assuming an
stk500
### module.
EPRB0 := $(subst EPRB=,,$(filter EPRB=%,$(MAKECMDGOALS)))
ifneq ($(EPRB_),)
  EPRB := $(EPRB0)
endif
MAKECMDGOALS := $(filter-out EPRB=%,$(MAKECMDGOALS))

ifneq (x$(MIB510),x)
   PROGRAMMER := STK
   PROGRAMMER_FLAGS=-dprog=mib510 -dserial=$(MIB510)
$(PROGRAMMER_PART)
$(PROGRAMMER_EXTRA_FLAGS_MIB)
endif
ifneq (x$(EPRB),x)
  PROGRAMMER := STK
  PROGRAMMER_FLAGS=-dprog=stk500 -dhost=$(EPRB) $(PROGRAMMER_PART)
$(PROGRAMMER_EXTRA_FLAGS_STK)
endif
ifdef AVRISP
  PROGRAMMER := STK
  PROGRAMMER_FLAGS=-dprog=stk500 -dserial=$(AVRISP) $(PROGRAMMER_PART)
$(PROGRAMMER_EXTRA_FLAGS_AVRISP)
endif






There is something we should change to tell the program that we have a
mib510 into COM port 1, but I'm not sure as how to do it...



-----Original Message-----
From: Michael Schippling [mailto:[EMAIL PROTECTED] Sent: Friday, December 08, 2006 7:19 PM
To: Tony Ling
Cc: tinyos-help@Millennium.Berkeley.EDU
Subject: Re: [Tinyos-help] Flash Errors when Loading programs from
anywhere except Contrib Folder

alright then, now we're getting somewhere...

when I do the make reinstall in apps I get this line:

     uisp -dprog=mib510 -dserial=COM3 -dpart=ATmega128 ...

whereas you have:

     uisp -dprog=dapa -dpart=ATmega128  ....

Note that "dapa" is some other kind of programmer board,
and there is no COM spec. My belief is that this info comes
from the env var  MIB510=COM3  but I think one of the Getting
Started guides describes how to set things up correctly.
I've not used the make command line option that you have,
so I don't know if that's the way it's supposed to work...
Once I find a magic combination of configurations I usually
just ignore other possibilities and hope it just keeps doing
whatever it is supposed to be doing...

Another curious thing I can't explain is why your make _RE_install
goes ahead and redoes the ncc and objcpy passes...whereas mine just
fires off uisp...I'm not generally greatly happy with TOS makefile
dependencies, but the above doesn't really make sense...

MS


Tony Ling wrote:
I tried running HFS.nc \tinyos-1.x\apps\HighFrequencySampling\

First, I typed "make mica2"
And it terminated with exit code 0.

Then, I typed "make mica2 reinstall mib510,com1"
And these are the errors I received:

---------- Capture Output ----------
"C:\Program Files\Crossbow\Crimson\IDE.bat"
"C:\tinyos\cygwin\opt\tinyos-1.x\apps\HighFrequencySampling"
"c:\tinyos\cygwin\bin" "make mica2 reinstall mib510,com1"
#############################
Command:   make mica2 reinstall mib510,com1
Cygwin:    c:\tinyos\cygwin\bin
Directory: C:\tinyos\cygwin\opt\tinyos-1.x\apps\HighFrequencySampling
Directory: /opt/tinyos-1.x/apps/HighFrequencySampling #############################

    compiling HFS to a mica2 binary
ncc -o build/mica2/main.exe -Os -board=micasb -target=mica2  -Wall
-Wshadow -DDEF_TOS_AM_GROUP=0x7d -Wnesc-all -finline-limit=100000
-fnesc-cfile=build/mica2/app.c HFS.nc -lm compiled HFS to build/mica2/main.exe
           18010 bytes in ROM
             848 bytes in RAM
avr-objcopy --output-target=srec build/mica2/main.exe
build/mica2/main.srec
    installing mica2 binary
uisp -dprog=dapa -dpart=ATmega128 --wr_fuse_e=ff --erase Atmel AVR ATmega128 is found.
Erasing device ...
Reinitializing device
Atmel AVR ATmega128 is found.
pulse
pulse

Fuse Extended Byte set to 0xff
sleep 1 uisp -dprog=dapa -dpart=ATmega128 --wr_fuse_e=ff --upload
if=build/mica2/main.srec
Atmel AVR ATmega128 is found.
Uploading: flash
pulse

Fuse Extended Byte set to 0xff
sleep 1 uisp -dprog=dapa -dpart=ATmega128 --wr_fuse_e=ff --verify
if=build/mica2/main.srec
Atmel AVR ATmega128 is found.
Verifying: flash
flash error at address 0x0: file=0x0c, mem=0xff
flash error at address 0x1: file=0x94, mem=0xff
flash error at address 0x2: file=0xb5, mem=0xff
flash error at address 0x3: file=0x01, mem=0xff
flash error at address 0x4: file=0x0c, mem=0xff
flash error at address 0x5: file=0x94, mem=0xff
flash error at address 0x6: file=0xd2, mem=0xff
flash error at address 0x7: file=0x01, mem=0xff
flash error at address 0x8: file=0x0c, mem=0xff

...and so on


-----Original Message-----
From: Michael Schippling [mailto:[EMAIL PROTECTED] Sent: Friday, December 08, 2006 3:39 PM
To: Tony Ling
Cc: tinyos-help@Millennium.Berkeley.EDU
Subject: Re: [Tinyos-help] Flash Errors when Loading programs from
anywhere except Contrib Folder

MakeXbowlocal is just that...xbow's version of the apps/Makelocal
file...
Nothing in the regular apps tree references it and it probably
contains
a lot of defines that won't be of any use there anyway.

Can you post the output from "make install" in both dirs so we can
try
to compare them?

MS

Tony Ling wrote:
In my contrib/xbow/MakeXbowlocal file I have:
------------------------
DEFAULT_PROGRAM=mib510
MIB510=COM1

DEFAULT_LOCAL_GROUP=0x88

CFLAGS = -DCC1K_DEFAULT_FREQ=RADIO_433BAND_CHANNEL_00
CFLAGS += -DRADIO_XMIT_POWER=0xFF

CFLAGS +=-DCC2420_TXPOWER=TXPOWER_MAX
------------------------


Keep in mind that this is the only directory that works. I don't
even
have a MakeXbowlocal file in my cygwin/opt/tinyos-1.x/apps directory
(the one that doesn't work). Perhaps this is the problem? I tried
copying my MakeXbowlocal (from contrib/xbow/MakeXbowlocal) file over
to
the cygwin/opt/tinyos-1.x/apps directory (that isn't working for
me),
but that didn't fix my problem.


The only makefiles I have in my faulty directory (.nc programs won't
load onto my mote) are: .cvsignore, Makefile, and Makerules

Contents:
--------------------
.cvsignore:
                Makelocal
(that is all that file says)
--------------------

Makefile:
        

######################################################################
# # Top-level make file. Just build all of the apps
        #
        

######################################################################
        # default to using -s, unless VERBOSE_MAKE is set
        ifeq ($(VERBOSE_MAKE)_x, _x)
        MAKEFLAGS += -s
        endif
        export VERBOSE_MAKE

        # handle documentation generation
        DOCS := $(filter docs, $(MAKECMDGOALS))
        MAKECMDGOALS := $(filter-out docs, $(MAKECMDGOALS))
        ifeq ($(DOCS)_x, docs_x)
        MAKEFLAGS += -k
        endif


        # catch-all rule - pass targets on to the lower level
        %:
                @for d in `ls`; do \
                if [ -f $$d/Makefile ]; then \
                        echo "$$d...."; \
                        $(MAKE) -C $$d $@ $(DOCS) \
                        || case "$(MAKEFLAGS)" in *k*) fail=yes;; *)
exit 1;;        esac; \
                fi; \
                done; test -z "$$fail"


        all:


        docs:
                @echo ""
------------------------------

Makerules: (very long, will post if necessary)
        
------------------------------

Thanks for any and all help,
Tony

-----Original Message-----
From: Michael Schippling [mailto:[EMAIL PROTECTED] Sent: Thursday, December 07, 2006 10:49 PM
To: Tony Ling
Subject: Re: [Tinyos-help] Flash Errors when Loading programs from
anywhere except Contrib Folder

Please send messages to the help-list to keep a record of
any useless advice I may have...

The MIB510 is not a sensor board, it's a base station.
The micasb is the usual sensor board that xbow sends in their
startup
kits.
The sensorboard setting shouldn't affect the ability to download
programs.

In my contrib/xbow/MakeXbowlocal I have:

     DEFAULT_PROGRAM=mib510
     MIB510=COM3

I also have an envvar MIB510=COM3
This seems to work for downloading in either directory.

If you are still having trouble, send your whole make output to the
list
so we can see what's what.

MS


Tony Ling wrote:
I opened a directory of a program (HighFrequencySampling) in the
directory that isn't working for me
(\tinyos\cygwin\opt\tinyos-1.x\apps)
Through the "HighFrequencySampling" directory I opened "Makefile"

All that is in the file is the following:

# This application assumes a mica sensor board, so does not run on
mica2dot
PLATFORMS=mica mica2
COMPONENT=HFS
SENSORBOARD=micasb
include ../Makerules


I am using a mica2 mote with mib510 sensor board, so should I
change
the
line "SENSORBARD= " and change it to something like "MIB510=COM1" ?

Thanks,
Tony

-----Original Message-----
From: Michael Schippling [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 06, 2006 7:25 PM
To: Tony Ling
Cc: tinyos-help@Millennium.Berkeley.EDU
Subject: Re: [Tinyos-help] Flash Errors when Loading programs from
anywhere except Contrib Folder

I have not observed any differences in downloading between the two
trees.
You might want to search through your local makefiles and see if
you
have
mistakenly overloaded the "mib510,com1" argument someplace. Also
look
at
the uisp line in the make output and see if it does what you
want...
MS

Tony Ling wrote:
Hello,

I am trying to install the "SenseLightToLog.nc" program onto my
mica2
mote through the mib510 configuration board.  I am using Crimson
Editor
to view the file. To compile, I type "make mica2" and the program compiles. To load the program onto my mote, I type "make mica2 reinstall mib510,com1" as I normally do to load any program to my mote.

I receive multiple "flash" errors when trying to install anything
out
of
this folder (\tinyos\cygwin\opt\tinyos-1.x\apps) but successfully
load
programs out of

\tinyos\cygwin\opt\tinyos-1.x\contrib\xbow\apps

this way.

Is there something in the Makerules file (\tinyos\cygwin\opt\tinyos-1.x\apps\Makerules) that needs to be
changed
to avoid these errors?  I am sure the flash errors are not caused
by
a
loose connection, since the files load through the contrib folder.

Thanks,

Tony



------------------------------------------------------------------------
_______________________________________________
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU

https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-hel
p
_______________________________________________
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU

https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-hel
p
_______________________________________________
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to