-
Notifications
You must be signed in to change notification settings - Fork 0
How to install 6LoWPAN Linux Kernel on Raspberry Pi
Install a fairly new (next) Linux kernel on a raspberry pi, which is able to run IEEE802.15.4 devices (i.e. the Atmel AT86RF233) and 6LoWPAN.
NOTE There is much room for improvement here, so follow the steps with caution :-)
http://elinux.org/RPi_Low-level_peripherals
git clone git@github.com:raspberrypi/linux.git linux-rpi
cd linux rpi
git checkout rpi-4.0.y
git clone git@github.com:raspberrypi/firmware.git firmware
cd firmware
git checkout next
http://openlabs.co/blog/archives/1-6LoWPAN-kernel-on-a-Raspberry-Pi Don't forget the lib dir
Follow these sections:
- cross-compiling
- building the Linux kernel
- patching the device tree
Boot options -> Use appended device tree blob to zImage
-- is this needed? --
http://elinux.org/Raspberry_Pi_Kernel_Compilation
http://elinux.org/Raspberry_Pi_Kernel_Compilation
http://elinux.org/Raspberry_Pi_Kernel_Compilation
https://github.com/raspberrypi/linux/wiki/How-to-boot-using-device-tree
(but remove the option init_emmc_clock
)
sudo apt-get install libnl-3-dev libnl-genl-3-dev
####get them from here:
https://github.com/linux-wpan/wpan-tools
The current master seems to fail while configuring...
cd wpan-tools
./autogen.sh
./configure
http://wpan.cakelab.org/releases/wpan-tools-0.4.tar.gz
tar xfvz wpan-tools-0.4.tar.gz
cd wpan-tools-0.4.tar.gz
./configure
make
sudo make install
For testing, follow some of the instructions at http://wpan.cakelab.org/#_how_to_8217_s
This howto will guide you to
- Configure the Raspberry Pi Kernel for 802.15.4 and 6LoWPAN
- show you how to patch support for the openlabs Raspberry-Pi-802.15.4-radio
- compile a recent Linux kernel (rpi-4.0.y) for the Raspberry Pi
- and use the new built Kernel on your RasPi
To start off, we obtain the official and latest Raspbian image and flash it on our SDCard.
- We download the official latest Raspbian image (scroll down a bit),
- and follow the guides to flash it on our SDCard.
- Then we Plug the SDCard and fire our RasPi.
- Note if you login the first time, the username is
pi
and the password israspberry
- Second note watch out if you have a german keyboard layout, the keys
y
andz
are switched. - In the first run we set the filesystem to be expanded and if desired set additional options for the system using the
raspi-config
tool and let the RasPi reboot when we finished. - After the reboot we login and first update the system entering
sudo apt-get update
andsudo apt-get upgrade
.
We focus on cross compilation here, since we don't want to spend a night watching the build process ;).
First we obtain an appropriate and recent Cross GCC to build the Kernel.
The RasPi rquires an arm-gnueabihf
GCC for cortex a7
processors.
So, the Linaro GCC 4.9 is our candidate here.
We download the appropriate tar.xz
file and decompress it.
Now we open a terminal and export the path to the newly decompressed GCC bin directory.
We type export PATH=$PATH:/home/<myusername>/Downloads/gcc-linaro-4.9-2014.11-x86_64_arm-linux-gnueabihf/bin
.
To test if the export succeeded we type arm-linux-gnueabihf-gcc --version
and should be provided with the version information of our cross compiler.
If not, the path export seems to be failed, you can check it by type in $PATH
in the terminal.
Note, if you use a 64 bit Linux you may also need multilib support.
Now we get the RasPi latest Kernel sources from their Git repository
git clone https://github.com/raspberrypi/linux.git linux-rpi
cd linux rpi
git checkout rpi-4.0.y
cd ..
and the latest firmware
git clone https://github.com/raspberrypi/firmware.git firmware
cd firmware
git checkout next
cd ..
First we configure the sources with an appropriate configuration for the RasPi.
We switch in the kernel source folder, typing cd linux-rpi
followed by
make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- bcmrpi_defconfig
This setups the kernel with an initial configuration.
Now we need to enable 802.15.4 and 6LoWPAN plus the supported devices. We type
make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- menuconfig
and start to configure/enable the desired features.
RIOT - The friendly Operating System for the Internet of Things
Homepage | [GitHub] (https://github.com/RIOT-OS/) | Developers Mailing List | Users Mailing List | Twitter @RIOT_OS
- Family: ARM
- Board: Airfy Beacon
- Board: Arduino Due
- Board: CC2538DK
- Board: HikoB Fox
- Board: IoT LAB M3
- Board: LimiFrog-v1
- Board: mbed_lpc1768
- Board: MSB-IoT
- Board: MSBA2
- Board: Nucleo-L1
- Board: Nucleo-F334
- Board: Nucleo-F303
- Board: Nucleo-F091
- Board: Mulle
- Board: OpenMote
- Board: PCA1000x (nRF51822 Development Kit)
- Board: Phytec phyWAVE-KW22
- Board: RFduino
- Board: Samr21 xpro
- Board: Spark Core
- Board: STM32F0discovery
- Board: STM32F3discovery
- Board: STM32F4discovery
- Board: UDOO
- Board: yunjia-nrf51822
- Family: ATmega
- Board: Arduino Mega2560
- Family: MSP430
- Board: MSB-430H
- Board: TelosB
- Board: WSN430
- Board: Zolertia Z1
- Board: eZ430-Chronos
- Family: native
- Board: native
- Family: x86
- Board: Intel Galileo