>
> *I want to start advancing this code to control GPIO pins, blink LEDs,
> read and write to registers, etc. I'm wondering what include files I need
> to do this and what function calls to use. Is there a mass list somewhere
> that I can be referred to? All the tutorials and help that I've seen only
> talk about C++ and I need to use C.*


Which tutorials ? I've seen several examples where the persons
demonstrating the code *think* they're using C++, but their code is all C.
Remember, a C++ compiler can build / compile C code too. Derrek Molloy's
example however does seem to be C++ where possible.

With that said:
https://learnbuildshare.wordpress.com/2013/05/19/beaglebone-black-controlling-user-leds-using-c/

This code is all C except for the statement

*using*

* namespace std;*
Which probably means this person was using g++ instead of gcc*. *It is also
what I'd consider bad practice . . .The #include statements are all C, and
as such all library functions used are in C. Demonstrated by printf() ( C++
uses cout, and the insertion operator << ).

Anyway, I'm not sure that example is "good" or not, but baring that it is a
example in how to blink the USR LEDs in C.

As for the linux libc headers . . .
debian@beaglebone:~$ apt-cache search linux-libc
linux-libc-dev - Linux support headers for userspace development

so

debian@beaglebone:~$ sudo apt-get install linux-libc-dev

Should do the trick.

On Wed, Jun 10, 2015 at 12:00 PM, 'Mark Lazarewicz' via BeagleBoard <
[email protected]> wrote:

> For barebones use TI  starterware supply  example code from TI.
>
> Sent from Yahoo Mail on Android
> <https://overview.mail.yahoo.com/mobile/?.src=Android>
> ------------------------------
>   *From*:"Brendan Merna" <[email protected]>
> *Date*:Wed, Jun 10, 2015 at 11:30 AM
> *Subject*:[beagleboard] Using C to access on board LEDs and GPIO Pins for
> Beagle Bone Black
>
> I've hooked up my Beagle Bone Black through the micro USB cable to a
> computer running Windows 7. I was able to follow a project which involves
> cross compiling and remote connecting to the Beagle Bone through an the
> Eclipse Luna environment. It tuns a simple hello world program in C. Here's
> the link: http://jkuhlm.bplaced.net/hellobone/
>
> I want to start advancing this code to control GPIO pins, blink LEDs, read
> and write to registers, etc. I'm wondering what include files I need to do
> this and what function calls to use. Is there a mass list somewhere that I
> can be referred to? All the tutorials and help that I've seen only talk
> about C++ and I need to use C.
>
> Thanks for any help!
>
> --
> 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.
>
> --
> 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.
>

-- 
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