Friday, July 3, 2015

Powering Rpi with power bank (updated)


Now i had buy new power bank (InnJoo E1 10000mAh Powerbank) with specs ( Capacity: 10000mAh - Input: 5V/1A - Output: 5V/2A );

when i full charged it , it can power on the Rpi connected to wifi dongle

but i want to test how much time it will survive it

so i used this code to save the run time and save time every 30 sec

    while :; do date >> time_servive_test.txt; sleep 30; done

when i open the file "time_servive_test.txt" it will have a saving if time every 30 sec 
so to know  if it works will you can use this command line to count the numbers of test executed 


    wc -l time_servive_test.txt


i will publish the result of my test :) soon (inshaa Allah)
------------

i had updated the code to be interval every 1 minuet 
also i had added a chick  for global ip address

   echo 'start saving time';
   echo '' > time_servive_test.txt;
   while :;
   do
        date >> time_servive_test.txt;
        curl icanhazip.com; >> time_servive_test.txt;
        sleep 60;
   done

-------------------------------------------------------------------------
finally the test had been finished 
the power-bank of 10000 mAh survived the  Raspberry pi for more than 11 hours (around 12 or more).

when i used the command sudo shutdown -h now the raspy shutdown and the power disconnected , when i pressed the power of the power-bank the raspy powered on

No comments:

Post a Comment