Instructables

A Remotely Programable Relay Controller (Christmas Lights or Home Automation Controller)

Featured

What was that?  A Whats-a-Maja-Thimagig?

Yep - One of those!  This Instructable extends my Arduino Ethernet controller to control a set of up to 6 relays, but that's not the neat bit.  The neat bit is that there is a web based state machine in the AtMega chip so that the relays will operate in whatever sequence with whatever timing you want - all by themselves.

This allows you to have a set of relays connected to the end of a piece of Ethernet cable that can be accessed from a web browser anywhere from your house.

I needed a system to sequence a set of relays to control some Christmas lights around my house this Christmas, as well as to turn on and off a water fountain, so I thought that a simple controller for it would be an AtMega328 chip.  Then I thought about how cool it would be to allow these things to be controlled from a web interface.  A little bit of tinkering later, and this project was born.  I really only needed 4 relays, but as I was doing the layout, I decided that here was enough space for 6!

This project is an autonomous controller, operating a set of 6 relays according to a pre-programmed pattern, over and over again.  If you are impatient, jump to the section on programing the board to see how it is programmed.

In my case, I wanted to control a fountain and some Christmas lights, so my pre-programmed pattern is as follows:

Relay 1 - Front fairy lights
Relay 2 - Fountain Blue Light
Relay 3 - Fountain Green Light
Relay 4 - Fountain Pump

On startup, do the following forever until it is switched off:

Turn on the Fairy lights, the Blue light and run the pump.  After 3 minutes, turn off the blue light, and turn on the Green light.  After 3 more minutes, turn off the fountain and the fountain lights.

This would be defined in the controller as:-

State0;  Relay 1, Relay 2, Relay 4 - time 3 minutes - jump to state 1
State1;  Relay 1, Relay 3, Relay 4 - time 3 minutes - jump to state 2
State2;  Relay 1 - time 3 minutes - jump to state 0

Relay 1 would be connected to the Fairy lights. 
Relay 2 would be connected to the Blue light
Relay 3 would be connected to the Green light
Relay 4 would be connected to the pump.

You can have a completely different program, say for running a gardening facility, where the relays drive various pumps and lights for watering and heating.  Whatever you like!  The uses are limitless!  And the hacking potential is limited only by your imagination.
 
Remove these adsRemove these ads by Signing Up

Step 1: How does the programming work - or What is a state machine?


I am glad that you asked that!

The controller implements a wonderful tool called a state machine.  A state machine is one of the simplest controllers that just knows two things; What the current state is, and what will the next state be?

State machines are driven by a table called a state table.  Essentially what the controller does, is cycle through the state table one state at a time.  Our state table documents the current output settings, and what the next state will be.  In our case, it also specifies the amount of time we wait in the current state.  Here is an example of a state table that toggles the first 4 relay outputs in sequence, waiting for 3 minutes between cycles;

State 0: 1 on, 2 off, 3 off, 4 off, 5 off, 6 off, Wait 3 minutes - goto State 1
State 1: 1 off, 2 on, 3 off, 4 off, 5 off, 6 off, Wait 3 minutes - goto State 2
State 2: 1 off, 2 off, 3 on, 4 off, 5 off, 6 off, Wait 3 minutes - goto State 3
State 3: 1 off, 2 off, 3 off, 4 on, 5 off, 6 off, Wait 3 minutes - goto State 0

The controller runs in an infinite loop, where it knows what the current state is, waits the required time, and then jumps to the next state as dictated by the table. 

You will find state machines in things ranging from traffic lights, through washing machines, through to Industrial controllers.




Step 2: The Hardware

Picture of The Hardware

The basis for my project was my Arduino Ethernet controller board - I simply connected 6 switched relays of some spare I/O lines, and designed a new PCB layout because I enjoy the quiet Zen state when I am laying out a new PCB.

There is nothing stopping you from putting a set of relays onto a piece of stripboard, and running them from an Arduino board with an Ethernet shield.  The only caveat is that the Ethernet shield has to be based on the ENC28J60 chipset.  That is what I support in my code.

