It might be ok, but it makes more sense to put it in the .platform file since you may be compiling for different processors at different times. You should probably jsut follow the example from how they do it in /tinyos-2.x/tos/platforms/intelmote2/.platform
Kevin On Oct 30, 2007 11:28 AM, mejda chouaieb <[EMAIL PROTECTED]> wrote: > Hi, > first of all thak you. > I have a question : > I created a file under "C:\jennic\cygwin\etc\profile.d" named "tinyos.sh" > when I installed TinyOS. My question is : > if I just add the Variable "NESC_MACHINE" to the containt of this file, is it > sufficient to use "env" in my .platform file ? > > the containt of my "tinyos.sh" file is : > ______________________________________ > > #!/bin/sh > export TOSROOT="/opt/tinyos-2.x" > export TOSDIR="$TOSROOT/tos" > export CLASSPATH='cygpath -w $TOSROOT/support/sdk/java/tinyos.jar' > export CLASSPATH="$CLASSPATH;." > export MAKERULES="$TOSROOT/support/make/Makerules" > export PATH="/opt/msp430/bin:$PATH" > export NESC_MACHINE="pcc_bitfield_type_matters=false word_size=1 pointer=2,1 > float=4,1 double=4,1 long_double=4,1 short=2,1 int=2,1 long=4,1 long_long=8,1 > int1248_align=1,1,1,1 wchar_size_size=2,2 char_wchar_signed=true,true > empty_field_boundary=8 structure_size_boundary=8" > > _______________________________________ > > or is what I have done wrong ? > > Thanks. > > ----- Message d'origine ---- > De : Kevin Klues <[EMAIL PROTECTED]> > À : mejda chouaieb <[EMAIL PROTECTED]> > Cc : Amit Pendharkar <[EMAIL PROTECTED]>; [email protected] > Envoyé le : Mardi, 30 Octobre 2007, 0h31mn 05s > Objet : Re: Re : Re : [Tinyos-help] Urgent!! Help on msp430 needed!!! > > > The -mmcu flag is a gcc flag used to tell msp430-gcc the specific > microcontroller it should compile for. The same compiler is used to > compile for an entire family of processors, and this flag tells it > which one it should compile for specifically. > > The -fnesc-target flag is used to tell nesC which processor is the > final target of the C file it generates. It is used to determine the > size of variables on your platform (i.e. a uint is 4 bytes or two > bytes), as well as their alignment. > > Straight from 'man nescc' > -fnesc-target=architecture > Specify the target architecture to compile for. Currently supported > platforms are avr (the Atmel AVR family), msp430 (the TI MSP430 > family) and self (the machine the nesC compiler is running on). If > you use the env target, the architecture details are read from the > NESC_MACHINE environment variable. See the separate env target > documentation for details. > > In your case, you need to run `man jannic-gcc` or (whatever the name > of your compiler is) and see what it takes for its -mmcu flag for your > specific model of jannic processor. > > And for -fnesc-target you need to make it env, and then set > NESC_MACHINE to something appropriate for your platform. > Instructions here: > http://senseless.eecs.harvard.edu/repos/mainland-tinyos/nesc/doc/envtarget.html > > And example under /tinyos-2.x/tos/platforms/intelmote2/.platform for > the pxa27x xscale mcu > > Kevin > > > > > On 10/29/07, mejda chouaieb <[EMAIL PROTECTED]> wrote: > > > > Hi, > > yes I have gcc for jennic, the compiler for JN5139 Chips is ba-elf and it > > contains ba-elf-gcc. > > in lesson 10 they don't explain what does this 2 lines mean, that's why i'm > > asking in TinyOS Help. > > I'm working since 3 months to port TinyOS to jennic, it's my Master thesis. > > I will try with JN5139, but I have to finish writing makefiles before > > testing if it works. > > I just want to understand to which file or folder msp430 refers? if it > > refers to a file or folder, or to something else ? > > Thanks. > > > > > > ----- Message d'origine ---- > > De : Amit Pendharkar <[EMAIL PROTECTED]> > > À : mejda chouaieb <[EMAIL PROTECTED]> > > Envoyé le : Lundi, 29 Octobre 2007, 23h10mn 22s > > Objet : Re: Re : [Tinyos-help] Urgent!! Help on msp430 needed!!! > > > > Hi, > > > > Well, I have not used jennic. Do you have gcc available for jennic? > > > > I can at the most give you some pointers. See > > http://www.tinyos.net/tinyos-2.x/doc/html/tutorial/lesson10.html > > It talks about .platform file & its contents. > > > > Next you may contact jennic technical support, they might be able to help > > you. > > > > Logic tells me to replace msp430 with JN5139. But dont count me on this. > > > > See if it works. I am interested to know how you are doing the porting. > > > > Amit > > > > > > On 10/29/07, mejda chouaieb < [EMAIL PROTECTED]> wrote: > > > > > > > > > > > > Hi, > > > first of all thank you. > > > I'm porting TinyOS to jennic that's why I want to know, what should I > > write in place of msp430 in each of this 2 lines ? > > > Jennic microprocessor is JN5139. > > > Thanks > > > > > > > > > ----- Message d'origine ---- > > > De : Amit Pendharkar < [EMAIL PROTECTED]> > > > À : mejda chouaieb <[EMAIL PROTECTED]> > > > Cc : [email protected] > > > Envoyé le : Lundi, 29 Octobre 2007, 22h12mn 14s > > > Objet : Re: [Tinyos-help] Urgent!! Help on msp430 needed!!! > > > > > > MSP430 is the ultra low power microprocessor by texas instruments that is > > used on telos motes. see wwww.msp430.com > > > > > > It is specifying msp430 as your processor and optimizing your code for > > that mcu. > > > > > > Amit Pendharkar > > > > > > > > > On 10/29/07, mejda chouaieb < [EMAIL PROTECTED]> wrote: > > > > Hello All, > > > > Please can someone help me to understand this line in > > "tos/platforms/yamp/.platform" : > > > > _______________________ > > > > -mmcu=msp430x1611 > > > > -fnesc-target=msp430 > > > > _______________________ > > > > > > > > I need to understand what is msp430 in this two lines, I mean it refers > > to what? > > > > and where is msp430 in tinyos to which it refers ? > > > > Thanks. > > > > > > > > > > > > > > ____________________________________________________________________________________________ > > > > Découvrez le blog Yahoo! Mail : dernières nouveautés, astuces, > > conseils.. et vos réactions ! > > > > http://blog.mail.yahoo.fr > > > > > > > > _______________________________________________ > > > > Tinyos-help mailing list > > > > [email protected] > > > > > > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help > > > > > > > > > > > > > > > > > > > ________________________________ > > Découvrez le blog Yahoo! Mail : dernières nouveautés, astuces, conseils.. > > et vos réactions ! > > > > > > > > > > ________________________________ > > Stockage illimité de vos mails avec Yahoo! Mail. Changez aujourd'hui de > > mail ! > > _______________________________________________ > > Tinyos-help mailing list > > [email protected] > > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help > > > > > -- > ~Kevin > > > > ______________________________________________________________________________ > > Stockage illimité de vos mails avec Yahoo! Mail. Changez aujourd'hui de mail ! > -- ~Kevin _______________________________________________ Tinyos-help mailing list [email protected] https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
