That got me on the right path. I was using variable expansion, and when I
put an absolute path in, it worked.

I was using the variable $TOSDIR for expansion. I'll have to investigate
further what I did (or didn't) do, but it appeared correct in the ncc echo
output.

CFLAGS wasn't working, but PFLAGS was. With nesC 1.1.2 if that helps. I
think there was a change to that option with 1.1.3?

Thanks,
-Ben

On Mon, June 11, 2007 7:53 pm, David Moss said:
> The problem you describe sounds like it's not pulling in the right files
> during compile time.  In your Makefile, try using CFLAGS instead of PFLAGS.
>
> CFLAGS += -I/opt/tinyos-1.x/tos/contrib/rincon/tos/platform/mica2
> (or whatever directory you're using)
>
> If the compiler can't find that and your other files are missing, then the
> compiler will generate an error and at least you'll know.
>
> You shouldn't need to restart the radio after changing its frequency once
> everything is pulled in correctly.
>
> Also, be sure to verify the CC1000Const.h is using 433 MHz - I'm using 900
> MHz, so I know what I uploaded to contribs won't be automatically compatible
> with your hardware.
>
> -David
>
>
>
>
> -----Original Message-----
> From: Benjamin Madore [mailto:[EMAIL PROTECTED]
> Sent: Monday, June 11, 2007 4:14 PM
> To: David Moss
> Cc: [email protected]
> Subject: RE: [Tinyos-help] CC1000 Channels
>
> I have altered TOS_Base to change frequencies.
>
> When I have it change frequencies, it never resumes forwarding.
>
> I added:
>
> PFLAGS += -I/opt/tinyos-1.x/tos/contrib/rincon/tos/platform/mica2
>
> to my makefile, but I haven't been able to confirm it's actually using the
> rincon stack.I'm not sure I'm getting the contrib. files to include
> properly. I tried altering several to generate errors, and nothing changed.
>
> The app is in /workspace/Base (I use the Eclipse plugin)
>
> I used the LEDs to debug, and the change frequency call is returning
> correctly.
>
> I'm calling
>
> call CC1000Control.TunePreset(action);
>
> where action is the preset number sent over the UART from the packet.
>
> Should I be turning on and off the radio?
>
> What I'd really appreciate is a pointer to someone else who has done
> something similar with Mica2 motes, and has it working.
>
> (TinyOS 1.x, Cygwin, Mica2 motes, 433Mhz)
>
> -Ben
>
> On Wed, May 2, 2007 3:13 pm, David Moss said:
>> The preset table is actually in the CC1000Const.h file.  You'll see it's
> an
>> array of register values starting with:
>>
>> static const prog_uchar CC1K_Params[6][31] = {
>>  ....
>> };
>>
>> There are two functions you can call in your application in TinyOS 1.x to
>> adjust the frequency through the CC1000Control interface:
>>
>>   command result_t TunePreset(uint8_t freq);
>>
>>   command uint32_t TuneManual(uint32_t DesiredFreq);
>>
>> The difference between TunePreset and TuneManual is that TuneManual
> actually
>> calculates what the CC1000 register values should be, and the TunePreset
>> contains pre-calculated values.
>>
>> The problem is the default CC1000 stack is broken when it comes to
> changing
>> frequencies at runtime.  So if you plan on doing runtime frequency
> changes,
>> you should really be using Rincon's CC1000 stack (stable but unsupported)
> in
>> tinyos-1.x/contribs/rincon/tos/lib/CC1000Radio
>>
>> -David



-- 
The difference between the right word and the almost right word is really a
large matter- it's the difference between a lightning bug and the lightning.
-Twain

_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to