Here is the circuit diagram of one of the relay outputs.  You can see that each relay is driven using a BC547 transistor.  There is nothing fancy about the BC547 (except that they cost about $0.03 in quantity)  you can use whatever type of NPN switching transistor you like.  There is a current limiting resistor between the base of the switching transistor and the Arduino output to protect the transistor from damage.  There is also a spike protection diode across the transistor to protect it from the large electrical spike that occurs when the relay is switched off.  There is also a LED installed so that you can visually see the state of the outputs.

You will also find the full schematic diagram for the project here as a PDF.  For more information, have a look at my Ethernet Arduino Instructable.

Update - It was suggested that the protection diodes should be placed straight across the relay - so I have amended the pcb layout, as well as fixed the schematic.  Thanks for that!

Step 3: The Board

Picture of The Board
Ethernet-Relay-Controller.png
Silkscreen-v1.png

Here is the PDF that I used for Toner Transfer PCB manufacturing - As long as you print the sheet out in full size, then you won't have any problems with size.

Also included is the parts overlay, for the top and bottom of the PCB.   As was suggested, I re-wired the protection diode across the coils - so the PCB changed, but not enough to warrant replacing the parts overlays!

There is a small number of surface mount components on the board, but, like the Arduino Ethernet controller, their use is minimal.

I have also loaded up a PNG of the board from KiCad.  It is sooo pretty!

Step 4: The Software


Here is the .pde sketch file.

Just download this sketch and load it into your AtMega328 chip and you are off and running!

The code has almost exhausted the RAM capacity of the ATMega328 - if you decide to make any changes, you will need to be very careful not to let the buffers corrupt the stack space.

All of the code is commented - and should be able to be followed.


Step 5: Construction

Picture of Construction
DSC_2047.JPG

Start assembling the board by installing the components that are mounted on the back of the PCB - The 74HC08, 4 x 18pF Caps, 4 x 10uF caps, 3 x 0.1uF caps.  These are all surface mount, and are surprisingly simple to solder.  It just takes patience.

Next, install the wire jumpers - there are a total of 6 jumpers to install.  I can only make single sided PCBs at home, so this is a small price to pay for convenience.

After that, install the connectors, and IC sockets. Followed by the crystals, voltage regulators, diodes, and transistors.

Next, get a short length of cut off resistor lead, and install the ferrite bead, and the MagJack.  Note that this is a socket with magnetics installed.  Not just an RJ45 socket.

Finish by installing the LEDs, and relays.

There you have it - a competed controller board.

Once you have finished building the board, load the sketch up using the Arduino IDE, and a FTDI USB-232 cable from Sparkfun.  The FTDI cable is connected to the 6 pin header on the right side of the PCB.







Step 6: Parts List


The following parts are needed to construct this project;

Surface Mount parts:

1 x 74HC08 SO16 package
4 x 18pf Caps 1206 package
4 x 10uf/16V caps 1206 package
3 x 0.1uF caps 1206 package

Through lead parts

6 x 470R resistors
11 x 270R resistors
4 x 50R resistors (51 ohm is fine)
3 x 10K resistors
1 x 2k7 resistor
6 x BC547 transistors
1 x 78l05 Voltage regulator
1 x 78l33 Voltage Regulator
1 x 16Mhz HC18 crystal
1 x 25Mhz HC18 crystal
7 x 1N4004 diodes
2 x 3mm blue LEDs
6 x 5mm Yellow LEDs
1 x 5mm red LED
1 FX18 Ferrite bead
1 x Microchip 28J60 Ethernet controller (DIP)
1 AtMega 328 microcontroller (DIP)

6 x 3 pin 5mm spacing screw connectors
1 x 2 pin 5mm spacing screw connector
1 x 6 pin header 0.1 inch
1 x 4 pin header 0.1 inch
1 RJ-45 Mag Jack (From Sparkfun)
http://www.sparkfun.com/commerce/product_info.php?products_id=8534

1 x 4 way dip switch (optional)
1 x small pushbutton
2 x 28 pin IC sockets

