Hi Sofia,

Have you tried to use the Int1 interface provided by the 
HplAtm128InterruptC component? This might not be the recommended way (I 
think you should not use Hpl* components), but I think it works much 
better than trying to access the interrupt vectors directly.

Cheers,
Urs


On 02/02/2011 09:21 AM, sofia aparicio wrote:
> Hello,
>
> Using AVR_ATOMIC_HANDLER(SIG_INTERRUPT1) I get the same error:
>
> In component `UltrasoundControlM':
> /opt/tinyos-2.x_Cricket_iris/tos/platforms/iris/UltrasoundControlM.nc:834:
> redef
> inition of `__vector_2'
> /opt/tinyos-2.x_Cricket_iris/tos/chips/atm128/pins/HplAtm128InterruptSigP.nc:51:
> previous declaration of `__vector_2'
> make: *** [exe0] Error 1
>
> Do you what is the problem?
>
> Thank you!
>
> Sofia
>
>
>
>  > Date: Tue, 1 Feb 2011 22:51:08 +0100
>  > Subject: Re: [Tinyos-help] Problem calling an external interrupt INT1
> tinyos-2.x
>  > From: mmar...@math.u-szeged.hu
>  > To: aparicioso...@hotmail.com
>  > CC: tinyos-help@millennium.berkeley.edu
>  >
>  > Hi Sofia,
>  >
>  > Use
>  >
>  > AVR_ATOMIC_HANDLER(SIG_INTERRUPT1) {
>  > }
>  >
>  > Miklos
>  >
>  >
>  > On Tue, Feb 1, 2011 at 1:21 PM, sofia aparicio
>  > <aparicioso...@hotmail.com> wrote:
>  > >
>  > > Hello,
>  > >
>  > > I would like to define an external interrupt in INT1 pin. When I
> call the
>  > > interrupt a get an error message.
>  > > 1) If I use :
>  > > ISR(INT1_vect){
>  > > }
>  > > I get the following error:
>  > > In component `UltrasoundControlM':
>  > >
> /opt/tinyos-2.x_Cricket_iris/tos/platforms/iris/UltrasoundControlM.nc:823:
>  > > use (
>  > > ), not (void), for 0-argument functios
>  > >
> /opt/tinyos-2.x_Cricket_iris/tos/platforms/iris/UltrasoundControlM.nc:823:
>  > > use (
>  > > ), not (void), for 0-argument functios
>  > >
> /opt/tinyos-2.x_Cricket_iris/tos/platforms/iris/UltrasoundControlM.nc:823:
>  > > redef
>  > > inition of `__vector_2'
>  > >
> /opt/tinyos-2.x_Cricket_iris/tos/platforms/iris/UltrasoundControlM.nc:823:
>  > > previ
>  > > ous declaration of `__vector_2'
>  > > make: *** [exe0] Error 1
>  > >
>  > >
>  > > 2) If I use:
>  > > SIGNAL(SIG_INTERRUPT1){
>  > > }
>  > > I get the same error.
>  > >
>  > > 3) I had the same problem with timers and I have solved it doing the
>  > > following-
>  > > In UltrasoundControlM.nc file:
>  > > module UltrasoundControlM {
>  > > provides {
>  > > interface UltrasoundControl;
>  > > }
>  > > uses {
>  > > interface HplAtm128Compare<uint16_t> as Compare3A;
>  > > }
>  > > }
>  > > implementation {
>  > > async event void Compare3A.fired(){
>  > > }
>  > > }
>  > >
>  > > In UltrasoundControlAppM.nc file:
>  > > configuration UltrasoundControlAppM {
>  > > provides {
>  > > interface UltrasoundControl;
>  > > }
>  > > }
>  > > implementation
>  > > {
>  > > components UltrasoundControlM;
>  > > UltrasoundControl=UltrasoundControlM;
>  > > components HplAtm128Timer3C;
>  > > UltrasoundControlM.Compare3A->HplAtm128Timer3C.Compare[0];
>  > > }
>  > >
>  > > Do you know how can I call the external interrupt in INT1 pin?
>  > >
>  > > Thank you very much.
>  > >
>  > > Sofia
>  > > _______________________________________________
>  > > Tinyos-help mailing list
>  > > Tinyos-help@millennium.berkeley.edu
>  > >
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>  > >
>
>
>
> _______________________________________________
> Tinyos-help mailing list
> Tinyos-help@millennium.berkeley.edu
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

_______________________________________________
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to