Jarvis Add-on #1


United Kingdom

Robot's needed be mobile, walking, talking beings... so I plan to do something I doubt has been thought of before... I'm turning my staircase in to a robot:) Well, JARVIS is controlling it to be more specific. (Note: The title may say Add-On #1 but it's actually idea #127 - yes there really have been 126 other ideas before this one, and more since too... needless to say my ideas don't always come to light)

User-inserted image

The History: When walking up or down the staircase I want something that looks insanely awesome... So, I had the idea of fitting LED strip to the underside of the stair rail, routered in to the rail so it is not visible at all until turned on and then just a wash of light coming from the rail. Easy to do, it doesn't even need an EZ-B or ARC... You know what, that's not insanely awesome, it's just pretty awesome... Not good enough for me so back to the drawing board.

What if it looked kinda like runway lights when they turn on, you know one pair either side of the runway come on, then the next, then the next and so on. That would be pretty damn awesome right? But still not quite insanely awesome...

What if they were automatic? Pretty cool right? So we have cool and awesome but not insanely awesome...

What if they were totally automatic, direction dependent? You know, get to the bottom of the stairs and the trail lights from bottom to top. Get to the top and it lights top to bottom. Yeah that's pretty insane, we're on the right tracks now.

But what about turning off? What about changing your mind about going up?.. Sorted... ARC can do that...

So something insanely awesome? You tell me. I think so:)

The Plan: Take sections of LED strip, fix to the underside of the stair rail, sensors top and bottom to detect movements, LED strips switched by the Digital ports of the EZ-B, Sharp IR sensors for the proximity detection, EZ-Script to set the dance in motion...

User-inserted image

However since drawing it up I have found (thanks to Tony) some better IR sensors which would work much better and be less demand on ARC. So, as always, this is a work in progress, it will be adjusted throughout but it's a start.

What will happen is Sensors 1, 2 & 3 (3 is needed for coming down from up) will be triggered, EZ-Script will detect this, turn each section one one at a time with slight delay between. When the other sensor the other end (i.e. Sensor 2 if coming from downstairs or Sensor 1 from up) is triggered it knows you're done and will turn off the lights after a small delay (3 or 4 minutes).

If you trigger Sensor 1 then Sensor 1 again it will cancel the action.

If Sensor 1 is triggered and neither Sensor 1 or Sensor 2 within a minute or two then it alerts of a problem.

Photos, schematics, scripts etc. all will follow:)

By — Last update


Upgrade to ARC Pro

Subscribe to ARC Pro, and your robot will become a canvas for your imagination, limited only by your creativity.


This might also work for night lighting of pathways from room to room.

United Kingdom

Yeah, it can be used for a bunch of different applications, also energy saving to only light areas that are occupied is one I thought of. My house isn't big enough for that though (it's no bigger than I need - it's too big for me to clean as it is).

Hopefully this will also inspire others to think up awesome ways to use the EZ-B or to use this idea. I have another plan for external lighting that will be awesome (but will be kept under wraps for now).

I forgot to mention, this will be using EventGhost to know when it is dark enough to illuminate the strips too, which should hopefully demonstrate the telnet abilities of ARC and how simple it can be to link ARC to other applications.


Cool ideas , I couldnt do that with my staircase because it is carpeted , there doesn't look like a good place to hide lighting. It would be cool for lights to turn on when you walk into a room without having to turn the lights on. Then maybe a verbal command "turn out the lights" or "dim lights.


Man, you throw in a fog machine and you could be a space invader or a super something every time you went up and doe your stairs. Have you thought of using pressure plates?

United Kingdom

I can get away with IR sensors since my stairs have had no carpet on for the best part of three years now... So I can fit them and then hide them in the carpet:) I hadn't thought of pressure plates, and now you have me thinking:) It would be cheaper and tidier but the foot of the stairs would be the problem (no way I could fit a pressure plate there, it would need to be on the first stair, which isn't when I want it to start up).

@Josh, I already have automatic lighting through RF modules and an RFXCON RXFTRX433. Currently it's only activated via voice, time, web page, tablet/smart phone and the original switches but soon it'll know when I'm home (based on detection of bluetooth devices). This isn't done with the EZ-B for the simple fact it's mains voltage and I don't want to mess with that if I can help it.


Hello Rich, have you think about using an analog photo-eye at one end of the stairs ? This way you only have one sensor. It not perfect but it can be easier than using a lot of sensors.


