Rechargeable Lithium Ion Sensor Custom PCB


  • Mod

    @HenryWhite said:

    That's not correct. You are mixing up something. The RAW pin is for unregulated power input. With this you can bypass the internal voltage regulator. When you use the normal VCC input, the voltage will be regulated to 3.3V, if the input is (depending on arduino model) between 3.3V and 12V.

    It is actually the other way around. From https://www.arduino.cc/en/Main/ArduinoBoardProMin :

    If you're supplying unregulated power to the board, be sure to connect to the "RAW" pin on not VCC.

    Power on RAW pin results in the regulator being in use.
    Power on Vcc bypasses the regulator.


  • Mod

    This post is deleted!


  • @mfalkvidd said:

    Power on RAW pin results in the regulator being in use.
    Power on Vcc bypasses the regulator.

    indeed. seems like I mixed up something there 😄
    I will update the eagle files when i have time to.


  • Mod

    I did the same mistake in the beginning. not sure why it is so confusing 🙂



  • So if I sum up, powering this node with a single Lipo cell will work by connecting the Lipo to the raw pin on the arduino. This will work from 4.2v to 3.4v. This is not that good for the battery life.
    Using 2*AA batteries with a boost converter seems a lot easier...
    I'm almost giving up on this idea : I liked the flat form factor of the lipos and they were solar pannel friendly. Is there a way to use a voltage regulator from 4.2v to 3.4v and then switch the circuit to a boost converter from 3.3v to 2.8v ?



  • @akumar It's the same problem as with all lipos. But you have to consider that it will take a really long time until the battery hits 3.4V or less. There are even smartphone batteries with 3000+ mAh which are very small.

    Also it seems to be good for battery lifetime when the voltage does not drop that much compared to using a step-up converter below 3.4V.



  • @akumar
    You shall not go below 3,0v on a Lipo, it will/can get damage



  • Looking at discharge curves I can see that I should be able to squeeze 75% of the battery capacity if I charge it back when it reaches 3.3v. On a low power node this could work.
    @flopp The reason I was mentionning 2.8v is because the battery protection module will kick in at this voltage. But you're right, no reason to go this far.

    Thanks !



  • @akumar
    That battery protection is built-in on battery, but must take it with care. There as some cheap LiPo that doesn't have that feature.
    I don't think the TP4056 have protection or does it?



  • Sure ! The newer ones have a battery protection chip. I've tested it and it kicks in at 2.8v.
    http://www.aliexpress.com/item/Free-Shipping-10pcs-lot-1a-lithium-battery-charging-18650-with-protection-one-plate-protec-2-in/1876166772.html



  • Now I see, there are pads for battery and pads for out. Looks good



  • @flopp said:

    Now I see, there are pads for battery and pads for out. Looks good

    Correct. The old Tp4056 modules do not have the OUT terminals (and therefore won't fit on the pcb I designed in this thread)

    @akumar said:

    On a low power node this could work.

    Why should it only work on a low power node?


  • Hardware Contributor

    hi.

    "Why should it only work on a low power node?"

    with time we will have more and more things to charge every week/day (phone, watch, iot...), so I would say : for less maintenance ? lol

    more seriously, it is a nice project I will follow it 😉 I have one board to order (not ordered yet) with a li charger but mine is definitely not diy (too small chip so it is for stencil use).
    Mobile phone batt is a very nice idea 😃 I am a more confident than cheap lipo..and I have some old cheap galaxy s2 batt..How do you plan to hook the battery to your board?



  • @scalz said:

    How do you plan to hook the battery to your board?

    As smartphone batteries are usually fully enclosed, I will just stick the battery (I will use the galaxy s4 batteries) under the pcb.

    The whole package should fit nicely in a 75x75x40 distribution box, which will only cost a few cents in your local hardware store.
    Only downside of the boxes is that they are a bit ugly 😄
    But since I don't have a 3D printer yet i will go with that solution and maybe paint the boxes black or white.


  • Hardware Contributor

    cool.
    I am building my 3d printer actually because I want custom things (not too much ugly) 😉
    I was talking about how to wire between the batt and the board. So you will solder wire on it?
    but it is not a big a problem I think, if I use these sort of batt, maybe I will try to find some contacts and handle this in the custom box.

    see you soon 🙂



  • @scalz said:

    I am building my 3d printer actually because I want custom things (not too much ugly) 😉

    I thought about that too, but then I saw how much calibration, try&error etc. you need to assemble your own 3D printer. And after that it's still a hassle to get prints with good quality.
    Because of that I will just save money for the ultimaker 2.. 😄

    @scalz said:

    I was talking about how to wire between the batt and the board. So you will solder wire on it?

    Yes, I will solder the contacts of the battery directly to the tp4056 module. Because you don't have to replace the battery (until it breaks) this method should be fine.


  • Hardware Contributor

    👍 it makes sense too.


  • Hardware Contributor

    "Because of that I will just save money for the ultimaker 2"

    yep but calibration, try&errors, settings.. are always there, even if you have a 2000 dollars printers. no plug and play, it is some kind of myth for the moment that people don't know before buy one. but lot of people are working to improve commercial or diy printer.
    For instance, I did some orders on 3dhub. Some were printed with prusa or ultimaker, pla or abs... And sometimes I got better quality from a prusa owner than ultimaker owner. One box was dark burnt on ultimaker, it was not good. So it is a matter to well know the stuff 😉
    and then it is very proprietary (filament, settings, software...).
    I have talked about this with some fablabs people who have expensive printer (ultimaker, zortrax for instance) and diy corexy printer. That is why I am building my corexy which cost to me 300€ and I know every angle of it ;). Some learning curve, which expensive printer have too, but then no more proprietary&co problem..just my point of view...



  • If the module also should be operated while charging and the DHT11 sits directly on the board close to the battery charger the sensor would show significantly higher temperatures caused by the TP4056 battery charger which becomes really hot during charging.

    On an experiment on a breadboard with comparable distance I measured a temperature of the TP4056 of about 70 degree Celsius in the first phase of charging and the sensor reading rises from about 20 to 22 degrees.



  • @Heizelmann you're right, the module gets pretty warm.
    Here I found some more measurements for the Tp4056: http://lygte-info.dk/review/Review Charger TP4056 UK.html

    Although the board is designed to bend the DHT22 over the prototyping area so that it is horizontal and not vertical aligned, I think I could swap positions of the prototyping area and the mounting point for the DHT22.

    To keep the Tp4056 cooler, you could add a small heatsink to it or replace the resistor so that it charges with lower current.



  • @akumar said:

    So if I sum up, powering this node with a single Lipo cell will work by connecting the Lipo to the raw pin on the arduino. This will work from 4.2v to 3.4v. This is not that good for the battery life.
    Using 2*AA batteries with a boost converter seems a lot easier...
    I'm almost giving up on this idea : I liked the flat form factor of the lipos and they were solar pannel friendly. Is there a way to use a voltage regulator from 4.2v to 3.4v and then switch the circuit to a boost converter from 3.3v to 2.8v ?

    Maybe this can be used. But I use 0.1mA when "sleeping"
    https://www.pololu.com/product/2122





  • @flopp : cool module ! This could do the trick. The 0.1 mA could be taken care of by powering the module via a MOSFET controlled by the arduino. It would then power the sensors and the radio only when needed.



  • Again, to prove my point that you don't need to go below 3.3V (at least with modern smartphone batteries), I just measured my Galaxy S5's battery at 4% battery state. The measured voltage is 3.65V.



  • @HenryWhite
    Wow, what are your low/max limit?

    4% seems to be very low if your low limit is 3.3.



  • @flopp said:

    @HenryWhite
    Wow, what are your low/max limit?

    I must admit i didn't understand that 😄

    At 2% battery state (according to what is shown in the android UI) the s5 battery still outputs 3.43V (measured with multimeter and compared to android app "Ampere")
    Even at 1% the voltage is still above 3.3V:
    2016-01-13 19_17_14-Screenshot_2016-01-13-19-10-52.png

    But: I just discovered that the galaxy s5's battery is a 3.85V li-ion battery with a charging voltage of 4.4V instead of 4.2V..

    But even then, the 3.8V S4 battery which I'm going to use for my sensors will approximately reach less than 3.3V not before the battery is under 5% charging state I think.



  • I just added revision 0.3 to the first post:

    @HenryWhite said:

    Rev 0.3: swapped footprints of DHT22 and prototyping area to prevent false temp measurements when charging the battery; connected TP4056 OUT to arduino's RAW instead of VCC_IN (so the internal voltage regulator is used)
    sensorboard_v0.3.sch
    sensorboard_v0.3.brd



  • Thanks for Rev 03. Another optimization would be to turn the DHT22 180 degrees. Then the open front would face outside. Better for air circulation if put into a case with only a small open slot for the DHT.



  • This post is deleted!


  • Here it is: Revision 1.0

    Changes:

    Schematics (Rev 1.0)
    0_1453762885667_schematics_v1.0.png
    Board view (Rev 1.0)
    0_1453762894187_board_v1.0.png
    3D board view (Rev 1.0)
    0_1453762899960_3dview_v1.0.png
    Build files
    Eagle files: 0_1453762986505_Sensorboard_v1.0.zip
    Gerber files: 0_1453763061782_Sensorboard_v1.0_Gerber.zip



  • I just received my ordered PCBs (Revision 0.1) from Elecrow. The PCBs are very well made for that low price! (I got 14PCBs for 14$)

    It fits nicely in a 75x75mm electric box (not the prettiest housing, but very cheap and easily processable for drilling holes for the connections; plus you can paint it to make it more beautiful 😄 )

    Since it is revision 0.1, I had to cut one pcb trace (V+ from POWER to Arduino's V_IN) and connect V+ from POWER manually with Arduino's RAW input.

    Soldering directly to the battery went better than I thought!

    0_1453847229416_IMG_1533.JPG
    0_1453847244354_IMG_1534.JPG
    0_1453847256810_IMG_1538.JPG
    0_1453847273862_IMG_1539.JPG
    0_1453847289150_IMG_1540.JPG
    0_1453847303296_IMG_1543.JPG
    0_1453847315474_IMG_1544.JPG
    0_1453847333555_IMG_1545.JPG
    0_1453847345295_IMG_1546.JPG
    0_1453847360925_IMG_1547.JPG
    0_1453847375217_IMG_1548.JPG


  • Hardware Contributor

    Nice, but I think R3 =330k would give you a better battery voltage monitoring divider ratio (Vmax 4.43V). Maybe a little higher total resistance would limit current loss though (even 10M+3M would work).
    Maybe something useful here.



  • @m26872 said:

    Nice, but I think R3 =330k would give you a better battery voltage monitoring divider ratio (Vmax 4.43V). Maybe a little higher total resistance would limit current loss though (even 10M+3M would work).
    Maybe something useful here.

    Good point! 🙂 Didn't thought about that.



  • @HenryWhite Did you make any estimates how long your node is running on the fully charged battery?



  • @alexsh1 said:

    @HenryWhite Did you make any estimates how long your node is running on the fully charged battery?

    I'm just testing it 🙂
    The Version without relay (Rev. 0.3) should be good for at least two months, assuming you want to read temp/humidity every 60 seconds and you have a 2600mAh (smartphone) battery.
    I think you can improve the battery life much further, for example with the following:

    • a better sketch, e.g. bigger sleep time
    • removing the power LED on the arduino
    • higher battery capacity

    The DHT22 is also drawing much current, i think i will replace it in a next version with a Si7021.

    PS: The version with relay could never run very long, because you need to keep the node awake in order to send a command to switch the relay. But even if you use the relay version, you could just attach a bigger battery.



  • @HenryWhite Thanks - I was gonna make this suggestion about the DHT22:

    1. you do not need temp/hum every 60 sec. 5 -10 mins should be enough
    2. Power LED has a negligible consumption if you have DHT22 onboard.
    3. I have Si7021 (powered by two batteries) and DHT22 (powered from 240V via AC/DC adapter). Si7021 is more accurate and less power hungry. My suggestion would be Si7021 or BMP280 as they are working the best with batteries.

    Just out of curiosity, what do you do when the battery is flat? Take out the node and charge it? Or charging is automated?



  • @alexsh1 said:

    Just out of curiosity, what do you do when the battery is flat? Take out the node and charge it? Or charging is automated?

    You don't have to take anything apart. Just plug in a micro usb loading cable in the Tp4056 and the battery will be charged. Plus, you never need to shutdown the node, charging works simultaneously.



  • A little update in terms of battery lifetime: all nodes are still running, I think they will last at least for 10 months before you have to recharge them.



  • I've been looking for some time for similar module/board,
    (was too lazy to make it myself) and somehow i never found this board.
    If I understood you are now on half the battery (after a six months) ?

    Did you had any tests with the Relay version on battery power?
    I guess it will consume quite some power if it needs to keep relay on from the battery?
    If it relay doesn't consume a lot of power then it could be very very useful to have it there (or if it is switched for short period of time and not that often)

    Project looks very good, it has all it needs for generic module, thank you for making it.



  • @dakipro said:

    I've been looking for some time for similar module/board,
    (was too lazy to make it myself) and somehow i never found this board.
    If I understood you are now on half the battery (after a six months) ?

    Did you had any tests with the Relay version on battery power?
    I guess it will consume quite some power if it needs to keep relay on from the battery?
    If it relay doesn't consume a lot of power then it could be very very useful to have it there (or if it is switched for short period of time and not that often)

    Project looks very good, it has all it needs for generic module, thank you for making it.

    Yes, i expect the battery to last ~12 months with one motion sensor + temp/hum sensor installed.
    When you want to use the relay, the board normally consumes a lot more power and the battery would not even last 1 month I think, because your board has to be active all the time to receive commands for the relay.

    If you do not insist on instant relay switching, you could implement the SmartSleep() functionality of mysensors. With this the battery should last way longer, maybe even as long as without relay.

    By the way, I got myself a 3D printer and designed a casing for my usecase (motion sensor -- but the case should fit a variety of other components too):

    0_1470836685263_PHOTO_20160810_154021[1].jpg
    0_1470836715515_PHOTO_20160810_154056[1].jpg
    0_1470836826597_PHOTO_20160810_154145.jpg



  • Makes sense. I am just comparing different editions, it appeared to me that the relay board could be a completelly separate project/pcb, as it would not work quite well on the rechargeable battery, and has quite a different purpose/audience I guess.
    Rev 0.3 would then be trully "rechargeable" battery sensor (as in the title), and rev 1.0 would be completelly different, or does it contain same pins as 0.3 (pluss relay which can simply be ignored?).

    I would use it for motion, temp+hum, door switch and light/lux meter, is it then safe to order rev 1.0 for such a sensor?

    And to order it, i usually/only need the .brd and sch files right?

    p.s. custom housing looks very slick 🙂



  • @dakipro said:

    Rev 0.3 would then be trully "rechargeable" battery sensor (as in the title), and rev 1.0 would be completelly different, or does it contain same pins as 0.3 (pluss relay which can simply be ignored?).

    Rev 1.0 has nearly the same pins, except that you can only connect one switch (Rev 0.3: two switches) - but yes, you can simply ignore the relay, diode and transistor if you don't want to use a relay.
    Nonetheless, if you are sure that you will never use the board with a relay, I suggest that you go with Rev. 0.3.

    And to order it, i usually/only need the .brd and sch files right?

    It depends on the pcb manufacturer, but most of the time you will need the gerber files (which can be generated with the .sch file through the CAM-processor with the .cam file (which the specific board house provides).

    PS: I ordered my boards from elecrow.



  • Thanks, I was ordering from oshpark before, but I see that elecrow has some nice prices as well.
    I noticed that you have _gerber.zip for 1.0, if you by any chance find _gerber.zip for 0.3 I would appreciate if you upload it to the thread 🙂
    (no, i am not lazy to convert them with eagle, but still not confortable and afreaid that I might select some wrong option 🙂 )



  • @dakipro here you go:

    0_1470866547655_Gerber_rev0.3.zip

    Be aware that this are the gerber files for the pcb service from elecrow. Other pcb services may have other specifications!



  • Hi HenryWhite,

    Great job, very nice.

    I have some questions:

    • Why do you sent input voltage to A0? is it for voltage supervision?
    • Is it possible to have your sketch file?

    Thanks for your sharing,
    TouFou



  • @toufou said:

    Hi HenryWhite,

    Great job, very nice.

    I have some questions:

    • Why do you sent input voltage to A0? is it for voltage supervision?
    • Is it possible to have your sketch file?

    Thanks for your sharing,
    TouFou

    Hi, yes it's for measuring the battery level.
    You can find the schematics and all the other files in my first post.



  • Hi,
    Thanks for your reply.
    In the first post, i see schematics, brd and gerber file, but i don't see .ino file to flash arduino pro mini.....



  • @toufou said:

    Hi,
    Thanks for your reply.
    In the first post, i see schematics, brd and gerber file, but i don't see .ino file to flash arduino pro mini.....

    You can adapt the example sketches MySensors offers, it shouldn't be hard. Also the sketch will depend on what you plan to use the board for. (Motion, Switch, Temperature,...)



  • Ok!

    I thought you had specific because your sensor is about 10month with arduino regulator! excellent.

    Another question:
    You use a motion sensor as i want. You make a reference to a hack to use it with 3.3V instead of 5V. Have you a link to see that?

    Thanks



  • @toufou said:

    You use a motion sensor as i want. You make a reference to a hack to use it with 3.3V instead of 5V. Have you a link to see that?

    Yes, here's a picture (the only thing you have to do is solder vcc to the HIGH-pad of your motion sensor):
    0_1473068491824_123.png


Log in to reply
 

Suggested Topics

  • 87
  • 6
  • 5
  • 10
  • 2
  • 7

15
Online

11.4k
Users

11.1k
Topics

112.7k
Posts