On Thu, Nov 29, 2012 at 12:56 AM, Doug Carlson <[email protected]> wrote:
> Andras, > Thanks! I made some fixes and it seems good to go now. I've attached the > fixed version to the issue in the google code repo: > http://code.google.com/p/tinyos-main/issues/detail?id=152 > Great! > > It was mostly there, but some constants were incorrect and it didn't > handle ACK's properly. The code's not beautiful-- it wasn't clear to me how > to cleanly incorporate the multi-threading requirements of ACKs with the > existing structure. But this keeps the behavior identical between > PacketSources, and works fine in my application. > That's why I didn't do the same. I've seen some ugly hacks, and I'm not an expert in python so I decided to check it later. By the way, do you know how to get the sender's nodeid of a package? With java, I used message.getSerialPacket().get_header_src(), but there's no getSerialPacket method in the class generated by mig. Andris > > Thanks for the pointer! > -Doug > > > On Wed, Nov 28, 2012 at 3:30 AM, András Bíró <[email protected]>wrote: > >> Hi Doug, >> >> I had the same issue recently: >> http://code.google.com/p/tinyos-main/issues/detail?id=152 >> Yann Le Corre was kind enough to send me his working version of the >> pyton sdk, what he found somewhere on the internet: >> http://dl.dropbox.com/u/363226/munka/tos-python.tar.gz >> But I never really worked with it, we had to do the project fast and >> stable, and we don't really trust the python sdk. >> >> Andris >> >> >> On Tue, Nov 27, 2012 at 5:31 PM, Doug Carlson <[email protected]> wrote: >> >>> Howdy. >>> Looking at the code for tinyos.message.MoteIF, it looks like if you use >>> a serial@dev:baud source when calling addSource, it will check for the >>> existence of a tinyos.packet.SerialSource module (which is set to None if >>> the import of such a module fails). >>> >>> I don't see a SerialSource.py anywhere, so direct serial connections >>> fail. Is this intentional (i.e. blocked off for future work), or is it >>> missing from the repo and actually exists somewhere? >>> >>> Everything works great if I run the java SerialForwarder and use an >>> sf@host:port source in my python script (which uses the >>> tinyos.packet.SFSource class), but I'd prefer to cut out the middle man if >>> possible. If it's not available, then I'm assuming the correct way to >>> proceed would be to adapt the code in tos.py in something that inherits >>> tinyos.packet.PacketSource? >>> >>> Thanks, >>> Doug >>> >>> _______________________________________________ >>> 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
