To get 'fail safe' you should probably have a master periodically polling
the buttons. It can generate an error if it doesn't get an answer from a
button.
Of course, you'll need to handle the case where the master itself fails.
Perhaps a hardware watchdog (_not_ the one inside the chip, see related
thread).
Noise shouldn't be too big a problem, as long as you keep the impedence down
on your line. Each remote PIC is connected to nothing except the two-wire
bus, and most noise on the bus will be common mode (especially if your pair
is actually twisted).
Bob Ammerman
RAm Systems
(contract development of high performance, high function, low-level
software)
It might be nice to have a local indicator led that lights once the master
station acknowleges the button press. This will give some confidence to the
patients that their request has been received. Cancelled from the nurses
station or by a magnet/reed switch on the push button?
Richard P
To get 'fail safe' you should probably have a master periodically polling
the buttons. It can generate an error if it doesn't get an answer from a
button.
Of course, you'll need to handle the case where the master itself fails.
Perhaps a hardware watchdog (_not_ the one inside the chip, see related
thread).
Noise shouldn't be too big a problem, as long as you keep the impedence
down
on your line. Each remote PIC is connected to nothing except the two-wire
bus, and most noise on the bus will be common mode (especially if your pair
is actually twisted).
Bob Ammerman
RAm Systems
(contract development of high performance, high function, low-level
software)
I am in the process of doing a single pair power+communications system for
synchronized clocks (like in a school). What I am doing is encoding the data
as momentary interruptions in the power. A 1.0 ms interruption is a zero, a
1.5 millisecond interruption is a one, and a 2.0 millisecond interruption is
a 'start condition' to establish the message framing. My application is
unidirectional (from the master to the slave only) so it isn't directly
comparable to $SUBJ. I am sending the data using a 5 millisecond period, so
I am getting 200 bits per second.
I would consider using a scheme similar to the above to send from the master
to the slaves. Following a poll, the master would then drive the line for a
short while with reverse polarity but thru a relatively high resistance
(1000 ohms perhaps). The addressed slave would load the line down in a
pattern to return data to the master. Thus, any break in the wire or a
failed slave could be easily detected by the master.
I'd probably use a 12C508 for the slave, and burn each one with a unique
serial number. The master would allow me to define a mapping from the
physical serial number of the slave to the logical room number for display.
Bob Ammerman
RAm Systems
(contract development of high performance, high function, low-level
software)
>
>
> Sven,
>
> I used to work in a similar area of the market, installing TV systems
which are
> usually attached with the nurse call.
>
> For liability reasons and reliability, it is best to pull the extra wires.
In
> the USA, the cost of rewiring with union workers is about half the cost of
the
> lawyers, let alone any settlements which could result.
>
> Andy
>
Sorry, I disagree here. There is _no_ reason the 2-wire system should be
less reliable than a 1 pair per button system. In fact, with fewer parts...
Of course, if something does go wrong, it is likely to involve much more of
the system with the 2-wire.
Bob Ammerman
RAm Systems
(contract development of high performance, high function, low-level
software)
>Sorry, I disagree here. There is _no_ reason the 2-wire system should be
>less reliable than a 1 pair per button system. In fact, with fewer parts...
Agreed. You don't have to convince me, you have to convince the insurance
company, which sees more wires as more reliable.
Hopefully you'll never have to convince a jury composed of 12 non-technical
people who are selected for their lack of understanding of technical things, and
their ability to be swayed by a lawyer's emotional appeal. (My buddy from
growing up is a lawyer, and they do all they can to remove "thinking people"
from a jury pool).
"The hospital tried to cut costs by only having one set of wires..." You can
finish the argument yourself.
The key is to having it certified by UL and any other organization you can find.
If a product meets the standards of those bodies, then it's a lot harder to
squeeze money from the maker.
I've had enough of it. I stay clear of anything that goes anywhere near a
patient room any more.
>Of course, if something does go wrong, it is likely to involve much more of
>the system with the 2-wire.
Right. Failure means the whole system (conceivably) goes down, not just one
bed.
At 08:39 AM 10/27/2000 -0400, you wrote:
>>Sorry, I disagree here. There is _no_ reason the 2-wire system should be
>>less reliable than a 1 pair per button system. In fact, with fewer parts...
>
>Agreed. You don't have to convince me, you have to convince the insurance
>company, which sees more wires as more reliable.
>
>Hopefully you'll never have to convince a jury composed of 12 non-technical
>people who are selected for their lack of understanding of technical
things, and
>their ability to be swayed by a lawyer's emotional appeal. (My buddy from
>growing up is a lawyer, and they do all they can to remove "thinking people"
>from a jury pool).
>
>"The hospital tried to cut costs by only having one set of wires..." You can
>finish the argument yourself.
>
All references to lawyers, lawsuits, and juries aside, with this
type of system, you probably do better using a polled arrangement
where each remote is polled/checked "continuously" versus a much
more complicated one where the remotes call in by themselves and
have to individually deal with collisions on the bus, and are only
occasionally checked by the master.
>...you probably do better using a polled arrangement
>where each remote is polled/checked "continuously" versus a much
>more complicated one where the remotes call in by themselves and
>have to individually deal with collisions on the bus, and are only
>occasionally checked by the master.
make a pic controlled TDR, or Time Domain Reflectometer... you would need quite a fast sampling
circuit i suspect.
use your already installed 2 wires and parallel switches.
(if you don't actually short out the wires with the switch but connect them together through a
resistor then you should be able to cope with more than one switch closed simultaneously.)
you then need to map out your wiring to work out where each switch is as far as the tdr is
concerned.
a nice side-benefit is that you can monitor the status of your network with the same system and
detect the position of any short circuits / broken cables.
oh and the push-button circuitry is a little simpler :)
Simon you are almost right. With such an installation line testing
equipment installed at the power supply is essential for troubleshooting.
In my project I used a standard DVM on the ohms scale and a 3 way switch,
in the time honored phone people way (measures resistance and voltage, ac
and dc, between line wires, and each line and ground). This was a fixed
part of the installation (mounted inside the PSU box).
Peter
-- http://www.piclist.com hint: PICList Posts must start with ONE topic:
"[PIC]:","[SX]:","[AVR]:" =uP ONLY! "[EE]:","[OT]:" =Other "[BUY]:","[AD]:" =Ads
You can always use a non-zero voltage as 'LOW' f.ex. by using a zener to
pull down the line to transmit, and have the power supply be a low current
supply above zener voltage and a higher current supply below. Then add
chip fuses in each handheld box and wire branch box. If something shorts
the wire or if a box is destroyed or whatnot then the respective fuses
will go. You can help the fuses to go by putting a crude humidity sensor
on the PCB (interlaced traces) to drive an extra (low) power transistor
that shorts the input wires and helps the fuse to depart. I have used this
method and it works (in another project where things tended to get wet and
then go berserk and interfere with signalling). I also used little 5mA
LEDs that were in series with the line in each button box and a bridge
rectifier in each box to avoid polarity problems. This was not a PIC
project, it used 4XXX CMOS ;-). I also had three steps of current from the
PSU so the user would get feedback on the LED when pressing a button.
hope this helps,
Peter
-- http://www.piclist.com hint: PICList Posts must start with ONE topic:
"[PIC]:","[SX]:","[AVR]:" =uP ONLY! "[EE]:","[OT]:" =Other "[BUY]:","[AD]:" =Ads