Magnetic Levels Probe

A forum for discussion on the WMT River Control System hardware.
TerryJC
Posts: 2616
Joined: 16/05/2017, 17:17

Magnetic Levels Probe

Post by TerryJC »

All,

The issues that we've had with the environment over the past week or two have underlined the need to protect all of our designs from anything that the world can throw at us :!:

We are still having problems with water ingress into the Resistance Probe electronics; even with the new plastic 'caps' for the Pi Board and Wireless Access Point, but that's a problem that is relatively easily overcome when we develop the 'production' models.

Of more concern has been the erosion / corrosion of the wet contacts of the Resistance Probe, which means that for this type of sensor to be reliable, we'll have to identify probe materials that are stable in such a environment. Maybe this isn't such a good approach.

I mentioned our problems to the guys at the Linux User Group Meeting on Tuesday evening and Paul (who Penri and I used to work with), suggested an alternative approach; a magnetic sensor. The attached diagram should illustrate the technique. The beauty of this design is that anything carrying electricity is sealed from the water inside a tube. The collar that has been drawn at the bottom of the tube will slide up and down it as the water level rises and falls. When the collar is adjacent to a reed relay, then it will be energised and an active high signal will be routed to the Pi. (Active low designs are also possible if required and may be better.)

Those are the advantages, but there are some disadvantages of such a system:
  1. Mechanical problems:
    1. Debris in the water could get between the collar and the tube, jamming it in one place.
    2. If the sensor is placed inside a bigger tube (such as we might want to do at the butts), the sensor will have to be very narrow or the outer tube very wide to avoid debris in the water getting between the collar and the outer tube, jamming it in one place.
  2. Electrical / Electronic problems:
    1. How do we know where the collar is if it is floating between relays?:
      1. Lots of relays, so that one is always energised. That becomes a problem in itself because we would then need a lot of GPIO pins and buffers.
      2. Keep track of what relay last triggered and assume that the level is in that 'zone'.
    2. There may be more problems that I haven't thought of.
So it could be a good approach but will need some thinking about. Any ideas on how to improve this / solve the problems identified? Also, any other problems/
Attachments
Prototype_Magnetic_Levels_Probe_V0.1.odg
(17.21 KiB) Downloaded 81 times
Terry
TerryJC
Posts: 2616
Joined: 16/05/2017, 17:17

Re: Magnetic Levels Probe

Post by TerryJC »

I've posted this update as I've been thinking about this design and I've also realised that my original diagram made an error; I was refering to Reed Relays instead of Reed Switches, which is of course what I meant. CPC do these from 53p + VAT each, so a system like this could end up cheaper than the Resistance Probe where each level needs a transistor and a LED, as well as resistors, etc and the whole thing has to be mounted on a piece of Veroboard.

I've also thought of another solution to one of the problems that I posed earlier:
TerryJC wrote:
  1. Electrical / Electronic problems:
    1. How do we know where the collar is if it is floating between relays?:
      1. Lots of relays, .......
      2. Keep track of what ........
      3. Make the 'collar' deep enough to energise the next relay just as the previous one de-energises. (This will require a fairly large magnet or lots of little ones.)
Updated diagram attached.
Attachments
Prototype_Magnetic_Levels_Probe_V0.2.odg
(17.19 KiB) Downloaded 83 times
Terry
Penri
Posts: 1284
Joined: 18/05/2017, 21:28

Re: Magnetic Levels Probe

Post by Penri »

Terry

I like it, well worth thinking through and putting together a prototype.

The LEDs are only on the resistance probe prototype to give us a visual indication of what we should be seeing, would we need them on the production item?

Thought, we could use Hall effect devices instead of reed switches.

Penri
TerryJC
Posts: 2616
Joined: 16/05/2017, 17:17

Re: Magnetic Levels Probe

Post by TerryJC »

Penri wrote:The LEDs are only on the resistance probe prototype to give us a visual indication of what we should be seeing, would we need them on the production item?
Probably not. Once we have the Visitor / Staff GUI, we won't need to physically look at the probe any more.
Penri wrote:Thought, we could use Hall effect devices instead of reed switches.
I'm sure we could, but they would need some interfacing electronics I would have thought; to turn the pulse into a logic level signal. Also, the cheapest Hall effect sensor at CPC is about 12p +VAT more expensive than a reed switch, so it wouldn't save us any money.

I suspect we would still have the same problem with inter-level ambiguity as with the reed switches too.
Terry
Penri
Posts: 1284
Joined: 18/05/2017, 21:28

