Difference between revisions of "Dooropener"

From Whitespace (Hackerspace Gent)
Jump to: navigation, search
(Old version (lost))
 
(27 intermediate revisions by 6 users not shown)
Line 1: Line 1:
 
{{Project
 
{{Project
 
|Current=Yes
 
|Current=Yes
 +
|Participants=Joren, Fs111, Koen, Sandb, Bert, Koenraad
 
|Locations=Whitespace
 
|Locations=Whitespace
|Short description=Ring the number, get reconised, enter the premises.  
+
|Short description=Ring the number, get recognised, enter the premises.
 
}}
 
}}
[[Category:Project]]
+
=Why=  
=About=
+
The lease of the space gives us three remotes to open the gate. We're coming up to 20 members now. So we decided to take one remote, mount it in reach of the gate and hook it up to a computer with a huawei modem.
For more information about the first version of the system, see the events [[Doorhacking]] and [[Doorhack2.7]]
+
The idea is: you call the number of the modem, it checks the caller id against a text file, and if it's in there it switches the remote. Best of all: 'just letting it ring one time' doesn't cost money and opens the door.
<del>Since the first system was unstable and damaging to the remote</del> was thought to be harming the remote, a complete redesign was called, with special attention to robustness and proper stable operation.
+
It's democratic because all our members have a cellphone, not all have a smartphone.
 +
 
 +
=Next plans=
 +
* Make a webinterface (Integrate with [[spacecontrol]])
 +
* do something with pgp keys and smartphone.
  
 
=System architecture=
 
=System architecture=
All hardware will be divided in two cases:
+
All hardware will be divided in three cases:
* An old Lantronix Lantronix terminal server 1U mounted in the hackerspace rack
+
* A computer running the [[Gatekeeper]] software (currently the Audio server) and connected to a Huawei modem and a Launchpad in a Terminal server case.
* A plastic IP65 junction box to be placed in front of the gate
+
* An old ATX PSU and a junction board containing a TI Launchpad board.
 
+
* A plastic IP65 junction box to be placed in front of the gate.
[[File:dooropener-full.jpg]]
+
* A cat5 UTP cable will connect the front junction box with the one in the space.
 
+
The exception to this division is the USB GSM modem, which will be placed outside the hackerspace rack for reception reasons.
+
 
+
A cat5 UTP cable will connect both boxes.
+
  
 
=Circuit=
 
=Circuit=
Line 24: Line 25:
 
[[File:circuit-dooropener.png]]  
 
[[File:circuit-dooropener.png]]  
  
Circuit of the two printboards together. The switch represents the pin on the beagleboard - which can go 1.8v or 0v. When it is high, the relay does not trigger, when it is low, the relay does trigger.
+
The current circuit is a PNP transistor that, when base goes high (+5V), connects the Terminal PSU to a relais in the junction box that turns on the remotes (as if it's buttons were pushed). Since we migrated from the beagle board to the Launchpad only the right half, From the 1K resistor on, of the diagram is used.
  
 
=Hardware=
 
=Hardware=
  
==Lantronix case==
+
==Lantronix case (obsolete)==
  
 +
[[File:dooropener-full.jpg]]
 
===Power supply===
 
===Power supply===
  
The original Lantronix PS can be reused.  
+
The original Lantronix PSU can be reused.  
 
It gives the following outputs on a 6-pin molex:
 
It gives the following outputs on a 6-pin molex:
  
Line 57: Line 59:
 
|}
 
|}
  
===Beagle Board===
+
===TI Launchpad===
  
pinout on the beagleboard towards the gate opener:
+
Pinout on the Launchpad towards the gate opener:
  
* pin 24: white: 1.8V on/off (when high, remote gets "pushed")
+
* Pin 1.7: white: 5V on/off (when high, remote gets "pushed")
 
+
* Pin GND: black: ground (required to make sure we have a stable ground shared between the usb-computer connection and the terminal server PSU)
===USB Hub===
+
 
+
===USB2eth===
+
  
 
===Stripboards===
 
===Stripboards===
Line 71: Line 70:
 
[[File:Printboards.jpg]]
 
[[File:Printboards.jpg]]
  