6 x Jaycar FRM1-1C1 SPST 12V DC relays

Ethernet Relay Controller PCB


Step 7: Using the Controller Manually

Picture of Using the Controller Manually
OK - Now that you have the controller built, and the software installed, just turn it on.

The default program will run.  It just cycles through all of the outputs, alternately turning them on and off.  It does this once per second.

Plug the board into your computer, make sure that your computer is on the 192.168.1 network, and assuming that you didn't change the sketch to supply a new address, connect your web browser to http://192.168.1.2.  I use firefox - I have not tested it with Opera, Chrome, or IE yet.

The screen shown as the first screen in this step will appear.

First things first, there is a timer running in the controller all of the time - every second, it refreshes the relay to whatever the program has.  to use the relay board in manual mode, you will have to turn off the timer - just click on the Timer Off link - and it will stop.  The fact that the timer is stopped will be written to the EEPROM, so when the board is turned on next, the timer will be off.  You will need to explicitly turn on the timer again to get the board to run automatically.

Next, you can toggle the state of the relays, simply by clicking on the corresponding toggle command.  Operation is instantaneous, so the output will change as soon as you select it!

Have a play with the options, until you are comfortable with how it works.

Step 8: Setting up a Program

Picture of Setting up a Program
Modify.jpg
Now - we can set up a program in the controller.

Before we do that, lets turn on the timer again, so that the automatic functions can operate.

Then, select "Program 0-6" at the top of the screen to view the current program states 0 through 6. The screen below will be displayed.

The program shown uses 2 states;

State 0 which turns on relays 1 3 & 5 for 1 second then jumps to state 1
and
State 1 which turns on relays 2 4 & 6 for 1 second then jumps to state 0

Round and round it goes....... alternating every second.

Lets modify it so that state 0 turns on relays 1 3 & 5 for 10 seconds, then goes to state 1.

Just type 0 in the state selection box at the bottom and push 'Modify". This will cause the modify screen to be shown. It is also shown below.

In the modify screen you are shown the state (or step) that you are changing, and you can alter the wait time (between 1 and 65000 seconds), the step to jump to (between step 0 and step 19, and what outputs to turn on for this step.

Just make your changes by entering 10 for the wait time, 1 for the next state, and select relays 1, 3 & 5. Then push the Modify button - Your step will then be saved, and you can re-select the "Program 0-6 tab" to see the whole program.

The steps will automatically be saved into EEPROM on the micro, so that your program will run automatically by itself as soon as the board is powered up.


Step 9: Conclusion and next steps


There you have it - an extremely useful little board.

With 20 program steps available and delay timers of up to 65000 seconds (a little over 18 hours), there are almost limitless possibilities to what the board can do...

And - finally, with great power comes great responsibility (tm) - You will have noticed that there was no login option - there is no security - don't connect this to the big bad Internet and expect people to not fiddle.  The board does not understand routing anyway, so you would need to NAT any connection from the board.

Also - it is possible to setup state 0 - turning off all relays - and jumping to state 0 - Guess what that does???  Yep - nothing - again and again and again - but that was what you typed in :-)  But - remember , you can always type in a new program.

Where to next?  Well - I am glad that you asked that - I have a couple of other jobs to do around the house (an my mother in laws house as well) - but when they are finished, I will be providing an input module - that should extend the project to provide Programmable Logic Controller functionality - such as - If Input 3 is on, and 4 seconds have passed, dont go to step 5, go to step 9 instead.  There is a 4 pin expansion connector in the middle of the board fo that capability to be just plugged in....  Given time we shall see.

I hope you enjoy building and using it as much as I enjoyed designing it.

Finally, if you really want a kit for the project - or completed boards, send me a message - I will see what level of popularity the project has and will provide kits if there is sufficient interest.
evilcomputer3 months ago
Hello sir, i'm having problem making the pcb, can i ask you to upload the kicad pcb project files please.
rmartin1911 months ago
Sorry for the noob-ish question, but how would one add a clock module (e.g. ds1302) to this board?
drj113 (author)  rmartin1911 months ago
Hi,

