Started making Bluetooth 4.0 keyboard, as described here Turning HM-10, HM-11 into Bluetooth HID modules - Album on Imgur
The problem is to add the battery and the charger the way it reuses existing MicroUSB connector.
E.g. it looked like there (the battery hooked to VCC/GND):
I wanted to hook the charger "after" the arduino (I want to have access to USB data when it's plugged in and I don't want to solder D+/D- to the charger connector):
Now it looks like this (the diode is 1n4008, it apparently works but looks doubtful):
TL;DR: I want to use arduino's MicroUSB connector for charging and data exchange when it's plugged in and use the battery when is unplugged. Did I hook up the charging circuit properly? I know it's better to hook it before the arduino and use charger's connector but it's not elegant and would need soldering to D+/D- pins which сharger doesn't have.