LED Blinking (B4J)

Explore the Raspberry Pi
Site Admin
Posts: 224
Joined: 07 Oct 2017, 12:16

LED Blinking (B4J)

Postby rwblinn » 09 Oct 2017, 15:15

A blinking LED connected to the Raspberry Pi GPIO (General Purpose Input/Output Pins) controlled via a B4J Non-UI Console Application.

Ready to develop?
Before starting, ensure to read Setup B4J first to develop this B4J Console Application.

Raspberry Pi, GPIO Extension Board, GPIO cable, Breadboard, 1 Resistor 330 ohm, 1 LED 3.3 V, several jumper wires.

Build the circuit
The Raspberry Pi GPIO is connected via a GPIO Extension Board (T-Cobbler) and GPIO cable to a Breadboard.
On the Breadboard, place the LED with a 330 ohm resistor in series with the GND (Physical Pin 6) and the GPIO18 Pin (Physical Pin 12, Pi4J GPIO1).

Create the Software
A B4J console application using the jPi4J Libary (Raspberry Pi GPIO controller).
For detailed information about the project see Description below or look up in project source.

Run the Experiment
On the Raspberry Pi start the B4J-Bridge by login on as user Pi, open a terminal, go to folder /home/pi/b4j and run sudo java -jar b4-bridge.jar, note the MyIp address.
Open the B4J IDE and load the B4J project file, connect to the B4J-Bridge (Menu Tools > B4J Bridge > Connect > Enter IP address.
Run the application from the B4J IDE by pressing F5.

Download the B4J Project Source

Sep 01, 2015: First Version.

Additional Information
Related to this experiment, is LED On/Off.
Download the B4J Project Source

Return to “Raspberry Pi”

Who is online