I have been playing with RPI for some time now trying to get Hal2Arduino
working for a multi-task hobby cnc that I have built. Have software working for
xyza axis still need to hook up drivers and steppers. I know that linuxcnc is
not going to work as well as what Gene Haskett is doing but this is a hobby
machine. Still having trouble getting xyuv axis part of machine working have a
config file error to figure out.
But the reason why I responded to this post I have instructions on how
to create a minimal install for RPI image that will work on RPI2 or 3. Seems it
could help allot of people, so here it is.
Follow these direction in order to make a minamal Raspbian "Debian Jessie"
install
with a realtime kernel,(ver. 4.4.9-rt17) and Mate Desktop and Linuxcnc
sdcard will work with rpi2 or 3
Download Emlid image for sd card then extract from
https://files.emlid.com/images/emlid-raspbian-20160718.img.xz
# On Linux computer download Etcher to write image to sdcard at
https://etcher.io/
Download, extract and run Etcher
Select the archive file with image and sd card drive letter.
Click “Flash!”. The process may take a few minutes.
----------------------------------------------------------------------
# RT-PREEMPT realtime kernel
# Download kernel image
http://download.frank-durr.de/kernel-4.4.9-rt17.tgz
# Extract files
# Start your file manager from terminal with root privliges, my file manager is
thunar so I use:
# sudo thunar
# Copy extracted files inside boot directory, to boot directory on sdcard
choose to overwrite files
# Copy extarcted file lib, to root of other partition on sdcard choose to
overwrite files
-----------------------------------------------------------------------
# Install Sdcard into PI
# Connect to wired network
# Or shh from another computers ethernet connection
------------------------------------------------------------------------
# See posts at this site about rt patched kernel on pi2 & 3 freezing during
wifi use
https://www.raspberrypi.org/forums/viewtopic.php?f=29&t=159170
# Need to add to end of cmdline.txt
sudo nano /boot/cmdline.txt
#Add the following
dwc_otg.fiq_fsm_enable=0 dwc_otg.fiq_enable=0 dwc_otg.nak_holdoff=0
sudo reboot -n
---------------------------------------------------------------------
# Update to correct keyboard layout
sudo dpkg-reconfigure keyboard-configuration
---------------------------------------------------------------------
# Generate locales
sudo dpkg-reconfigure locales
#add correct language
en_US.UTF-8
locale -a
#To check locale
-----------------------------------------------------------------------
#Update Time Zone
sudo dpkg-reconfigure tzdata
------------------------------------------------------------------------
sudo raspi-config
#NOTE: do not Overclock
1 Expand File system
when finished choose to reboot
If you need other things enabled such as SPI or C12 ect. it can be done here
----------------------------------------------------------------------
sudo apt-get -y update && sudo apt-get -y upgrade
------------------------------------------------------------------------
# RPI 2 or 3
sudo apt-get install -y mate-core mate-desktop-environment xorg lightdm
sudo apt-get install -y network-manager-gnome synaptic iceweasel xterm
# RPI 3
sudo apt-get install -y pi-bluetooth
sudo apt-get install -y bluetooth bluez blueman
-----------------------------------------------------------------------
#Setup network manager
sudo nano /etc/network/interfaces
#Comment out
#iface wlan0 inet dhcp
#iface default inet dhcp
#iface wlan1 inet dhcp
#iface eth0 inet manual
# Use control key and x to save and save to default
-------------------------------------------------------------------------
#Update rpi firmware without over writing rt kernel
sudo apt-get install rpi-update
sudo SKIP_KERNEL=1 rpi-update
sudo reboot -n
------------------------------------------------------------------------
#Install Linuxcnc
On RPI goto web page
http://buildbot.linuxcnc.org/
Follow directions to install 2.7 or Master, Jessie (uspace: realtime with
RT-Preempt, and simulation), armhf
# first add repository key, open Mate Terminal look for it in system tools menu
item, you can copy and paste from web site page:
sudo apt-key adv --keyserver hkp://keys.gnupg.net --recv-key E0EE663E
# Start text editor Pluma with root privliges like this:
sudo pluma /etc/apt/sources.list.d/linuxcnc-buildbot.list
#Add the following to file for 2.7 then save:
deb http://buildbot.linuxcnc.org/ jessie 2.7-sim
deb-src http://buildbot.linuxcnc.org/ jessie 2.7-sim
# Now update the system:
sudo apt-get update
# Now start Synaptic which will only start from terminal
sudo synaptic
# Type in search box linuxcnc find the following, then click and mark for
installation then apply;
linuxcnc-uspace
linuxcnc-doc-en
-------------------------------------------------------------------------
#To make image backup of sdcard on a linux computer I think this works on MAC
also
# First use Gparted to shrink second partition
sudo fdisk -u -l <----use to find where sdcard is mounted run without card,
then with card
sudo fdisk -u -l /dev/mmcblk0 <----name of sdcard in my computer yours maybe
different
sudo dd if=/dev/mmcblk0 of=~/SDCardBackup.img count=9023487 <---- # = END of
sectors on second partition, yours will be different
# Remember to exspand file system with raspi-config when rewiting to a new
sdcard
Hope this is helpful
Tim March
On 2017-05-05 06:28 PM, [email protected] wrote:
Send Emc-users mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
https://lists.sourceforge.net/lists/listinfo/emc-users
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Emc-users digest..."
1. Re: about to give up on the pi's (Gene Heskett)
----------------------------------------------------------------------
Message: 1
Date: Fri, 5 May 2017 17:34:57 -0400
From: Gene Heskett <[email protected]>
Subject: Re: [Emc-users] about to give up on the pi's
To: [email protected]
Message-ID: <[email protected]>
Content-Type: Text/Plain; charset="iso-8859-1"
On Friday 05 May 2017 09:25:01 Charles Steinkuehler wrote:
On 5/5/2017 7:56 AM, andy pugh wrote:
On 5 May 2017 at 13:41, Charles Steinkuehler
<[email protected]> wrote:
So does the armhf build run in Raspian or are you using qemu or
something? AFAIK, standard Debian armhf code won't run on the RPi
because Raspbian uses a different ABI (due to the not-quite full
armhf compatible CPU on the original RPi).
It might be worth considering that Gene's experience seems to be
that LinuxCNC on the Pi runs less than flawlessly.
Indeed. I've only just started playing with the RPi3 and have already
hit some issues. I was hoping the GPU would be usable, but it looks
like there are still problems. I think the BBB (or an SoC+FPGA) is
probably a better choice if you don't need a native GUI, and if you
_do_ want a GUI a low-end x86 box is likely a much better choice.
I've ordered one of these x86 SBCs to play with and see if I can get
it talking to Mesa hardware via SPI:
http://up-shop.org/up-boards/2-up-board-2gb-16-gb-emmc-memory.html
...if it works out, it may be a good midway point between the ARM
based SBCs and a full x86 machine.
https://wiki.debian.org/RaspberryPi
Seems to suggest that armhf works on Pi >= 2.0
buildbot "sim" builds run with realtime on preempt-rt kernels.
Yeah, I should be able to use the armhf builds if I'm running stock
Debian (which works on the RPi 2 & 3). I started with Raspbian to see
what the "out-of-the-box" experience is like, and figure it's unlikely
I can tweak Debian to work better than Raspbian. I'm unclear what
Gene's running, but I'm guessing it's Debian armhf rather than
Raspbian.
Nope, raspian. From my /etc/apt/sources.list:
deb http://mirrordirector.raspbian.org/raspbian/ jessie main contrib
non-free rpi
# Uncomment line below then 'apt-get update' to enable 'apt-get source'
#deb-src http://archive.raspbian.org/raspbian/ jessie main contrib
non-free rpi
deb http://buildbot.linuxcnc.org/ jessie master-sim
deb-src http://buildbot.linuxcnc.org/ jessie master-sim
no debian in site other than whats been thru the raspian "filter".
Cheers, Gene Heskett
Follow these direction in order to make a minamal Raspbian "Debian Jessie"
install
with a realtime kernel,(ver. 4.4.9-rt17) and Mate Desktop and Linuxcnc
sdcard will work with rpi2 or 3
# Install Emlid image to card download at
https://files.emlid.com/images/emlid-raspbian-20160718.img.xz
# On Linux computer download Etcher to write image to sdcard at
https://etcher.io/
Download, extract and run Etcher with administrator rights
Select the archive file with image and sd card drive letter.
Click “Flash!”. The process may take a few minutes.
----------------------------------------------------------------------
# RT-PREEMPT realtime kernel
# Download kernel image
http://download.frank-durr.de/kernel-4.4.9-rt17.tgz
# Extract files
# Start your file manager from terminal with root privliges, my file manager is
thunar so I use:
# sudo thunar
# Copy extracted files inside boot directory, to boot directory on sdcard
choose to overwrite files
# Copy extarcted file lib, to root of other partition on sdcard choose to
overwrite files
-----------------------------------------------------------------------
# Install Sdcard into PI
# Connect to wired network
# Or shh from another computers ethernet connection
------------------------------------------------------------------------
# See posts at this site about rt patched kernel on pi2 & 3 freezing during
wifi use
https://www.raspberrypi.org/forums/viewtopic.php?f=29&t=159170
# Need to add to end of cmdline.txt
sudo nano /boot/cmdline.txt
#Add the following
dwc_otg.fiq_fsm_enable=0 dwc_otg.fiq_enable=0 dwc_otg.nak_holdoff=0
sudo reboot -n
---------------------------------------------------------------------
# Update to correct keyboard layout
sudo dpkg-reconfigure keyboard-configuration
---------------------------------------------------------------------
# Generate locales
sudo dpkg-reconfigure locales
#add correct language
en_US.UTF-8
locale -a
#To check locale
-----------------------------------------------------------------------
#Update Time Zone
sudo dpkg-reconfigure tzdata
------------------------------------------------------------------------
sudo raspi-config
#NOTE: do not Overclock
1 Expand File system
when finished choose to reboot
If you need other things enabled such as SPI or C12 ect. it can be done here
----------------------------------------------------------------------
sudo apt-get -y update && sudo apt-get -y upgrade
------------------------------------------------------------------------
# RPI 2 or 3
sudo apt-get install -y mate-core mate-desktop-environment xorg lightdm
sudo apt-get install -y network-manager-gnome synaptic iceweasel xterm
# RPI 3
sudo apt-get install -y pi-bluetooth
sudo apt-get install -y bluetooth bluez blueman
-----------------------------------------------------------------------
#Setup network manager
sudo nano /etc/network/interfaces
#Comment out
#iface wlan0 inet dhcp
#iface default inet dhcp
#iface wlan1 inet dhcp
#iface eth0 inet manual
# Use control key and x to save and save to default
-------------------------------------------------------------------------
#Update rpi firmware without over writing rt kernel
sudo apt-get install rpi-update
sudo SKIP_KERNEL=1 rpi-update
sudo reboot -n
------------------------------------------------------------------------
#Install Linuxcnc
On RPI goto web page
http://buildbot.linuxcnc.org/
Follow directions to install 2.7 or Master, Jessie (uspace: realtime with
RT-Preempt, and simulation), armhf
# first add repository key, open Mate Terminal look for it in system tools menu
item, you can copy and paste from web site page:
sudo apt-key adv --keyserver hkp://keys.gnupg.net --recv-key E0EE663E
# Start text editor Pluma with root privliges like this:
sudo pluma /etc/apt/sources.list.d/linuxcnc-buildbot.list
#Add the following to file for 2.7 then save:
deb http://buildbot.linuxcnc.org/ jessie 2.7-sim
deb-src http://buildbot.linuxcnc.org/ jessie 2.7-sim
# Now update the system:
sudo apt-get update
# Now start Synaptic which will only start from terminal
sudo synaptic
# Type in search box linuxcnc find the following, then click and mark for
installation then apply;
linuxcnc-uspace
linuxcnc-doc-en
-------------------------------------------------------------------------
#To make image backup of sdcard on a linux computer I think this works on MAC
also
# First use Gparted to shrink second partition
sudo fdisk -u -l <----use to find where sdcard is mounted run without card,
then with card
sudo fdisk -u -l /dev/mmcblk0 <----name of sdcard in my computer yours maybe
different
sudo dd if=/dev/mmcblk0 of=~/SDCardBackup.img count=9023487 <---- # = END of
sectors on second partition, yours will be different
# Remember to exspand file system with raspi-config when rewiting to a new
sdcard
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-users