Please do not top post as it makes the discussion much harder to follow.
> Ok. I've seen 
> #define CC2420_TXCTRL_PAPWR          0   /* 5 bits (0..4): Output PA level
> */
The data sheet is readily available so you can trivially look things like ths
up yourself. Yes th data sheet quite clearly identifies this as the relevant
part of the txctrl register. 
> in /kernel/include/linux/spi/cc2420.h
> Is it the needed one?
> And I couldn't find if it is used anywhere, and it is a bit not clear, how
> to use it properly. 
It isn't used, hence my previous email saying that power control has not been 
implemented.  There are a number of examples of register writes in the code.
Use them to work out how to write this register and try writing it with 
the value you want which can be established by reading the data sheet.
In this case the bottom 5 bits need to equal 31 (all set) for maximum 
power.  A quick glance at the data sheet would have told you that this
is the default anyway and hence you imote2's are transmitting at the
highest power they can.
> I don't actually need a real-time power control at the time, I just want my
> imotes to see each other.
Perhaps if you explain the conditions under which they cannot see each other
people may be able to advise on how to improve matters.  For example, over
what range are you trying to transmit and does it work fine when nearer?
> Hmm. 
> 
> 
> On Fri, 11 Jun 2010 14:30:29 +0100, Jonathan Cameron <[email protected]>
> wrote:
>> On 06/11/10 13:25, agogolev wrote:
>>> Hello everyone,
>>>
>>> Couldn't figure out how to set max rx/tx output power for cc2420.
>>> Are there any user space commands (from root console, for example) to
>>> adjust it, or I should recompile the kernel with some new driver
>>> parameters?
>>> What and where are these parameters?
>>>
>>> Can anyone help?
>> I can't currently see any driver support for this, so it looks like
>> you are going to have get your hands dirty in the driver.
>>
>> From the data sheet it looks like a simple register write to
>> TXCTRL.PA_LEVEL
>>
>> Can't actually see any support for power control in any of the
>> drivers.
>>
>> Jonathan


------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
Linux-zigbee-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-zigbee-devel

Reply via email to