There is no such thing as a Noob-ish question - Everybody learnt at some stage :-)

You could simply add a DS1302 to the board by looking at something like my later clock designs - they use a DS1302. Essentially there are three wires that get connected from the clock module to the AtMega chip. You also need to include the DS1302 library and write some software, but thats not impossible.

I am a little flat out with the clock business at the moment to spend the time to modify the project - but I would encourage you having a play - You can even find space on the board by removing the 4 way dip switch that is not used, and using that space to place the DS1302.chip.

Let me know how you get on.

Doug
farticus drj1136 months ago
Do you need a clock if you can access an NTP server?
http://arduino.cc/en/Tutorial/UdpNTPClient

drj113 (author)  farticus6 months ago
That's a definite thought - but you should also cater for the possibility that the network is isolated.
francisroan11 months ago
Hi how can i connect this to the "internet" and not the local home network ..What if i want to access this from anywhere in the world..?
irowe francisroan7 months ago
You have to go into your wireless router settings and port forward to the local address.
Example: your IP address is 50.145.78.99 and the arduino is 192.168.1.2.
You set the router to forward port 8081 to -> 192.168.1.2.
Now when you are anywhere in the world you would use the address: 50.145.78.99:8081 and you would see the arduino control page just like you would at home!
Hi There! This is exactly what i have been looking for!! Thankyou.

however...

having built the board successfully, i am having problems with the programming.

firstly i simply tried using my current version (0020) of the arduino software to burn the file however it quickly came up with errors, so after reading through previous posts i see that you were using the 0017 version, so i went and downloaded it, tried it and found that it apparently dosnt support the UNO board? so... i tried with my origonal version (0020) and tried changing the file names of the library in the code, it got a few steps further but then came up with these errors:

sketch_mar25a:89: error: 'Ethernet' does not name a type
sketch_mar25a.cpp: In function 'void setup()':
sketch_mar25a:119: error: 'es' was not declared in this scope
sketch_mar25a:127: error: 'PHLCON' was not declared in this scope
sketch_mar25a.cpp: In function 'void loop()':
sketch_mar25a:227: error: 'es' was not declared in this scope
sketch_mar25a:283: error: 'IP_PROTO_P' was not declared in this scope
sketch_mar25a:283: error: 'IP_PROTO_ICMP_V' was not declared in this scope
sketch_mar25a:283: error: 'ICMP_TYPE_P' was not declared in this scope
sketch_mar25a:283: error: 'ICMP_TYPE_ECHOREQUEST_V' was not declared in this scope
sketch_mar25a:289: error: 'IP_PROTO_P' was not declared in this scope
sketch_mar25a:289: error: 'IP_PROTO_TCP_V' was not declared in this scope
sketch_mar25a:289: error: 'TCP_DST_PORT_H_P' was not declared in this scope
sketch_mar25a:289: error: 'TCP_DST_PORT_L_P' was not declared in this scope
sketch_mar25a:290: error: 'TCP_FLAGS_P' was not declared in this scope
sketch_mar25a:290: error: 'TCP_FLAGS_SYN_V' was not declared in this scope
sketch_mar25a:294: error: 'TCP_FLAGS_P' was not declared in this scope
sketch_mar25a:294: error: 'TCP_FLAGS_ACK_V' was not declared in this scope
sketch_mar25a:298: error: 'TCP_FLAGS_FIN_V' was not declared in this scope
sketch_mar25a.cpp: In function 'uint16_t print_program_page(uint8_t*, uint8_t)':
sketch_mar25a:445: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a:448: error: 'es' was not declared in this scope
sketch_mar25a:452: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a:476: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a:492: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a.cpp: In function 'uint16_t print_manual_page(uint8_t*)':
sketch_mar25a:514: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a:517: error: 'es' was not declared in this scope
sketch_mar25a:521: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a:540: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a:554: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a.cpp: In function 'uint16_t edit_program_page(uint8_t*, uint8_t)':
sketch_mar25a:578: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a:582: error: 'es' was not declared in this scope
sketch_mar25a:586: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a:604: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a:616: error: 'TCP_CHECKSUM_L_P' was not declared in this scope
sketch_mar25a:627: error: 'TCP_CHECKSUM_L_P' was not declared in this scope


