Go to advanced search

by savageautomate
Tue Nov 20, 2012 4:40 pm
Forum: General programming discussion
Topic: Using 17 GPIO output pins with Pi4J
Replies: 37
Views: 10643

Re: Using 17 GPIO output pins with Pi4J

Un4Seen wrote:And finally, allow me to confirm the great news: all pins are now handled correctly bu Pi4J! My deepest and most sincere thanks to Robert! :)
Excellent news!
You are welcome and I am glad to be able to help out and contribute back to the Pi community!
by savageautomate
Tue Nov 20, 2012 4:39 pm
Forum: Other programming languages
Topic: Using 17 GPIO output pins with Pi4J
Replies: 17
Views: 4995

Re: Using 17 GPIO output pins with Pi4J

Un4Seen wrote:I can confirm the great news: all pins are now handled correctly by Pi4J!
My deepest and most sincere thanks to Robert!
Excellent news!
You are welcome and I am glad to be able to help out and contribute back to the Pi community!
by savageautomate
Tue Nov 20, 2012 4:12 pm
Forum: General programming discussion
Topic: Using 17 GPIO output pins with Pi4J
Replies: 37
Views: 10643

Re: Using 17 GPIO output pins with Pi4J

Is there a JAVA_HOME environment variable pointing to the JRE/JDK 6? Is tomcat possibly running under Java 6?
by savageautomate
Tue Nov 20, 2012 4:05 pm
Forum: General programming discussion
Topic: Using 17 GPIO output pins with Pi4J
Replies: 37
Views: 10643

Re: Using 17 GPIO output pins with Pi4J

I have run into this problem before ... I just need to remember what I did to correct it.....

I am compiling on a Windows 7 machine with:

Code: Select all

java version "1.7.0_06"
Java(TM) SE Runtime Environment (build 1.7.0_06-b24)
Java HotSpot(TM) 64-Bit Server VM (build 23.2-b09, mixed mode)
by savageautomate
Tue Nov 20, 2012 3:49 pm
Forum: General programming discussion
Topic: Using 17 GPIO output pins with Pi4J
Replies: 37
Views: 10643

Re: Using 17 GPIO output pins with Pi4J

I am running Java 7. I don't remember the specific dependency off the top of my head, but there is a Java 7 dependent class in the Pi4J codebase. See this article to make sure that the default version of Java is configured for java-7: http://www.savagehomeautomation.com/projects/raspberry-pi-change-...
by savageautomate
Tue Nov 20, 2012 7:39 am
Forum: Other programming languages
Topic: Using 17 GPIO output pins with Pi4J
Replies: 17
Views: 4995

Re: Using 17 GPIO output pins with Pi4J

I have responded to the questions listed above in the original thread:


Thanks, Robert
by savageautomate
Tue Nov 20, 2012 7:35 am
Forum: General programming discussion
Topic: Using 17 GPIO output pins with Pi4J
Replies: 37
Views: 10643

Re: Using 17 GPIO output pins with Pi4J

2. I tried to set up all the 17 GPIO pins as digital output pins, so that I can call nice methods like blink(), toggle(), pulse(), etc. ... The first thing that bothers me here is that I could not find a way to call the provisionDigitalOutputPin() method in a for loop (from 0 to 16), because the me...
by savageautomate
Tue Nov 20, 2012 7:28 am
Forum: General programming discussion
Topic: Using 17 GPIO output pins with Pi4J
Replies: 37
Views: 10643

Re: Using 17 GPIO output pins with Pi4J

1. I was only able to issue calls to the Pi4J library successfully by running the Tomcat server with root privileges (otherwise I was getting an error message, something like: "Unable to access the WiringPi export interface"). On the Pi4J website it is clearly stated that Pi4J won't run in any othe...
by savageautomate
Tue Nov 20, 2012 6:59 am
Forum: General programming discussion
Topic: Using 17 GPIO output pins with Pi4J
Replies: 37
Views: 10643

Re: Using 17 GPIO output pins with Pi4J

PS:

