Clean up local changes
This commit is contained in:
94
README.md
94
README.md
@@ -4,22 +4,16 @@ A comprehensive tool suite for optimizing Linux laptop battery life using TLP an
|
||||
|
||||
## 🔋 Overview
|
||||
|
||||
This repository provides scripts, configurations, and tools to maximize your Linux laptop's battery life through advanced power management. The toolkit includes automated installation scripts, optimized configuration files, CPU power management tools, and real-time monitoring utilities.
|
||||
|
||||
**Key Achievement**: Dynamic CPU frequency scaling from 400 MHz (idle) to 4.2 GHz (turbo) on AC power, and 400 MHz to 2.2 GHz on battery for optimal battery life while maintaining responsiveness.
|
||||
This repository provides scripts, configurations, and tools to maximize your Linux laptop's battery life through advanced power management. The toolkit includes automated installation scripts, optimized configuration files, and monitoring tools.
|
||||
|
||||
## ✨ Features
|
||||
|
||||
- **Dynamic CPU Frequency Scaling**: 400 MHz to 4.2 GHz on AC, 400 MHz to 2.2 GHz on battery
|
||||
- **CPU Power Management**: Intel RAPL power limits with preset profiles
|
||||
- **Real-time Monitoring**: CPU frequency, power consumption, and battery drain analysis
|
||||
- **Automated Installation**: One-command setup for TLP and PowerTOP
|
||||
- **Optimized Configurations**: Pre-tuned settings for maximum battery life
|
||||
- **Monitoring Tools**: Real-time battery and power consumption monitoring
|
||||
- **Power Analysis**: Detailed PowerTOP reports and recommendations
|
||||
- **Profile Management**: Easy switching between power profiles
|
||||
- **Safety First**: Backup and rollback capabilities
|
||||
- **BIOS Configuration Guide**: Documentation for optimal firmware settings
|
||||
|
||||
## 🚀 Quick Start
|
||||
|
||||
@@ -66,51 +60,21 @@ cd battery_life
|
||||
./scripts/tlp-manager.sh --profile powersave
|
||||
```
|
||||
|
||||
### 5. CPU Power Management
|
||||
|
||||
```bash
|
||||
# Show current CPU power status
|
||||
./scripts/cpu-power-control.sh status
|
||||
|
||||
# Apply power presets
|
||||
./scripts/cpu-power-control.sh preset dynamic # 400MHz-4.2GHz (recommended)
|
||||
./scripts/cpu-power-control.sh preset balanced # 400MHz-2.2GHz (battery)
|
||||
./scripts/cpu-power-control.sh preset max-performance # 1.6GHz-4.2GHz
|
||||
|
||||
# Set custom power limit
|
||||
./scripts/cpu-power-control.sh set 25 # Set 25W power limit
|
||||
|
||||
# Monitor CPU frequencies in real-time
|
||||
sudo ./scripts/monitor-cpu-freq.sh
|
||||
```
|
||||
|
||||
### 6. Battery Drain Analysis
|
||||
|
||||
```bash
|
||||
# Analyze what's draining your battery
|
||||
./scripts/battery-drain-analysis.sh
|
||||
```
|
||||
|
||||
## 📁 Directory Structure
|
||||
|
||||
```
|
||||
battery_life/
|
||||
├── scripts/
|
||||
│ ├── install.sh # Installation script
|
||||
│ ├── uninstall.sh # Uninstallation script
|
||||
│ ├── battery-monitor.sh # Battery status monitor
|
||||
│ ├── battery-drain-analysis.sh # Identify battery draining processes
|
||||
│ ├── cpu-power-control.sh # CPU power management tool
|
||||
│ ├── monitor-cpu-freq.sh # Real-time CPU frequency monitor
|
||||
│ ├── powertop-analyze.sh # PowerTOP analysis tool
|
||||
│ └── tlp-manager.sh # TLP configuration manager
|
||||
│ ├── install.sh # Installation script
|
||||
│ ├── uninstall.sh # Uninstallation script
|
||||
│ ├── battery-monitor.sh # Battery status monitor
|
||||
│ ├── powertop-analyze.sh # PowerTOP analysis tool
|
||||
│ └── tlp-manager.sh # TLP configuration manager
|
||||
├── config/
|
||||
│ ├── tlp.conf # Optimized TLP configuration
|
||||
│ └── powertop.service # PowerTOP systemd service
|
||||
│ ├── tlp.conf # Optimized TLP configuration
|
||||
│ └── powertop.service # PowerTOP systemd service
|
||||
├── docs/
|
||||
│ ├── BIOS-FIX.md # BIOS configuration guide
|
||||
│ ├── powertop-guide.md # PowerTOP usage guide
|
||||
│ └── tlp-configuration.md # TLP configuration details
|
||||
│ └── [Documentation files]
|
||||
└── README.md
|
||||
```
|
||||
|
||||
@@ -255,46 +219,6 @@ Results vary based on:
|
||||
- Existing system settings
|
||||
- Battery age and health
|
||||
|
||||
## 💡 Additional Battery Saving Tips
|
||||
|
||||
### Browser Optimization
|
||||
Browser tabs are often the biggest battery drain. **Recommended actions**:
|
||||
|
||||
1. **Install a tab suspender extension** (e.g., Suspender MV3, The Great Suspender)
|
||||
- Automatically suspends inactive tabs
|
||||
- Can save 50-70% of browser CPU usage
|
||||
- Dramatically improves battery life
|
||||
|
||||
2. **Use Brave's Task Manager** (`Shift+Esc`)
|
||||
- Identify and close CPU-intensive tabs
|
||||
- Look for tabs using >20% CPU
|
||||
|
||||
3. **Close unused tabs regularly**
|
||||
- Each tab consumes memory and CPU
|
||||
- Aim for <20 active tabs
|
||||
|
||||
4. **Disable unnecessary extensions**
|
||||
- Some extensions run constantly in background
|
||||
- Check `chrome://extensions` regularly
|
||||
|
||||
### Application Management
|
||||
|
||||
1. **Close Element/Slack/Discord when not in use**
|
||||
- Chat applications can use 15-30% CPU in background
|
||||
- Use web versions when occasional access is needed
|
||||
|
||||
2. **Pause file sync services** (Nextcloud, Syncthing, Dropbox)
|
||||
- Manually trigger sync when needed
|
||||
- Prevents constant disk and network activity
|
||||
|
||||
3. **Reduce screen brightness**
|
||||
- Screen is often 30-50% of power consumption
|
||||
- Every 10% reduction saves significant battery
|
||||
|
||||
4. **Close VS Code/IDEs when not coding**
|
||||
- Language servers and extensions consume CPU
|
||||
- Properly exit rather than minimize
|
||||
|
||||
## 🔍 Troubleshooting
|
||||
|
||||
### Common Issues
|
||||
|
||||
Reference in New Issue
Block a user