Hi João
If the first bang is triggered, wait some time and if within this time frame the second is triggered as well, then you know the direction. It's actually mostly about timing and to make sure to clear the state after a certain time, if not both bangs are triggered within the time frame.
Check the attached (ugly; done with touchpad) patch.
Roman
On Tue, 2010-08-17 at 13:45 +0100, João de Brito Rocha Reis Vidigal wrote:
Hi again. Here goes another problem!
Ok. So I'm working with Arduino firmata here... To expose to problem in a simple way, I have 2 sensors that are detecting a door crossing. The 2 detectors give an order to the door crossing: coming in or going out. Now I just don't know how I can translate that to bang 2 different [bang( depending on if someone's comming in or going out!
Can you help me with that!? Thanks