💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel
-
@Nca78 said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
@NeverDie and what is your approximative power consumption with the photoresistor ?
With the photoresistor installed, current consumption for the entire node measures out at 4ua in the dark and 7.2ua in full saturation brightness. That compares to 3.9ua current consumption for the node with no photoresistor installed.
I'm still waiting for the I2C light sensor to arrive. However, as these photoresistors cost only a little more than 2 cents each for a pack of 50 (see above Aliexpress link), I think they're a reasonable choice for a refrigerator app, where it's going to be completely dark most of the time anyway.
-
@Nca78 said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
@NeverDie and what is your approximative power consumption with the photoresistor ?
With the photoresistor installed, current consumption for the entire node measures out at 4ua in the dark and 7.2ua in full saturation brightness. That compares to 3.9ua current consumption for the node with no photoresistor installed.
I'm still waiting for the I2C light sensor to arrive. However, as these photoresistors cost only a little more than 2 cents each for a pack of 50 (see above Aliexpress link), I think they're a reasonable choice for a refrigerator app, where it's going to be completely dark most of the time anyway.
@NeverDie said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
I'm still waiting for the I2C light sensor to arrive. However, as these photoresistors cost only a little more than 2 cents each for a pack of 50 (see above Aliexpress link), I think they're a reasonable choice for a refrigerator app, where it's going to be completely dark most of the time anyway.
Yes it's nearly not changing the consumption in sleep so if you have only a basic use for dark/light it's a waste to use an i2c sensor, which will use more energy most of the time.
-
@nca78 What would be a good tiny buzzer to put on it, for making one of those ever popular location tags? I'm guessing something piezo? I'm not finding anything tiny though.
-
-
@neverdie this looks pretty small for a buzzer already. Sorry no idea about smaller ones, but please post your results I'm interested :)
-
I finally received the MAX44009 board:
https://www.aliexpress.com/item/Smart-Electronics-5PCS-lot-MAX44009-ambient-light-sensor-is-the-I2C-digital-output-module-development-board/32767691971.html?spm=a2g0s.9042311.0.0.sOFetX
I'm able to read lux values by pulling A0 on the board to Vcc and using this library and sketch:
https://github.com/dantudose/MAX44009/blob/master/Example/Luxmeter.ino
Very easy. :) -
I finally received the MAX44009 board:
https://www.aliexpress.com/item/Smart-Electronics-5PCS-lot-MAX44009-ambient-light-sensor-is-the-I2C-digital-output-module-development-board/32767691971.html?spm=a2g0s.9042311.0.0.sOFetX
I'm able to read lux values by pulling A0 on the board to Vcc and using this library and sketch:
https://github.com/dantudose/MAX44009/blob/master/Example/Luxmeter.ino
Very easy. :)@neverdie you don't even need to bother with a lib, just 2 functions are enough.
https://blog.kkessler.com/tag/max44009/ -
even if it's two functions only, if i need to reuse them in others sketch, I would prefer them in a lib. Only "one line" (include) in the sketch compared to x lines ;)
-
@neverdie this looks pretty small for a buzzer already. Sorry no idea about smaller ones, but please post your results I'm interested :)
@nca78 said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
@neverdie this looks pretty small for a buzzer already. Sorry no idea about smaller ones, but please post your results I'm interested :)
Received it today. Putting just DC across it produces no sound at all. Driving it with a pulsed voltage (say 10K hertz at 50% duty cycle) directly from an arduino pin produces sound, but at very low volume. Since it draws 220ma with a straight 3v DC voltage across it, I'm guessing a current more like that is what it will take to get it to produce louder sound, but that's only just a wild guess.
-
@nca78 said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
@neverdie this looks pretty small for a buzzer already. Sorry no idea about smaller ones, but please post your results I'm interested :)
Received it today. Putting just DC across it produces no sound at all. Driving it with a pulsed voltage (say 10K hertz at 50% duty cycle) directly from an arduino pin produces sound, but at very low volume. Since it draws 220ma with a straight 3v DC voltage across it, I'm guessing a current more like that is what it will take to get it to produce louder sound, but that's only just a wild guess.
I tried driving it from a load switch controlled by the arduino, and that helped increase the volume somewhat.
Doing that, and using this script, I think it will be audible if you're in the same room as it (and if the room is otherwise quiet).
long lastMicrosTime=0; //timestamp in microseconds void setup() { pinMode(10,OUTPUT); } void loop() { for (int x=0;x<1000;x++) { digitalWrite(10,HIGH); lastMicrosTime=micros(); while ((micros()-lastMicrosTime)<300) {} //wait until 300 microseconds have passed digitalWrite(10,LOW); while ((micros()-lastMicrosTime)<x) {} //wait until another x microseconds have passed } }So, if you were to use it as a locator beacon attached to something you wanted to find, it might be good enough for that.
-
I tried driving it from a load switch controlled by the arduino, and that helped increase the volume somewhat.
Doing that, and using this script, I think it will be audible if you're in the same room as it (and if the room is otherwise quiet).
long lastMicrosTime=0; //timestamp in microseconds void setup() { pinMode(10,OUTPUT); } void loop() { for (int x=0;x<1000;x++) { digitalWrite(10,HIGH); lastMicrosTime=micros(); while ((micros()-lastMicrosTime)<300) {} //wait until 300 microseconds have passed digitalWrite(10,LOW); while ((micros()-lastMicrosTime)<x) {} //wait until another x microseconds have passed } }So, if you were to use it as a locator beacon attached to something you wanted to find, it might be good enough for that.
@neverdie said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
Doing that, and using this script, I think it will be audible if you're in the same room as it (and if the room is otherwise quiet).
Guess this is not made for Vietnam then :D
I supposed this type of buzzer is made more for user feedback for things like touch sensors, than for raising alert. -
@neverdie said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
Doing that, and using this script, I think it will be audible if you're in the same room as it (and if the room is otherwise quiet).
Guess this is not made for Vietnam then :D
I supposed this type of buzzer is made more for user feedback for things like touch sensors, than for raising alert. -
Here's the latest version of the PIR sensor embodiment:

It runs from two CR2032's.Very compact! :)
-
Here's the latest version of the PIR sensor embodiment:

It runs from two CR2032's.Very compact! :)
@neverdie how do you connect thr two Cr batteries ?
Another question ? I read in another comments that you need 100-200 uF capacitor so that the radio can work since thr CR battery wont be strong enough. Did you add this ?
-
@neverdie how do you connect thr two Cr batteries ?
Another question ? I read in another comments that you need 100-200 uF capacitor so that the radio can work since thr CR battery wont be strong enough. Did you add this ?
@ahmedadelhosni said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
how do you connect thr two Cr batteries ?
This was recently discussed in the Bluetooth action! thread.
-
@nca78 What strange is that if I cup my hand over it, it actually becomes louder. Not sure what's up with that. So, maybe I'm just not driving it right.
@neverdie said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
@nca78 What strange is that if I cup my hand over it, it actually becomes louder. Not sure what's up with that. So, maybe I'm just not driving it right.
Isn't that the principle for most speakers, using a sound box ?
-
Wich board do you use in arduino? I can only use Waveshare BLE4.0. At Generic etc. It seems, that the oscillator doesn't work probably.
@tiwo85 said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
Wich board do you use in arduino? I
Not sure what you're asking.
-
@tiwo85 said in 💬 Multi-Sensor: Temp/Humidity/PIR/ Leak/Magnet/Light/Accel:
Wich board do you use in arduino? I
Not sure what you're asking.
