I guess you're right. I just copied the makefile, I really don't understand why the compiler didn't give me an error :S. In any case ...(from the gcc man): "If you use multiple -O options, with or without level numbers, the last such option is the one that is effective." So if you use Os and O2 only one will be used. *Jordi Soucheiron* Software Engineer
*DEXMA* Parc Tecnològic la Salle Sant Joan de la Salle, 42 08022 Barcelona t/f: [+34] 93 181 01 95 www.dexmatech.com [email protected] 2010/5/19 Michiel Konstapel <[email protected]> > I'm guessing that > > > > $(CC) $(CFLAGS) *-0s* -g -mmcu=msp430x2617 -o led.elf > led.c > > > > should be > > > > $(CC) $(CFLAGS) *-Os* -g -mmcu=msp430x2617 -o led.elf > led.c > > > > That is, an O (oh) instead of a zero, to optimize for size. Could be > mistaken though, since you specified -O2 in CFLAGS. > > Michiel > > > > *From:* [email protected] [mailto: > [email protected]] *On Behalf Of *Jordi > Soucheiron > *Sent:* woensdag 19 mei 2010 9:22 > *To:* Michael Schippling > *Cc:* tinyos forum > *Subject:* Re: [Tinyos-help] Using TinyOS mspgcc toolchain for building > MSP430MCU-s > > > > I've had to do this quite regularly. A makefile like the one you're asking > for could look like this: > CFLAGS=-O2 -DPRINTFUART_ENABLED > CC=msp430-gcc > > all: > $(CC) $(CFLAGS) -0s -g -mmcu=msp430x2617 -o led.elf led.c > msp430-objcopy --output-target=ihex led.elf led.ihex > z1-bsl --z1 -c $(shell motelist-z1 -c | cut -d, -f2 | head -n1) -r -e > -I -p led.ihex > > This example is for the Zolertia Z1 (based on the msp430f2617) but changing > the appropriate bits I'm sure you'll be able to make it work with your > platform. > Good luck > > 2010/5/18 Michael Schippling <[email protected]> > > You can find most everything anyone knows about mspgcc at: > mspgcc.sourceforge.net/ > > MS > > > > Andres Vahter wrote: > > Hi, > > > > I have mspgcc toolcain installed and it is working well with telosb. > > How can I use it for building and uploading a simple example program > > from TI webpage: MSP430F22x2, MSP430F22x4 > > > <http://www.ti.com/lit/zip/slac123>? > > > These example programs consist of only single .c file. > > > > Could someone provide example how Makefile should look like and how to > > upload binary to MCU using tos-bsl. > > > > Andres > > > > > > > ------------------------------------------------------------------------ > > > > > _______________________________________________ > > Tinyos-help mailing list > > [email protected] > > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help > _______________________________________________ > Tinyos-help mailing list > [email protected] > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help > > > > _______________________________________________ > Tinyos-help mailing list > [email protected] > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help >
_______________________________________________ Tinyos-help mailing list [email protected] https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
