3.3 V or 5 V sensors?

I use 5 V boards (Uno and NANO).

Therefore I have to go for 5V LED Display and 5V sensors. One problem is that I have to pay attention to level shifting - which I still jave to learn how to.

The question is:

  • Shall I keep 5V boards (Nano has nice pins and 5 V are easy to obtain, also an wonderful piece - you reccomanded this one in this forum some 9 months ago - thank very much!)
    or
  • Shall I move to 3.3 Boards and therefore no 5V sensor in hand? Are they available (or connectable) sensors on 3.3V? Of course I can search the net, but I do not need the commercial info.

+++++

So far, I mounted: DHT22, BMP280 (that I hate), temt6000, various light and colour sensors (which I found rather tricky).

In hand: UV and IR sensors.

Preferred method: I2C (I use the dedicated library and no plans to give up:-))

I also have some wonderful experience with EEPROM (thanks to you guys - hope you remember me from the summer), which I plan to log the data.

The final products are to be used outdoor.

I am looking for a down-to-Earth opinion, related to the future and availability of the devices, based on experience and/or professional background. On Arduino, of course.

I read the following:

But does not mean to much to me in practical terms. On other words, if I want to mesrue temperature, pressure and humidity on a 3.3. V Board, using 3,3. Sensors, whould that be feasible at the same level of complexity as I get for a 5 V arhitecture?

The decision means for me spending and learning for the next years (hopefully).

The reason why the question is in this section is that the main concern is sensors.

Thank you!

In my experience, most sensors work fine on 3.3V, just a few require 5V (there are versions of the HC-SR04 ultrasonic sensor that need 5V, mine work great at 3.3V).

Many sensors can't handle 5V and need level shifting - a single level shifter for a 3.3V I2C bus can connect many such sensors. Though many breakout boards have a regulator and level shifters on board (most Adafruit boards do - Sparkfun tends to not add this extra circuitry).

Precision and overall complexity of a 3.3V system will be pretty much the same as a 5V system, but you'll be able to do away with level shifters. If you want to use the ATmega or ATtiny microcontrollers you will have to reduce the clock speed to 8 or 12 MHz, as they can't do the full 16-20 MHz on that lower voltage.

The 3.3 V board that I found locally is this one:

Adafruit: "95% compatible".
must The Arduino MKR 1000 has to be powered by 5V, but works at 3.3. V. Ok, but I have to set a common ground for a 5V source, 5 V board, 3.3.V logic and 3.3. V senors. Not sure I can handle.

Don't buy frankenduino boards.
Try to use the official Arduino boards (or clones) as much as possible. They will be supported for many years.
The Pro Trinket uses a ATmega328P microcontroller with a special library for USB. You need to install extra software from Adafruit for it, that means you are depending on Adafruit for support and bug fixes.

The MKR1000 is a 3.3V board, because the processor runs at 3.3V. It is expensive... :frowning:

My first board was (and is) a genuine Arduino UNO. Great piece. Took all my stupidities on board without meowing.

Then I switched to a clone of Nano (CH340), because I did not want to use shields and the Nano can be transferred to PCB.

I had bad experience with Adafruit sensors library. To mount a DHT22 I need to install 2 libraries. Ok, but when adding BMP_280 the dedicated library refused to work, so I have to install the Sensors I2C library (a contributed one, very nice), which has nothing to do with the Adafruit sensors master library.

To much time and effort in juggling with libraries. For one or two sensors may be OK, but for more It comes to the fact that I better use 2 boards.

Now I have 3 sensors mounted on my board:

DHT22
BMP280
TEMT6000

to a 1602 Display.

If I add one more (which I am going to do anyway), the LCD shall go scrolling (or flipping) = more coding. And I have to take care about voltage = + 1 regulator.

Now, my bizarre conclusion:

Why not one nano (or similar) + 1 Sensor (or 2) + 1 Display , in place of all this mess of wires, coding and stubborn libraries?

If I go for 3.3. boards (and find acceptable chep ones), I can use (maybe) one unit of 3.7 18650 LiIon for all boards.

You want too much too fast. There is no single solution that does it all.

I still use an Arduino Uno for most things: testing, simple projects.
To find a good library, you need our help. Arduino is open source, so everyone can make a library.
Don't forget to write in the sketch which extra libraries you use and where they come from :wink:

Using a 3.3V board with I2C sensors is a good option.
The ARM Cortex M0+ core is a nice processor, they are used in the Arduino Zero, MKR1000, M0, and also in many Adafruit Feather series boards.
Using I2C is slow, when you want to process a lot of data at high speed (a robot, drone, glove) then you have to look for sensors with SPI interface.

The BME280 includes a humidity sensor, which is many times more accurate than a DHT22. The temperature of the BME280 is however less accurate than a DS18B20.
Perhaps a I2C light sensor can give extra information for fun (UV, light color).

The LCD displays are so ugly. Perhaps you want to use a 3.3V OLED or Nextion display some day. Maybe you want to show the data on a webpage in the future.

What I'm saying is: Start with a Uno, make a project with, keep that project or make something better. Move forward with the M0+ processor for normal projects. The WeMos ESP boards for wifi is also a good option.

The reason I go for I2C is the clarity:

One device = one address.

Two wires = all devices

For the time being I am not concerned about the speed, but about the allowed number of the sensors.

When the sensor is not an I2C component, it should be a way to bind it to the I2C bus. I imagine no sensor is born I2C, anyway. Still digging in this issue.

+++

The version I have is a BMP, namely has no humidity component, but only pressure and temperature ones.

When I mount the TEMT 6000 along with DHT22 and BMP280 (on I2C), the "altitude" decreases by 200 meters. I suspect some drop in the ref voltage, but I didnt have the time to measure.

Right now I am struggling to figure out how to wire correctly the BMP280 (the one you saved, remember? :-)) on a logical level shifting to a Nano.

falexandru:
When the sensor is not an I2C component, it should be a way to bind it to the I2C bus.

I2C is probably the most used interface for sensors, for the exact reasons you state above. Speed is for most sensors not an issue (the bus can easily do 400 kbps). It's also my preferred bus, nice and easy to work with.
The BMP180/BMx280 only offer I2C interface.
The TEMT6000 is a very cheap light sensor producing an analog output (and it can't even handle bright sunlight) - better light sensors like the TSL2561 and TSL2591 offer an I2C interface and are much harder to saturate.

But besides sensors many other peripherals work with I2C, including the ADS1115 ADC, the various port expanders, etc.

You can measure the altitude with a GPS receiver, not with those sensors. Measuring the altitude can be done if you know the height that you are at, and the baromic pressure at sea level.
If the baromic pressure in kPa changes when another sensor is connected, that would be something to investigate.

An I2C level shifter has a high side and a low side. The high side is the 5V I2C bus and the low side is the 3.3V I2C. It needs both 5V and 3.3V voltages, or else the level shifting won't work.

The Master can be on the 5V I2C bus and on the 3.3V I2C bus. It does the level shifting both ways.

Indeed, a barometric sensor cant be used to measure altitude. That was for demo only. I was expecting the "altitude" to vary with the pressure.

But it was strange to see the altitude varying after linking the TEMT6000 sensor, which is a poor simple analogue sensor.

I imagine TEMT does not draw so much to decrease the voltage (which is something I suppose it happened, if not mistaken). The Data sheet cant help, it is about real life here :-).