i am afraid im one of these "hardware blokes" and have little knowledge of programming.

any help with this would be much appreciated!
ynos1 year ago
Thanks for a nice instructable. I am trying to build the same project and my concern is the power supply. In my understanding the relays require 12V and the arduino/enc28j60 requires 5v and 3.3v respectively. How should I go about building/purchasing the power supply if I want to have one power supply to power this project. I suppose the voltage is 12V but how about the ampere or wattage rating.

Also I am planning to use this (HFJ11-2450E-L12RL) - http://docs-asia.electrocomponents.com/webdocs/106e/0900766b8106e81d.pdf, will this work?

Thanks in advance.
mantux1003 years ago
on schematic you wrote that the controler is Atmega8 and on parts list you write that it's AtMega 328 and that gate ic is 74ls08 but on pats list you write 74HC08 . WTF????
drj113 (author)  mantux1003 years ago
The parts list is definitive. The Micro is definitely an AtMega328, and the gate is a HC part.
can i use mega168 instead of mega328?
Hey, I solved the problem of the ferrite bead by taking one out of an old dial up modem board.
and finally the board worked completely
i programmed the atmega and it runs the relays on and off as you said here .
and when i connect the power
the yellow led in the RJ-45 lights on . and when i connect the Ethernet cable the green one flashes many times and when i press the reset switch . both yellow and green flashes 2 or 3 times then start working again.
My BIGGEST PROBLEM HERE !! >> is that i can't open the webpage of the board
with the ip"192.168.1.2" . i tried many times with different cables. i tried to connect it directly to the laptop and another time to the router.
but at both times the webpage cannot be opened . !!!
i tried to re-program the chip with changing the ip address in the sketch .
and also i can't open it .
I"M SO HOPELESS after all that working and the board works fine . i can't control it :SSS
PLEASE HELP ME
drj113 (author)  mahmoudmorsy1 year ago
That can be really frustrating.

Are you able to ping the IP address? What output does executing ARP -a provide?

Doug
I have the same problem...but I can ping the IP address but cant open the webpage. can you tell me what is the problem?
I tried to ping the ip from cmd . and it doesn't give me "reply from ..."
and when i connect it directly to the computer . it gives me a message "local area connection doesn't have a valid ip 'configuration' or 'address' i can;t remember exactly.
by the way . I can't understand what is the "ARP-a"???
i can send you a video of the board while it is working . but without controlling it from my computer . just leds, relays , and every thing on the board is working fine but still my problem isn't solved...
jajen1 year ago
Can you specify type of rj45 MagJack use this project? Thera are a lot of rj45 MagJack and I dont know which one should I use.
It's this one
it should have magnetics
I have made this project and one of my faults was that i get the wrong RJ45
so this one should works as it is wriiten in the parts list as Mr. Doug said :)
http://www.sparkfun.com/commerce/product_info.php?products_id=8534

Mahmoud Morsy
Today the electronic components shop received an Ethernet MagJack it's not exactly like yours but the same idea of magnetics and its using is for ethernet interfaces.
I bought it and soldered it instead of the old one
but i got the ENC28j60 hot and the board also can't ping
i revised all connections and solders for any shortage between wires or any thing wrong but i didn't find any thing wrong . so i don't know what to do now :S
drj113 (author)  mahmoudmorsy1 year ago
That is bad news.

The ENC chip getting hot could mean that it has been damaged.

The project does *need* the magjack. Without it, it probably won't work.

If you like, you can post your project to me here in Australia and I will see if I can make it work for you.

Doug
I Can adjust it to 9V bec. it is variable adapter.

Also I don't know if this is a problem or not . I didn't find your RJ45 in the component list in my country . But I found this
http://ram-e-shop.com/oscmax/catalog/product_info.php?products_id=1415
and i connected two 3mm leds instead of the RJ45 leds
{The engineer in the shop said that they are the same your RJ45 and this one}

I hope I Could do this :( .. But I'm here in EGYPT . so it is too hard to send it to you
But i Can easily Send You Pictures and Videos for the project. and I appreciate you a lot for helping me

M.Morsy
So Could be the problem in the input current
I'm Using a 220V-AC to 12V-DC ADAPTER 1000mA
..
drj113 (author)  mahmoudmorsy1 year ago
That will work ok although it is a bit high voltage - ideally you should use about 9V.

Would you like to send your project to me here in Australia so I can see if I can find out what the problem is?

Doug
I found that the input is 5V with the output 3.3V on the component "78l33"
and input 10V with output 5V on the component "78l05"

and when i remove the ATMEGA chip and the enc28j60 from the board . the component doesn't get hot . but while i'm connecting the 2 chips on board . it gets hot...
drj113 (author)  mahmoudmorsy1 year ago
The 78l05 will be getting hot, as it will be converting the 10V to 5v, producing between 1/2 and 3/4 W of heat.

The 78L33 should not be hot.
HeY !!
I noticed something . that the component U4 : 78L33 is getting hot while the board is powered on. Is that normal or there is something wrong in the board??
drj113 (author)  mahmoudmorsy1 year ago
That component should not be hot at all - it is only supplying about 50mA with 2V across it - so it would seem that there is some excessive load.

Do you have a multimeter? If so, you could verify the voltage out ofthe 3.3v regulator.

Doug'
Sorry for my poor English , but i can't understand what is the crossover cable connection to my pc??
it's always flashing while i'm connecting the plug into it , even i'm not connecting it to the router or computer. and connecting one side only !.


can the problem be in the soldering or components ? . or the problem is in the ip configuration only??
drj113 (author)  mahmoudmorsy1 year ago
It could be the soldering - it may also be the IP configuration.

The activity light flashes when it receives a packet. Are you able to just connect it - with a crossover cable to your pc?

Doug
Sorry for my poor English , but i can't understand what is the crossover cable connection to my pc??
Here it is
I do what you have said . i turned off the wi-fi
and connected the computer and the circuit directly to the switch
and this is the ip configured from cmd
=================================================
Microsoft Windows [Version 6.2.9200]
(c) 2012 Microsoft Corporation. All rights reserved.

C:\Users\MOORSY>ipconfig

Windows IP Configuration


Wireless LAN adapter Local Area Connection* 12:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :

Ethernet adapter Ethernet:

Connection-specific DNS Suffix . :
Link-local IPv6 Address . . . . . : fe80::3004:1e43:d042:d64f%13
IPv4 Address. . . . . . . . . . . : 192.168.1.2
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 192.168.1.1

Wireless LAN adapter Wi-Fi:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :

Tunnel adapter isatap.{BCE244F2-A4FF-4815-8FB4-D22D5FA36027}:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :

Tunnel adapter Teredo Tunneling Pseudo-Interface:

Connection-specific DNS Suffix . :
IPv6 Address. . . . . . . . . . . : 2001:0:9d38:6ab8:3c78:16ee:3f57:fefd
Link-local IPv6 Address . . . . . : fe80::3c78:16ee:3f57:fefd%17
Default Gateway . . . . . . . . . : ::

C:\Users\MOORSY>
===================================================
and when i ping the circuit board which i changed its ip address in the sketch to "192.168.1.5"

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

C:\Users\MOORSY>ping 192.168.1.5

Pinging 192.168.1.5 with 32 bytes of data:
Reply from 192.168.1.2: Destination host unreachable.
Reply from 192.168.1.2: Destination host unreachable.
Reply from 192.168.1.2: Destination host unreachable.
Reply from 192.168.1.2: Destination host unreachable.

Ping statistics for 192.168.1.5:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),

C:\Users\MOORSY>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

So what i have to do now??
drj113 (author)  mahmoudmorsy1 year ago
Hmm - Thats really weird.

When you ping, do you see the activity light on the board flashing with each ping?

