[Rack] doorport - do you know how the door opener works?
jake at spaz.org
Tue Dec 6 22:35:43 PST 2011
> Jake, what is the difference between https://www.noisebridge.net/wiki/User:Jake and
i don't know, i guess they are both me. I made the jerkey one to edit
wiki pages, and i made the jake one so that i could be given ssh access to
> Do you want your SSH key for "jake" pushed to minotaur?
yes, that would be great. so, what's that machine "for" and what is
running on it?
> I'm happy to help facilitate making anything related work with the
> hardware/software, since I feel like I know it well. However, from my
> perspective, it was already working. Coming onto the list and saying
> "Help! Make the door work!" doesn't make it clear what you're looking
> for, or how anyone can help you out.
I did the hardware, since there was nothing to plug the door wiring into
anymore (the Wise box was gone and i heard they are bunk anyway) but I had
nowhere to begin to try to get it to work with the new setup.
It turns out that the hardware was working when i sent that message,
except that a wire had come loose on the dooropener circuitboard, which I
fixed with Danny. But hardware is nothing without software, and there was
no software on the Minotaur to activate it. It's fixed now, says Danny.
> I put the two most-helpful tools for dealing with the hardware on minotaur:
> - /usr/local/sbin/open-door (a setuid root binary that "buzzes" open the door with the parallel port hardware)
> - /usr/local/sbin/parport_daemon (a setuid binary that takes control of the parallel port, starts listening on UDP
> 0.0.0.0:30012, and talks a simple protocol to query the state of the ringer and open the gate)
> Personally, I'd like to use the parport_daemon program going forward, though most of the scripts others use are not setup
> to use it just yet. The protocol is dead simple. Ask it "Sup?" and it will respond with "Nothing." (nobody's ringing) or
> "RING!" (someone is or just rang the gate buzzer). If you send it "OPEN!" it will respond "Acknowledged. Buzzing it
> open." (buzzes open the door) or "Already opened recently." (if someone beat you to it -- there's a timeout to avoid
> wailing on the solenoid).
> So, to open the gate from pony, one could do something like: echo -n 'OPEN!' | socat stdio udp4:minotaur.noise:30012
> I should probably make a wrapper script or controller around that next.
> I'm also thinking it would be cute to have the computer hosting the daemon to also announce a Zeroconf/Avahi service
> records for the door. Maybe _door._udp?
More information about the Rack