Active TopicsActive Topics  Display List of Forum MembersMemberlist  Search The ForumSearch  HelpHelp
  RegisterRegister  LoginLogin
PowerHome Programming
 PowerHome Messageboard : PowerHome Programming
Subject Topic: Entry/Exit Sensing Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
TonyNo
Moderator Group
Moderator Group
Avatar

Joined: December 05 2001
Location: United States
Online Status: Offline
Posts: 2889
Posted: August 10 2005 at 23:21 | IP Logged Quote TonyNo

A new project!

I'm currently testing an idea that I had for using Hawkeye motion sensors and Multi-X to tell when someone enters or exits a room. Not just motion, but direction of the motion (in or out).

More later as the test continues!
Back to Top View TonyNo's Profile Search for other posts by TonyNo Visit TonyNo's Homepage
 
krommetje
Super User
Super User
Avatar

Joined: December 29 2004
Location: Netherlands
Online Status: Offline
Posts: 695
Posted: August 11 2005 at 04:22 | IP Logged Quote krommetje

TonyNo wrote:
A new project!I'm currently testing an idea that I had for using Hawkeye motion sensors and Multi-X to tell when someone enters or exits a room. Not just motion, but direction of the motion (in or out).


I am eagerly awaiting your tests... I can imagine how you'd do it with 2 sensors... If you would place them in a 180degrees angle of eachother and combine the commands with a macro.... Am I in the right direction?

Peter
Back to Top View krommetje's Profile Search for other posts by krommetje Visit krommetje's Homepage
 
TonyNo
Moderator Group
Moderator Group
Avatar

Joined: December 05 2001
Location: United States
Online Status: Offline
Posts: 2889
Posted: August 11 2005 at 20:26 | IP Logged Quote TonyNo

So far, so good!

Yes, they are side-by-side. I also masked off all but the center 1/8" of the lenses with electrical tape to narrow their field of view.

This is economical due to the occasional sales x10.com has on these.

Now I just need to come up with some good logic to tie this in with general motion for better light control and such. I hate when I go into a room and the light goes out if I linger...
Back to Top View TonyNo's Profile Search for other posts by TonyNo Visit TonyNo's Homepage
 
krommetje
Super User
Super User
Avatar

Joined: December 29 2004
Location: Netherlands
Online Status: Offline
Posts: 695
Posted: August 12 2005 at 10:05 | IP Logged Quote krommetje

Well let me think, perhaps if you could make a distinction between which hawkeye sends its code first.... when hawkeye 1 sends first and then 2 then the motion is outgoing, when the other way around the motion is incoming or if you could read the time of both codes changed and substract them... if the outcome is positive then the motion is incoming, when negative, then the motion is outgoing e.g. or make a macro which AND checks which code was received first AND checks the receival-time!

This would still however not solve the problem when you linger... that would take some more thinking. a timer and reset of the timer when you are moving around would be a solution, if you'd use a GV which is 1 when you are at home then either one of the hawkeyes would be sufficient to change the timer....

This all is just a brainstorm...

Peter

Edited by krommetje
Back to Top View krommetje's Profile Search for other posts by krommetje Visit krommetje's Homepage
 
TonyNo
Moderator Group
Moderator Group
Avatar

Joined: December 05 2001
Location: United States
Online Status: Offline
Posts: 2889
Posted: August 12 2005 at 10:27 | IP Logged Quote TonyNo

Oh, I have the code done to count how many people are in a room. That is where MultiX comes in. You have the logic correct. 1-then-2 is "in" (count+1) and 2-then-1 is "out" (count-1).

MultiX makes it easy. The Hawkeyes are set up on HC F and UC's 1/2 and 3/4. A MultiX query of ph_multix("F", 1, 2) that returns "F0102F0302" means "in" and "F0302F0102" is "out".

I was referring to adding this to the motion sensor logic already in place. Maybe to turn the light off immediately when the room count goes to zero.
Back to Top View TonyNo's Profile Search for other posts by TonyNo Visit TonyNo's Homepage
 
krommetje
Super User
Super User
Avatar

Joined: December 29 2004
Location: Netherlands
Online Status: Offline
Posts: 695
Posted: August 13 2005 at 12:02 | IP Logged Quote krommetje

Wow, makes you curious.... when you are at work and your wife is alone at home and suddenly a second person pops-up

