[Tinyos-help] ADC switch channel

Jan Hauer jan.hauer at gmail.com
Wed Oct 11 06:14:02 PDT 2006


Hi Andrea,

what you want to do is possible with the msp430 ADC12, but it has not
been implemented, neither in TinyOS 1.x nor 2.x. With the current
implementation/interfaces you can only sample *the same* channel with
one command (that's why in TinyOS 2.x it is called
"Msp430Adc12SingleChannel"). Changing the implementation to work with
multiple channels should not be much effort. It has not been done yet,
mainly because we have not thought about a proper interface definition
- e.g. you could to pass an array of [channel, reference voltage] and
a length parameter to bind() (in TinyOS 1.x). I have always planned to
implement it (probably first in 2.x), but I'm not sure when I'll do it
- I try to find some time (not so many people seem to need this
functionality?).

Jan

On 9/26/06, lamiaimeil <lamiaimeil at yahoo.it> wrote:
> Hi all,
> I have a 3-axis accelerometer mount on tmote sky.
> Every axis (x,y and z) is connected with a different
> pin of the expansion connector and I want to sample a
> channel and switch to the next (from x to y and from y
> to z) cyclical. I must do it at 6000Hz but I see that
> the ADC time for switch from a channel to another is
> 10ms(!) so I can go at maximum rate of 100Hz.. I can't
> believe that an ADC that can sample at 200KHz take
> 10ms for switching on channels.. How can I do to
> improve this frequency?
> I try to look on MSP430 user guide and I see there is
> a register called ADC12MCTLx (ADC12 Conversion Memory
> Control Registers) where I can switch the input
> channel setting INCHx. Do this mean I must use
> assembly code? If yes, how can I do this?
> Thanks in advance.
> Andrea.
>
> __________________________________________________
> Do You Yahoo!?
> Poco spazio e tanto spam? Yahoo! Mail ti protegge dallo spam e ti da tanto spazio gratuito per i tuoi file e i messaggi
> http://mail.yahoo.it
> _______________________________________________
> Tinyos-help mailing list
> Tinyos-help at Millennium.Berkeley.EDU
> https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>


More information about the Tinyos-help mailing list