Special

Introducing the “Welcome to Xojo” Bundle!

New to Xojo and looking for guidance? We've put together a terrific bundle to welcome you! Xojo Bundle

This bundle includes six back issues of the magazine -- all of year 21 in printed book and digital formats -- plus a one-year subscription (beginning with 22.1) so you'll be learning all about Xojo for the next year. It's the perfect way to get started programming with Xojo. And you save as much as $35 over the non-bundle price!

This offer is only available for a limited time as supplies are limited, so hurry today and order this special bundle before the offer goes away!

Article Preview


Buy Now

Issue 22.1 ('Sandstorm')
Instant purchase and download via GumRoad!

FEATURE

Rasp Pi Electronic Fun Part 5

Retrieve GPIO information from Raspberry Pi

Issue: 22.1 (January/February 2024)
Author: Eugene Dakin
Author Bio: Eugene works as a Senior Oilfield Technical Specialist. He has university degrees in the disciplines of Engineering, Chemistry, Biology, Business, and a Ph.D. in Chemical Engineering. He is the author of dozens of books on Xojo available on the xdevlibrary.com website.
Article Description: No description available.
Article Length (in bytes): 13,324
Starting Page Number: 36
Article Number: 22104
Resource File(s):

Download Icon project 22104.zip Updated: 2023-12-31 23:50:53

Related Web Link(s):

http://abyz.me.uk/lg/lg.zip

Excerpt of article text...

Programming the Raspberry Pi with electronics is very rewarding, especially when programming electronics and seeing your inventions work in the real world. As programmers, we know that mistakes and errors can occur which may be from programming, poor wiring, wrong voltage, and many other possibilities. This article shows how to retrieve status information about the Raspberry Pi to help troubleshoot issues when bug hunting! This information is specifically handy when a pin is "thought" to be output and is accidentally set to input (which has happened to yours truly).

If you have ever had to work on someone's old Raspberry Pi where the information has been rubbed off, or determine if some pins are in working condition, then this article will help.

To run today's demonstration program, open the lgInfo project in Xojo's IDE, press the build button, and copy the generated folder and libraries to the Raspberry Pi. Open a terminal and change to the directory containing the lgInfo binary. Use two commands in the terminal to start the program.

sudo chmod +x lgInfo

sudo ./lgInfo

...End of Excerpt. Please purchase the magazine to read the full article.