Battery Historian for windows environment construction

Reprinted from: http://www.cnblogs.com/jytian/p/5647798.html

1. First install the Go programming language

  1. Click to download [ Download ];
  2. install Go;
  3. Configure GOROOT and GOPATH

    a. The role of GOROOT is to tell the Go command and other related tools, where to find the Go package installed on your system, so the GO installation directory is configured here

     

 

    b.GOPATH can be simply understood as the directory of the project, so create a GO project path

     

 

         C. Finally configure the environment variables and put the Go bin directory into the path environment variable

     

 

  4. To check if Go is installed successfully, open the command line and enter Go version

   

 

2. Install Git

  1. Click to download [ Download ];
  2. Follow the steps to install;
  3. Installation complete check: enter git version on the command line

   

   You can also directly open git bash to check

   

 

3. Install Python

  1. Click to download [ Download ], note that only python2.7 is supported
  2. The installation is complete;
  3. Environment variable configuration, add the path of Path, which is the installation path of Python
  4. Enter the command line python -V (note the capital V) to check whether the installation is successful

     

 

Fourth, install the Java environment

  1. Click to download [ Download ];
  2. finish installation.

 

5. Download the Battery Historian source code and run it

  1. Enter the command line go get -d -u github.com/google/battery-historian/…

     

     **Download to the GOPATH configuration directory

  2. Go to the $GOPATH/src/github.com/google/battery-historian directory
  3. Run Battery Historian

    a. go run setup.go

    # Compile Javascript files using the Closure compiler

    $ go run setup.go


    Wait for a few minutes or about 10 minutes, if the download is still not successful, you can download it manually, as follows

    **Download [ closure-library ], [ closure-compiler ] and [ flot-axislabels ], unzip it and place it in the closure-compiler, closure-library and flot-axislabels folders under the third_party folder in the GOROOT directory../battery -historian\third_party; if not created manually

     

    b. go run cmd/battery-historian/battery-historian.go

    # Run Historian on your machine (make sure $PATH contains $GOBIN)

    $ go run cmd/battery-historian/battery-historian.go [--port <default:9999>]

  4. Check whether /battery-historian is running, log in to the URL  http://localhost:9999 to view

6. Export the Bugreport log of the mobile phone

1. Enter the command adb bugreport > bugreport.txt to export.

 

7. Upload the bugreport.txt file to  http://localhost:9999

    1. Upload bug log


    2. View Results

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325348285&siteId=291194637
Recommended