====== Differences ====== This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
power [2016/06/20 01:49]
admin created
power [2016/06/20 03:47] (current)
admin [WiFi & Bluetooth]
Line 8: Line 8:
   - How much storage space is available on the embedded system?   - How much storage space is available on the embedded system?
  
-__**No Network (or Internet) Access**__+=== No Network (or Internet) Access ​===
  
 If your system doesn'​t have a network, or Internet, connection at all, the question shouldn'​t even be asked. You'll have to bring back the beast (or at least it's SD card), and use one of the below mentioned methods to access the stored data. If your system doesn'​t have a network, or Internet, connection at all, the question shouldn'​t even be asked. You'll have to bring back the beast (or at least it's SD card), and use one of the below mentioned methods to access the stored data.
  
 The main parameter in this scenario will most probably be the available embedded storage space. For example having a 15sec timelapse running at maximum resolution (Pi Camera v1: 2592x1944), will generate a jpg file weighting about 3MB every 15sec. This would saturate a 16GB SD card in about 16h30m... Way before you battery pack goes out!\\ The main parameter in this scenario will most probably be the available embedded storage space. For example having a 15sec timelapse running at maximum resolution (Pi Camera v1: 2592x1944), will generate a jpg file weighting about 3MB every 15sec. This would saturate a 16GB SD card in about 16h30m... Way before you battery pack goes out!\\
-You could spare some storage space by running a minimal OS on your RasPi, but that's another subject that is covered in [[this article]]...+You could spare some storage space by running a minimal OS on your RasPi, but that's another subject that is covered in [[:​os:​minibian|this article]]...
  
 **Side note**: When the SD card gets saturated, and there is //really// no more space left on it, the OS itself will get inoperable. This is because it requires a minimum amount of storage space to function. For example trying to issue any command on a RasPi'​s console while running on a saturated SD card will return: **Side note**: When the SD card gets saturated, and there is //really// no more space left on it, the OS itself will get inoperable. This is because it requires a minimum amount of storage space to function. For example trying to issue any command on a RasPi'​s console while running on a saturated SD card will return:
Line 20: Line 20:
 </​Code>​ </​Code>​
  
-At this stage your only option will be to plug the SD card into a reader on another platform and erase at least a few of the images.+At this stage your only option will be to plug the SD card into a reader on another platform and freeing up some space.
  
-__**"​Costly"​ Internet Access (like GSM 3/4G)**__+=== "​Costly"​ Internet Access (like GSM 3/4G) ===
  
 In case you have a "​costly"​ connection, like a GSM stick holding a 3/4G SIM card, you'll probably want to minimize the bandwidth usage. In case you have a "​costly"​ connection, like a GSM stick holding a 3/4G SIM card, you'll probably want to minimize the bandwidth usage.
Line 30: Line 30:
 I'll try to give a more in-depth coverage of this point whenever I get the opportunity to access the required hardware. I'll try to give a more in-depth coverage of this point whenever I get the opportunity to access the required hardware.
  
-__**Available Network Access**__+=== Available Network Access ​===
  
-When a  +When a network access is available, wired or WiFi, one should consider that it utilizes a noticeable amount of power to operate, one should thus optimize its usage. The following paragraphs will try to present a few possible solutions. 
-==== Reduce Power Consumption ==== + 
-----+ 
 +===== Reduce Power Consumption =====
  
 This article assumes we're working on any //Raspberry Pi Model B//, fully equipped with network adapter, USB ports and HDMI. //Pi Zero// and //Model A// are already built in such ways that their power consumption is much lower than Model Bs. This article assumes we're working on any //Raspberry Pi Model B//, fully equipped with network adapter, USB ports and HDMI. //Pi Zero// and //Model A// are already built in such ways that their power consumption is much lower than Model Bs.
  
-=== Network and USB adapters ===+Also note that most of the following commands **should be run as root**, so whether login as root on systems that allows it or use **''​su root''​** to operate as root. 
 +==== Network and USB adapters ​====
  
-The power hungry monsters in the Raspberry Pi are certainly the USB and Network Adapters. They were reported to consume as much as 200mA! ​Since they'​re not mandatory for our timelapse system to function, we're better turning ​them off to enhance ​our system'​s autonomy when running off a power bank.+The power hungry monsters in the Raspberry Pi are certainly the USB and Network Adapters. They were reported to consume as much as 200mA! ​Turning ​them off will enhance ​the system'​s autonomy when running off a power bank.
  
-__//USB//__+=== USB (+ Ethernet) ===
  
-To switch the USB bus on a RasPi one can use the following commands:+To **switch ​off the USB bus** on a RasPi, which will in effect **also switch off the Ethernet** port that is linked to this same bus, one can use the following commands:
 <​Code:​bash |**Turn off USB** on the Raspberry Pi:> <​Code:​bash |**Turn off USB** on the Raspberry Pi:>
 > echo 0x0 > /​sys/​devices/​platform/​bcm2708_usb/​buspower > echo 0x0 > /​sys/​devices/​platform/​bcm2708_usb/​buspower
Line 54: Line 56:
 </​Code>​ </​Code>​
  
-__//Network Adapter//__+=== Network Adapter ​===
  
 To switch the network adapter on a RasPi one can use the following commands: To switch the network adapter on a RasPi one can use the following commands:
Line 69: Line 71:
 <color darkorange>​**Be aware that turning off both the USB and network adapters might lockout your entire RasPi system!**</​color>​ <color darkorange>​**Be aware that turning off both the USB and network adapters might lockout your entire RasPi system!**</​color>​
  
-=== HDMI ===+==== HDMI ====
  
 Referring to [[http://​www.pidramble.com/​wiki/​benchmarks/​power-consumption|this article concerning Raspberry'​s models power consumption]],​ we observe that HDMI and LED usage are using about 30 mA (for a RasPi 3). Another [[http://​www.mikeslab.net/?​p=455|interesting article about RasPi'​s power consumption]] states that turning off HDMI in a "​headless"​ configuration saves about 20mA. Referring to [[http://​www.pidramble.com/​wiki/​benchmarks/​power-consumption|this article concerning Raspberry'​s models power consumption]],​ we observe that HDMI and LED usage are using about 30 mA (for a RasPi 3). Another [[http://​www.mikeslab.net/?​p=455|interesting article about RasPi'​s power consumption]] states that turning off HDMI in a "​headless"​ configuration saves about 20mA.
  
-To turn off HDMI on the RasPi, simply issue this command:+To **turn off HDMI** on the RasPi, simply issue this command:
 <​Code:​bash |**Turn off HDMI** on the RasPi:> <​Code:​bash |**Turn off HDMI** on the RasPi:>
 > sudo /​opt/​vc/​bin/​tvservice -o > sudo /​opt/​vc/​bin/​tvservice -o
Line 79: Line 81:
  
 Unfortunately this command won't survive a reboot, so if we known the system is going to be headless we should trigger this on each boot. Unfortunately this command won't survive a reboot, so if we known the system is going to be headless we should trigger this on each boot.
 +
 +<​Code:​bash |Create cron job running at startup to turn off HDMI>
 +TO BE COMPLETED
 +</​Code>​
 +
 +To **turn HDMI back on**, you'll need to have the **''​kbd''​** package installed to access and use the ''​chvt''​ command:
 +<​Code:​bash |Turn HDMI back on>
 +> /​opt/​vc/​bin/​tvservice -p && chvt 1 && chvt 7
 +</​Code>​
 +
 +==== WiFi & Bluetooth ====
 +https://​www.raspberrypi.org/​forums/​viewtopic.php?​f=63&​t=138610
 +
 +http://​www.mikeslab.net/?​p=455