From owner-freebsd-hardware Fri Oct 1 13:11: 8 1999 Delivered-To: freebsd-hardware@freebsd.org Received: from alpo.whistle.com (alpo.whistle.com [207.76.204.38]) by hub.freebsd.org (Postfix) with ESMTP id 8C5FD14EA4 for ; Fri, 1 Oct 1999 13:11:05 -0700 (PDT) (envelope-from julian@whistle.com) Received: from current1.whistle.com (current1.whistle.com [207.76.205.22]) by alpo.whistle.com (8.9.1a/8.9.1) with SMTP id NAA88501; Fri, 1 Oct 1999 13:10:59 -0700 (PDT) Date: Fri, 1 Oct 1999 13:10:58 -0700 (PDT) From: Julian Elischer To: David Wolfskill Cc: freebsd-hardware@FreeBSD.ORG Subject: Re: Computer-controlled switch? (Not X10 complexity) In-Reply-To: <199910011718.KAA51184@pau-amma.whistle.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hardware@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Davo.... come to my cube for a bunch-o-stuff I picked up at the embedded systems conference.... for those who can't come to my cube :-) there is a ton of stuff out there and a starting poing might be www.echelon.com julian On Fri, 1 Oct 1999, David Wolfskill wrote: > I have an application where I'd like to be able to have a daemon > monitoring a set of conditions, and in response to a certain set of them, > be able to open a circuit, keep it open for a certain length of time > (at least 5 seconds), then close it. Although there is some room for > choice as to precisely which circuit I use (more on that below, if folks > care), there is no reason to be concerned with anything greater than > usual house wiring, and far less than 0.25 A. Ideally, the circuit > would merely be a phone line (RJ-11 jacks). > > The machine that would, ideally, be doing this is also in physical > proximity to the circuit in question. > > I've started looking at the x10 stuff, and it looks interesting and > all... but > > * it seems overly complex for the aplication; > > * it isn't clear to me how well the x10 signalling will work if a > device to be controlled is getting its power from a UPS. > > > Now, I'm certain this is doable. I'm less certain that it can be done > economically and reasonably safely by someone (me) whose track record > with hardware is... less than stellar. > > I would also prefer to be able to control it from, say, a serial port > (by sending ASCII text to it; possibly getting ASCII replies back, > though that's far less critical). > > > The specific application is to force a re-sync for the Alcatel xDSL 1000 > network termination device I have at home. Every once in a while, it > detects loss of sync and copes appropriately, but then sometimes it > fails to recognize loss of sync, even though it won't pass packets. > If/when that happens (as it did yesterday morning) after I get to work, > the home net is isolated... which rather defeats much of the purpose of > having a 24x7 connection to the Net. > > So I figured I could have a daemon pay attention to what's going on > (either try to ping the default router a couple of times every 2 or 3 > minutes, or look at the output of "netstat -ni" on the external > interface, and if there was traffic in both ways, go back to sleep; > otherwise, try the ping). If the daemon decides that corrective action > is appropriate, I'd have it either power-cycle the Alcatel unit or -- > preferably -- (effectively) unplug the DSL connection for at least 5 > (probably 6, to be safe) seconds, which (empirically) seems to be enough > for the Alcatel unit to realize that Something Is Wrong, then re-connect > it, and let the Alcatel device re-establish sync. > > Power-cycling the device would also do it, but would go through its POST > as well, which would slow recovery. But if I were to adopt this approach, > I could either remove the house current from the "wall-wart" > (transformer/rectifier), or interrupt the 12 VDC output of the > wall-wart. > > And yes, I realize that if the Pac*Bell folks are actually doing things > with the outside wires, this may not be useful... but the vast majority > of the outages I've experienced so far would be circumventable via such > an approach. > > I'm quite willing to summarize responses sent direct. > > Thanks, > david > -- > David Wolfskill dhw@whistle.com UNIX System Administrator > voice: (650) 577-7158 pager: (888) 347-0197 FAX: (650) 372-5915 > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hardware" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hardware" in the body of the message