>
Table of content

Notebook - SleepNon24LightSensorNotes

SleepNon24LightSensorNotes

Créée le jeudi 22 octobre 2020

Best vendors: mchobby.be and mouser.be

BEST FINAL LIGHT LUX AND SPECTROMETER (COLOR) SENSOR DIY:

madbodgerAujourd’hui à 14:05
I think a LiPo cell would be fine. If a person is wearing it, it's not going to get too hot, and they would presumably notice if it started to swell up or something.
lrq3000Aujourd’hui à 14:06
ok thank you @madbodger yes that's my reasoning, since lipo can operate up to 60°C usually, it's unlikely even this temperature will be reached since a person will be wearing it
but maybe I can take some additional precautions? Are there techniques to insulate the battery (such as with a tape)?
I'm really new to boards :confused:
interesting read btw on the topic: http://www.batterypoweronline.com/images/PDFs_articles_whitepaper_appros/MicroPowerBatteriesExtreme.pdf
madbodgerAujourd’hui à 14:13
You could add polyimide tape or make sure its protection circuitry included a temperature sensor.
There's this interesting writeup of how you can get skin burns from even low voltage, but I doubt you're going to have any exposed wiring. https://www.sparkfun.com/news/1513
  • polyimide tape = kapton
  • https://en.wikipedia.org/wiki/Kapton
    • "Kapton-insulated electrical wiring has been widely used in civil and military aircraft because it is lighter than other insulators and has good insulating and temperature characteristics. However, Kapton insulation ages poorly: an FAA study shows degradation in hot, humid environments,[5] or in the presence of seawater. It was found to have very poor resistance to mechanical wear, mainly abrasion within cable harnesses due to aircraft movement."
    • "Due to its large range of temperature stability, and its electrical isolation ability, Kapton tape is usually used in electronic manufacturing as an insulation and protection layer on electrostatic sensitive and fragile components. As it can sustain the temperature needed for a reflow soldering operation, its protection is available throughout the whole production process, and Kapton is often still present in the final consumer product."
    • "Kapton and ABS adhere to each other very well, which has led to widespread use of Kapton as a build surface for 3D printers. Kapton is laid down on a flat surface and the ABS is extruded onto the Kapton surface."
  • http://budgetlightforum.com/node/20258 and https://www.rcgroups.com/forums/showthread.php?677844-kapton-Tape
    • "Actually Kapton is really tough stuff, tougher than almost any shrink wrap. I wouldnt mind wrapping a battery with it."
    • can do multiple turns to be more scratch/tear resistant
  • Casing:
    • need to be transparent
    • BEST IDEA: take a casing that filters UV light, so that it is less hot for the battery


https://store.micropython.org/pyb-features
https://learn.adafruit.com/adafruit-apds9960-breakout
batteries how to choose: https://www.youtube.com/watch?v=U_Q3djsktQs
arduino tuto https://www.youtube.com/watch?v=nL34zDTPkcs + https://www.youtube.com/watch?v=p40OetppIDg bloklyduino and shields and node-red
tinycircuits https://www.youtube.com/watch?v=5bb3npa3uDI
flora vs gemma https://www.youtube.com/watch?v=bGVBR4BwIPs



https://www.youtube.com/watch?time_continue=728&v=i-ksb-gzfyE

LiPo battery + LiPo charger module to be able to easily charge through USB
Simply wrap in plastic to make rain resistant
BESTTUTO: https://www.instructables.com/id/Make-your-own-activity-tracker/ + https://github.com/godstale/retroband
soldering iron and wires
"It’s very simple to supply the power. Just connect (+) -> RAW with (-) -> GND. But if you care about recharging, you can use a Li-Po recharging module. In this case, you should connect (+) and (-) connectors on the battery with B+,B- on the recharging module, and out+, out- on the module should be connected with RAW, GND on the Arduino board respectively."
https://www.arduino.cc/en/tutorial/memory --> need to extend EEPROM
use micro-sd card reader! https://create.arduino.cc/projecthub/electropeak/sd-card-module-with-arduino-how-to-read-write-data-37f390
https://www.arduino.cc/en/reference/SD
https://docs.micropython.org/en/latest/library/machine.SDCard.html
https://docs.micropython.org/en/latest/pyboard/general.html
https://itechnofrance.wordpress.com/2019/06/21/utilisation-dune-carte-sd-en-micropython/
pyboard includes microsd https://store.micropython.org/product/PYBv1.1H#image4

micropython vs circuitpython https://www.youtube.com/watch?v=wyOcb2MHzIs

https://www.youtube.com/watch?v=iswES_5HkeM

no bluetooth or later? Because battery cosumption and need to program receiver app, usb is easier

adafruit quickstart with arduino: https://www.youtube.com/watch?v=YDa5FjnT9mw
adafruit history https://www.youtube.com/watch?v=D27U3wHN8fs

