more G-Labs products

Author Topic: Arduino Ethernet Switches  (Read 1821 times)

July 11, 2015, 11:29:22 PM
Read 1821 times

enterprised

  • ****
  • Information
  • Sr. Member
  • Posts: 101
  • Things are only impossible until they are not
Just a little fun project with some spare components I had laying around.

Arduino Ethernet Relay Controller

This is based on the original Arduino Switches code for HomeGenie and some of the freely available Arduino code.

Hardware Requirements:
  • Arduino Uno, Mega 2560 or equivalent
  • Ethernet Shield W5100 for Arduino Uno, Mega or equivalent
  • JBtek 8 Channel DC 5V Relay Module
  • Patch cable 200mm male to female
A very simple project, no soldering required.

The HomeGenie part is a series of virtual switches activating the Arduino over Ethernet,

Attached code for Arduino is based on the Arduino Mega 2560 and uses pin 31 to 38.

Ethernet shield code is based on DHCP IP address assignment.

The Arduino relays are controlled via a simple API.
Example below for relay 1
 
This project has potential for further development to include sensors and messaging. I may work on this, but if anybody else wants to jump in, you are very welcome to do so.

NOTE: The attached zip file contains both .INO file for Arduino .HGX file for HomeGenie
« Last Edit: July 29, 2015, 03:40:29 AM by enterprised »
4a 75 73 74 20 61 20 70 65 72 73 6f 6e 20 68 61 76 69 6e 67 20 66 75 6e 20 77 69 74 68 20 68 6f 6d 65 20 61 75 74 6f 6d 61 74 69 6f 6e
enterprised == guytpetj

July 17, 2015, 08:58:30 AM
Reply #1

KaZe

  • ****
  • Information
  • Sr. Member
  • Posts: 219
Hi!

With this program do not keep growing use of the memory of the homegenie service?

July 17, 2015, 11:47:19 PM
Reply #2

enterprised

  • ****
  • Information
  • Sr. Member
  • Posts: 101
  • Things are only impossible until they are not
I have HomeGenie running this on a Rasberry Pi 2 and have not seen an increase in memory usage over the last week.
4a 75 73 74 20 61 20 70 65 72 73 6f 6e 20 68 61 76 69 6e 67 20 66 75 6e 20 77 69 74 68 20 68 6f 6d 65 20 61 75 74 6f 6d 61 74 69 6f 6e
enterprised == guytpetj