Monday, August 17, 2015

Setup 6lbr to run 6LowPAN with CC2531 USB dongle on Raspberry Pi 2B

1. Unzip and flash a CC2531 USB dongle with cc2531-slip-radio_contikimac.zip.
2. SSH login to Raspberry Pi.
3. sudo apt-get install libncurses5-dev
4. sudo apt-get install bridge-utils
5. sudo vi /boot/cmdline.txt file and add the following configuration parameter in the beginning of cmdline.txt
    dwc_otg.speed=1
6. git clone --recursive https://github.com/cetic/6lbr
7. cd 6lbr/examples/6lbr
8. make all plugins tools ---> This step takes lots of time so go for a break!
9. sudo make install
10. Create /etc/6lbr/6lbr.conf with the content below
      MODE=ROUTER

      RAW_ETH=1
      BRIDGE=0
      DEV_BRIDGE=br0
      DEV_TAP=tap0
      DEV_ETH=eth0
      RAW_ETH_FCS=0

      DEV_RADIO=/dev/ttyACM0
      BAUDRATE=115200

      LOG_LEVEL=3
11. Change to channel 25,which is used by cc26xx Contiki port
      $/usr/lib/6lbr/bin/nvm_tool --update --channel 25 /etc/6lbr/nvm.dat
12. Run "/usr/lib/6lbr/bin/nvm_tool --print /etc/6lbr/nvm.dat" to make sure it switches to channel 25.

13. Plug CC2531 USB dongle to Raspberry Pi and the dongle should appear as /dev/ttyACM0. Run "sudo lsusb -v" to verify this.

14. run "sudo service 6lbr start" to start 6lbr.

15. Open browser like Firefox and input [bbbb::100].


5 comments:

  1. Hey, im found of your amazing works at developing and sharing your research with community.

    But can i have a litte tip? I cant really start my 6lbr cuz when i ty "6lbr start" stuff at my console at first it says that there is no such thing as 6lbr.service, and after rebooting it gives no output at all. [bbbb::100] doesnt work in both cases. So, any suggestions?

    ReplyDelete
  2. Do you following all the steps exactly?

    ReplyDelete
  3. Thank you for the great instruction. I was able to follow through your post and successfully installed 6lbr on my debian (I am using Beaglebone Black with CC2531 dongle).
    However, I have a few question to ask.

    On my nvm data file, it states WSN accpe RA : false and I cannot connect to web-browser using [bbbb:100]. I cannot solve this problem on my own and I am stuck at this step.

    Hope you can give me any suggestion to solve this.

    Thank you.

    ReplyDelete
    Replies
    1. go to /6lbr folder and run "git checkout ff69ae4214407eeec4c71f87589ac4bc7d3a8a49". You will get 6lbr version on 2016 Dec. 22th and you can rebuild 6lbr to test again.

      Delete
    2. This comment has been removed by the author.

      Delete