Page 1 of 1

Piface2 setup - no spi_bcm2708 (solved)

Posted: Wed Mar 11, 2015 1:32 am
by ImmerStudent
Hi, I'm trying to set to PiFace Digital 2. I've followed all the instructions, enabled SPI using raspi-config, rebooted, commented out SPI_BCM2708 in the blacklist and run spidev setup. sudo modprobe spi-bcm2708 returns 'no such file or device' and spidev0.0 is not in dev. Therefore blink.py fails.

Any suggestions please?

Re: Piface2 setup - no spi_bcm2708

Posted: Thu Mar 12, 2015 10:18 pm
by bulletmark
Since no-one has answered, you could try my installer:

Code: Select all

sudo apt-get install python-pip
sudo pip install pifaceio
sudo install-spidev.sh

Re: Piface2 setup - no spi_bcm2708

Posted: Fri Mar 13, 2015 3:54 am
by ImmerStudent
Thanks, I executed the 3 commands successfully, but I still get 'no such device' when I execute modprobe spi-bcm2708

Re: Piface2 setup - no spi_bcm2708

Posted: Fri Mar 13, 2015 6:02 am
by bulletmark
That script would have told you to reboot when it finished. Did you do that?

Are you running raspbian, and if so is it up to date?

Please run that "sudo install-spidev.sh" command again and post the complete output here (in code tags).

Re: Piface2 setup - no spi_bcm2708

Posted: Fri Mar 13, 2015 9:03 am
by DougieLawson
ImmerStudent wrote:Thanks, I executed the 3 commands successfully, but I still get 'no such device' when I execute modprobe spi-bcm2708
Have you enabled SPI in /boot/config.txt?
Add

Code: Select all

dtparam=spi=on
and reboot. Or use the option in sudo raspi-config (advanced options).

Re: Piface2 setup - no spi_bcm2708

Posted: Fri Mar 13, 2015 9:06 am
by bulletmark
DougieLawson wrote: Have you enabled SPI in /boot/config.txt?
My script does that, with everything else that is required. But, of course that only gets enabled after a reboot.

Re: Piface2 setup - no spi_bcm2708

Posted: Fri Mar 13, 2015 11:55 am
by ImmerStudent
Yes, I did a reboot, I am running raspbian, I did an update/upgrade and I updated the firmware and I had already enabled SPI in config.txt (dtparam=spi=on).
The version of Raspbian (from uname -r) is 3.18.6-v7i-aufs

The output from spidev.sh is:
<output>
Adding pi to spi group ..
groupadd: group 'spi' already exists
Adding user pi to group spi

Creating udev spi rules file ..

Removing blacklist for spi-bcm2708 ..
SPI already added to device tree

Reloading udev rules ..

User pi must log out and back in again.

</output>

I didn't log out, I rebooted.

Re: Piface2 setup - no spi_bcm2708

Posted: Fri Mar 13, 2015 12:09 pm
by DougieLawson
What does lsmod show?
What does dmesg show?
What's in /etc/modules?
What's in /etc/modprobe.d/raspi-blacklist.conf?

Re: Piface2 setup - no spi_bcm2708

Posted: Fri Mar 13, 2015 12:53 pm
by bulletmark
ImmerStudent wrote: The version of Raspbian (from uname -r) is 3.18.6-v7i-aufs
That's quite a different kernel to the one on my RPis and from reading other recent posts around here (with similar problems, e.g. http://www.raspberrypi.org/forums/viewt ... 7&p=717710) it seems you installed Raspbian via BerryBoot? I'd say it's a Berryboot issue, perhaps you have to set that dtparam=spi boot option elsewhere?

Re: Piface2 setup - no spi_bcm2708

Posted: Fri Mar 13, 2015 11:14 pm
by ImmerStudent
Yes, I am using Berryboot. I have no idea how to change the boot parameters for Berryboot itself. Therefore are you saying that if I want to use Piface, I can't use Berryboot? That is sad, as I've set up a lot of stuff in the Raspbian image.

Re: Piface2 setup - no spi_bcm2708

Posted: Fri Mar 13, 2015 11:29 pm
by bulletmark
Sorry, I don't know anything about BerryBoot. Perhaps you should raise an issue at http://github.com/maxnet/berryboot/issues?

Ultimately you probably just need to add "dtparam=spi=on" to BerryBoot's config.txt, which I presume is in the root folder on your USB drive? Maybe try that first.

Re: Piface2 setup - no spi_bcm2708

Posted: Fri Mar 13, 2015 11:39 pm
by DougieLawson
What's the partition layout on your Berryboot SDCard?
Is there more than one FAT/FAT32 partition?
If there is then what's on the one that isn't mounted as /boot? Mount it and take a look, it may have a copy of the RPi firmware (since Berryboot is the grandparent of NOOBS).

Re: Piface2 setup - no spi_bcm2708

Posted: Sat Mar 14, 2015 4:28 am
by ImmerStudent
Hi Dougie. I cut the Gordian knot by removing Berryboot from the equation and just using standalone Raspbian. Now the Piface works and I can find spidev0.0 etc!
So I can assume that Berryboot is the issue and I will leave the research to make Piface work with it to others more qualified.

As a former IBM mainframe sysprog and new to Linux, I have no idea how to find the partition layout or where I might find Berryboot's config.txt, as I have assumed that it would be opaque to the guest OS's file manager. I can only find the guest Raspbian's config.txt.

Thanks for your prompt help.
Now to reinstall my stuff on the new card (sigh)

Re: Piface2 setup - no spi_bcm2708

Posted: Sat Mar 14, 2015 10:25 am
by DougieLawson
ImmerStudent wrote:
As a former IBM mainframe sysprog and new to Linux, I have no idea how to find the partition layout or where I might find Berryboot's config.txt, as I have assumed that it would be opaque to the guest OS's file manager. I can only find the guest Raspbian's config.txt.
Get a USB SDCard reader. Mount the Berryboot card and take a look at it with fdisk -l.

I'm a mainframe sysprog and ex IBM'er, been doing that since Dec 1982.

Re: Piface2 setup - no spi_bcm2708

Posted: Sat Mar 14, 2015 7:17 pm
by MikeBlue
Hello,

You are right for the config.txt in the bootberry.
You just need to use the booberry menu option and add the dtparam=spi=on to the config.txt.
I have tested this method it is perfect !.

Regards

Re: Piface2 setup - no spi_bcm2708 (solved)

Posted: Mon Mar 16, 2015 2:15 am
by ImmerStudent
Dougie, I started in mainframe in 1978. Which doesn't alter the fact that I'm new to the chaos that is Linux.

Mike, I had already tried updating config.txt . Didn't work for me, so I went for the KISS solution.