Riot raspberry BR + Openlabs

Hi Alessandro,

Hi Sebastian, Sorry if i disturb you, but i had follow the tutorial for:

  • Create a 6LoWPAN Raspbian image   • Spice up Raspbian for the IoT

SCENARIO Now i should be able to query, from the Raspberry PI 3, my SAMR21-XPRO running a RIOT microcoap server ( with global address) On my PI i've plugged a OpenLabs 802.15.4 transceiver, from pins 15 to 24.

NOTE : Following the 1 tutorial, i didn't found the /boot/overlays/at86rf233-overlay.dtb

But when i run the coap-client command on PI it gives me back this error:

root@raspberrypi:/home/pi# coap-client -m GET coap://[2001:db8::1]/.well-known/core v:1 t:CON c:GET i:0b38 {} Jun 23 18:24:30 CRIT coap_send_impl: Network is unreachable

How can i fix it? Thanks a lot.

You should debug this problem step-by-step, starting with COAP right away might not be the best way to begin with.

Assuming you followed the 2 guides above carefully, you should see a `wpan0` device running `ifconfig`. This is how it looks on one of my RasPis:

$ ifconfig
eth0      Link encap:Ethernet  HWaddr b8:27:eb:03:64:bd  
          init addr:  Bcast:www.xxx.yyy.zzz  Mask:255.255.255.0
          inet6 addr: fe80::8099:426e:ba8e:3652/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:2765151 errors:0 dropped:21 overruns:0 frame:0
          TX packets:216917 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:194526990 (185.5 MiB)  TX bytes:40495510 (38.6 MiB)

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          inet6 addr: fd9a:1234:5678:0:ba21:5b58:d2b2:79b8/128 Scope:Global
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

lowpan0   Link encap:UNSPEC  HWaddr BA-21-5B-58-D2-B2-79-B8-00-00-00-00-00-00-00-00  
          inet6 addr: fd9a:1234:5678:0:b821:5b58:d2b2:79b8/64 Scope:Global
          inet6 addr: fe80::b821:5b58:d2b2:79b8/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1280  Metric:1
          RX packets:33549 errors:0 dropped:0 overruns:0 frame:0
          TX packets:133498 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1 
          RX bytes:2130027 (2.0 MiB)  TX bytes:13887785 (13.2 MiB)

wpan0     Link encap:UNSPEC  HWaddr BA-21-5B-58-D2-B2-79-B8-00-00-00-00-00-00-00-00  
          UP BROADCAST RUNNING NOARP  MTU:123  Metric:1
          RX packets:33995 errors:0 dropped:0 overruns:0 frame:0
          TX packets:133645 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:300 
          RX bytes:931713 (909.8 KiB)  TX bytes:13604264 (12.9 MiB)

You also see a `lowpan0` device already configured above -- but the important thing is that `wpan0` **must** be visible. Otherwise the OpenLabs transceiver failed to init or the driver is not loaded. You can also check with the wpan-tools run `iwpan list` you should see some detailed info.

If `wpan0` is missing, check that you enable the overlay in `/boot/config.txt` [1], further the overlay itself must exist in `/boot/overlays/at86rf233.dtbo`. If the latter is missing you did not follow the description [2], maybe you forgot to copy the files to the SD card like this:

sudo cp arch/arm/boot/dts/overlays/*.dtb* <path/to/boot-mount>/overlays

If you see `wpan0` but `lowpan0` is missing, run `sudo create_lowpan 26 "0x23"` (assuming you have installed my helper scripts [3]).

I suggest you try to get this working first. When you have a `lowpan0` interface up and running on the Pi you can proceed -- try the RIOT gnrc_networking example [4] first, before diving into COAP.

Cheers,   Sebastian

[1]: https://github.com/RIOT-Makers/wpan-raspbian/wiki/Create-a-generic-Raspbian-image-with-6LoWPAN-support#33-enable-transceiver [2]: https://github.com/RIOT-Makers/wpan-raspbian/wiki/Create-a-generic-Raspbian-image-with-6LoWPAN-support#44-release-the-kraken--aehm-kernels [3]: https://github.com/RIOT-Makers/wpan-raspbian/wiki/Spice-up-Raspbian-for-the-IoT#systemd-lowpan [4]: https://github.com/RIOT-OS/RIOT/tree/master/examples/gnrc_networking