This - like several solutions - tries to open /dev/mem for read and write. 
On my Rev C debian BBB, this operation fails, I suspect due to access 
rights as it seems like it may need root access privilege? (Similarly for 
the sysfs method, you can't write to sys/class/gpio/export unless you're 
root, making it easy from a shell using sudo, and a PITA from C++). Is that 
correct?

On Thursday, 11 July 2013 06:05:09 UTC+1, Jacek Radzikowski wrote:
>
> I wrapped the code up and posted the library on github. It is more of 
> a framework, which allows to write applications that can be easily 
> ported between different platforms. The GPIO access is just a small 
> part of the library. 
> Currently I have only implementation for Beaglebone, but RPI port 
> should be trivial to make. I'm also thinking about  a version for 
> Cortex MCUs. 
> Please check out, clone and comment at https://github.com/piranha32/IOoo 
>
> j. 
>
>
> On Tue, Jun 18, 2013 at 2:58 AM, Jacek Radzikowski 
> <[email protected] <javascript:>> wrote: 
> > I'm pretty close to having some code ready for release. All what is 
> > left is to get rid of the most obvious bugs, clean up the code a bit, 
> > add simple makefile and I think I will be ready to post it. My current 
> > biggest headache is the crosscompiler. I've been using pre-compiled 
> > g++ from Angstrom, but it adds some memory leaks to the compiled 
> > programs. Running valgrind on a trivial cross-compiled "Hello world" 
> > shows big allocation and memory corruption problems localized 
> > somewhere around main(). The same code compiled natively on beaglebone 
> > passes all the checks. I'm building right now new cross-toolchain with 
> > angstrom and I hope it will work better and will fix most of the 
> > memory-related problems I was observing. 
> > I will definitely need testers, so I'll post information to the list 
> > as soon as the library will be ready for download. 
> > 
> > j. 
> > 
> > 
> > 
> > On Tue, Jun 18, 2013 at 2:21 AM, MH <[email protected] <javascript:>> 
> wrote: 
> >> Jacek, 
> >> 
> >> so after some experimenting with the libraries and using sysfs to 
> control 
> >> the GPIO pins.  I have found that this method of toggling gpio pins is 
> >> extremely slow.  It is great for simple applications, yet is really 
> >> limiting.  I think the best case on-off time toggling the pins is about 
> .1 
> >> milliseconds on the BBB.  How is your library progressing?  Is there 
> >> anything you are particularly stuck with? 
> >> 
> >> Thanks, 
> >> 
> >> Mark 
> >> 
> >> -- 
> >> For more options, visit http://beagleboard.org/discuss 
> >> --- 
> >> You received this message because you are subscribed to the Google 
> Groups 
> >> "BeagleBoard" group. 
> >> To unsubscribe from this group and stop receiving emails from it, send 
> an 
> >> email to [email protected] <javascript:>. 
> >> For more options, visit https://groups.google.com/groups/opt_out. 
> >> 
> >> 
> > 
> > 
> > 
> > -- 
> > Given a choice between two theories, take the one which is funnier 
>
>
>
> -- 
> Given a choice between two theories, take the one which is funnier 
>

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to