Simple block detector - zero loss

Post Reply
Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Re: Simple block detector - zero loss

Post by Richard-TX » 23.02.2014, 16:54

Neither of my biasing circuits work. :(

Oh well. It was a nice idea.

rjversluis
Site Admin
Posts: 42321
Joined: 10.04.2006, 08:48
Location: Speyer, Germany
Contact:

Re: Simple block detector - zero loss

Post by rjversluis » 23.02.2014, 17:06

The idea is not new.
Peter also made a test case and can only detect loco's or 1kOhm.
He will wait for special transistors and if that does not bring the promised result he will dump the idea too.

Maybe this link can help you:
http://dcc-mueller.de/wire4dcc/sensor_e.htm

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Re: Simple block detector - zero loss

Post by Richard-TX » 23.02.2014, 17:18

I can reliably detect 30k ohm loads with an ADC. :D

WIth the current TTL circuit, I can reliably detect two LEDS but not one.

There is one more thing that I can try to brig the TTL version down to 10k ohm detection. I will post the results in a little while.

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Re: Simple block detector - zero loss

Post by Richard-TX » 23.02.2014, 17:30

I just realized that I have been using the wrong current transformer for my tests. No all current transformers are the same. :shock: :shock:

Sometimes I am my own worst enemy.

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Re: Simple block detector - zero loss

Post by Richard-TX » 23.02.2014, 18:28

This biasing circuit does work. :D I can get at least 2x sensitivity.
A 10 turn Bourns trimpot is recommended.
You do not have the required permissions to view the files attached to this post.
Last edited by Richard-TX on 23.02.2014, 18:39, edited 1 time in total.

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Re: Simple block detector - zero loss

Post by Richard-TX » 23.02.2014, 18:32

For any of these circuits to work right, a Murata 56100C is mandatory.

Do not substitute!

rjversluis
Site Admin
Posts: 42321
Joined: 10.04.2006, 08:48
Location: Speyer, Germany
Contact:

Re: Simple block detector - zero loss

Post by rjversluis » 23.02.2014, 18:37

Hi Richard,

congratulations. ;)
But I do not like the trimpot; The circuit should work under all conditions without any.
Further more the circuit should provide an interfacing to the CAN-GC2, GCA50 or GCA-Pi02.
An ADC connection does not come in question what my support concerns.

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Re: Simple block detector - zero loss

Post by Richard-TX » 23.02.2014, 18:55

Rob,

I will come up with a fixed resistor value. It will be next week before I can determine that. I am waiting for my order of Murata transformers as the few I have are being tested with the ADC. I was able to find 10 turn, 10k Trimpots for $0.13 each.

Being able to detect very small voltages is where the ADC excels. A bipolar transistor needs about .6 Vbe to turn on. The ADC can detect .02 volts which means the ADC is about 30X more sensitive.

This circuit will and does work with the MCP23017. As far as the rest of the interfaces go, I cannot test with them as I do not have them. If those other interfaces present a the same load as the MCP23017 does, then I see no reason why it won't work.

rjversluis
Site Admin
Posts: 42321
Joined: 10.04.2006, 08:48
Location: Speyer, Germany
Contact:

Re: Simple block detector - zero loss

Post by rjversluis » 23.02.2014, 19:16

Richard,

how much time does the ADC need to detect?
It should be below 100ms otherwise its too slow.

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Re: Simple block detector - zero loss

Post by Richard-TX » 23.02.2014, 20:31

The sample time for the ADC is dependent on the I2C Clock rate. In the case of the Rpi, the clock rate would be 100 kc.
Since the default mode of the PCF8591 is sample and hold, and you are polling the ADC roughly every 10ms, the maximum delay for a single read is the polling time or 10ms.

The data sheet says basically the same thing:

"An A/D conversion cycle is always started after sending a valid read mode address to a
PCF8591 device. The A/D conversion cycle is triggered at the trailing edge of the
acknowledge clock pulse and is executed while transmitting the result of the previous
conversion
"

In short the delay is one read cycle. If you read the ADC twice per poll, the delay time is now the time it takes to transmit the read request and to read the data. It might be a good idea to double read the ADC. If the result of 10 ms ago agrees with the current value, the reliabilty of the data read is very high. In other words what is actually happening is 2x oversampling.

RainerK
Moderator
Posts: 4078
Joined: 29.04.2009, 09:31
Location: Sprockhövel (zwischen BO u. W)
Contact:

Re: Simple block detector - zero loss

Post by RainerK » 24.02.2014, 07:37

