Skip to content

sn4k3/WaterDispenser

Repository files navigation

WaterDispenser

Consuptions

LCD

Each option is based on a good initialized lcd module. A line of text is printed to the LCD on setup.

Code

Upload this code and do the proper connections to the hardware.

void loop(){
	// Idle, backlight on
	DELAY_FUNC(3000);
	on();

	// Idle, backlight off
	DELAY_FUNC(5000);
	lcd.noBacklight();

	// Idle, backlight off, lcd off
	DELAY_FUNC(3000);
	off();
	
}
Results

Probe LCD VCC with a multimeter or a ampmeter.
All values are not 100% correct (+/- mA)

  1. Idle, backlight on: 33.10mA
    1. lcd.backlight();
    2. lcd.display();
    3. Same as lcd.on();
  2. Idle, backlight off: 5.35mA
    1. lcd.noBacklight();
  3. Idle, backlight off, lcd off: 5.23mA
    1. lcd.noBacklight();
    2. lcd.noDisplay();
    3. Same as lcd.off();
Power Optimization

Works with a transistor, but requires a Initalize every ON operation (Slow).
The LCD will be always ON with a timeout on backlight, if user don't perform any action for about X seconds MCU will cut the backlight power.
Since this project shows usefull information as temperature and humidity, the LCD will be in passive mode, allowing the people read some information on the LCD. Still it will require a good level of environment light.
Also a fast feedback from operations are required, without a big delay in a Resume operation.
Awake and User operations must be fluid.

Ping

Each option is based on a good initialized ping module.

Code

Upload this code and do the proper connections to the hardware.

void loop()
{
	// Idle
	Serial.println("Idle");
	delay(5000);

	// Active
	Serial.println("Active");
	for (int i = 0; i <= 10000; i++) {
		sonar.ping_cm();
	}
}
Results

Probe sensor VCC with a multimeter or a ampmeter.
All values are not 100% correct (+/- mA)

  1. Reading data: 8mA
  2. Idle: 5.55mA
Power Optimization

Works great with a transistor.
This sensor is only used when needed or when user perform an action, a transistor will be used to control power ON or OFF in order to spare power.
Awake operation is almost instantaneous without requiring a preheat.

BME280

Each option is based on a good initialized BME280 module.

Code

Upload this code and do the proper connections to the hardware.

void loop()
{
	// Active
	Serial.println("Active");
	lcd.clear();
	BME280.update();
	Serial.print(BME280.data.temperature);
	Serial.print(" ");
	Serial.print(BME280.data.humidity);
	Serial.print(" ");
	Serial.print(BME280.data.altitude);
	Serial.print(" ");
	Serial.println(BME280.data.pressure);
	
	// Idle
	Serial.println("Idle");
	delay(5000);
}
Results

Probe sensor GND with a multimeter or a ampmeter.
All values are not 100% correct (+/- uA)

  1. Reading data: 470uA
  2. Idle: 460uA
Power Optimization

This module uses a very low power sensors.
This kind of sensors require preheat time to give accurate reading, in this case and given the low power consuption will be always on.
Power libraries will take care of extra optimization over I2C ports.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages