RE: Detection with a reed switch and a magnet. Experiences?

#1 von RudyB , 11.10.2014 15:53

Today I tried occupancy detection with a reed switch and a small magnet under the loc. Results seemed OK.

Link to the video.

Although current sensing probably is the most used detection method, I like to try some other methods too before I make up my mind what to use with my near-future layout.

At this moment chances are 80% That I'm going to use an Arduino for S88 sensor feedback, simply because of its low cost. In that case current sensing is not the most easy, because some additional current detection PCB's will be needed, which will also raise cost again. Optical or magnetic detection are easier and more cost efficient.

The drawback is that there will always be a sensor in view, somewhere besides or between the rails. Some will not like the view or will find it non-realistic. To me this is not a big factor though, since I'm not that much of a 'prototypical purist' ... more a 'technical tinkerer'. Both the optical sensor as well s a reed switch (10 x 2 mm) will fit neatly between the rails, not really that much noticeable.

A reed switch needs only 2 wires, while an IR sensor needs 3. So, that might make me turn to the reed switches as train detection method.

Chances are that (many?) forum members also tried these detection methods, or even use them in practice? I'm curious about experiences ... good or bad ... and if there are any tips ... or any pitfalls?


Youtube channel on Model Railway, Traincontroller, Arduino and more


RudyB  
RudyB
InterRegioExpress (IRE)
Beiträge: 268
Registriert am: 20.09.2014
Homepage: Link
Gleise Peco 75
Spurweite H0
Steuerung TrainController
Stromart Digital


RE: Detection with a reed switch and a magnet. Experiences?

#2 von Stahlbahn ( gelöscht ) , 11.10.2014 16:07

Been there, done that. 20 yrs. ago. Reed switchs are ok for speedometers or anything else when you need a short impulse. And if your going to equip every loco with magnet. For track occupany current detection is the best way. The additional costs are affordable, if one uses DIY circuits instead of out-of-the-box solutions. I would never go back to reeds for that purpose.

Frank


Stahlbahn

RE: Detection with a reed switch and a magnet. Experiences?

#3 von RudyB , 11.10.2014 16:56

Thx Frank for your reply.

I hear you say ...'For track occupany current detection is the best way" ... but could you maybe elaborate a bit on the reasons why? Besides from having to put a magnet on every train ... that is obvious ... what were the troubles that made you change from reed switches to current sensing?


Youtube channel on Model Railway, Traincontroller, Arduino and more


RudyB  
RudyB
InterRegioExpress (IRE)
Beiträge: 268
Registriert am: 20.09.2014
Homepage: Link
Gleise Peco 75
Spurweite H0
Steuerung TrainController
Stromart Digital


RE: Detection with a reed switch and a magnet. Experiences?

#4 von spielbahn ( gelöscht ) , 11.10.2014 17:03

Reed switches control one point but current sensors will control a whole track.


spielbahn

RE: Detection with a reed switch and a magnet. Experiences?

#5 von Stahlbahn ( gelöscht ) , 11.10.2014 17:21

Zitat von spielbahn
Reed switches control one point but current sensors will control a whole track.


Yes, that's it.

Train arrives in staging yard and ze loco's magnet activates the reed switch for a short moment. After that, the switch opens again. Your control systems recognizes that and shifts track status to "occupied". OK. Then operating is finish, power is shut off and the control system loses its memory. Next day, either all tracks are occupied or free, depending on the system's default value. Apart from that, removing or adding a train manually isn't detected either..

To sum up, that approach is not reliable and therefore too expensive.

Frank

BTW: I changed to current sensors when introducing DCC and softwar control.


Stahlbahn

RE: Detection with a reed switch and a magnet. Experiences?

#6 von RudyB , 11.10.2014 21:13

I see ... yes of course that is an important point to consider. So, the computer control does not save its status when closing down in order to start up with that same staus at next powerup? In stead it reads out where the trains are? Which computer control program are you referring to?

That's a neat piece of wiring you have there Frank!


Youtube channel on Model Railway, Traincontroller, Arduino and more


RudyB  
RudyB
InterRegioExpress (IRE)
Beiträge: 268
Registriert am: 20.09.2014
Homepage: Link
Gleise Peco 75
Spurweite H0
Steuerung TrainController
Stromart Digital


RE: Detection with a reed switch and a magnet. Experiences?

#7 von Rio , 12.10.2014 02:27

