Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Beginner
1,286 Views

SPI, MRAA and Ubuntu 16.04.1 LTS

Hello,

I updated the BIOS, installed Ubuntu 16.04.1 LTS, and installed MRAA from (github.com/intel-iot-devkit/mraa) on my on the Intel Joule 570X Development Board.

 

I can set GPIO pins, but I cannot initialize the SPI. Is there someone that can help me please?

 

Thanks.

System setup:

- Intel Joule 570X Development Kit

- Operating System:

$ uname -a

Linux joule 4.4.0-53-generic # 74-Ubuntu SMP Fri Dec 2 15:59:10 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

$ lsb_release -a

No LSB modules are available.

Distributor ID: Ubuntu

Description: Ubuntu 16.04.1 LTS

Release: 16.04

Codename: xenial

- MRAA:

$ mraa-gpio version

 

Version v1.5.1 on Intel GT Tuchuck

Reproducing the issue:

$ ./mraa/build/examples/spi_max7219

Initialization of spi failed, check syslog for details, exit...

Syslogs:

Dec 9 15:06:14 joule libmraa[6098]: libmraa version v1.5.1-11-gc1017bb initialised by user 'chiara' with EUID 1000

Dec 9 15:06:14 joule libmraa[6098]: joule: Failed to detect i2c buses, making wild assumptions!

Dec 9 15:06:14 joule libmraa[6098]: libmraa initialised for platform 'Intel GT Tuchuck' of type 13

Dec 9 15:06:14 joule libmraa[6098]: spi: Failed opening SPI Device. bus:/dev/spidev32766.0. Error 2 No such file or directory

0 Kudos
5 Replies
Highlighted
Community Manager
10 Views

Hi ChiaraT,

Thanks for your interest in the Intel® Joule Platform.

We have looked at this other thread: /message/436901# 436901 https://communities.intel.com/message/436901# 436901, there is a discussion regarding MRAA and Ubuntu 16.04.1 LTS, we'd recommend you to read that, it could be helpful.

Additionally, Ubuntu is still in beta, so there might be issues while using it. We'd suggest you to contact Ubuntu support for any Ubuntu questions on Joule, please refer to: https://developer.ubuntu.com/en/snappy/start/intel-joule/ https://developer.ubuntu.com/en/snappy/start/intel-joule/.

Regards,

-Yermi

0 Kudos
Highlighted
Novice
10 Views

@Yermi, this feels a little unsatisfactory. Could you give some hints why you feel an SPI problem using mraa is a problem for Ubuntu support?

0 Kudos
Highlighted
Beginner
10 Views

Hi Yermi,

 

thanks for your answer. I already read this post, but it does not address SPI issues.

Regards,

Chiara

0 Kudos
Highlighted
10 Views

The other thread on MRAA ( ) was specifically about avoiding having to run programs accessing the GPIOs via MRAA as root. However, it assumed you ALREADY had access to the GPIOs when running as root.

Therefore, the first thing I would do for SPI (and I2C...) is try to access these devices with a program run using sudo or as root. Once you have THAT working, then you can probably the approach in the above thread to make things *easier* to access from userspace.

I assume you are trying some of the test programs included with MRAA for SPI? What happens when you run those as root? Note also that the sample programs provided are for specific devices, though.

0 Kudos
Highlighted
Community Manager
10 Views

Hi Kubark,

 

 

Ubuntu is still in beta and we're working on finalizing the documentation, is for that reason we suggested the Ubuntu support.

 

 

Regards,

 

-Yermi

 

0 Kudos