Hi together,

in how many cases is it a problem to loss 1.4 Volt in current detectors,
if You use dummy detectors (only diodes) in non detecting rail sections ?

IMHO near Zero :!:

So I can't see an advantage to drive such an (not cheap) effort with a danger to fail,
because a tricky fine adjustment is necessary and its possible to get faulty ingress. :shock:

All examples You can found in the web, document only prototypes
and no use over longer time and with more as a handfull feedback points. :roll:

My recommandation is:
Hands away from this very probably frustrating adventure :!:

Best Regards
RainerK

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Re: Simple block detector - zero loss

Post by Richard-TX » 24.02.2014, 19:26

RainerK,

The losses of the diode detector are indeed minimal, but the engineer in me likes zero-loss detection. 8)

This project has been one that I have been experimenting with off and on for the past several months. I have tried a variety of circuits and rejected them all for either being too complex or for their lack of sensitivity. Even the commercially made units like the NCE BD-20 are not sensitive enough assuming 1-1/2 to 2 turns for the primary. The biggest breakthrough occurred when when I received and tested the Murata transformers. That was when I realized that I had found the answer.


The project originally had four goals.

1 - zero loss detection of a loco or LED.
2 - simple to construct on an experimenter's 5x7cm PC Board.
3 - lower cost than a commercially made product. (Commercial zero-loss detectors are $12-$15 each.)
4 - minimal parts count.

Rob later suggested that the load requirement be changed to a 10k ohm resistor (~1.2 ma)

I first decided to use an ADC connected to a Raspberry Pi. With an ADC I don't have to worry about amplifying the signal to TTL levels.

Then Rob then suggested a TTL version for those that want to use it with things other than a Raspberry Pi.

The ADC version works well and does not need anything except for some software. I will likely bang out some python code on the Raspberry Pi and send the sensor information back to Rocrail via SRCP. Why SRCP? Because it is so very easy to do.

The TTL version is something that I want a certain margin of error with. While the specification calls to detect a 10k ohm load, I want the ability to detect at least a 12k ohm load.

The latest TTL circuit is as complex as I want to make it. I would rather that the biasing circuit not even be there. I did it for two reasons.

1 - To see what the results would be. (I am seeing about a 2x increase in sensitivity)
2 - Because I could.

Further tests are needed on the TTL version and the results of those tests will determine everything. It will be 3-4 days until I can complete my tests.

Here is the current status of the project.

- The ADC version is done. Rpi software will follow. Cost is about 1/8 of a commercial product.
- The TTL version is being tested. Test results within a week. Assuming all goes well, the cost is less than the ADC version.

I am having fun with this project. :D While this isn't for everyone, I hope that others will have fun with it too.

Happy Modelling!

Richard

RainerK
Moderator
Posts: 4078
Joined: 29.04.2009, 09:31
Location: Sprockhövel (zwischen BO u. W)
Contact:

Re: Simple block detector - zero loss

Post by RainerK » 25.02.2014, 06:39

Hi Richard,
Richard-TX wrote:...I am having fun with this project. :D While this isn't for everyone, I hope that others will have fun with it too...
thats a glance on Your project, I can accept.
But nevertheless, all other modell railroader should consider:
It's a time-devouring project with no garantee for stable operation.

Best Regards
RainerK

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Re: Simple block detector - zero loss

Post by Richard-TX » 25.02.2014, 09:59

RainerK,

I thank you for your concerns. I appreciate the criticism.

I agree that there are no guarantees except to say that:

1 - The base concept works and works well enough that commercial products like the NCE BD-20 are based on it.
2- It works for me on my layout and is rock solid. No noise, false triggers, etc.
3 - The ADC version reliably detects a 20k ohm load. Even greater sensitivity can be achieved by adding more turns to the primary.
4 - The monetary risk is minimal at $10-$12 for 4 sensors. Compare that to the NCE BD-20 which would cost $50-$60 for 4 sensors.

I think some people need to build it and try it. The merit of a design can be determined by independent and successful duplication.

I should have some software ready late tomorrow for those that want to build a 4 sensor ADC version.

I will post a full schematic for the ADC version suitable for use with a Rpi later today.

Richard

If anyone in the USA wants to try building one, let me know. I am willing to help.

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Re: Simple block detector - zero loss

Post by Richard-TX » 26.02.2014, 02:35

Here is the full schematic for the ADC version of the Block Detector.

Image

A larger picture is at http://mymachineryforum.com/download/file.php?id=25

Post Reply

Return to “DIY Hardware”