Editing SmartPlug Help File

Jump to navigation Jump to search

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.

Latest revision Your text
Line 2: Line 2:
 
   
 
   
  
Help file for smart plug application ( Documentation for Ver7 ).  You can also get a lot of information about how the program works by looking at the GUI and its explanation:  '''[[SmartPlug GUI Images]]'''.
+
Help file for smart plug application ( Program now Ver5 ).
  
  
Line 8: Line 8:
  
 
*Works with multiple smartplugs.
 
*Works with multiple smartplugs.
*Provides on, off, timing, and  energy recording functions from a graphical user interface ( gui ), see '''[[SmartPlug GUI Images]]'''.
+
*Provides on, off, timing, and  energy recording functions from a graphical user interface ( gui )
 
*Supports graphing of data.  Currently power and energy over time.  Multiple devices on one graph.
 
*Supports graphing of data.  Currently power and energy over time.  Multiple devices on one graph.
*Supports comma separated values ( csv ) output of data to text files.
+
*Supports csv output of data.
 
*Saves data to a sql lite database that you can use any way you wish.
 
*Saves data to a sql lite database that you can use any way you wish.
 
*Highly configurable.
 
*Highly configurable.
Line 40: Line 40:
  
 
= How To:... =  
 
= How To:... =  
 
Some stuff is pretty obvious from the GUI, take a look at it as well as reading the material here [[SmartPlug GUI Images]].
 
 
  
 
== Either/Both Applications ==
 
== Either/Both Applications ==
Line 52: Line 49:
 
*Edit the log file:  This is a standard python logging file.  Useful for debugging and general tracking of the application.  You can set the level of the logging using the parameter file.
 
*Edit the log file:  This is a standard python logging file.  Useful for debugging and general tracking of the application.  You can set the level of the logging using the parameter file.
 
*Backup the database: Just make a copy of the database using your file manager.  It is all in one file, but you can make multiple databases.
 
*Backup the database: Just make a copy of the database using your file manager.  It is all in one file, but you can make multiple databases.
*Add a new device or change device data: edit the parameter file, device_list. Restart the application. <Restart> will do it
+
*Add a new device or change device data: edit the parameter file, device_list.
 
*Quick Restart of the application:  As perhaps after a parameter change.  Use the <Restart> button.  See also: [[SmartPlug GUI Images]]
 
*Quick Restart of the application:  As perhaps after a parameter change.  Use the <Restart> button.  See also: [[SmartPlug GUI Images]]
 
*Make a graph: Use the graphing application or Live Graph ... see sections below. See also: [[SmartPlug GUI Images]].
 
*Make a graph: Use the graphing application or Live Graph ... see sections below. See also: [[SmartPlug GUI Images]].
Line 66: Line 63:
 
*Monitor Plug: continuously monitor and display  
 
*Monitor Plug: continuously monitor and display  
 
*Set a timer:  Use drop down list to select time, then press <Start Timer..> Time remaining will be displayed on the GUI.
 
*Set a timer:  Use drop down list to select time, then press <Start Timer..> Time remaining will be displayed on the GUI.
 +
*Start a live graph:  Use the <Live Graph> checkbox, you should have monitor checked for some devices.  Data is accumulated in memory, not the database.
 
*Find plugs on your network:  Press the <Probe Plugs> button.  Scan can take a long time ( minutes ).  Use parameters to control how the scan is conducted.
 
*Find plugs on your network:  Press the <Probe Plugs> button.  Scan can take a long time ( minutes ).  Use parameters to control how the scan is conducted.
 
*Get Data about a Plug:  Press the button with the plug name.  Info appears in the message area.
 
*Get Data about a Plug:  Press the button with the plug name.  Info appears in the message area.
*Start a live graph:  Use the <Live Graph> checkbox, you should have monitor checked for some devices.  Data is accumulated in memory, not the database. Live graph is a graph of the data as it comes in.  Will only collect data for devices whose monitor button is turned on.  Data is deleted when graph is stopped.
 
*Save CSV file: <Save CSV>  Save the data to a CSV file, live_data.csv.  Saves time ( python timestamp ) and power.  Delimiter is actually a tab character.  Data is appended if file already exists.
 
  
 
== Graphing Application ==
 
== Graphing Application ==
Line 84: Line 80:
 
*Change the units on the time scale of the graph -- see parameters.py
 
*Change the units on the time scale of the graph -- see parameters.py
 
*Change the max and minimum values on the graph -- see parameters.py or zoom the graph
 
*Change the max and minimum values on the graph -- see parameters.py or zoom the graph
*Export a csv file:  Saves time ( python timestamp ), power and energy.  Delimiter is actually a tab character.  File name is data.csv Data is appended if file already exists.
+
*Export a csv file:   
*Create a new empty database:  There is a button on the graphing application.  First set the file name ( including full path ) to a non existent file.  You can browse to an existing file and then edit the name.
+
*Create a new empty database:  There is a button on the graphing application.  First set the file name ( including full path ) to a non existent file.
*Set default size of the graph: parameters.py.
 
  
 
=  How to Use the Parameter File =  
 
=  How to Use the Parameter File =  
 
See: [[Configuration Files For Python]]
 
See: [[Configuration Files For Python]]
You need a text editor suitable for .py files to manage the parameter file ( parameters.py )
+
You need a text editor sutiable for .py files to manage the parameter file ( parameters.py )
 
This includes most text editors.  I particularity like:
 
This includes most text editors.  I particularity like:
  
Line 179: Line 174:
  
 
*[[Python Control of Smart Plugs]] main page for this project  
 
*[[Python Control of Smart Plugs]] main page for this project  
* see categories below as well
 
 
  
[[Category:Python SmartPlug]] [[category:Python]] [[category:Python Projects]]
+
*[[Category:Python_SmartPlug]] category page for this project
 +
 
 +
 
 +
[[Category:Python SmartPlug]] [[category:Python]]

Please note that all contributions to OpenCircuits may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see OpenCircuits:Copyrights for details). Do not submit copyrighted work without permission!

Cancel Editing help (opens in new window)