I have tested GPIO pins 2,8,9 (wiringPi pin numbering scheme) on my 256 MB Raspberry Pi (don't have a 512 MB unit) with the latest Pi4J library (0.0.4-SNAPSHOT) and it seems to be working here.
by savageautomate
Tue Nov 20, 2012 6:45 am
Forum: Other programming languages
Topic: Using 17 GPIO output pins with Pi4J
Replies: 17
Views: 4995

Re: Using 17 GPIO output pins with Pi4J

The new 0.0.4-SNAPSHOT development build is available for testing. This build is compiled against the latest wiringPi sources. You can download the latest packaged JAR from the Maven repository here: https://oss.sonatype.org/content/groups/public/com/pi4j/pi4j-core/0.0.4-SNAPSHOT/ Please report succ...
by savageautomate
Tue Nov 20, 2012 6:44 am
Forum: General programming discussion
Topic: Using 17 GPIO output pins with Pi4J
Replies: 37
Views: 10643

Re: Using 17 GPIO output pins with Pi4J

The new 0.0.4-SNAPSHOT development build is available for testing. This build is compiled against the latest wiringPi sources. You can download the latest packaged JAR from the Maven repository here: https://oss.sonatype.org/content/groups/public/com/pi4j/pi4j-core/0.0.4-SNAPSHOT/ Please report succ...
by savageautomate
Sat Nov 17, 2012 4:07 am
Forum: General programming discussion
Topic: Using 17 GPIO output pins with Pi4J
Replies: 37
Views: 10643

Re: Using 17 GPIO output pins with Pi4J

If you do decide to build yourself be aware that the latest wiringPi does not create /usr/local/lib/libwiringPi.a which pi4j relies on. I created a symbolic link to libwiringPi.so.1.0 which allowed it to build (presumably correctly as it works). This is probably a bit iffy but has worked for me. Th...
by savageautomate
Sat Nov 17, 2012 3:52 am
Forum: General programming discussion
Topic: Using 17 GPIO output pins with Pi4J
Replies: 37
Views: 10643

Re: Using 17 GPIO output pins with Pi4J

Hi Guys,

Sorry, I missed this post. I will push a new SNAPSHOT of Pi4J compiling against the latest WiringPi sources early next week. I'll post back here when its ready so you both can test it out.

Thanks, Robert
by savageautomate
Sat Nov 17, 2012 3:33 am
Forum: Other programming languages
Topic: Using 17 GPIO output pins with Pi4J
Replies: 17
Views: 4995

Re: Using 17 GPIO output pins with Pi4J

I will be looking into this issue next week.
Thanks, Robert
by savageautomate
Thu Nov 15, 2012 5:02 am
Forum: Other projects
Topic: GPIO Testing / Development / Prototyping Board
Replies: 0
Views: 1005

GPIO Testing / Development / Prototyping Board

While working on The Pi4J Project , I found the need to have some type of GPIO prototyping board to quickly visualize the state of GPIO pins and control the state of GPIO pins. I purchased a handful of electronics parts and set out to build my GPIO testing board. The full article along with the wiri...
by savageautomate
Fri Nov 09, 2012 9:44 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: Serial port - is this what I need ?
Replies: 32
Views: 7138

Re: Serial port - is this what I need ?

I would not think that the Ring Indicator pin would matter. If you software is constantly monitoring the serial port for data, then it *should* be OK. The RI is just a "heads-up" notification interrupt to proactively notify the computer/software that some data will be available soon so get ready.
by savageautomate
Fri Nov 09, 2012 7:37 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: Serial port - is this what I need ?
Replies: 32
Views: 7138

Re: Serial port - is this what I need ?

If you intend to use the ttyAMA0 serial port for your own application, then make sure to configure the OS to disable using the serial port as a console access port. Otherwise you will get conflicts and data corruption. See this link for more details: http://www.savagehomeautomation.com/projects/rasp...
by savageautomate
Fri Nov 09, 2012 7:30 pm
Forum: Other programming languages
Topic: Run a .jar RPi
Replies: 6
Views: 4009

Re: Run a .jar RPi

I ran into a similar UnsupportedClassVersionError exception when I was attempting to run a pre-compiled Java program that was compiled using Java 7 on my desktop and trying to run using Java 6 on the Raspberry Pi. Make sure you are compiling using Java 6 or install Java 7 on the Pi.
by savageautomate
Wed Nov 07, 2012 2:55 am
Forum: Other programming languages
Topic: GPIO Pins and Java
Replies: 11
Views: 6998

Re: GPIO Pins and Java

Hello! I'm working on a project that involves (very fast) manipulation of the GPIO pins using Java. ... This project claims to be able to achieve around 30kHz max frequency, which would be excellent for my project. ... Another library I have heard some talk about is the Pi4J project . I intend to l...
by savageautomate
Wed Nov 07, 2012 1:14 am
Forum: Other programming languages
Topic: GPIO Pins and Java
Replies: 11
Views: 6998

Re: GPIO Pins and Java

Ok, I thought there may have been a bug in Pi4J when exporting a pin, but after reviewing and testing it here, I don't think this is a Pi4J defect. I think upgrading your system to one of the later distributions may help. When I use the gpio utility and export an output pin manually, an edge file do...
by savageautomate
Mon Nov 05, 2012 3:03 am
Forum: Other programming languages
Topic: GPIO Pins and Java
Replies: 11
Views: 6998

Re: GPIO Pins and Java

That could be a minor defect. I'll test it out over the next couple of days and make the fix.

Thanks, Robert
by savageautomate
Fri Nov 02, 2012 4:08 am
Forum: Other programming languages
Topic: GPIO Pins and Java
Replies: 11
Views: 6998

Re: GPIO Pins and Java

When you go to test with the Pi4J project, please be aware that there are two ways to access and control GPIO state from this library. The source code examples and documentation on the website all describe using classes in the "com.pi4j.io.gpio" namespace for accessing and controlling GPIO on the Ra...
by savageautomate
Fri Nov 02, 2012 3:57 am
Forum: Other programming languages
Topic: GPIO Pins and Java
Replies: 11
Views: 6998

Re: GPIO Pins and Java

Hi rorosaurus, The Pi4J project used same pin number scheme as the WiringPi project. It's not the same numbering as the hardware GPIO pin numbers on the Pi, but this abstraction helps to isolate the consuming program from board revisions changes. In theory (and thus far this has held true) the GPIO ...
by savageautomate
Sun Oct 28, 2012 8:35 pm
Forum: Other programming languages
Topic: Pi4J - A Java library to interface with the Raspberry Pi
Replies: 57
Views: 48476

Re: Pi4J - A Java library to interface with the Raspberry Pi

(all this com. stuff is new to me.) The com. stuff is just the packaging namespaces. Mostly its a convention to help create unique fully-qualified containers for classes and helps prevent class collisions at import time in user code. Java does not impose or define a required convention to use and o...
by savageautomate
Sun Oct 28, 2012 8:25 pm
Forum: Other programming languages
Topic: Pi4J - A Java library to interface with the Raspberry Pi
Replies: 57
Views: 48476

Re: Pi4J - A Java library to interface with the Raspberry Pi

... I will try harder to not ask stupid questions and not work on problems when I'm 8 hours into a session! :) No apologies needed! 8-) No question is stupid .. its how we all learn. It usually the simplest things that get us tripped up and the easiest to overlook as we attempt to diagnose. Glad yo...

Go to advanced search