TODO: need to mount resistances to mount leds in serial (since there is no other way)? But need to be in input, is resistance needed in input? https://www.youtube.com/watch?v=nL34zDTPkcs
TODO: calculate how much battery is needed: https://www.youtube.com/watch?v=U_Q3djsktQs
TODO: choose between Arduino and MicroPython/CircuitPython
TODO: if can't succeed, just ask someone or Arduino to make such a build under opensource (including software to save as csv) and pay him. I know what sensors to use and how i will wear it (as a pendant), so not hard.

BESTTUTO on capacitors: https://www.youtube.com/watch?v=sy_G1oYRQmM

Energy for light sensors:

need capacitor and 3 pull-up resistors of 10K ohm impedance
bypass capacitor (1 micro Faraday connected between power source and device) that has a low effective series resistance (ESR) and low effective series inductance (ESI), such as the common ceramic types, which provide a low impedance path to ground at high frequencies to handle transient currents caused by internal logic switching.
After removal from the bag, the parts should be soldered within 168 hours if stored at the recommended storage conditions. If times longer than 168 hours are needed, the parts must be stored in a dry box.
Supply Current max: 154 microA in active mode, else 2 microA in standby mode
Accurate CCT, means can derive Kelvin: https://insights.regencylighting.com/what-is-correlated-color-temperature-cct-and-how-do-you-choose-it-for-your-lighting
Supply voltage 1.7V to 3.6V

Vcc supply 2 to 3.6V
27 KOhm resistor, makes output linear
see page 2 for Typical Application Circuit
Supply Current typical: 230 micro A
Appendix B: The thickness of the window should be kept as minimum as possible because there is a loss of power in every optical window of about 8% due to reflection (4% on each side) and an additional loss of energy in the plastic material.
The material of the window is recommended to be polycarbonate. The surface finish of the plastic should be smooth, without any texture.

((150+230)*0.3+4) * 3600/3600 = 118 micro Ah = .118 mAh -- with a 200 mAh battery, it's 200/.118 = 70 days of battery with a continuously recording photoreceptor each second! -- but need to include the board consumption! With pyboard lite without accelerometer, it's 2 days only: (200/(13*0.3)+.118+.180)/24 https://store.micropython.org/pyb-features
A milliampere second (mA⋅s) is a unit of measure used in X-ray imaging, diagnostic imaging, and radiation therapy. It is equivalent to a millicoulomb. https://en.wikipedia.org/wiki/Ampere_hour
BESTTUTO CRITICAL: 1 amp-hour = 3600 coulombs = 3600 amps https://www.allaboutcircuits.com/textbook/direct-current/chpt-11/battery-ratings/
"A battery with a capacity of 1 amp-hour should be able to continuously supply current of 1 amp to a load for exactly 1 hour, or 2 amps for 1/2 hour, or 1/3 amp for 3 hours, etc., before becoming completely discharged. In an ideal battery, this relationship between continuous current and discharge time is stable and absolute, but real batteries don’t behave exactly as this simple linear formula would indicate. Therefore, when amp-hour capacity is given for a battery, it is specified at either a given current, given time, or assumed to be rated for a time period of 8 hours (if no limiting factor is given)."
"Conversely, if a very light load (1 mA) were to be connected to the battery, our equation would tell us that the battery should provide power for 70,000 hours, or just under 8 years (70 amp-hours / 1 milliamp), but the odds are that much of the chemical energy in a real battery would have been drained due to other factors (evaporation of electrolyte, deterioration of electrodes, leakage current within battery) long before 8 years had elapsed. Therefore, we must take the amp-hour relationship as being an ideal approximation of battery life, the amp-hour rating trusted only near the specified current or timespan given by the manufacturer. Some manufacturers will provide amp-hour derating factors specifying reductions in total capacity at different levels of current and/or temperature."
"Watt-hours acknowledges a battery’s voltage and amp-hours ignores it. As long as your units are consistent, either measure will work." https://sciencing.com/watt-hour-vs-amp-hour-12135955.html
"The ampere hour is frequently used in measurements of electrochemical systems such as electroplating and for battery capacity where the commonly known nominal voltage is dropped." https://en.wikipedia.org/wiki/Ampere_hour

BESTTUTO: light sensor on arduino: https://www.youtube.com/watch?v=z9PPfE8dvGs and https://arduinogetstarted.com/tutorials/arduino-light-sensor
https://greenspector.com/en/measuring-the-energy-consumption-of-iot-using-arduino-to-measure-raspberry/
https://learn.adafruit.com/how-to-choose-a-microcontroller
kill a watt meter https://www.parkedinparadise.com/device-calculations/
https://www.edf.fr/groupe-edf/espaces-dedies/l-energie-de-a-a-z/tout-sur-l-energie/l-electricite-au-quotidien/volt-watt-ampere-les-unites-en-electricite

