Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

7/3/2018 Installing Machinekit · kinsamanka/PICnc-V2 Wiki · GitHub

kinsamanka / PICnc-V2

Dismiss
Join GitHub today
GitHub is home to over 28 million developers working together to host
and review code, manage projects, and build software together.

Sign up

Installing Machinekit
kinsamanka edited this page on Aug 15, 2014 · 2 revisions

Using Pre-built Image: Pages 7

Download the minimal raspbian image at http://0ptr.link/files/ Home


Compare the md5sum of the downloaded file: http://0ptr.link/files/MD5SUMS
Compiling HAL component
Install the image by following the instructions here
Compiling the Firmware
The first boot up will be a bit slow as the ssh keys are being generated
The default username is pi and the password is raspberry Installing Machinekit

Post install OpenOCD PIC32 Programmer

Sample configuration
Configure locale
Testing
sudo dpkg-reconfigure locales

Clone this wiki locally


Configure timezone https://github.com/kinsaman

sudo dpkg-reconfigure tzdata Clone in Desktop

Installing from an Existing Raspbian image:

Login to the running RPi

Import GPG keys

sudo apt-key adv --keyserver hkp://keys.gnupg.net --recv-key 49550439

Add RPi Machinekit repository

sudo sh -c 'echo "deb http://0ptr.link/raspbian wheezy main' > \


/etc/apt/sources.list.d/rpi-machinekit.list"

Update

sudo apt-get update

Backup old kernel and install xenomai kernel

sudo apt-get install linux-image-xenomai


sudo mv /boot/kernel.img /boot/kernel.img.bck
sudo cp /boot/vmlinuz* /boot/kernel.img

https://github.com/kinsamanka/PICnc-V2/wiki/Installing-Machinekit 1/2
7/3/2018 Installing Machinekit · kinsamanka/PICnc-V2 Wiki · GitHub

Install machinekit

sudo apt-get install machinekit-xenomai

Modify user rights

sudo usermod -a -G xenomai,kmem <username>

Configure udev rules

sudo sh -c \
'cat >/etc/udev/rules.d/xenomai.rules<<EOF
# allow RW access to /dev/mem
KERNEL=="mem", MODE="0660", GROUP="kmem"
# real-time heap device (Xenomai:rtheap)
KERNEL=="rtheap", MODE="0660", GROUP="xenomai"
# real-time pipe devices (Xenomai:rtpipe)
KERNEL=="rtp[0-9]*", MODE="0660", GROUP="xenomai"
EOF
'

Reboot

sudo reboot

Test if xenomai is working

latency-test

NOTE: If cpufreq is running, make sure it is set to performance mode.

https://github.com/kinsamanka/PICnc-V2/wiki/Installing-Machinekit 2/2

You might also like