However, it is not a bad idea to have the lights turn on when the count is 1 or above... But what happens when one of the hawkeye sends a code and PH doen't receive it? Then the whole room count is lost... If you'd use a GV to store the last room count, you'd have a fall-back or am I lost now?

Peter
Back to Top View krommetje's Profile Search for other posts by krommetje Visit krommetje's Homepage
 
TonyNo
Moderator Group
Moderator Group
Avatar

Joined: December 05 2001
Location: United States
Online Status: Offline
Posts: 2889
Posted: August 13 2005 at 18:20 | IP Logged Quote TonyNo

Have not been married for a while, so, it's not an issue!

Quote:
what happens when one of the hawkeye sends a code and PH doen't receive it?

Them's the breaks with wireless and X-10!

Things have not been without issue.

I need to relocate my main motion sensor for that room; the second sensor trips about the same time as it does, occasionally stomping on the signal. It's just a matter of fine-tuning the setup, I think. It works well enough so far to give me hope!

Yes, a Global holds the count. I also added code to make sure that the count does not go negative.
Back to Top View TonyNo's Profile Search for other posts by TonyNo Visit TonyNo's Homepage
 
krommetje
Super User
Super User
Avatar

Joined: December 29 2004
Location: Netherlands
Online Status: Offline
Posts: 695
Posted: August 14 2005 at 04:02 | IP Logged Quote krommetje

TonyNo wrote:
I need to relocate my main motion sensor for that room; the second sensor trips about the same time as it does, occasionally stomping on the signal. It's just a matter of fine-tuning the setup, I think. It works well enough so far to give me hope


perhaps if you'd place them in a near90 degrees angle?

Peter

Edited by krommetje
Back to Top View krommetje's Profile Search for other posts by krommetje Visit krommetje's Homepage
 
TonyNo
Moderator Group
Moderator Group
Avatar

Joined: December 05 2001
Location: United States
Online Status: Offline
Posts: 2889
Posted: August 14 2005 at 09:16 | IP Logged Quote TonyNo

They are at 90°. I just need to move the main one. It would be easy if I had field-of-view info for them, but I can't find it anywhere. I even sent a note to X-10.
Back to Top View TonyNo's Profile Search for other posts by TonyNo Visit TonyNo's Homepage
 
krommetje
Super User
Super User
Avatar

Joined: December 29 2004
Location: Netherlands
Online Status: Offline
Posts: 695
Posted: August 14 2005 at 10:48 | IP Logged Quote krommetje

Perhaps this link will help?

http://info.spruitnet.nl/automation/ms13.html

It is a dual language dutch site from someone who built an MS13 into a birdhouse....

Peter
Back to Top View krommetje's Profile Search for other posts by krommetje Visit krommetje's Homepage
 
TonyNo
Moderator Group
Moderator Group
Avatar

Joined: December 05 2001
Location: United States
Online Status: Offline
Posts: 2889
Posted: August 14 2005 at 11:29 | IP Logged Quote TonyNo

Many thanks! I just spent a couple hours reverse engineering the physical properties of the sensor and it's sensitivity! I come up with 120° versus his 110°.

After sketching it out, I think the solution is to use one pointed across the doorway, and the existing room sensor as the second.

More later...
Back to Top View TonyNo's Profile Search for other posts by TonyNo Visit TonyNo's Homepage
 
krommetje
Super User
Super User
Avatar

Joined: December 29 2004
Location: Netherlands
Online Status: Offline
Posts: 695
Posted: August 14 2005 at 23:24 | IP Logged Quote krommetje

TonyNo wrote:
After sketching it out, I think the solution is to use one pointed across the doorway, and the existing room sensor as the second. More later...


So One sensor doesn't look into the others field of view?
I presume that one sensor is looking into the room and the other is looking the other way into the doorway and this is a near 90degrees angle.... What have you done with the fact that when a door is open and soneone passes by the room but not actually entering the room? will it trip the light or does someone have to be in the second sensors field of view to have the light switch on?

Peter
Back to Top View krommetje's Profile Search for other posts by krommetje Visit krommetje's Homepage
 
TonyNo
Moderator Group
Moderator Group
Avatar

Joined: December 05 2001
Location: United States
Online Status: Offline
Posts: 2889
Posted: August 15 2005 at 08:22 | IP Logged Quote TonyNo