Do you have a rail on your stairs? If so I got some ideas to run by you that's relevant to the topic.

United Kingdom

Not at the moment I haven't...

Excuse the mess, it was taken while decorating/building.

User-inserted image

Pretty much a blank canvas for the entire staircase.


I like the idea of the lighting behind the furniture. That gives guys like a a place to hide some cool lighting. What would be really cool is if the light moved along with you. Maybe one stair in front of the one that you have a foot on and one behind. A gradual fade on then off is awesome.


That's actually what I was thinking for the rail, you get the steady lights so you can see on the stairs them self then you have that kind if light action with the railing.

United Kingdom

A few bits and bobs of EZ-Script which will be used for this...

Currently there is an external photocell fitted for the outside light. The photocell is RF and Jarvis already aware of it's status. On change EventGhost picks up the event and a simple Python Script in EventGhost writes this change to the MySQL database. A PHP web page has also been already written which will lookup the data in the MySQL database and display a simple "On" or "Off" on the web page. A further overview web page exists however this holds a lot more information therefore would require parsing for use in ARC. The simple PHP page photocellstatus.php was the simplest option.

I'll post the PHP code and Python Scripts when I get home and have the chance to tidy them up a little.

# Daylight Check
# External RF Photocell status on

# Periodically check external photocell to enable or disable lighting
IF(HTTPGet("") = "On")
  $lightsactive = 1
  $lightsactive = 0

This now checks for the status every 10 seconds and is stored in ARC as $lightsactive. This can now be used to enable other scripts to only work when either dark (or light) outside.

With that running and ARC aware of the photo cell status we can now look at the next part of activation. Time based. While it may not necessarily be used I will have it there just in case I change my mind.

# Time Check
# Disable lights during specified time over night

# Lights inactive between 11.30pm and 5.30am
IF($hour > 23 and $minute > 30 or $hour < 5 and $minute < 30 or $hour < 5)
  $lightsenabled = 0
  $lightsenabled = 1

This one will check if the time is between 23:30 and 05:30, if it is then it sets $lightsenabled to 0 otherwise $lightsenabled is set to 1. At the end it waits for the minute to change (i.e. a different method of waiting or sleeping for 1 minute) and loops back to the start again.

Now we have; $lightsactive $lightsenabled

Now we have the "dependencies" on whether the lights should work we can move on to the sensors and getting the lights working...

For the lights to work, $lightsactive and $lightsenabled both need to be on, or set to a 1. The sensor must also be triggered, since there will be two sensors (originally three sensors however I think I may get away with using only two) in this case and the direction of the dance depends on which sensor is triggered we need to periodically check for triggering of each sensor and then run the correct sequence.

# Trigger Code

# First ensure that $lightsactive and $lightsenabled are set to 1
IF($lightsactive = 1 and $lightsenabled = 1)
  # Check if any are triggered and run sequence if they have been
  IF(GetDigital(D0) = 1)
    ControlCommand("Script Manager", ScriptStart, "Sequence1")
  ElseIF(GetDigital(D1) = 1)
    ControlCommand("Script Manager", ScriptStart, "Sequence2")

Sequence1 & Sequence2 will be the scripts to illuminate the lights in the correct order, check for triggering of the sensors again to determine the direction the lights turn off, timing of the lights etc.

The bottom of the staircase (Sensor 1) takes priority over Sensor 2. This has assumed the sensors are digital on/off type (or pressure plates) connected to D0 and D1 and will, on being triggered, supply +5V to the signal pin of the port(s).

The code for Sequence 1 and Sequence 2 will follow another time. Hopefully the above does two things, 1. flags up any errors I may have made (which happens) and 2. explains a few of the commands and built in variables in EZ-Script and how they can be used. It also means I can work on scripts while at work and have them ready to copy and paste in to ARC when I get home:) But shhh... don't tell the boss!:D


One additional feature you might want to consider at some point is to tie your stairway lights in to some detectors and turn them on if a smoke is detected leading the way to an exit in case of a fire. (Heaven forbid!) A smoke detector at the top of a stairwell is not a bad idea anyway as smoke rises.

United Kingdom

Smoke detectors are already installed;) But they don't turn the lights on... yet (cool idea though and easily added through Jarvis' current set up, I may add that in).

The main point in this project/add on is to use the EZ-B and ARC. I've wanted to use it as part of Jarvis for a while and just needed to find something that required (or could do with) a little bit of extra help from the EZ-B:)