Doug
it's always flashing while i'm connecting the plug into it , even i'm not connecting it to the router or computer. and connecting one side only !.


can the problem be in the soldering or components ? . or the problem is in the ip configuration only??
Ahh and btw this screenshot when i typed the ip in IE and didn't work the i pressed the fix problem button . it gives me this screen
ip.png
OKay . Here is a copy of my ipconfig from cmd

====================================
Microsoft Windows [Version 6.2.9200]
(c) 2012 Microsoft Corporation. All rights reserved.

C:\Users\MOORSY>ipconfig

Windows IP Configuration


Wireless LAN adapter Local Area Connection* 12:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :

Ethernet adapter Bluetooth Network Connection:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :

Ethernet adapter Ethernet:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :

Wireless LAN adapter Wi-Fi:

Connection-specific DNS Suffix . :
Link-local IPv6 Address . . . . . : fe80::a093:7370:5a4e:a777%12
IPv4 Address. . . . . . . . . . . : 192.168.1.2
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 192.168.1.1

Tunnel adapter isatap.{BC39A4FF-1F08-43E4-9D0D-02CC91628AF0}:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :

Tunnel adapter Teredo Tunneling Pseudo-Interface:

Connection-specific DNS Suffix . :
IPv6 Address. . . . . . . . . . . : 2001:0:4137:9e76:49d:481:d67d:80d0
Link-local IPv6 Address . . . . . : fe80::49d:481:d67d:80d0%17
Default Gateway . . . . . . . . . : ::

Tunnel adapter isatap.{97F50E96-CF33-4F76-B691-FAF7A543FDCC}:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :

C:\Users\MOORSY>
=================================================


BTW . i'm using windows 8
and i tried to open it from my android phone through wireless and also didn't work.\

when i ping board ip . it gives me this
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

Microsoft Windows [Version 6.2.9200]
(c) 2012 Microsoft Corporation. All rights reserved.

C:\Users\MOORSY>ping 192.168.1.8

Pinging 192.168.1.8 with 32 bytes of data:
Reply from 192.168.1.2: Destination host unreachable.
Reply from 192.168.1.2: Destination host unreachable.
Reply from 192.168.1.2: Destination host unreachable.
Reply from 192.168.1.2: Destination host unreachable.

Ping statistics for 192.168.1.8:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),

C:\Users\MOORSY>

>>>>>>
and sometimes it gives me "Destination net unreachable."
drj113 (author)  mahmoudmorsy1 year ago
It looks like you are not actually connected to the PHYSICAL network.

Ethernet adapter Ethernet:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :


You have a wireless connection.

Wireless LAN adapter Wi-Fi:

Connection-specific DNS Suffix . :
Link-local IPv6 Address . . . . . : fe80::a093:7370:5a4e:a777%12
IPv4 Address. . . . . . . . . . . : 192.168.1.2
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 192.168.1.1

How do you have the board connected to your network?

I would hard code your PC to have a 192.168.1.2 address, connect the laptop to a switch, connect the board to the same switch and see how that went.

Disable your wireless in the meantime to make sure that it is not conflicting.

Doug
I tried to ping the ip from cmd . and it doesn't give me "reply from ..."
and when i connect it directly to the computer . it gives me a message "local area connection doesn't have a valid ip 'configuration' or 'address' i can;t remember exactly.
by the way . I can't understand what is the "ARP-a"???

i can send you a video of the board while it is working . but without controlling it from my computer . just leds, relays , and every thing on the board is working fine but still my problem isn't solved...
drj113 (author)  mahmoudmorsy1 year ago
Ok - it seems as though you may not have your local network configured correctly.

Can you let me know the IP of your computer and your router?

It is best if you hard code your IP for your network and computer, as opposed to using a DHCP address from your router.

You also need to make sure that your computer is on the 192.168.0.x network

Doug
Pro

Get More Out of Instructables

Already have an Account?

close

PDF Downloads
As a Pro member, you will gain access to download any Instructable in the PDF format. You also have the ability to customize your PDF download.

Upgrade to Pro today!