Smart Plug Integration
Control Tasmota-based smart plugs for automated power management of your 3D printers.
Overview
Smart plug integration enables:
- Automatic power-on when prints start
- Safe power-off after prints complete (with cooldown)
- Scheduled power on/off times
- Power consumption monitoring
- Energy alerts
Supported Devices
Any smart plug running Tasmota firmware with HTTP API enabled:
Popular Compatible Devices
- Sonoff S31 / S26
- Gosund smart plugs
- Teckin smart plugs
- Treatlife smart plugs
- Any ESP8266/ESP32-based plug with Tasmota
Requirements
- Tasmota firmware installed
- HTTP API enabled (default)
- Same network as Bambuddy server
Setting Up a Smart Plug
Step 1: Flash Tasmota (if needed)
If your plug doesn't have Tasmota:
- Follow the Tasmota installation guide
- Configure WiFi to connect to your network
- Note the plug's IP address
Step 2: Add to Bambuddy
- Go to Settings > Smart Plugs
- Click Add Plug
- Enter the plug's IP address
- Click Test to verify connection
- Enter a name (auto-filled from device if available)
- Optionally add authentication credentials
- Click Add
Step 3: Link to Printer
- In the plug settings, find Linked Printer
- Select the printer this plug controls
- The plug is now associated with that printer
Automation Options
Master Toggle
Enabled: Turns all automation on/off for this plug
Auto Power On
When enabled, the plug turns on automatically when:
- A print starts on the linked printer
- A scheduled print is about to begin
Auto Power Off
When enabled, the plug turns off after:
- A print completes successfully
- The delay mode conditions are met
Delay Modes
Control when the printer powers off after a print completes:
Time-Based Delay
Wait a fixed number of minutes:
- Range: 1-60 minutes
- Use case: Simple cooldown period
- Example: Power off 15 minutes after print ends
Temperature-Based Delay
Wait until nozzle cools down:
- Default threshold: 50°C (configurable)
- Safer for the printer and environment
- Monitors actual nozzle temperature
Recommendation: Use temperature-based delay for safety. Hot nozzles can be a fire hazard.
Scheduled Power On/Off
Set daily schedules for automatic power control:
Scheduled Power On
Turn on the plug at a specific time each day:
- Use case: Warm up printer before work hours
- Example: Power on at 8:00 AM
Scheduled Power Off
Turn off the plug at a specific time each day:
- Use case: Safety shutoff at night
- Example: Power off at 11:00 PM
Configuring Schedules
- Expand the plug settings panel
- Enable Scheduled On and/or Scheduled Off
- Set the desired time for each
- Schedules run daily at the specified times
Power Monitoring
For Tasmota plugs with energy monitoring (e.g., Sonoff S31):
Live Power Display
- Current wattage shown on plug card
- Updates in real-time
Power Alerts
Get notified when power consumption exceeds a threshold:
- Enable Power Alert in plug settings
- Set Power Threshold in watts (e.g., 200W)
- Receive notification when threshold exceeded
Use Cases for Power Alerts
- Detect printer issues (unexpected high power)
- Confirm heater failures (power too low during printing)
- Verify printer is actively heating/printing
Manual Control
Each plug card displays:
- Status: ON / OFF / Offline
- Power: Current consumption (if supported)
- On/Off buttons: Manual toggle
Click the buttons to manually control the plug at any time.
Plug Settings Panel
Expand any plug card to access all settings:
| Setting | Description |
|---|---|
| Name | Display name for the plug |
| IP Address | Network address of the plug |
| Username/Password | Authentication (if Tasmota requires it) |
| Linked Printer | Which printer this plug controls |
| Enabled | Master automation toggle |
| Auto On | Power on when print starts |
| Auto Off | Power off when print completes |
| Delay Mode | Time-based or temperature-based |
| Delay Value | Minutes or temperature threshold |
| Scheduled On/Off | Daily power schedule |
| Power Alert | Enable consumption alerts |
| Power Threshold | Wattage for alerts |
Troubleshooting
Plug Not Responding
- Verify IP address is correct
- Check plug is on the same network
- Test via browser:
http://<plug-ip>/cm?cmnd=Power - Access Tasmota web UI:
http://<plug-ip>
Authentication Issues
If Tasmota has a password:
- Edit the plug in Bambuddy
- Enter username and password
- Save and test connection
Auto Power-Off Not Working
- Verify plug is linked to a printer
- Check Enabled, Auto On, Auto Off toggles
- For temperature mode: ensure printer is still connected
- Check logs for error messages
Power Monitoring Not Showing
- Not all plugs support power monitoring
- Requires Tasmota with energy module
- Check Tasmota console for power readings
Best Practices
Safety First
- Always use temperature-based delay for power-off
- Set a scheduled power-off time as a safety net
- Don't leave printers unattended for extended periods
Network Reliability
- Use static IP or DHCP reservation for plugs
- Ensure strong WiFi signal at plug location
- Consider wired connection if reliability is critical
Printer Compatibility
- Ensure your printer handles power cycling gracefully
- Some printers need manual intervention after power-on
- Test the automation flow before relying on it
Tips
- Use power monitoring to track electricity costs
- Set up power alerts to detect print failures
- Combine with print scheduling for full automation
- Schedule power-off at night for safety and savings