Hi Guys!

Can someone verify, that indeed in CC2520DriverLayerP the
RadioSend.sendDone is called before the RadioSend.send is returned? It
seems strange, and I do not see why it should from the code. Also, do
you both use the same TASKLET_IS_TASK setting? If that is defined in
your makefile, then everything works in task context, otherwise in
interrupt context.

Best,
Miklos

On Tue, Dec 7, 2010 at 3:33 PM, Chih-Ming Hsieh
<[email protected]> wrote:
> Hi John,
>
> I tried to merge your version to my project and I managed to send one packet
> using the test application /apps/TestDriverLayer. However, when the
> application tries to send second packet, it gets EBUSY state in
> RandomCollisionLayerP.RadioSend.send(). After tracing the log, I found that
> during the first sending, RandomCollisionLayer.SubSend.send() is called in
> event RandomCollisionLayerP.RadioAlarm.fired(). Then
> SoftwareAckLayerP.RadioSend.send(), CC2520DriverLayerP.RadioSend.send() are
> invoked subsequently. However, RandomCollisionLayerP.SubSend.sendDone()
> seems to be called before RandomCollisionLayerP.RadioAlarm.fired() exits,
> i.e. before the state is set to STATE_TX_SENDING. As a result, I got ASSERT
> error in
>
> SoftwareAckLayerP.SubSend.sendDone() complaining state is not
> STATE_DATA_SEND
> RandomCollisionLayerP.SubSend.sendDone() complaining state is not
> STATE_TX_SENDING
>
> and eventually in RandomCollisionLayerP.RadioAlarm.fired() the state is set
> to STATE_TX_SENDING. So the second sending got busy state in
> RandomCollisionLayerP.RadioSend.send().
>
> Currently I get stuck at this point. Could you please give me some hints?
>
> Thank you very much for your help.
>
> Best regards,
> Jimmy
>
> On Mon, Nov 29, 2010 at 11:46 PM, JeongGil Ko (John) <[email protected]>
> wrote:
>>
>> Ah forgot the link.
>>
>> http://hinrg.cs.jhu.edu/git/?p=jgko/tinyos-2.x.git;a=shortlog;h=refs/heads/cc2520
>> Don't forget to checkout the cc2520 branch.
>> -John
>> On Nov 29, 2010, at 5:34 PM, Chih-Ming Hsieh wrote:
>>
>> Hi Miklos,
>>
>> Thank you very much for the information.
>>
>> After I traced the code with diag messages, I found that the problem seems
>> to be RadioAlarm. More specifically, it's in
>> RandomCollisionLayerP.RadioSend.send(). I found that RadioAlarm.wait() never
>> triggers an alarm and therefore the message is not sent. I did a test and
>> found that the only RadioAlarm which can be triggered is the one in
>> XXXDriverLayerP (in my case, CC2520DriverLayerP). I found that it's wired to
>> the alarm in platform's HPL code (HplCC2520C.nc, AlarmMicro16C()). The
>> RadioAlarm in other places seem not working. I don't know whether I miss
>> something since my code looks similar to the RF230 one. Is there any trick
>> to make this work?
>>
>> Thank you very much for your  help.
>>
>> Best regards,
>> Jimmy
>>
>> On Sun, Nov 28, 2010 at 5:19 PM, Miklos Maroti <[email protected]>
>> wrote:
>>>
>>> Hi Jimmy,
>>>
>>> The rfxlink layer is picking up more chipsets (Atmega128RFA1 is
>>> working and we have plans for the SI4431) and is actively maintained
>>> and improved. You can either stick with the older chips/rf2xx/layers
>>> and util setup or use the lib/rfxlink mainline. I have plans to update
>>> the packet handling a bit, but that should not affect you.
>>>
>>> On Thu, Nov 25, 2010 at 6:40 PM, Chih-Ming Hsieh
>>> <[email protected]> wrote:
>>> > Hi Thomas,
>>> >
>>> > Thanks for the reply. I tried to stick with the module "rf2xx" and
>>> > copied
>>> > two directories "layers" and "util" from /chips/rf2xx/rf230 to
>>> > /chips/cc2520. Now I can build the project and send one packet (on
>>> > sniffer
>>> > and the content seems to be correct). However, it seems like the
>>> > AMSend.sendDone() is never called. Could you please maybe point me some
>>> > directions about how to investigate this?
>>>
>>> You should put a lot of diag messages into the driver and use the java
>>> net.tinyos.tools.DiagMsg to print them (you have to connect your mote
>>> via the serial to the PC).
>>>
>>> You can also use the "tinyos-2.x/apps/tests/rfxlink/TestTransmit"
>>> application to stress the driver and to see if it does not lock up.
>>> You might have to adopt that program a little but it works fine
>>> (continuously transmits messages).
>>>
>>> Best,
>>> Miklos
>>>
>>> >
>>> > By the way, I notice that the interface "InterruptCCA" in
>>> > HplCC2420InterruptsC is not provided in HplCC2520C anymore. Is this a
>>> > functional change of CC2520 chip? I am not sure whether I need this to
>>> > integrate MSP430X yet. However, it's good to know whether this affects.
>>> >
>>> > Thank you very much for you help.
>>> >
>>> > Best regards,
>>> > Jimmy
>>> >
>>> > On Thu, Nov 25, 2010 at 1:36 PM, Thomas Schmid
>>> > <[email protected]>
>>> > wrote:
>>> >>
>>> >> It won't be a "standard", but we will have several drivers using these
>>> >> modules eventually.
>>> >>
>>> >>
>>> >> - Thomas
>>> >>
>>> >>
>>> >>
>>> >>
>>> >>
>>> >> On Thu, Nov 25, 2010 at 4:00 AM, Chih-Ming Hsieh
>>> >> <[email protected]> wrote:
>>> >> > Hi Janos,
>>> >> >
>>> >> > Thanks for the information. I've checked out the new code from the
>>> >> > trunk.
>>> >> > Looks like there is a new module "rfxlink" for radio interface. Will
>>> >> > it
>>> >> > be
>>> >> > standard to integrate radio driver with this module for further
>>> >> > implementation? Should I move to this baseline? What's your opinion?
>>> >> > (to
>>> >> > Thomas, too)
>>> >> >
>>> >> > Thanks a lot.
>>> >> >
>>> >> > Best regards,
>>> >> > Jimmy
>>> >> >
>>> >> >
>>> >> >
>>> >> > On Wed, Nov 24, 2010 at 8:31 PM, Janos Sallai
>>> >> > <[email protected]>
>>> >> > wrote:
>>> >> >>
>>> >> >> Jimmy,
>>> >> >>
>>> >> >> I committed the cc2420x driver to the main tree. Since Thomas's
>>> >> >> cc2520
>>> >> >> implementation should be very similar, you can just take a look at
>>> >> >> the
>>> >> >> wirings in chips/cc2420x and in platforms/micaz/chips/cc2420x and
>>> >> >> use
>>> >> >> them as a reference.
>>> >> >>
>>> >> >> Janos
>>> >> >>
>>> >> >> On Wed, Nov 24, 2010 at 9:39 AM, Chih-Ming Hsieh
>>> >> >> <[email protected]> wrote:
>>> >> >> > Hi Thomas,
>>> >> >> >
>>> >> >> > I am currently trying to integrate the cc2520 driver to cc2520dk
>>> >> >> > platform,
>>> >> >> > however I encountered some problems. I was wondering if I could
>>> >> >> > have
>>> >> >> > some
>>> >> >> > advices from you. Thank you in advance.
>>> >> >> >
>>> >> >> > Currently, I take the reference from the platform setting from
>>> >> >> > sam3u_ek2520
>>> >> >> > and wire cc2520 driver to MSP430X. However, when I tried to
>>> >> >> > compile,
>>> >> >> > I
>>> >> >> > couldn't find a couple of components. Then I tried to use
>>> >> >> > rf2xx_new
>>> >> >> > chip
>>> >> >> > and
>>> >> >> > this looked better but I still got some errors (until now) due to
>>> >> >> > some
>>> >> >> > interface changes (e.g. DummyLayerC.RadioState). So I am thinking
>>> >> >> > that
>>> >> >> > maybe
>>> >> >> > I've got wrong settings and it's better to consult with you about
>>> >> >> > the
>>> >> >> > correct combination.
>>> >> >> >
>>> >> >> > If possible, could you please tell me what are the correct
>>> >> >> > modules
>>> >> >> > which
>>> >> >> > I
>>> >> >> > should include to make the driver working? Thank you very much.
>>> >> >> >
>>> >> >> > Best regards,
>>> >> >> > Jimmy
>>> >> >> >
>>> >> >> > On Thu, Sep 30, 2010 at 11:01 AM, Chih-Ming Hsieh
>>> >> >> > <[email protected]>
>>> >> >> > wrote:
>>> >> >> >>
>>> >> >> >> Hi Thomas and Janos,
>>> >> >> >>
>>> >> >> >>
>>> >> >> >> Great! Thanks a lot for the information. I am going to try it on
>>> >> >> >> my
>>> >> >> >> cc2520DK. Really appreciate your efforts.
>>> >> >> >>
>>> >> >> >> Also thanks to Miklos.
>>> >> >> >>
>>> >> >> >> Best regards,
>>> >> >> >> Jimmy
>>> >> >> >>
>>> >> >> >>>
>>> >> >> >>> On 09/23/2010 04:49 PM, Thomas Schmid wrote:
>>> >> >> >>>>
>>> >> >> >>>> Yes, we have a cc2520 driver. But it is not in contrib nor
>>> >> >> >>>> main
>>> >> >> >>>> yet
>>> >> >> >>>> (though hopefully soon). You can find it here:
>>> >> >> >>>>
>>> >> >> >>>> http://github.com/tschmid/tinyos-2.x
>>> >> >> >>>>
>>> >> >> >>>> in tos/chips/cc2520
>>> >> >> >>>>
>>> >> >> >>>>
>>> >> >> >>>> - Thomas
>>> >> >> >>>
>>> >> >> >>>
>>> >> >> >>> On 09/23/2010 04:49 PM, Thomas Schmid wrote:
>>> >> >> >>>>
>>> >> >> >>>> Yes, we have a cc2520 driver. But it is not in contrib nor
>>> >> >> >>>> main
>>> >> >> >>>> yet
>>> >> >> >>>> (though hopefully soon). You can find it here:
>>> >> >> >>>>
>>> >> >> >>>> http://github.com/tschmid/tinyos-2.x
>>> >> >> >>>>
>>> >> >> >>>> in tos/chips/cc2520
>>> >> >> >>>>
>>> >> >> >>>>
>>> >> >> >>>> - Thomas
>>> >> >> >>>>
>>> >> >> >>>> --
>>> >> >> >>>> Post Doctoral Researcher
>>> >> >> >>>> University of Michigan, Ann Arbor
>>> >> >> >>>>
>>> >> >> >>>> "The most renewable energy we have is our own potential, and
>>> >> >> >>>> our
>>> >> >> >>>> own
>>> >> >> >>>> passion." - Bertrand Piccard
>>> >> >> >>>>
>>> >> >> >>>>
>>> >> >> >>>>
>>> >> >> >>>> On Thu, Sep 23, 2010 at 10:28 AM, Janos Sallai
>>> >> >> >>>> <[email protected]>  wrote:
>>> >> >> >>>>>
>>> >> >> >>>>> Jimmy,
>>> >> >> >>>>> If I remember correctly, Thomas Schmid wrote a cc2520 stack
>>> >> >> >>>>> based
>>> >> >> >>>>> on
>>> >> >> >>>>> my
>>> >> >> >>>>> cc2420 code. I suggest that you check with him whether the
>>> >> >> >>>>> code
>>> >> >> >>>>> is
>>> >> >> >>>>> publicly
>>> >> >> >>>>> available.
>>> >> >> >>>>> Janos
>>> >> >> >>>>> On Sep 23, 2010 3:43 AM, "Chih-Ming
>>> >> >> >>>>> Hsieh"<[email protected]>
>>> >> >> >>>>>  wrote:
>>> >> >> >>>>>>
>>> >> >> >>>>>> Hi Miklos,
>>> >> >> >>>>>>
>>> >> >> >>>>>> Thank you very much for the information. I'll take a look at
>>> >> >> >>>>>> this
>>> >> >> >>>>>> module
>>> >> >> >>>>>> as
>>> >> >> >>>>>> well as CC2420 port then come back when I get concrete
>>> >> >> >>>>>> questions.
>>> >> >> >>>>>>
>>> >> >> >>>>>> Thanks again and best regards,
>>> >> >> >>>>>> Jimmy
>>> >> >> >>>>>>
>>> >> >> >>>>>> On Wed, Sep 22, 2010 at 2:57 PM, Miklos Maroti
>>> >> >> >>>>>> <[email protected]>wrote:
>>> >> >> >>>>>>
>>> >> >> >>>>>>> Hi Jimmy,
>>> >> >> >>>>>>>
>>> >> >> >>>>>>> I do not know of an exact port. There is a cc2420 radio
>>> >> >> >>>>>>> stack
>>> >> >> >>>>>>> written
>>> >> >> >>>>>>> by Janos Sallai (tinyos-2.x-contrib/vu/tos/chips/cc2420x)
>>> >> >> >>>>>>> that
>>> >> >> >>>>>>> could
>>> >> >> >>>>>>> be quite easy to port to the cc2520, but that requires some
>>> >> >> >>>>>>> effort. I
>>> >> >> >>>>>>> would be happy to help with that and give hints, but I have
>>> >> >> >>>>>>> no
>>> >> >> >>>>>>> access
>>> >> >> >>>>>>> to a cc2520 based mote. The other option would be to port
>>> >> >> >>>>>>> the
>>> >> >> >>>>>>> original
>>> >> >> >>>>>>> cc2420 code.
>>> >> >> >>>>>>>
>>> >> >> >>>>>>> Best,
>>> >> >> >>>>>>> Miklos
>>> >> >> >>>>>>>
>>> >> >> >>>>>>> On Wed, Sep 22, 2010 at 11:38 AM, Chih-Ming Hsieh
>>> >> >> >>>>>>> <[email protected]>  wrote:
>>> >> >> >>>>>>>>
>>> >> >> >>>>>>>> Hi Miklos,
>>> >> >> >>>>>>>>
>>> >> >> >>>>>>>> Thank you very much for the reply. It's good to know that
>>> >> >> >>>>>>>> there
>>> >> >> >>>>>>>> might
>>> >> >> >>>>>>>> be
>>> >> >> >>>>>>>> some efforts done before I jump into this. Yes, I am
>>> >> >> >>>>>>>> referring
>>> >> >> >>>>>>>> to
>>> >> >> >>>>>>>> the
>>> >> >> >>>>>>>> CC2520+MSP430 support. As you suggested I looked up in the
>>> >> >> >>>>>>>> tinyos-2.x-contrib module and did find a port for CC2500
>>> >> >> >>>>>>>> from
>>> >> >> >>>>>>>> "David
>>> >> >> >>>>>>>
>>> >> >> >>>>>>> Moss,
>>> >> >> >>>>>>>>
>>> >> >> >>>>>>>> et al." It's a step closer but I suspect there will still
>>> >> >> >>>>>>>> be
>>> >> >> >>>>>>>> some
>>> >> >> >>>>>>>> work
>>> >> >> >>>>>>>> to
>>> >> >> >>>>>>>> make it running on CC2520 development kit. Therefore I
>>> >> >> >>>>>>>> would
>>> >> >> >>>>>>>> like
>>> >> >> >>>>>>>> to
>>> >> >> >>>>>>>> ask
>>> >> >> >>>>>>>
>>> >> >> >>>>>>> you
>>> >> >> >>>>>>>>
>>> >> >> >>>>>>>> whether you know an exact port for CC2520. Any hints would
>>> >> >> >>>>>>>> be
>>> >> >> >>>>>>>
>>> >> >> >>>>>>> appreciated,
>>> >> >> >>>>>>>>
>>> >> >> >>>>>>>> since I had no luck with "tinyos cc2520" combination on
>>> >> >> >>>>>>>> Google
>>> >> >> >>>>>>>> search.
>>> >> >> >>>>>>>
>>> >> >> >>>>>>> :-(
>>> >> >> >>>>>>>>
>>> >> >> >>>>>>>> Thank you very much.
>>> >> >> >>>>>>>>
>>> >> >> >>>>>>>> Best regards,
>>> >> >> >>>>>>>> Jimmy
>>> >> >> >>>>>>>>
>>> >> >> >>>>>>>> On Tue, Sep 21, 2010 at 9:15 PM, Miklos Maroti
>>> >> >> >>>>>>>> <[email protected]
>>> >> >> >>>>>>>>
>>> >> >> >>>>>>>> wrote:
>>> >> >> >>>>>>>>>
>>> >> >> >>>>>>>>> Hi Jimmy,
>>> >> >> >>>>>>>>>
>>> >> >> >>>>>>>>> Are you referring to the support of the CC2520 radio chip
>>> >> >> >>>>>>>>> and/or
>>> >> >> >>>>>>>>> for
>>> >> >> >>>>>>>>> the support of the CC2520 development kit? If I know
>>> >> >> >>>>>>>>> correctly,
>>> >> >> >>>>>>>>> then
>>> >> >> >>>>>>>>> there are efforts (or might have already been done) to
>>> >> >> >>>>>>>>> port
>>> >> >> >>>>>>>>> the
>>> >> >> >>>>>>>>> cc2420
>>> >> >> >>>>>>>>> code to cc2520.
>>> >> >> >>>>>>>>>
>>> >> >> >>>>>>>>> Miklos
>>> >> >> >>>>>>>>>
>>> >> >> >>>>>>>>> On Tue, Sep 21, 2010 at 3:24 PM, Chih-Ming Hsieh
>>> >> >> >>>>>>>>> <[email protected]>  wrote:
>>> >> >> >>>>>>>>>>
>>> >> >> >>>>>>>>>> Dear All,
>>> >> >> >>>>>>>>>>
>>> >> >> >>>>>>>>>> I am planning to work on TinyOS and CC2520DK for my
>>> >> >> >>>>>>>>>> research
>>> >> >> >>>>>>>>>> project
>>> >> >> >>>>>>>>>> therefore I would need a CC2520DK port. Since I couldn't
>>> >> >> >>>>>>>>>> find
>>> >> >> >>>>>>>>>> there
>>> >> >> >>>>>>>
>>> >> >> >>>>>>> are
>>> >> >> >>>>>>>>>>
>>> >> >> >>>>>>>>>> existing contributions, I would like to confirm you guys
>>> >> >> >>>>>>>>>> that
>>> >> >> >>>>>>>>>> there
>>> >> >> >>>>>>>>>> is
>>> >> >> >>>>>>>>>> and
>>> >> >> >>>>>>>>>> will be no TinyOS ported on CC2520DK released in the
>>> >> >> >>>>>>>>>> short
>>> >> >> >>>>>>>>>> future
>>> >> >> >>>>>>>>>> to
>>> >> >> >>>>>>>>>> avoid
>>> >> >> >>>>>>>>>> redundant efforts. If there are no efforts on this task,
>>> >> >> >>>>>>>>>> I
>>> >> >> >>>>>>>>>> would
>>> >> >> >>>>>>>>>> like
>>> >> >> >>>>>>>
>>> >> >> >>>>>>> to
>>> >> >> >>>>>>>>>>
>>> >> >> >>>>>>>>>> work on it.
>>> >> >> >>>>>>>>>>
>>> >> >> >>>>>>>>>> Hope someone can give me some advices. Thanks in
>>> >> >> >>>>>>>>>> advance.
>>> >> >> >>>>>>>>>>
>>> >> >> >>>>>>>>>> Best regards,
>>> >> >> >>>>>>>>>> Jimmy
>>> >> >> >>>>>>>>>>
>>> >> >> >>>>>>>>>> _______________________________________________
>>> >> >> >>>>>>>>>> Tinyos-devel mailing list
>>> >> >> >>>>>>>>>> [email protected]
>>> >> >> >>>>>>>>>>
>>> >> >> >>>>>>>>>>
>>> >> >> >>>>>>>
>>> >> >> >>>>>>>
>>> >> >> >>>>>>>
>>> >> >> >>>>>>>
>>> >> >> >>>>>>> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-devel
>>> >> >> >>>>>>>>>>
>>> >> >> >>>>>>>>
>>> >> >> >>>>> _______________________________________________
>>> >> >> >>>>> Tinyos-help mailing list
>>> >> >> >>>>> [email protected]
>>> >> >> >>>>>
>>> >> >> >>>>>
>>> >> >> >>>>>
>>> >> >> >>>>>
>>> >> >> >>>>> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>>> >> >> >>>>>
>>> >> >> >>
>>> >> >> >
>>> >> >> >
>>> >> >> > _______________________________________________
>>> >> >> > Tinyos-help mailing list
>>> >> >> > [email protected]
>>> >> >> >
>>> >> >> >
>>> >> >> > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>>> >> >> >
>>> >> >
>>> >> >
>>> >
>>> >
>>> > _______________________________________________
>>> > Tinyos-help mailing list
>>> > [email protected]
>>> >
>>> > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>>> >
>>
>> _______________________________________________
>> Tinyos-help mailing list
>> [email protected]
>> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>>
>> ------
>> JeongGil Ko (John)
>> Ph.D. Student
>> Department of Computer Science
>> Johns Hopkins University
>> http://www.cs.jhu.edu/~jgko
>
>

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

Reply via email to