Hy Rudy,
I had reed contacts which worked reasonably. My problem with Mä C-Track: as there is no room inbetween rails (without cutting the track bed) I had to position the reeds on the outer side of track. This in turn made it kind of difficult to hide the Magnets on the locos. I also noticed some magnetisation of the switches. If I ran the switch open, the switch blade sometimes "glued" in the "wrong" position. Switching usually corrected it but until than, the train in the other direction ended up on the wrong track... BTW: used the reeds to activate switches analogically.

Regards
Klaus


Rio  
Rio
InterRegioExpress (IRE)
Beiträge: 296
Registriert am: 20.03.2011


RE: Detection with a reed switch and a magnet. Experiences?

#8 von RudyB , 12.10.2014 09:21

Thx for your reply Klaus. Yes ... it is not possible to hide the reed between the rails with some kinds of set track. Roco has a special rail where a reed is hidden inside a hollow sleeper, a nice solution. I plan to use Peco HO 75, there is room between the sleepers.

The sticking of the contacts indeed is a known issue. Sometimes it can be residual magnetism, but that actually means the reed is faulty. More often it has to do with current flow. Either too high or too low a current can cause sticking.


Youtube channel on Model Railway, Traincontroller, Arduino and more


RudyB  
RudyB
InterRegioExpress (IRE)
Beiträge: 268
Registriert am: 20.09.2014
Homepage: Link
Gleise Peco 75
Spurweite H0
Steuerung TrainController
Stromart Digital


RE: Detection with a reed switch and a magnet. Experiences?

#9 von Stahlbahn ( gelöscht ) , 12.10.2014 10:04

Zitat von RudyB
The sticking of the contacts indeed is a known issue. Sometimes it can be residual magnetism, but that actually means the reed is faulty. More often it has to do with current flow. Either too high or too low a current can cause sticking.



For that reason I never connected reed contacts directly to turnout motors but installed a small circuit (basically a transistor, a flip-flop and a relay) to protect the reed contacts - especially when the contacts were located in hard-to-reach positions. From that point of view, current detection would cost the same or maybe even cheaper. Downside: current detection should be installed during track laying. It may be difficult to do the extra track isolation and wiring afterwards.

Frank


Stahlbahn

RE: Detection with a reed switch and a magnet. Experiences?

#10 von shaddowcanyon , 12.10.2014 12:35

Hello,

