In this detailed form it’s rather complicated, I think
First of all, you need a service that receives ACTION_BATTERY_CHANGED broadcasts and records changes in battery level, so you can make rough estimates, for example: if you are now when the battery was 100% and then 50% you could get a reasonable assumption when it will be 0%.
If you want to get the estimated talk time, you need to watch ACTION_PHONE_STATE_CHANGED broadcasts, as well as the already mentioned CommonsWare. By taking recorded call times along with a low battery level, you get an idea of how long you can talk with the current battery level.
source share