756 EV cars sold in Portugal during 2016

I’ve just read that the Portuguese bought 756 (+17%) full electric vehicles during 2016 (mostly Nissan Leafs). That might seem a small number — as it is just 0,36% of the market — but it is a good clear sign of the future. Electric is both cheap and clean and with the arrival of the 300+Km cars in 2017 I imagine that many will start looking at them with greater curiosity. I’m really curious to see how the introduction of the 41Kwh Renault Zoe, the Opel Ampera-e and the Hyundai Ioniq will impact these numbers during this year.

Lithium battery charge recovery strategy for MacBook Pro

Lithium batteries don’t really like to be full discharged and they don’t really like to be used fully charged. Their sweet spot lays somewhere in the middle. To keep the battery of my Macbook Pro healthy I sometimes adopt a regular discharge / charge cycle, (but we should completely discharged it).

I use the following bash script, that I then put in into a cronjob running every 10 min and this alerts me every time the battery charge is lower than 40% or higher than 80%! Lithium batteries don’t have memory, so If you’re like me and have the Laptop used mainly as a Desktop, instead of having it always plugged in, use this strategy some times during the month. It will revitalize the maximum charge of your battery. Then, once per month or every 30/40 cycles you should do a calibration of the sensors by letting it fully discharge followed by a full charge.

#!/usr/bin/env bash
low="Battery charge is to low, please charge it"
high="Battery charge is to high, please unplug it"
bat=`pmset -g ps | grep -o -e [0-9]*% | sed -e 's/%//g'`
if [ $bat -lt 40 ]; then
	say $low &
elif [ $bat -gt 80 ]; then
	say $high &

On the other hand if you’re going to use the laptop always plugged to the power outlet, you might consider taking the battery off. To do this let it go to 40% before removing the battery. This will help the longevity of the charge and the health of the battery if you latter use it again.