Custom Raspi GPIO Interfcae PCB Project

There’s a bill of material in this file and my original element14 order.

Would you be willing to upload the Gerber files somewhere? Really like the look of this board, don’t mind waiting the extra time if I can use a cheaper supplier.

Here you go:

(Right click and save as).

1 Like

This is so satisfying! Really nice job.

Did you have any problems with pi-mqtt-gpio, or any feedback from using it with quite a few inputs?

Only feedback I have is that it has been working perfectly and I have been recommending it to lots of other people with similar requirements.

Thanks for sharing it!

@flyte having said that I’ve only ever used inputs. Now that I want to configure an output I’m a bit stuck.

For this config in your mqtt-gpio bridge:

  port: 1883
  user: "mqtt_user"
  password: "redacted"
  topic_prefix: gpio_bridge_2
  status_topic: status
  status_payload_running: online
  status_payload_stopped: offline
  status_payload_dead: dead

  - name: raspberrypi
    module: raspberrypi
    cleanup: yes

  - name: led_green
    module: raspberrypi
    pin: 5
    on_payload: "ON"
    off_payload: "OFF"
    initial: low
    retain: yes

What do I put for the HA state_topic: and availability_topic: ?

- platform: mqtt
  name: "led_green"
  state_topic: # ?
  command_topic: "gpio_bridge_2/output/led_green/set"
  availability_topic: # ?
  qos: 1
  payload_on: "ON"
  payload_off: "OFF"
  payload_available: "online"
  payload_not_available: "offline"
  retain: false

EDIT: A bit of sluthing with mqttfx and I’ve found the state_topic:

state_topic: "gpio_bridge_1/output/led_green"

Still not sure about the availability topic.

@tom_l the availability topic should be gpio_bridge_2/status I believe. It’s just <topic_prefix>/<status_topic>.

1 Like

Thanks flyte.

1 Like

One other thing I have noticed is a steadily increasing RAM use of about 10MB a day. Turns out it is not the mqtt-gpio bridge but is the lxpanel service (or one of its dependants). Seems to be known about but there is no plan to fix it. The work around is to add a cron job to reset it every night:

0 0 * * * DISPLAY=":0.0" lxpanelctl restart

EDIT: Glances also seems to leak slightly. So I now use this for monitoring of the io pis: Remote RPI system monitor

Ah, interesting.

I’ve never run the software on a Pi that has a desktop environment installed, but I’ve got several of them running in my house with year-long uptimes without any memory leaks. Glad to hear I didn’t mess anything up this time!

Yeah, I’m considering removing the GUi. If I VNC in I only end up using the terminal anyway.

I think this is all I need to do (after removing VNC):

sudo apt-get remove --purge x11-common
sudo apt-get autoremove

Some stuff does use X11 libraries despite not being GUI applications, so make sure you double check what’s being removed before you confirm the apt command. It might be better to remove ‘lxde’ or whatever DE you’re using.

Also, a note from earlier that I’ve just noticed. Your pi-mqtt-gpio config should have the line:

status_payload_dead: offline

instead of ‘dead’, as HA won’t understand anything other than online/offline.

I read your other post about that and just finished changing it :slight_smile:

Noted, thanks.

1 Like

Nice work, it’s a little late now but you can use GPIO expanders also do give you more INS/OUTS over I2C, that way you’d only need a single Pi. :slight_smile:

Thanks. Yeah thing’s change pretty quick around here. I still like the configurable supply voltage and GND terminals around every GPIO on my solution (and the screw terminals). Makes it easy to hook up to wired PIRs and smoke sensors.

Can you upload it again?

@djeclemen Sorry, missed this. Here you go:

Hi sorry trying to rap my brain around this. Tow gpio’s dose this broad do. And can you drive single 12v led’s off a “out” ( the led is inside a switch ) thanks .

Sorry I don’t understand what you are trying to say here.


The outputs are the Rpi’s GPIO (3.3V). There is a 12V, 5V or 3.3V (selectable) power supply next to each gpio output. You could drive a general purpose transistor with the GPIO and use that to switch the 12V.

sorry need way more coffee. Was meant to say how meany gpio’s dose it have but have worked it out now thanks. and now under stand to 12v stuff. Thank for the help.