1

home automation is driven by a PC running Ubuntu. It currently has a 1-wire network of thermometers for managing our geysers and solar water heaters. I would like to extend it to manage our water pumps. The first problem I would like to solve is to measure the volume of water in the overhead tank. I couldn't see any 1-wire compatible distance sensor. I am ok with using a different setup to measure the water level, but would prefer if the sensors (say HC-SR04 or others) could be connected to my USB through some adapters/read made hardware.

  • Instead of setting up an Arduino or raspberry pi, etc. Any USB to general IO board adapter, that can be used to drive the sensors?

  • Any other recommended approach?

Electric_90
  • 2,112
  • 13
  • 25
melchi
  • 113
  • 3
  • 1
    I could be wrong, but maybe look into the FT232RL drivers from FTDI... you might be able to control DTR / RTS signals in one of their off-the-shelf cables, but you might not be able to pull quickly enough to accurately measure distance from pulse echos.... – vicatcu Apr 04 '19 at 03:20
  • 1
    @vicatcu No, a USB I/O chip will not work for this, as the latency is too great. What is required is an external MCU to take the tightly timed measurement - essentially the very "Arduino" (or its functional equivalent) that the asker wants to avoid, is the precise thing that this task requires. – Chris Stratton Apr 04 '19 at 05:35
  • For a one time design use cheapest Arduino clone that has usb connection + HC-SR04+ ping example. You can change the output format as you wish. Anything else is way more complicated and/or expensive – Dorian Apr 04 '19 at 07:50

1 Answers1

0

I would point that Arduino + HC-SR04 + blink example is the cheapest, quickest and easiest available solution. I guess that the tank is not in the proximity of the PC and you also have to deal with the USB 5 meters max cable length which it's not the case for a serial connection + usb to serial adapter.

See here some USB distance sensors. They use serial over USB. As Chris commented, there is no simple USB interface to read pulses length.

Dorian
  • 2,546
  • 2
  • 11
  • 20