I am using reed-switches on my layout as well. The specific advantage is that there is one, and only one specific position at each train - where the magnet is mounted - that triggers the reed relay. One side of the reed relay is connected to track mass (Within the 3-rail-system it's quite natural to do so), so there is only one wire per reed contact. Another advantage is that I can change the contact position very easily, without removing any tracks or ballast from the layout.

As Frank has already pointed out: the reed contact only creates one short impulse, and the information on track occupancy may be lost after layout shutdown. For this reason I always use reed contacts in connection with bistable relays. These relays keep their state when the layout is off. For track occupancy detection you need two reed contacts: one at the beginning and one at the end of the respective track section. I use this principle also for automatic block control.

One other thing is what happens when you remove a train from the respective track section by hand. I usually avoid to do this, and when I really need to do, I drive the train to a better accessible part of the main line. Further, I have connected something like a signal (actually it's 2 LEDs on a mast situated at the beginning of the track section) which indicates the present state of the relay. It's a nice optical feature and you are informed on that what the track occupancy bookkeeper believes.

Another point is that I mount the reed contacts on the right side of the track (seen in driving direction), not in the center between the rails. This offers the opportunity to make the contact sensitive to train direction, and it makes the mounting of the reed contact easier.

And yes, I never connect a Märklin turnout motor (7549 etc.) directly to a reed contact. The electro magnet inside these motors needs 1 A of current. Much more than miniature reed contacts can safely supply. There is always a pulse forming electronics and a power relay in between.

Best regards

Hans Martin


The Presidents, Chief Engineers, Finance Directors, Baggage Porters, and Yard Sweepers
of the Benton Valley Railroad Line : viewtopic.php?f=64&t=109585

Les Aventures du Chasseur Noir (alte Spur 0)
viewtopic.php?f=168&t=138761


 
shaddowcanyon
EuroCity (EC)
Beiträge: 1.178
Registriert am: 27.04.2014
Homepage: Link
Ort: Darmstadt
Gleise Märklin K-Gleis & Spur-0-Blechgleis
Spurweite H0, 0
Steuerung CU 6021
Stromart AC, Digital


RE: Detection with a reed switch and a magnet. Experiences?

#11 von RudyB , 12.10.2014 17:21

Thx for your extensive reply Hans Martin. Seems with all the additional circuitry you have in use in the end it's not cheaper (maybe even more expensive) then current detction. But, like you, I do like the flexibility to be able to move sensors around a bot during the testing phase. With current detection that is not very easy to do.


Youtube channel on Model Railway, Traincontroller, Arduino and more


RudyB  
RudyB
InterRegioExpress (IRE)
Beiträge: 268
Registriert am: 20.09.2014
Homepage: Link
Gleise Peco 75
Spurweite H0
Steuerung TrainController
Stromart Digital


RE: Detection with a reed switch and a magnet. Experiences?

#12 von Rio , 12.10.2014 23:32

Hi Rudy and others.

Apparently my experience was not correctly understood. Let me try again.

I meant to say: The magnets attached to the locos magnetize the moving parts of the turnouts, after some time of operation. This may cause problems, as the magnets on the locos or even wheels cutting turnouts open moved the needle (moving part of the turnouts / crossing / rail) to another position without interference of the electromagnetic activator (Reed, servo, actuator, etc). The small spring force to return the moving part to its original position was not always strong enough to overcome the acquired magnetic attraction force and return it to its original position.
I use c-tracks.

Regards

Klaus


Rio  
Rio
InterRegioExpress (IRE)
Beiträge: 296
Registriert am: 20.03.2011


RE: Detection with a reed switch and a magnet. Experiences?

#13 von shaddowcanyon , 13.10.2014 00:22

Hallo Klaus,

Yes, what you said is an issue. The moving parts of the turnouts may be magnetized, and the magnetized turnouts do not work reliable. This is one reason why I placed the reed contact besides, not between the rails on my layout. The reed relay is oriented parallel (not perpendicular) to the track, and so is the magnetization direction of the magnet. I had the problems you described as well, but placing the magnets outside the track did solve the problem so far. In this case the magnets are always far enough apart from the turnout tongue and spring (I use K-track, and the spring is simply a elastic bar made of plastics, so I guess it's the tongue that adheres at the rails when it is magnetized). With my modified arrangement I never had any difficulties. Best solution would be if they made the turnout tongues of non-magnetic materials, e.g. brass.

Regards

Hans Martin


The Presidents, Chief Engineers, Finance Directors, Baggage Porters, and Yard Sweepers
of the Benton Valley Railroad Line : viewtopic.php?f=64&t=109585

Les Aventures du Chasseur Noir (alte Spur 0)
viewtopic.php?f=168&t=138761


 
shaddowcanyon
EuroCity (EC)
Beiträge: 1.178
Registriert am: 27.04.2014
Homepage: Link
Ort: Darmstadt
Gleise Märklin K-Gleis & Spur-0-Blechgleis
Spurweite H0, 0
Steuerung CU 6021
Stromart AC, Digital


RE: Detection with a reed switch and a magnet. Experiences?

#14 von GDT518 , 13.10.2014 06:03

Hey Rudy,

I'm testing Hall sensor right now, I position them beside the track, just like the "indusi" used by the DB. The Indusi a the loco will be milled to make room for the 0.5mm think N52 magnets. I got some prototypes running already, up to know they work without any problems. Advantage is that you do not have any wear-out, the hall sensor is fully electronic, no mechanical parts.

Greetings from Chicago

Leif


Grüße aus Chicago

Leif

Meine Modellbahnbaustelle: viewtopic.php?f=64&t=114182


GDT518  
GDT518
InterCity (IC)
Beiträge: 546
Registriert am: 31.05.2013


RE: Detection with a reed switch and a magnet. Experiences?

#15 von jakeman103 ( gelöscht ) , 14.10.2014 11:28

Hello railers,

I tried reed sensors as well on a N gauge track and exactly the same errors; magnetic turn outs doing ghost manouvres at times you really don't want. In the end i used for my 3rail layout loconet s88 detection and used the reed contacts only for the Faller Car system / MCC control detection. Now for my TT layout i use current detection platines from
Hans de loof, and the costs and reliabillity is highly considerable. Also; let's say you want to control your layout with iTrain or Rocrail or Windigipet; computers will notice on wich track trains are placed after you shut down and restart at the beginning of a train day, once there is power on the tracks; the trains use current. If you use reed contacts and a magnet you need to drive all trains manually to their start piont were the reed switch will turn before you system again knows were all your trains are. So; i would say; all the magnetic troubles and insecure moments on you layout.. avoid the magnets and reed contacts and the bit higher costs are much more worth instead of the annoying moments having no fun with your layout and trains when ghost manouvres switch turnouts trains will clash or loose track and crash from your layout board on the ground, as they once did on my layout.

Succes! Greets Jake


jakeman103

RE: Detection with a reed switch and a magnet. Experiences?

#16 von Heinzi , 14.10.2014 15:06

Zitat
Reed switches control one point but current sensors will control a whole track.

Not only this.....
Reed switches controls only the loco, and not the attached "wagons". If you prepare the wheels of the wagons, current sensing can also detect wagons.

As far as I untersdood Hans Martin the reed switch has either to be palced in the midle of the track (and it needs two contacts) or beside the tracks (than it needs four contacts.)


Gruss Heinzi
------------------
CS1R / ControlGui


 
Heinzi
Metropolitan (MET)
Beiträge: 4.873
Registriert am: 26.04.2006


RE: Detection with a reed switch and a magnet. Experiences?

#17 von shaddowcanyon , 15.10.2014 17:47

Hello all,

Images tell more than 1000 words, so I took my camera:

This is how I have mounted a reed contact besides the rails (at the right side seen in driving direction):



One side of the reed contact is connected to the rails (i.e to ground potential), the other contact goes to a relay, a signal or whatever electronics. It looks like an Indusi, indeed. Concerning C- or K-track from Maerkin, which have rails made of magnetic material, there are two important points: 1. leave a gap of few millimeters between the reed contact and the rail. 2. The connecting wire between the pin of the reed contact and the grounding rail should be made of non-magnetic material (copper or brass, not steel). Otherwise the remanent magnetic field from the rail will eventually branch to the reed contact through that wire, so the contact will "hang"after some time. There is no such issue if one uses tracks with non-magnetic rails.

Here an image how a magnet could be attached to a locomotive:



I use tiny supermagnets for this purpose (only few millimeters in size). This one here fitted in a small gap on the fuel tank of the diesel. On other locomotives I found mounting at the trucks more suitable.

Regards

Hans Martin


The Presidents, Chief Engineers, Finance Directors, Baggage Porters, and Yard Sweepers
of the Benton Valley Railroad Line : viewtopic.php?f=64&t=109585

Les Aventures du Chasseur Noir (alte Spur 0)
viewtopic.php?f=168&t=138761


 
shaddowcanyon
EuroCity (EC)
Beiträge: 1.178
Registriert am: 27.04.2014
Homepage: Link
Ort: Darmstadt
Gleise Märklin K-Gleis & Spur-0-Blechgleis
Spurweite H0, 0
Steuerung CU 6021
Stromart AC, Digital


RE: Detection with a reed switch and a magnet. Experiences?

#18 von RudyB , 15.10.2014 18:01

Those are very nice pictures Hans!

I had to laugh on what you said about the magnet: 'This one here ...'.
This one where?
Probably the pcture shows the magnet, but it only catches the eye when you know where it is!


Youtube channel on Model Railway, Traincontroller, Arduino and more


RudyB  
RudyB
InterRegioExpress (IRE)
Beiträge: 268
Registriert am: 20.09.2014
Homepage: Link
Gleise Peco 75
Spurweite H0
Steuerung TrainController
Stromart Digital


RE: Detection with a reed switch and a magnet. Experiences?

#19 von shaddowcanyon , 15.10.2014 18:37

Oh, sorry!

The magnet is this tiny rectangular metal piece located close to the bottom of the grey part of the loco body between the trucks, just at the upper left edge of the reed contact (the part labeled as "MS06"). The magnet is a 5 x 5 x 1.5 mm neodymium (or "super") magnet.

Regards

Hans Martin


The Presidents, Chief Engineers, Finance Directors, Baggage Porters, and Yard Sweepers
of the Benton Valley Railroad Line : viewtopic.php?f=64&t=109585

Les Aventures du Chasseur Noir (alte Spur 0)
viewtopic.php?f=168&t=138761


 
shaddowcanyon
EuroCity (EC)
Beiträge: 1.178
Registriert am: 27.04.2014
Homepage: Link
Ort: Darmstadt
Gleise Märklin K-Gleis & Spur-0-Blechgleis
Spurweite H0, 0
Steuerung CU 6021
Stromart AC, Digital


   


  • Ähnliche Themen
    Antworten
    Zugriffe
    Letzter Beitrag
Xobor Einfach ein eigenes Forum erstellen
Datenschutz