BESTTUTO: diode to protect circuit flow: https://www.youtube.com/watch?v=ap7edIKkykA - light emitting diodes = LED
BESTTUTO: How ICs are number with dot + how to shrinkify any arduino project: https://www.youtube.com/watch?v=30rPt802n1k&t=1s and MIT Media Lab's High-Low Tech Group and https://web.archive.org/web/20111012165316/http://blog.makezine.com/archive/2011/10/how-to-shrinkify-your-arduino-projects.html and https://web.archive.org/web/20111012194731/http://hlt.media.mit.edu/?p=1229 (using ATtiny ICs)
BESTTUTO: how to solder + buy THT (through-hole perfboard) pcb that are not printed, just dots, then can make circuits myself using soldering or jumping wires + socket to put the IC on it so we can replace it if it becomes defective + SOLDER WICK to suck soldering out and remove without breaking! + smallest ICs are made for SMD (surface-mount) boards, so these are actually the smallest boards to make wearables: https://www.youtube.com/watch?v=VxMV6wGS3NY
BESTTUTO: use safety glasses and evacuate fumes https://www.youtube.com/watch?v=JCXGjD0Rpg8
A simple guide to electronic components: https://www.youtube.com/watch?v=6Maq5IyHSuc - electrolytic capacitor round to avoid, obsolete after some time because of eletrolytes drying

  • BEST: LEDs don't have a high reverse blocking voltage since they are optimized to emit light, so it's about 5V max of blocking reverse, whereas non light emitting diodes can block 1000 volts. When the threshold is trespassed, then it avalanches and actually worsen the circuit.
  • use zener diodes for voltage regulation, ie, reduce voltage to exactly the amount required in the circuit
  • transistors and mosfet are amplifiers of ampers and voltage
  • voltage drop (such as with diodes, transistors etc) produces heat dissipation, unless there is very low impedance hence no voltage drop. Mosfet are such low impedance components, but because of that they are not as robust as traditional transistors.
  • Watts = I * V, same as Ohm's law: V = I * R, another triangle.
  • oversize resistor: take more ohm and wattage to dissipate more heat and be more robust
  • electrolytic capacitor is flammable, prefer ceramic or film (polypropylene) or round aluminium polymer (solid electrolytes) capacitors: https://www.youtube.com/watch?v=2v8zBj7_sxg
  • Inductors + electron flow (minus to plus) vs conventional flow (plus to minus) conventions: https://www.youtube.com/watch?v=KSylo01n5FY
  • BESTTUTO on capacitors and how to handle safely and to mount in circuit (need to mount in parallel) - striped face is negative sign: https://www.youtube.com/watch?v=X4EUwTwZ110
How to Troubleshoot Electronics Down to the Component Level Without Schematics https://www.youtube.com/watch?v=QFAWb1F_EpE

etain Solder wire - Low vs High Quality https://youtu.be/5Ku7I3hA3AA


TOBUY:

  • battery LiPo 200 mAh?
  • battery charger through USB
  • breadboard to easily do tests, and breadboard wires (jumpers)
  • resistors, 4 10KOhm + one 27 KOhm
  • bypass capacitor in ceramic 1 micro farad x2 and 10 micro farad for both sensors
  • starter kit with lots of resistors and leds etc maybe?
  • buy leds and diodes, at least 6, to mount in serie to reduce voltage? https://forum.arduino.cc/index.php?topic=20967.0
  • micro sd card breaker (reader)
  • micro sd card of a few gb
  • the 2 photosensors APDS-9007 and APDS-9253
  • soldering iron + solder + solder wick + safety glasses
  • multicolor LED to signal battery level (adalogger already has the peripherals necessary to report battery)
  • TODO: finish https://www.youtube.com/watch?v=6Maq5IyHSuc and https://learn.adafruit.com/how-to-choose-a-microcontroller and battery measure

According to MCHobby about LiPo batteries:

«Pour application électronique uniquement
Ces accus sont conçus pour l'alimentation de projet électronique et pas pour la propulsion de moteur. L'accu est équipé d'un circuit de protection désactivant l'accu si sa tension chute en dessous de 3V ou si le courant débité est trop important.
Le courant de décharge de ce type d'accu est de 0.5C à 1C MAX!
Par exemple: un accu de 500mAh 1C pourrait produire un courant de 1x500mA = 500mA max.

Si vous avez besoin de motoriser un projet, vous devez rechercher des accu de modélisme capables de délivrer plusieurs C. En effet, la mise en marche d'un moteur crée un appel de courant très important (proche du courant de court-circuit), il faut donc un accu adapté.
Certains accus pour modélisme sont capables de délivrer jusqu'à 35C!
Ex: un accu de 2500mAh 35C pourrait produire un courant 35x2500mA = 87500mA = 87.5A sans broncher! De quoi assurer le démarrage de n'importe quel type de moteur.
Attention cependant, ces accus ne disposent d'aucune protection et peuvent donc prendre feu s'ils ne sont pas utilisés/chargés/déchargés correctement.»

Pycom Pyscan, Pyscan Accelerometer Sensor, Barometric Pressure Sensor, Light Sensor, Temperature & Humidity Sensor 37€ https://befr.rs-online.com/web/p/sensor-development-tools/1720649/

DIY 5Kohm resistor with paper and graphite pencil: https://makecode.adafruit.com/learnsystem/pins-tutorial/devices/make-a-resistor#input-resistor
Capacitors: https://makecode.adafruit.com/learnsystem/pins-tutorial/devices/capacitors