The two print boards, from RIGHT to LEFT: power connected to the inverter, connected to the relais steering, connected to the ethernet cable (unclear).
+
The two print boards, from RIGHT to LEFT: power connected to the inverter - now modified to act as passthrough (this pic is old), connected to the relais steering, connected to the ethernet cable (unclear).
  
====Invert steering====
+
====Invert steering (passthrough)====
 
The stripboard contains the following:
 
The stripboard contains the following:
  
Line 79: Line 78:
 
** blue (5v) (from psu)
 
** blue (5v) (from psu)
 
** red (12v) (from psu),  
 
** red (12v) (from psu),  
** black (ground) (from psu),  
+
** black (ground) (from psu, Launchpad),  
** white (1.8v or 0v when relay needs to be closed) (from beagleboard) and  
+
** white (0v or 5v when relay needs to be closed) (from Launchpad) and  
** orange (1.8v continuous) (from beagleboard).
+
** orange (not connected).
 +
 
 +
Not used:
 
* 2x 10k ohm in series
 
* 2x 10k ohm in series
 
* a PNP transistor (bc557b)
 
* a PNP transistor (bc557b)
 +
 
* Power output pins towards the next stripboard for steerin the relais:
 
* Power output pins towards the next stripboard for steerin the relais:
 
** blue (5v)  
 
** blue (5v)  
 
** red (12v)  
 
** red (12v)  
** white (0v or 1.8v when relay needs to be closed) (inverted steering power) and  
+
** white (0v or 5v when relay needs to be closed) and  
 
** black (ground)  
 
** black (ground)  
  
Line 95: Line 97:
 
** blue (5v)  
 
** blue (5v)  
 
** red (12v)  
 
** red (12v)  
** white (0v or 1.8v when relay needs to be closed) and  
+
** white (0v or 5v when relay needs to be closed) and  
 
** black (ground)  
 
** black (ground)  
 
* a 1.1K ohm resistor
 
* a 1.1K ohm resistor
Line 117: Line 119:
 
* one pair carrying the signal to the relais (+5 Volt if on, plus ground)
 
* one pair carrying the signal to the relais (+5 Volt if on, plus ground)
 
** we are using the brown pair for this
 
** we are using the brown pair for this
** the +5V comes from the PSU but the beagle bord does the switching through pin 24
+
** the +5V comes from the PSU, but the beagle bord does the switching through pin 9 on 1.8v
  
===LED controller===
+
== Local junction box ==
 +
===Power supply===
  
32 leds + controller are present on the case.
+
An old ATX PSU was used. One of the 4 pin connector was replaced with a 3 pin version to server our purpose.  
Connection to the controller is made by 10-pin flatcable.
+
Low-priority, but nice addition to the project.
+
  
===Door opener tester===
+
{| class="wikitable"
 +
! Pin Number
 +
! Color
 +
! Voltage
 +
|- style="color: black"
 +
| 1
 +
| BLACK
 +
|align="right" | Ground
 +
|- style="color: #777700"
 +
| 2
 +
| YELLOW
 +
|align="right" | +12V DC
 +
|- style="color: red"
 +
| 3
 +
| RED
 +
|align="right" | +5V DC
 +
|}
  
 +
=== Build in control leds LED===
 +
The current version has three control leds build right in the power distribution/Launchpad box. When the system is on both leds on the right should be lit. If this is not the case the system will definitely not work. In this case the first thing you should check if the PSU is properly connected. When an authorized phone call is being received the red led on the left will blink.
 +
 +
[[File:ControlLeds.jpg|thumb|575px|none|border|Control LEDs]]
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! location
 +
! color
 +
! function
 +
! status
 +
|-
 +
| Right bottom
 +
| Blue
 +
| 12V line is active
 +
| Always on
 +
|-
 +
| Right top
 +
| Green
 +
| 5V line is active
 +
| Always on
 +
|-
 +
| Left bottom
 +
| Red
 +
| The signal to open the gate is being send
 +
| On intermittently when an authorized phone call is being received
 +
|}
 +
 +
===Other===
 +
Sections [[#TI Launchpad|TI Launchpad]] and [[#Steering relay|Steering relay]] mentioned above still apply.
 +
 +
==Door opener tester==
 +
 +
===Old version===
 
Simply a RJ45 male plug with a led attached to the brown pair. To be inserted into the connection of the remote. Allows developing software and hardware and testing the door without actually making the door go open. When the led is on, the remote is pressed.
 
Simply a RJ45 male plug with a led attached to the brown pair. To be inserted into the connection of the remote. Allows developing software and hardware and testing the door without actually making the door go open. When the led is on, the remote is pressed.
  
[[File:Dooropener-tester.jpg]]
+
[[File:Dooropener-tester.jpg|thumb|500px|none|border|Dooropener tester]]
 +
 
 +
===New version===
 +
Similar to the previous version this can be used for software testing. In addition to the first version is will also show if both supply voltages are OK. Bottom right clear red led indicates if 5V DC is OK, the bottom left clear led is for the 12V DC, The top regular red led is only lit when the signal is being send. (A income call is received.)
 +
 
 +
[[File:Dooropener-tester2.jpg|thumb|575px|none|border|Dooropener tester 2]]
  
 
==IP65 Junction box==
 
==IP65 Junction box==
Line 184: Line 240:
 
For the gatekeeper python script, see [[Gatekeeper]]
 
For the gatekeeper python script, see [[Gatekeeper]]
  
==Beagleboard==
+
===msp430-gatekeeper===
* 172.22.32.11
+
Software running on the launchpad, providing 2400bps connection over usb, send ''u'' to open gate for +/- 1 sec, ''d'' to force close the gate.
 +
 
 +
==Host computer==
 +
* Currently ''audio'' is used as the controlling computer. This computer is booted automatically every evening (bios setting) and shuts down in the morning (cron job). ('''do not turn this server off!!''')

Latest revision as of 21:36, 24 June 2011


Dooropener
WhitespaceLogo.gif
What:
Ring the number, get recognised, enter the premises.
Participants:
Joren, Fs111, Koen, Sandb, Bert, Koenraad
Locations:
Whitespace
Cornify

Why[edit]

The lease of the space gives us three remotes to open the gate. We're coming up to 20 members now. So we decided to take one remote, mount it in reach of the gate and hook it up to a computer with a huawei modem. The idea is: you call the number of the modem, it checks the caller id against a text file, and if it's in there it switches the remote. Best of all: 'just letting it ring one time' doesn't cost money and opens the door. It's democratic because all our members have a cellphone, not all have a smartphone.

Next plans[edit]

  • Make a webinterface (Integrate with spacecontrol)
  • do something with pgp keys and smartphone.

System architecture[edit]

All hardware will be divided in three cases:

  • A computer running the Gatekeeper software (currently the Audio server) and connected to a Huawei modem and a Launchpad in a Terminal server case.
  • An old ATX PSU and a junction board containing a TI Launchpad board.
  • A plastic IP65 junction box to be placed in front of the gate.
  • A cat5 UTP cable will connect the front junction box with the one in the space.

Circuit[edit]

Circuit-dooropener.png

The current circuit is a PNP transistor that, when base goes high (+5V), connects the Terminal PSU to a relais in the junction box that turns on the remotes (as if it's buttons were pushed). Since we migrated from the beagle board to the Launchpad only the right half, From the 1K resistor on, of the diagram is used.

Hardware[edit]

Lantronix case (obsolete)[edit]

Dooropener-full.jpg

Power supply[edit]

The original Lantronix PSU can be reused. It gives the following outputs on a 6-pin molex:

Pin Number Color Voltage
1 RED +12
2 & 3 BLUE +5
4 & 5 BLACK Ground
6 YELLOW -5

TI Launchpad[edit]

Pinout on the Launchpad towards the gate opener:

  • Pin 1.7: white: 5V on/off (when high, remote gets "pushed")
  • Pin GND: black: ground (required to make sure we have a stable ground shared between the usb-computer connection and the terminal server PSU)

Stripboards[edit]

Printboards.jpg

The two print boards, from RIGHT to LEFT: power connected to the inverter - now modified to act as passthrough (this pic is old), connected to the relais steering, connected to the ethernet cable (unclear).

Invert steering (passthrough)[edit]

The stripboard contains the following:

  • 5-pin power input connector:
    • blue (5v) (from psu)
    • red (12v) (from psu),
    • black (ground) (from psu, Launchpad),
    • white (0v or 5v when relay needs to be closed) (from Launchpad) and
    • orange (not connected).

Not used:

  • 2x 10k ohm in series
  • a PNP transistor (bc557b)
  • Power output pins towards the next stripboard for steerin the relais:
    • blue (5v)
    • red (12v)
    • white (0v or 5v when relay needs to be closed) and
    • black (ground)

Steering relay[edit]

The stripboard contains the following:

  • 4-pin power input lines
    • blue (5v)
    • red (12v)
    • white (0v or 5v when relay needs to be closed) and
    • black (ground)
  • a 1.1K ohm resistor
  • an NPN transistor (bc547b)
  • Power output pins towards the remote
    • pair ground and 0/5V: for steering the relais (brown pair)
      • 5v
      • ground
    • pair ground and 12V continuous: for powering the remote (blue pair)
      • 12v
      • ground

RJ45 output connector to the IP65 case[edit]

  • left first RJ45 connector on terminal server acts as output connector
  • Connected to the stripboard
  • the pins on the connector have all been soldered, T568B style.

On the RJ45 connector is present:

  • one pair carrying power to the remote (+12 Volt continuous plus ground)
    • we are using the blue pair for this
  • one pair carrying the signal to the relais (+5 Volt if on, plus ground)
    • we are using the brown pair for this
    • the +5V comes from the PSU, but the beagle bord does the switching through pin 9 on 1.8v

Local junction box[edit]

Power supply[edit]

An old ATX PSU was used. One of the 4 pin connector was replaced with a 3 pin version to server our purpose.

Pin Number Color Voltage
1 BLACK Ground
2 YELLOW +12V DC
3 RED +5V DC

Build in control leds LED[edit]

The current version has three control leds build right in the power distribution/Launchpad box. When the system is on both leds on the right should be lit. If this is not the case the system will definitely not work. In this case the first thing you should check if the PSU is properly connected. When an authorized phone call is being received the red led on the left will blink.

Control LEDs
location color function status
Right bottom Blue 12V line is active Always on
Right top Green 5V line is active Always on
Left bottom Red The signal to open the gate is being send On intermittently when an authorized phone call is being received

Other[edit]

Sections TI Launchpad and Steering relay mentioned above still apply.

Door opener tester[edit]

Old version[edit]

Simply a RJ45 male plug with a led attached to the brown pair. To be inserted into the connection of the remote. Allows developing software and hardware and testing the door without actually making the door go open. When the led is on, the remote is pressed.

Dooropener tester

New version[edit]

Similar to the previous version this can be used for software testing. In addition to the first version is will also show if both supply voltages are OK. Bottom right clear red led indicates if 5V DC is OK, the bottom left clear led is for the 12V DC, The top regular red led is only lit when the signal is being send. (A income call is received.)

Dooropener tester 2

IP65 Junction box[edit]

Remote[edit]

Stripboard[edit]

The stripboard contains the following:

  • Two RJ45 connectors
  • RJ45 connector on the bottom (IN) to receive power & signal
  • Relais
  • Remote
  • Double line male pins, with female connector connected to in ethernet cable
    • currently only the first row is used
    • first brown pair and then blue pair is connected
Pin Usage
1 5v relay steeriong (brown)
2 ground
3 12v remote power (blue)
4 ground
  • Single line pin header with following connections:
Pin Usage
1 & 2 First button
3 & 4 Second button
5 +12V continuous power
6 Ground
7+ Unused

Software[edit]

Gatekeeper[edit]

For the gatekeeper python script, see Gatekeeper

msp430-gatekeeper[edit]

Software running on the launchpad, providing 2400bps connection over usb, send u to open gate for +/- 1 sec, d to force close the gate.

Host computer[edit]

  • Currently audio is used as the controlling computer. This computer is booted automatically every evening (bios setting) and shuts down in the morning (cron job). (do not turn this server off!!)