Things used in this project

Hardware components:
Texas Instruments SN74HC244N buffer ICs
×1
ULN2803A
×1
ProtoPal
×1
20-pin DIP socket - Through Hole - 3 pcs
×1
[10x] 3-Pin 2.54mm Pitch PCB Mount Screw Terminal Block Connector - Fits PCBs!
×1
A  overhead
Raspberry Pi 1 Model A+
×1
Hand tools and fabrication machines:
09507 01
Soldering iron (generic)

Schematics

schematic.JPG
Schematic

Code

Test CodePython
Code to test board
import RPi.GPIO as GPIO
from time import sleep
GPIO.setmode(GPIO.BCM)

myInputs = [17,22,23,24,5,6,12,13]
myOutputs = [25,8,7,16,20,19,26,21]

for pin in myInputs:
    GPIO.setup(pin,GPIO.IN,pull_up_down=GPIO.PUD_DOWN)

for pin in myOutputs:
    GPIO.setup(pin,GPIO.OUT)

while True:
    for pin in myOutputs:
        GPIO.output(pin,True)
        sleep(.25)
        GPIO.output(pin,False)
GPIO Buffer initializationPython
I've placed my script in /usr/share and a script in /etc/init.d to initialize this code on startup
import RPi.GPIO as GPIO
from time import sleep
GPIO.setmode(GPIO.BCM)

myInputs = [17,22,23,24,5,6,12,13]
myOutputs = [25,8,7,16,20,19,26,21]

for pin in myInputs:
    GPIO.setup(pin,GPIO.IN,pull_up_down=GPIO.PUD_DOWN)

for pin in myOutputs:
    GPIO.setup(pin,GPIO.OUT)

for pin in myOutputs:
    GPIO.output(pin,False)
Init.d script to initialize the bufferSH
With this script in the /etc/init.d folder and named gpio_init and the python script gpiobuffer_init.py in the /usr/share folder, run the command sudo update-rc.d gpio_init defaults
Now the script will run at startup and initialize the buffers
#! /bin/sh
### BEGIN INIT INFO
# Provides:          gpio_init
# Required-Start:    $remote_fs $syslog
# Required-Stop:     $remote_fs $syslog
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: Example initscript
# Description:       This file initializes the GPIO Buffer
### END INIT INFO

# Author: Doug
#


python /usr/share/gpiobuffer_init.py

Credits

Df9795cc7f4836a099ad423362f42aa3
Doug Wyman

Been playing with computers since 1962. Still learning.

Replications

Did you replicate this project? Share it!

Love this project? Think it could be improved? Tell us what you think!

Give feedback

Comments

Similar projects you might like

WalabotEye - Object Tracker with Haptic Feedback
Intermediate
  • 1,039
  • 9

Full instructions

For the hard of sight, use this to have a better understanding of the world around you.

End-Effector and Control Logic for Robot
Intermediate
  • 3,369
  • 25

For my thesis, I have developed the control system and end-effector for a robot, easily implementable and economic.

Theremino Adapter for CNC.
Intermediate
  • 303
  • 8

Full instructions

Attention: This adapter is used to replace the parallel port with the USB, and not to operate Mach3 CNC or Linux.

Smart Mirror (with Optional Alexa)
Intermediate
  • 19,140
  • 93

Full instructions

A low cost and easy to build smart mirror with off the shelf parts.

Pulse Train HAT Pick & Place Example
Intermediate
  • 443
  • 3

Protip

With this example, we show how to use the PTHAT and Raspberry Pi being used to learn commands for pick and place applications.

Create a Linux Virtual Machine with RPi Compute Module 3
Intermediate
  • 1,986
  • 12

Protip

Train as a Raspberry Pi Compute Module 3 (CM3) Jedi and explore a galaxy of new adventures.

ProjectsCommunitiesContestsLiveAppsBetaFree StoreBlogAdd projectSign up / Login
Respect project
Feedback