I'm a pre-newbie hoping to some day reach newbie status. These questions are probably stupid but I would appreciate your input.
I'll try to add info that I hope will help you help me. I have an Adafruit PowerBoost 1000 Charger, https://learn.adafruit.com/adafruit-powerboost-1000-basic
The 1000c will get its power from a "cellphone charger". I could not find a symbol for a cellphone charger so I used a battery symbol to symbolize the cellphone charger. It's marked as PWR1.
The 1000c has it's own little box in the schema, Adafruit #2465. What is not shown in the schema version i Fritzing is that the 1000c has 2 usb ports. One for power in and one for power out. To "simulate" the power in usb I added the small USB box (USB1) in the upper right corner of the 1000c box. I'm pretty sure this will cause even more confusion but it's the only way I can figure out how to symbolize the usb port on the 1000c. You just have to imagine that USB1 is part of the 1000c and that USB1 powers the 1000c. I have connected the positive end of PWR1 to connector 4 of USB1. Not sure if that is correct. It's not really part of the question how to connect the positive part of a power source to the correct terminal of a usb port so please ignore this possible error.
More on the 1000c:
- It has one micro usb port that is used to feed power from the cellphone charger to the 1000c.
- It has on regular usb port that is used to feed power from the 1000c to whatever contraption that need power.
- It has one connector for a battery. The battery can be used in case some one accidentally pulls out the cellphone charger from the wall socket.
- It has a couple of pins. The one that is interesting is LBO
From Adafruid website
LBO - not a leveraged buy out! this is the Low Battery Output. By default it is pulled high to BAT but when the charger detects a low voltage (under 3.2V) the pin will drop down to 0V. You can use this to signal when its time to shut down or alert the user that the battery is low. There is also a red LED connected to this pin.
I'll try to describe, as simple as I can, what I hope to achieve.
D1 gets power from LBO. D2 gets power from the cellphone charger. As long as LBO or cellphone charger deliver power, GPIO25 should get a HIGH. If both LBO and cellphone charger dies, GPIO25 should get a LOW.
The reason I have all the diodes is that I want to make sure that the power only flows towards the RPi. The reason I have the regulator(U1) is that I do not want to fry my RPi with the 5v that the cellphone charger deliver.
I have no clue if I need any of the diodes. I have no clue if the regulator(U1) is the right or wrong way to make sure that GPIO25 only gets 3v3.
All and any help i greatly appreciated.
My goal is to shutdown my Raspberry Pi when it is time, before power is cut. I want the Raspberry Pi to keep running as long as my charger, represented by +5V into the Adafruit PowerBoost 1000c, Part1, has power or there is enough power in the battery.
To make sure that power only goes from the 1000c, Part1, to the GPIO I have 2 diodes, D1 and D2, from both USB and LBO. Do I need them?
Even if I'm reading impaired I managed to find info stating that a GPIO only wants 3v3. If it is higher there is a risk of destroying the Raspberry Pi. I don't want that. Since the power from the 1000c, Part1, might be as much as 5v I need some way to get it down to 3v3 and the only way I know is a voltage-regulator, U1.
From the out of the voltage-regulator, U1, it goes to the GPIO, GPIO25 in this case.
I have put a diode, D3, between the voltage-regulator, U1, and the GPIO. I put it there to make sure the signal only goes one way, Do I need that?
I connected the GND from the 1000c, Part1, to voltage-regulator, U1, to Raspberry Pi. Is that OK or really really bad.
As you all understand, I can't even call myself a newbie.
Basic question is.
What is wrong with this picture?
If you feel the need to trash my whole solution or my knowledge, please feel free to do so, but tell me why and what I can do to fix my solution. I might actually learn something.