Constant power source guide - fochica/fochica-wiki GitHub Wiki
Some systems in the car receive power only when the key is in the ignition. The Fochica device requires constant power, so it can maintain a connection with the driver before he enters the car and after he exits from the car. This guide will cover the various methods of connecting to a constant power source in the car (AKA permanent power line).
A typical car has a 12V battery. Larger vehicles can have a 24V battery. This guide is for the typical 12V case.
Though the voltage is around 12V, in reality the voltage of the car's electrical system will fluctuate and depend on the state of the car and the battery. When the engine is running, the voltage may go as high as 14V. When cranking the engine it may drop to 7V. In addition to that, there could be temporary spikes of voltage up to 40V.
Scan your car for presence of any cigar sockets, USB sockets or an OBD-II socket (which must be close to the steering wheel):
Check your USB and cigar sockets whether they are constantly powered or only powered when the key is in the ignition. Try different modes of the ignition switch. You can check for power using some random USB device (i.e. a phone) and an "USB car charger/adapter":
Certain optional features of the system depend on battery sensing capability. This sensing assumes a typical gas car with a 12V battery. If you desire, these features can be disabled. Please see the sections below to see how your options will affect the system. This should help you evaluate your options.
The affected features are "discharge protection" and "fallback-reminder". Discharge protection will monitor the charge level of the battery and power down the device if there is risk of a dead battery. Fallback reminder will detect when the car engine has been turned off and will sound a reminder if the seat is occupied and no connection to a smartphone is available.
The Cigar and OBD-II sockets provide a 12V connection where the USB socket provides a 5V connection. It is highly recommended to provide a 12V connection to the device to be used for sensing and conversion to 5V by the device. When connecting the device only to a 5V source you loose both the "discharge-protection" and "fallback-reminder" features. Furthermore, it might be more difficult to convert a 5V switched USB socket to a constant power source than it would be to convert a 12V switched cigar socket.
Will support all features as designed provided the device has a connection to a 12V line.
The discharge protection is expected to work properly only if the car has a conventional 12V lead battery. Otherwise the behavior is unexpected and protection will most likely not work.
The fallback reminder is not expected to work correctly and would go off at the wrong times.
Which are vehicles that shut down the engine when the car stops and is idle.
The discharge protection is expected to work properly provided the device has a connection to a 12V line.
The fallback reminder is not expected to work correctly and would go off at the wrong times.
Here are the various methods with their pros and cons from best to worst
If you are lucky, you will have such a socket in your car. Get a "car cigarette plug" or disassemble a "car usb charger" which will provide you with a plug and a step down converter, though probably not of the best quality. If you have the option, choose a socket that is closer to the device, such as one in the back.
An assembled cigarette plug with a cable and a DC "barrel" plug on the other side might be a good fit in some cases. Those come with 5.5x2.1mm and 5.5x2.5mm DC male plugs and with straight or curly cables of different lengths. Search for "car cigarette lighter plug cable DC male" to find these.
Pros
- No need for additional modifications
- Parts are inexpensive
- Most often there is a convenient access to the socket
Cons
- A cigar socket will be occupied. If you have only one you will not be able to use it to light a cigarette. You could use a splitter to power several devices though.
You can modify your wiring to connect the socket to a constant power line. You can do that by installing a fuse tap in the fuse box which is of intermediate difficulty. A more advanced method is by cutting and reconnecting the wires in a different way. You might prefer to have an auto electrician perform that for you.
Once you have changed the socket to have constant power, continue as in the previous section.
Pros
- Parts are inexpensive
- Most often there is a convenient access to the socket
Cons
- Some modifications needed by you or a professional
- A cigar socket will be occupied
An OBD-II socket is a standard 16 pin socket that is common in new cars. It is located near the steering wheel and has a pin for 12V constant power line. You can plug to this socket to get power.
Pros
- Sure source of constant power
- No modifications to the systems of the car
Cons
- OBD-II plug parts might be hard to find, especially ones for a compact plug
- A plug sticking out of the OBD-II socket might be inconvenient for the driver
- Need to plan for wires from the steering wheel area to the back where the child seats are
More advanced makers or those using the services of an auto electrician could have a new socket installed in the car. Please make sure this new power line is fused. For the default build, a 3A fuse is more than enough.
Pros
- Flexibility at choosing location of socket
- Can have a socket and plug type of your choosing (cigar, 2.1 mm barrel, etc)
Cons
- Most complex and costly
Plug the Arduino USB port in the USB socket directly. Optionally, disable 12V sensing in code.
Pros
- You will not need a step-down converter in your build
- No need for additional modifications
- Parts are inexpensive
- Most often there is a convenient access to the socket
Cons
- Discharge-protection and fallback-reminder features will not work.
- An USB socket will be occupied
Perform the needed modifications as described in the "A cigar socket that needs to be modified" section and then continue as in the previous section.