Intel® Makers
Intel® Edison, Intel® Joule™, Intel® Curie™, Intel® Galileo
Announcements
Welcome - This is a Peer-to-Peer Forum only. Intel has discontinued these products but you may find support from other customers on this Forum
9867 Discussions

Accessing GPIO without sysfs

JJosé1
Beginner
1,104 Views

Hello everyone, this is my first post on this forum, but i'm look to be a active user, so i hope it won't be the last

So, i'm executing programs on Galileo Gen 2 executing them directly using ssh. I see that topic bellow about achieve better timings to interact with the GPIO of the Galileo, but is available only cross-compiling through the Arduino IDE.

So when i'm doing my research, i found this other topic

about building this features in libmraa, but in this case is for Edison. And i didn't understand well in the topic ( i'm not from a country with english as a native language ) if this feature was been added to the master branch or not. After that, my questions are : The MRAA lib have features for fast GPIO accessing? if yes, how can i use it? if not, have anyone already did this and can share some information or even a library ? (Can be in any language, but is preferred to be in C++)

 

Please help me to achieve this performance with Galileo D:

Thanks in advance!

4 Replies
idata
Community Manager
71 Views

Hi,

 

 

I looked for some information about fastGPIO on the Galileo but none of it was related to MRAA.

 

 

Some of the most useful links I found are

 

http://www.emutexlabs.com/13-projects/203-getting-started-with-intel-galileo-gen-2 http://www.emutexlabs.com/13-projects/203-getting-started-with-intel-galileo-gen-2

 

http://allynh.com/blog/intel-galileo-getting-to-grips-with-gpio-speeds/ http://allynh.com/blog/intel-galileo-getting-to-grips-with-gpio-speeds/

 

That discuss the speeds, code and performance of the pins. I found in this link http://iotdk.intel.com/docs/master/mraa/namespacemraa.html http://iotdk.intel.com/docs/master/mraa/namespacemraa.html an option of pinMode called PIN_FAST_GPIO. I haven't tested this with the Galileo but give it a try and let us know if you found this useful.

 

 

-Sergio

 

JJosé1
Beginner
71 Views

Hi Sergio! First thanks for reply!!

But have some way to do GPIO access directly without using the arduino IDE ? Or some material that can help me to understand create by myself some library for fast gpio running directly on Linux? The performance links I already saw but i don't know how to do it in a C/C++ program, for example.

Btw, the first link is broken D:

Again, Thanks!

idata
Community Manager
71 Views

You can access GPIOs directly from Linux. In /sys/class/gpio you can find the gpios available and can configure a variety of options. You can see more information here https://anandvetcha.wordpress.com/2014/09/28/galileo-gen2-gpio-control-using-linux/ https://anandvetcha.wordpress.com/2014/09/28/galileo-gen2-gpio-control-using-linux/

 

 

I didn't find any information on how to do fastgpio without the use of the IDE. What speeds are to attempting to reach using the fastgpio method?

 

 

-Sergio

 

idata
Community Manager
71 Views

Do you still need help with this thread? Were you able to access the GPIOs without the IDE?

 

 

-Sergio

 

Reply