The main motion sensor is next to the door, pointed into the room, and the other is looking across the entry way...

Image

The main sensor trips the light any time it's activated. The room count is only changed when these two fire one after another.
Back to Top View TonyNo's Profile Search for other posts by TonyNo Visit TonyNo's Homepage
 
krommetje
Super User
Super User
Avatar

Joined: December 29 2004
Location: Netherlands
Online Status: Offline
Posts: 695
Posted: August 16 2005 at 05:51 | IP Logged Quote krommetje

TonyNo wrote:
The main motion sensor is next to the door, pointed into the room, and the other is looking across the entry way...


so you had to narrow the field of view of the sensor that's looking into the entry way? and the Main sensor has full view?

TonyNo wrote:

The main sensor trips the light any time it's activated. The room count is only changed when these two fire one after another.


And the light stays on with a timer? What happens if you are e.g. reading a book and don't move for a certain period of time? Or is the roomcount also taken into account for the light to stay on?

Peter

Edited by krommetje
Back to Top View krommetje's Profile Search for other posts by krommetje Visit krommetje's Homepage
 
TonyNo
Moderator Group
Moderator Group
Avatar

Joined: December 05 2001
Location: United States
Online Status: Offline
Posts: 2889
Posted: August 16 2005 at 07:41 | IP Logged Quote TonyNo

I don't think I have to narrow the door sensor's FOV anymore. I started that way. The main is unmodified.

Yup! When my Bedtime flag is not set, the timer is ignored and only the room count controls the light.

Back to Top View TonyNo's Profile Search for other posts by TonyNo Visit TonyNo's Homepage
 
krommetje
Super User
Super User
Avatar

Joined: December 29 2004
Location: Netherlands
Online Status: Offline
Posts: 695
Posted: August 17 2005 at 04:13 | IP Logged Quote krommetje

TonyNo wrote:
I don't think I have to narrow the door sensor's FOV anymore. I started that way. The main is unmodified. Yup! When my Bedtime flag is not set, the timer is ignored and only the room count controls the light.


I would like to see how you programmed this. Not that I would like to copy the code for my own project but just for learning purposes... I sure am curious!!! I have been thinking for a while to be able to count people in the room, now I have an idea how... I had come up with an idea to give my entire family a keychain with a transponder... In every room there would be reader... since this would cost about $ 2300,- for the entire house, I abandoned (is that the right way to write it?) the idea...

Peter
Back to Top View krommetje's Profile Search for other posts by krommetje Visit krommetje's Homepage
 
TonyNo
Moderator Group
Moderator Group
Avatar

Joined: December 05 2001
Location: United States
Online Status: Offline
Posts: 2889
Posted: August 17 2005 at 07:03 | IP Logged Quote TonyNo

The code is fairly straight-forward...

I already described the counting portion. That part is easy, thanks to MultiX.

At bedtime, I set a flag (BedtimeFlag=1) and then in the portion of the code that would dim the light to zero after the timer expires, I just jump around it based on that flag being zero.

Do you mean using RFID? If so, there are a good number of people using it already. If it was not so expensive, I would have asked Dave to add support for the readers! There is a low-priced version, that reads over shorter distances, which is made by Parallax. Maybe this is what you were talking about?

There is also another system that uses high-powered readers that cover a large area (link). In this case, you would not need one in every room.

Edited by TonyNo
Back to Top View TonyNo's Profile Search for other posts by TonyNo Visit TonyNo's Homepage
 
krommetje
Super User
Super User
Avatar

Joined: December 29 2004
Location: Netherlands
Online Status: Offline
Posts: 695
Posted: August 17 2005 at 07:50 | IP Logged Quote krommetje

Hey that is an interesting link, thanx, I am going to look into that.... actually, RFID was not what I had in mind... here in Holland there is a firm called Conrad and they Have a remote ID-set which is similar... I would take a lot of work to integrate so that is why I didn't follow-up to it. But since this RFID reader has an 2400bd TTL serial interface the integration into PH should be doable
(like in this movie: "impossible, but doable" )
just connect the RFID-print to a MAX232 IC and connect it to the comport....

But first I am going to fool around a bit with MultiX, it like you said: "fairly straight-forward... "

Peter

Back to Top View krommetje's Profile Search for other posts by krommetje Visit krommetje's Homepage
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum