[riot-devel] Raw communication between native nodes

Alexander Aring aar at pengutronix.de
Tue Jun 28 19:13:44 CEST 2016


Hi,

On 06/22/2016 09:19 PM, Alexander Aring wrote:
> 
> Hi,
> 
> On 06/22/2016 05:28 PM, Jose Alamos wrote:
>> Hi,
>>
>> I was wondering if there's a way to send raw data between nodes running on
>> native. I need to send OpenThread packets between nodes (through a radio
>> abstraction), and I'm having problems with TAP interface since they only
>> process ethernet frames.
>>
>> I tried to hack a little bit (put these OT packets in ethernet frames) but
>> is not working well. Basically, I need to emulate a radio device.
>>
>> Is there an easy way to achieve this?
>>
> 
> some of you maybe knowing that I am working on a RIOT native 802154raw
> transceiver driver which works with AF_PACKET RAW linux-wpan interfaces.
> 
> At the end it should work like the following:
> 
> First I need to describe a special virtual 802.15.4 driver, it's named
> fakelb (maybe such idea can also be implemented in RIOT).
> 
> It works similar like the hwsim80211 driver in linux (but less
> functionality, I also was thinking to make a better implementation of
> fakelb and name it hwsim802154).
> 
> With such driver you can create "virtual phy's" in Linux.
> 
> E.g. 2 phy's,
> 
> 
>           6LoWPAN/etc               6LoWPAN/etc
>                |                         |
>       wpan node interface      wpan node interface
>                |                         |
>            mac802154                 mac802154
>                |                         |
>            wpan-phy0 <--L1(memcpy)--> wpan-phy1
> 
> Descrption:
>   - mac820154: Our 802154 SoftMAC stack
>   - 6LoWPAN/etc: upper layer IPv6, foo stack
>   - wpan node interface: a wpan node interface which does filtering
> 
> Now with a 802154raw native RIOT driver the following would be possible:
> 
> 
>    RIOT native (Userspace)
>      AF_PACKET RAW
>            |                    6LoWPAN/etc               6LoWPAN/etc
>            |                        |                         |
>   wpan monitor interface      wpan node interface      wpan node interface
>            |                        |                         |
>            |                    mac802154                 mac802154
>            |                        |                         |
>        wpan-phy2 <-L1(memcpy)-> wpan-phy0 <--L1(memcpy)--> wpan-phy1
> 

I implemented it [0]. You need 1-2 patches which currently pending on
linux-wpan mailinglist, but then it should be possible.

Next days I need to figure out how to send github pull requests again.

- Alex

[0] https://github.com/linux-wpan/RIOT/commits/802154_raw


More information about the devel mailing list