CM3-Home

Dry contact inputs

The CM3-Home board has two inputs designed for mechanical contact like switches or push-buttons. This article illustrates how to use them.

The contacts are available on screw terminals. Each contact can be closed on a single common line.

The input lines are opto-isolated from the CPU side and are in the same "electrical domain" of the RS485 ports.

The GPIOs used are:

  • GPIO 28: Left side contact #1. When closed the GPIO level is low
  • GPIO 29: Right side contact #2. When closed the GPIO level is low

Python example

This example reads the input #1 and #2 state and turn-on the left or right relays when closed.

import RPi.GPIO as GPIO
import time

INP_LEFT=28
INP_RIGHT=29
RELAY_LEFT=21
RELAY_RIGHT=22


GPIO.setmode(GPIO.BCM)
GPIO.setwarnings(False)
GPIO.setup(INP_LEFT,GPIO.IN)
GPIO.setup(INP_RIGHT,GPIO.IN)
GPIO.setup(RELAY_LEFT,GPIO.OUT)
GPIO.setup(RELAY_RIGHT,GPIO.OUT)

while True:
    if GPIO.input(INP_LEFT):
        GPIO.output(RELAY_LEFT,GPIO.LOW)
    else:
        GPIO.output(RELAY_LEFT,GPIO.HIGH)

    if GPIO.input(INP_RIGHT):
        GPIO.output(RELAY_RIGHT,GPIO.LOW)
    else:
        GPIO.output(RELAY_RIGHT,GPIO.HIGH)

eShop

EUR 130.00


CM3-HOME-B - CM3-Home board basic (only mother board)

CM3-Home is a Raspberry Pi Compute Module 3 motherboard designed to provide a reliable Home Automation hardware equipped with a wide range of electrical interfaces

  • NOT INCLUDED:
    • TP-BUS, LIGHT-BUS, RS485 (one instead of two), Yarm 868 MHz radio module (available on CM3-HOME-F)
    • Wifi module (Product # WIFI-2) amd antenna (Product # AN-WIFI-01)
    • The Raspberry Compute Module 3 or 3L (Product # CM3L)
    • MicroSD (Product # MICROSD8G-E)
    • Case (Product # CM3-HOME-CASE)
| Product description || CM3-Home catalog |

EUR 290.00


CM3-HOME-F - CM3-Home board full (only mother board)

CM3-Home is a Raspberry Pi Compute Module 3 motherboard designed to provide a reliable Home Automation hardware equipped with a wide range of electrical interfaces

  • NOT INCLUDED:
    • Raspberry Compute Module 3 or 3L (Product # CM3L)
    • Yarm antenna (Product # YARM-ANT-01)
    • Case (Product # CM3-HOME-CASE)
    • MicroSD (Product # MICROSD8G-E)
  • Included:
    • WiFi module (Product # WIFI-2)
    • WiFi antenna (Product # AN-WIFI-01)

For more info please visit the product description page

| Product description || CM3-Home catalog |

Sergio Tanzilli
System designer, software developer and company co-founder
tanzilli@acmesystems.it
Webpages: https://www.acmesystems.it and http://www.tanzolab.it
Github repository: https://github.com/tanzilli and https://github.com/acmesystems