[Tinyos-2.0wg] msp430 usart configure

Jonathan Hui jhui at archrock.com
Fri Aug 4 08:35:01 PDT 2006


Okay, makes sense. I did measure directly the overhead and it takes less 
than 10us extra processing time and setModeSpi uses about 90 bytes more 
overhead, so I guess it's not that much overhead.

--
Jonathan Hui
jhui at archrock.com

Vlado Handziski wrote:
> At the time I did the modifications I wanted to keep the changes to the 
> existing HPL interface to a minimum. According to the HAA, the HPL 
> should support both "full register" configs and selected descriptive 
> get/set methods. Since the HPL interface did not have all the necessary 
> get/set methods for complete configuration of the device, I decided to 
> pack everything into a struct. If/when we have all the necessary 
> methods, we can change this. However, I think that the configs from the 
> clients on the second level (the SPI/UART/I2C clients) should remain 
> like it is to be in line with the configuration of the ADCs and the timers.
> 
> Vlado
> 
> On 8/4/06, *Jonathan Hui* <jwhui at cs.berkeley.edu 
> <mailto:jwhui at cs.berkeley.edu>> wrote:
> 
>     Thanks for checking the stuff in. The cc2420 and stm25p on the telos
>     platform use the default spi configuration, so it just works.
> 
>     One question I have is why not just let the SPI/UART/I2C components
>     call the respective set/get methods on the configuration registers
>     directly rather than passing some configuration struct around having
>     the HPL call the set/get methods that it's providing? It seems to me
>     that the former is more efficient, while the latter requires
>     marshalling, unmarshalling, and the overhead of passing the pointer on
>     the stack. Accessing bit fields on the msp430 isn't terribly
>     efficient.
> 
>     --
>     Jonathan W. Hui
>     jwhui at cs.berkeley.edu <mailto:jwhui at cs.berkeley.edu>
>     http://www.cs.berkeley.edu/~jwhui/
> 
>     On 8/3/06, Philipp Huppertz <huppertz at tkn.tu-berlin.de
>     <mailto:huppertz at tkn.tu-berlin.de>> wrote:
>      > Hey,
>      >
>      > I've just checked in Vlado's msp430 usart configure changes.
>      >
>      > All platforms should wire to a module providing the interface
>      > Msp430SpiConfigure/Msp430UartConfigure if another configuration
>     than the
>      > default config in /chips/msp430/usart/msp430usart.h is desired.
>      >
>      > An example for the Msp430UartConfigure can be found at
>      >   /platforms/eyesIFX/chips/tda5250/HplTda5250DataC.nc
>      >   /platforms/eyesIFX/chips/tda5250/Tda5250BusResourceConfigureP.nc.
>      >
>      > An example for the Msp430SpiConfigure can be found at
>      >   /platforms/eyesIFX/PlatformSerialC.nc
>      >   /platforms/eyesIFX/eyesIFXSerialP.nc.
>      >
>      >
>      > Here is a list of potential files needing an update:
>      >
>      > _=tinynode:
>      > spi:
>      >   /tos/platforms/tinynode/chips/xe1205/HplXE1205SpiC.nc:
>      > uart:
>      >   /tos/platforms/tinynode/PlatformSerialC.nc
>      >   /tos/platforms/tinynode/TinyNodeSerialP.nc
>      >
>      > _=telosa:
>      > spi:
>      >   /tos/platforms/telosa/chips/cc2420/HplCC2420SpiC.nc:
>      >
>      > _=telosb:
>      > spi:
>      >   /tos/platforms/telosb/chips/stm25p/HplStm25pSpiC.nc
>      >
>      >
>      > regards,
>      >   philipp
>      >
>      > ps: i have just done a quick merge with the i2c stuff, so i think
>     it isn't
>      > working anymore. sorry for that...
>      > _______________________________________________
>      > Tinyos-2.0wg mailing list
>      > Tinyos-2.0wg at Mail.Millennium.Berkeley.EDU
>     <mailto:Tinyos-2.0wg at Mail.Millennium.Berkeley.EDU>
>      >
>     https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-2.0wg
>      >
>     _______________________________________________
>     Tinyos-2.0wg mailing list
>     Tinyos-2.0wg at Mail.Millennium.Berkeley.EDU
>     <mailto:Tinyos-2.0wg at Mail.Millennium.Berkeley.EDU>
>     https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-2.0wg
> 
> 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Tinyos-2.0wg mailing list
> Tinyos-2.0wg at Mail.Millennium.Berkeley.EDU
> https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-2.0wg


More information about the Tinyos-2.0wg mailing list