Re: Magnetic Levels Probe

Post by Penri »

Terry

I sort of agree with you, and not, on the reed / Hall effect issue.

Reeds are perfect when they work but they are fragile, prone to sticking if not uses, prone to wear out if overused, etc. Remember (at work) we always provided a self test to ensure they were functional and to locate the suspect ones and I can recall us having a relay rattler on the miniFLITS to make sure they didn't stick.

I know I'm talking about relays as opposed to switches, in ATEs we didn't necessarily have control of the signals that travelled through them and reeds have a long pedigree as sensors in alarm systems.

Hwyl

Penri
TerryJC
Posts: 2616
Joined: 16/05/2017, 17:17

Re: Magnetic Levels Probe

Post by TerryJC »

Penri wrote:I know I'm talking about relays as opposed to switches, in ATEs we didn't necessarily have control of the signals that travelled through them and reeds have a long pedigree as sensors in alarm systems.
The biggest problem with the relays in ATE was when they were only used to switch very small currents because the contacts would oxidise. I remember that on one project (about 20 years before miniFLITS) we developed a 'pre-wetting' routine to 'blast' the oxidisation away. Reeds could probably made reliable if we ensured that the current being switched was reasonably large. This is all grist for the development mill and we will need to compare the pros and cons of each solution:
  • Reeds are very simple, with nothing in the probe other than the switches and the magnet, but they can be unreliable.
  • Hall effect has nothing to wear out, but the electronics is more complex.
  • Optical has nothing to wear out, but the electronics is more complex and we may have to clear the optical path from time to time.
Terry
Penri
Posts: 1284
Joined: 18/05/2017, 21:28

Re: Magnetic Levels Probe

Post by Penri »

Hello all

I've had an enjoyable day in the workshop today and have built the core of a prototype magnetic level probe based on Hall effect switches (A3144 - data sheet attached). The attached photographs will give you some idea of what it looks like.
IMG_1348.jpg
IMG_1348.jpg (1.41 MiB) Viewed 1301 times
IMG_1349.jpg
IMG_1349.jpg (1.27 MiB) Viewed 1301 times
IMG_1350.jpg
IMG_1350.jpg (2.35 MiB) Viewed 1301 times
IMG_1351.jpg
IMG_1351.jpg (1.02 MiB) Viewed 1301 times
The led bar graph module is there for debugging purposes but I may keep it for the finished prototype when I've worked out how to mount this assembly in a waterproof container. For the container, my current plan is to use a 21.5mm waste pipe which I will seal with a home made blanking plug at the 0mm end, with some assembly in which I can fit a waterproof connector at the other end.

The magnetic float will be the challenge that follows that.

I've tested the assembly, hand holding the magnets, with a DC supply set at 12V and 5V, it worked. An led only comes on when a magnet is held fairly close to its corresponding sensor.


Hwyl

Penri
Attachments
A3141-2-3-4-Datasheet.pdf
(735.22 KiB) Downloaded 87 times
TerryJC
Posts: 2616
Joined: 16/05/2017, 17:17

Re: Magnetic Levels Probe

Post by TerryJC »

Penri,

A quick reply before I go to the shops.

This is looking good. If I understand you correctly, the cirscuit behind the Hall-effect sensors includes an active device, so I shouldn't need to design pull-ups into the Interfacing Board?
Terry
hamishmb
Posts: 1891
Joined: 16/05/2017, 16:41

Re: Magnetic Levels Probe

Post by hamishmb »

Hi,

I am to be honest finding this confusing due to my limited knowledge of electronics XD. Nevertheless it's very interesting and sounds like it could be a better alternative to a resistance probe. According to your datasheet the switches were retired from production quite some time ago, but it certainly sounds good.

Out of interest, did you work for/with Allegro Microsystems? They seem pretty interesting.

Hamish
Hamish
Penri
Posts: 1284
Joined: 18/05/2017, 21:28

Re: Magnetic Levels Probe

Post by Penri »

Hello

Taking the questions in turn:
Terry's - pull ups are required, we can put them at the probe end, with a visual display, as per my prototype or we could put them at the interface board end, pros and cons to either approach, we can discuss.
Hamish - Will explain how it works when we meet. I read the out of production notice on the data sheet after I ordered the devices via eBay, will do some more research before we commit for production but as they were only 10p each not a lot is lost either way. No I didn't work for Allegro.


Hwyl

Penri
Post Reply