Getting different sensor data to pc using arduino

Hello All,

I am really new to arduino and currently I am working on a digitisation project. I want to collect data from two different sensors which have outputs as below. I want to save the data in txt format.

  1. CO2 flow meter having 4 to 20 mA sensor output
  2. Water flow meter having a pnp type sensor output.

My questions are

  1. How can connect these sensors to PC using arduino? If any body can explain me in detail that will be great.
  2. Can I connect the two sensors to one arduino uno board?
  3. What is the program to read and save data on PC?

I want to use Python as my scripting language for this.

  1. Use Serial.print() to send the sensor data to the PC. A terminal program like TeraTerm or Putty can be connected to the Arduino COM port and log the data to a text file.

  2. Yes. Plenty of examples on line.

  3. Any terminal program, or write your own program to read the serial port.

Hello,
Is there any documentation available for connecting sensors to arduino where a step wise procedure is given?

Please understand I am really new. Just bought my first arduino uno today.

There are countless tutorials on line describing in detail how to connect sensors to Arduino. Google "arduino water flow meter" for example.

There are also many examples built in to the Arduino IDE (the software development package), to instruct in simple uses of Arduino. From the File menu select Open>Examples> and sift through the dozens of them. Turn on an LED, blink it, read a voltage, a switch, etc.

Finally, the on line Arduino Reference tells you how all the built in functions are to be used.

Arduino is programmed using C/C++, so if you are not familiar with those languages, there are countless tutorials and on line references.

1 Like

You really are new. :grin:

Despite the hype, the UNO is a very poor choice for a "real" project; the Nano is far more practical. :sunglasses:

Oh well ...

You of course, program the Arduino with "C" (some version, whatever), not Python. Python for the PC.

You show us the datasheets for the sensors and we can work you though it.

I can not attach data sheets here as it is giving me error while trying to upload them here.

But, Below are the details :slight_smile:

  1. Air flow meter : 4mA to 20 MA output type. Operating voltage 24 V.
  2. Water flow meter : Pnp type output
  3. Two meters for percentage of CO2 in air which hav 0 to 10V output type.

Now I need to connect these meters to arduino and get their outputs in an excel csv file.

Just insert the Web links,

Google "Arduino 4 to 20 ma sensor" for several tutorials.

Water flow meter : Pnp type output

Google "arduino pnp sensor" for several tutorials.

Two meters for percentage of CO2 in air which hav 0 to 10V output type.

Use two 5K resistors to make a 2:1 voltage divider, and connect the divider output to an analog input on a 5V Arduino. Don't forget to connect the grounds.

This is a big project for a beginner, so you should learn to read one sensor at a time. Avoid the temptation to put everything together, until you understand each part completely.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.