<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.playfulexploration.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=45.31.182.136</id>
	<title>Playful Exploration - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.playfulexploration.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=45.31.182.136"/>
	<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=Special:Contributions/45.31.182.136"/>
	<updated>2026-11-19T23:25:35Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.17</generator>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=Time_Series_Database&amp;diff=1046</id>
		<title>Time Series Database</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=Time_Series_Database&amp;diff=1046"/>
		<updated>2016-10-15T20:09:21Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: /* RPI2 Grafana Setup notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Links]][[category:r2a2]]&lt;br /&gt;
The abbreviation TSDB is commonly used for &amp;lt;b&amp;gt;T&amp;lt;/b&amp;gt;ime &amp;lt;b&amp;gt;S&amp;lt;/b&amp;gt;eries &amp;lt;b&amp;gt;D&amp;lt;/b&amp;gt;ata&amp;lt;b&amp;gt;b&amp;lt;/b&amp;gt;ase.&lt;br /&gt;
&lt;br /&gt;
Links:&lt;br /&gt;
:[http://blog.kugelfish.com/2014/01/raspberry-pi-temperature-data-recorder_24.html RRDTool]&lt;br /&gt;
:[http://opentsdb.net/overview.html OpenTSDB]&lt;br /&gt;
:[http://gridengine.eu/index.php/other-stories/229-installing-influx-db-on-raspberry-pi-2-2015-10-18 influx for Raspberry Pi]&lt;br /&gt;
:[http://gridengine.eu/index.php/other-stories/230-installing-grafana-on-raspberry-pi-2-2015-10-24 view influx using grafana on RPi]&lt;br /&gt;
:[http://www.philipotoole.com/tag/influxdb/ Howto article]&lt;br /&gt;
&lt;br /&gt;
== InfluxDB Write Examples ==&lt;br /&gt;
&lt;br /&gt;
=== Write available disk space every 5 min ===&lt;br /&gt;
Crontab lets you edit the task scheduler.  Run crontab as super user to edit the task scheduler of root.  That way the running task will never be under privileged.&lt;br /&gt;
 sudo crontab -e&lt;br /&gt;
&lt;br /&gt;
Add this line to the end:&lt;br /&gt;
 */5 * * * * M=`df|grep /dev/root|awk &#039;{print $4}&#039;`&amp;amp;&amp;amp;curl -i -XPOST &#039;http://localhost:8086/write?db=rocket&#039; --data-binary &amp;quot;cpu,host=rpi2 mem_available=$M&amp;quot;&lt;br /&gt;
&lt;br /&gt;
* M=`...` : executes the back-quoted command and assigns the output to variable M&lt;br /&gt;
* df : dumps some disk info, which gets piped into grep&lt;br /&gt;
* grep /dev/root : finds the line containing &#039;/dev/root&#039; which gets piped into awk&lt;br /&gt;
* awk &#039;{print $4}&#039; : parses the line and outputs the 4th (space separated?) string which is the number we are looking for&lt;br /&gt;
* &amp;amp;&amp;amp;curl : runs curl if the previous command (assignment to M) succeeded&lt;br /&gt;
* curl -i -XPOST : writes data via POST request&lt;br /&gt;
:* &#039;http://localhost:8086/write?db=rocket&#039; - target server is an influxdb server at &#039;localhost:8086&#039;, the target database is named &#039;rocket&#039;&lt;br /&gt;
:* --data-binary &amp;quot;cpu,host=rpi2 mem_available=$M&amp;quot; : the measurement is called &#039;cpu&#039;, the value is called &#039;mem_available&#039; and is tagged with the optional key and value host=rpi2&lt;br /&gt;
&lt;br /&gt;
== RPI2 Grafana Setup notes ==&lt;br /&gt;
&lt;br /&gt;
Grafana by default runs on port 3000 root i.e. http://chaospage.com:3000/ .  In order to reverse proxy this with nginx to http://chaospage.com/grafana do this:&lt;br /&gt;
&lt;br /&gt;
Edit the grafana ini file:&lt;br /&gt;
 nano /root/.gvm/pkgsets/go1.5/global/src/github.com/grafana/grafana/conf/defaults.ini&lt;br /&gt;
&lt;br /&gt;
Change root_url to:&lt;br /&gt;
 root_url = %(protocol)s://%(domain)s:%(http_port)s/grafana&lt;br /&gt;
&lt;br /&gt;
Edit nginx configuration:&lt;br /&gt;
 nano /etc/nginx/sites-enabled/default&lt;br /&gt;
&lt;br /&gt;
Add this location section:&lt;br /&gt;
 location /grafana {&lt;br /&gt;
       proxy_pass         http://localhost:3000;&lt;br /&gt;
       rewrite  ^/grafana/(.*)  /$1 break;&lt;br /&gt;
       proxy_set_header   Host $host;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
Restart nginx service there should be no errors:&lt;br /&gt;
 service nginx restart&lt;br /&gt;
&lt;br /&gt;
To have grafana server start automatically add it to rc.local:&lt;br /&gt;
 nano /etc/rc.local&lt;br /&gt;
&lt;br /&gt;
Add this line:&lt;br /&gt;
 /root/.gvm/pkgsets/go1.5/global/src/github.com/grafana/grafana/bin/grafana-server -homepath /root/.gvm/pkgsets/go1.5/global/src/github.com/grafana/grafana/ &amp;amp;&lt;br /&gt;
&lt;br /&gt;
Try it all out by starting grafana from the commanline:&lt;br /&gt;
 /root/.gvm/pkgsets/go1.5/global/src/github.com/grafana/grafana/bin/grafana-server -homepath /root/.gvm/pkgsets/go1.5/global/src/github.com/grafana/grafana/&lt;br /&gt;
&lt;br /&gt;
Navigate to https://www.playfulexploration.com/grafana/ , ensure the grafana web ui shows up.&lt;br /&gt;
&lt;br /&gt;
Then restart the pi and try again ensuring that the grafana webservice starts automatically.&lt;br /&gt;
 restart&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=Talk:ESP8266/Arduino-pid&amp;diff=929</id>
		<title>Talk:ESP8266/Arduino-pid</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=Talk:ESP8266/Arduino-pid&amp;diff=929"/>
		<updated>2016-07-10T19:14:27Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: /* Category? */ new section&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Category? ==&lt;br /&gt;
&lt;br /&gt;
How do I set category for this page? It should be in the ESP8266 category.&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=Talk:ESP8266/Arduino-pid&amp;diff=928</id>
		<title>Talk:ESP8266/Arduino-pid</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=Talk:ESP8266/Arduino-pid&amp;diff=928"/>
		<updated>2016-07-10T19:14:03Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: Blanked the page&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=Talk:ESP8266/Arduino-pid&amp;diff=927</id>
		<title>Talk:ESP8266/Arduino-pid</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=Talk:ESP8266/Arduino-pid&amp;diff=927"/>
		<updated>2016-07-10T19:13:46Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: Created page with &amp;quot;How do I set a category for this page?&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;How do I set a category for this page?&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=ESP8266/Arduino-pid&amp;diff=926</id>
		<title>ESP8266/Arduino-pid</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=ESP8266/Arduino-pid&amp;diff=926"/>
		<updated>2016-07-10T19:08:47Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: /* Or use an Arudino library: */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== PID control on ESP8266 or other Arduino compatible chips ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void loop() {&lt;br /&gt;
&lt;br /&gt;
  //-------------------- Calculates the PID drive value --------------------&lt;br /&gt;
&lt;br /&gt;
  Actual = analogRead(Position);&lt;br /&gt;
  Error = SetPt - Actual;&lt;br /&gt;
  &lt;br /&gt;
  if (abs(Error) &amp;lt; IntThresh){ // prevent integral &#039;windup&#039;&lt;br /&gt;
    Integral = Integral + Error; // accumulate the error integral&lt;br /&gt;
  } else {&lt;br /&gt;
    Integral=0; // zero it if out of bounds&lt;br /&gt;
  }&lt;br /&gt;
  P = Error*kP; // calc proportional term&lt;br /&gt;
  I = Integral*kI; // integral term&lt;br /&gt;
  D = (Last-Actual)*kD; // derivative term&lt;br /&gt;
  Drive = P + I + D; // Total drive = P+I+D&lt;br /&gt;
  Drive = Drive*ScaleFactor; // scale Drive to be in the range 0-255&lt;br /&gt;
&lt;br /&gt;
  if (Drive &amp;lt; 0){ // Check which direction to go.&lt;br /&gt;
    digitalWrite (Direction,LOW); // change direction as needed&lt;br /&gt;
  } else { // depending on the sign of Error&lt;br /&gt;
    digitalWrite (Direction,HIGH);&lt;br /&gt;
  }&lt;br /&gt;
  if (abs(Drive)&amp;gt;255) {&lt;br /&gt;
    Drive=255;&lt;br /&gt;
  }&lt;br /&gt;
  analogWrite (Motor,Drive); // send PWM command to motor board&lt;br /&gt;
  Last = Actual; // save current value for next time&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Source: http://www.maelabs.ucsd.edu/mae156alib/control/PID-Control-Ardunio.pdf&lt;br /&gt;
&lt;br /&gt;
=== Or use an Arudino library: ===&lt;br /&gt;
* [http://playground.arduino.cc/Code/PIDLibrary Arduino PID Library]&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=ESP8266/Arduino-pid&amp;diff=925</id>
		<title>ESP8266/Arduino-pid</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=ESP8266/Arduino-pid&amp;diff=925"/>
		<updated>2016-07-10T19:08:27Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== PID control on ESP8266 or other Arduino compatible chips ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void loop() {&lt;br /&gt;
&lt;br /&gt;
  //-------------------- Calculates the PID drive value --------------------&lt;br /&gt;
&lt;br /&gt;
  Actual = analogRead(Position);&lt;br /&gt;
  Error = SetPt - Actual;&lt;br /&gt;
  &lt;br /&gt;
  if (abs(Error) &amp;lt; IntThresh){ // prevent integral &#039;windup&#039;&lt;br /&gt;
    Integral = Integral + Error; // accumulate the error integral&lt;br /&gt;
  } else {&lt;br /&gt;
    Integral=0; // zero it if out of bounds&lt;br /&gt;
  }&lt;br /&gt;
  P = Error*kP; // calc proportional term&lt;br /&gt;
  I = Integral*kI; // integral term&lt;br /&gt;
  D = (Last-Actual)*kD; // derivative term&lt;br /&gt;
  Drive = P + I + D; // Total drive = P+I+D&lt;br /&gt;
  Drive = Drive*ScaleFactor; // scale Drive to be in the range 0-255&lt;br /&gt;
&lt;br /&gt;
  if (Drive &amp;lt; 0){ // Check which direction to go.&lt;br /&gt;
    digitalWrite (Direction,LOW); // change direction as needed&lt;br /&gt;
  } else { // depending on the sign of Error&lt;br /&gt;
    digitalWrite (Direction,HIGH);&lt;br /&gt;
  }&lt;br /&gt;
  if (abs(Drive)&amp;gt;255) {&lt;br /&gt;
    Drive=255;&lt;br /&gt;
  }&lt;br /&gt;
  analogWrite (Motor,Drive); // send PWM command to motor board&lt;br /&gt;
  Last = Actual; // save current value for next time&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Source: http://www.maelabs.ucsd.edu/mae156alib/control/PID-Control-Ardunio.pdf&lt;br /&gt;
&lt;br /&gt;
== Or use an Arudino library: ==&lt;br /&gt;
* [http://playground.arduino.cc/Code/PIDLibrary Arduino PID Library]&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=ESP8266/Arduino-pid&amp;diff=924</id>
		<title>ESP8266/Arduino-pid</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=ESP8266/Arduino-pid&amp;diff=924"/>
		<updated>2016-07-10T19:02:15Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: /* PID control on ESP8266 or other Arduino compatible chips */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== PID control on ESP8266 or other Arduino compatible chips ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void loop() {&lt;br /&gt;
&lt;br /&gt;
  //-------------------- Calculates the PID drive value --------------------&lt;br /&gt;
&lt;br /&gt;
  Actual = analogRead(Position);&lt;br /&gt;
  Error = SetPt - Actual;&lt;br /&gt;
  &lt;br /&gt;
  if (abs(Error) &amp;lt; IntThresh){ // prevent integral &#039;windup&#039;&lt;br /&gt;
    Integral = Integral + Error; // accumulate the error integral&lt;br /&gt;
  } else {&lt;br /&gt;
    Integral=0; // zero it if out of bounds&lt;br /&gt;
  }&lt;br /&gt;
  P = Error*kP; // calc proportional term&lt;br /&gt;
  I = Integral*kI; // integral term&lt;br /&gt;
  D = (Last-Actual)*kD; // derivative term&lt;br /&gt;
  Drive = P + I + D; // Total drive = P+I+D&lt;br /&gt;
  Drive = Drive*ScaleFactor; // scale Drive to be in the range 0-255&lt;br /&gt;
&lt;br /&gt;
  if (Drive &amp;lt; 0){ // Check which direction to go.&lt;br /&gt;
    digitalWrite (Direction,LOW); // change direction as needed&lt;br /&gt;
  } else { // depending on the sign of Error&lt;br /&gt;
    digitalWrite (Direction,HIGH);&lt;br /&gt;
  }&lt;br /&gt;
  if (abs(Drive)&amp;gt;255) {&lt;br /&gt;
    Drive=255;&lt;br /&gt;
  }&lt;br /&gt;
  analogWrite (Motor,Drive); // send PWM command to motor board&lt;br /&gt;
  Last = Actual; // save current value for next time&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Source: http://www.maelabs.ucsd.edu/mae156alib/control/PID-Control-Ardunio.pdf&lt;br /&gt;
&lt;br /&gt;
Or use an Arudino library:&lt;br /&gt;
* [http://playground.arduino.cc/Code/PIDLibrary Arduino PID Library]&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=ESP8266/Arduino-pid&amp;diff=923</id>
		<title>ESP8266/Arduino-pid</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=ESP8266/Arduino-pid&amp;diff=923"/>
		<updated>2016-07-10T19:01:54Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: Created with example code and links&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== PID control on ESP8266 or other Arduino compatible chips ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void loop() {&lt;br /&gt;
&lt;br /&gt;
  //-------------------- Calculates the PID drive value --------------------&lt;br /&gt;
&lt;br /&gt;
  Actual = analogRead(Position);&lt;br /&gt;
  Error = SetPt - Actual;&lt;br /&gt;
  &lt;br /&gt;
  if (abs(Error) &amp;lt; IntThresh){ // prevent integral &#039;windup&#039;&lt;br /&gt;
    Integral = Integral + Error; // accumulate the error integral&lt;br /&gt;
  } else {&lt;br /&gt;
    Integral=0; // zero it if out of bounds&lt;br /&gt;
  }&lt;br /&gt;
  P = Error*kP; // calc proportional term&lt;br /&gt;
  I = Integral*kI; // integral term&lt;br /&gt;
  D = (Last-Actual)*kD; // derivative term&lt;br /&gt;
  Drive = P + I + D; // Total drive = P+I+D&lt;br /&gt;
  Drive = Drive*ScaleFactor; // scale Drive to be in the range 0-255&lt;br /&gt;
&lt;br /&gt;
  if (Drive &amp;lt; 0){ // Check which direction to go.&lt;br /&gt;
    digitalWrite (Direction,LOW); // change direction as needed&lt;br /&gt;
  } else { // depending on the sign of Error&lt;br /&gt;
    digitalWrite (Direction,HIGH);&lt;br /&gt;
  }&lt;br /&gt;
  if (abs(Drive)&amp;gt;255) {&lt;br /&gt;
    Drive=255;&lt;br /&gt;
  }&lt;br /&gt;
  analogWrite (Motor,Drive); // send PWM command to motor board&lt;br /&gt;
  Last = Actual; // save current value for next time&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Source: http://www.maelabs.ucsd.edu/mae156alib/control/PID-Control-Ardunio.pdf&lt;br /&gt;
&lt;br /&gt;
Or use an Arudino library:&lt;br /&gt;
* [http://playground.arduino.cc/Code/PIDLibrary Arduino PID Library]&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=ESP8266/Ideas&amp;diff=588</id>
		<title>ESP8266/Ideas</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=ESP8266/Ideas&amp;diff=588"/>
		<updated>2016-04-14T02:28:34Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: /* Writing NodeMCU to ESP8266 using Raspberry Pi (first version) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:r2a2]][[category:ESP]]&lt;br /&gt;
&lt;br /&gt;
== working with Windows ==&lt;br /&gt;
&lt;br /&gt;
Driver for FTDI interface&lt;br /&gt;
:*[https://www.silabs.com/products/mcu/Pages/USBtoUARTBridgeVCPDrivers.aspx FTDI driver for Windows]&lt;br /&gt;
&lt;br /&gt;
Applications to program the ESP8266&lt;br /&gt;
&lt;br /&gt;
NODElua&lt;br /&gt;
&lt;br /&gt;
ESP8266 as an Arudino device&lt;br /&gt;
&lt;br /&gt;
== Options ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;htmlet&amp;gt;ESP8266-DiagramDraft02&amp;lt;/htmlet&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Connecting ESP8266 to Raspberry Pi ==&lt;br /&gt;
&lt;br /&gt;
These were my steps, but your specific setup may vary.&lt;br /&gt;
&lt;br /&gt;
Turn off aLaMode (don’t know if this is necessary)&lt;br /&gt;
Connect Tx, Rx, GND directly to GPIO pins&lt;br /&gt;
Connect VCC, CH_PD, to 3v3&lt;br /&gt;
&lt;br /&gt;
Device is accessible via /dev/ttyS0 on 9600 baud. Used Arduino IDE serial monitor.&lt;br /&gt;
&lt;br /&gt;
Used a variety of AT commands. Verified that I could connect to its Access Point (open wifi)&lt;br /&gt;
Connected it to home wifi network&lt;br /&gt;
&lt;br /&gt;
Pinged repeatedly. Power off/on time is &amp;lt; 1 second&lt;br /&gt;
&lt;br /&gt;
____________&lt;br /&gt;
&lt;br /&gt;
Flashing ESP from RPi using NODEMCU firmware&lt;br /&gt;
&lt;br /&gt;
Steps:&lt;br /&gt;
&lt;br /&gt;
# Ensure /dev/ttyS0 port is a functioning serial port&lt;br /&gt;
This may already be setup. Mine was configured when installing aLaMode ArduinoIDE support.&lt;br /&gt;
&lt;br /&gt;
# Install python library pyserial (used by firmware uploader tool)&lt;br /&gt;
 sudo pip install serial&lt;br /&gt;
# Baud rate. This presented a problem the first time around. But the nodemcu firmware uploader tool is open source so I was able to figure out the problem myself. Here’s the code that prevented the firmware from uploading to my ESP:&lt;br /&gt;
&lt;br /&gt;
 #Default baudrate. The ROM auto-bauds, so we can use more or less whatever we want.&lt;br /&gt;
 ESP_ROM_BAUD = 115200&lt;br /&gt;
&lt;br /&gt;
(Might want to check the assumption on this one.)&lt;br /&gt;
&lt;br /&gt;
My ESP has the original firmware installed and does not auto-sense baud rate like some of the later versions do. The NODEMCU tool uses 115200, so I had to change the baud rate from 9600 (default) to 115200.&lt;br /&gt;
AT+CIOBAUD=115200&lt;br /&gt;
&lt;br /&gt;
#. Start a new clone of nodemcu-firmware from git&lt;br /&gt;
&lt;br /&gt;
 sudo git clone https://github.com/nodemcu/nodemcu-firmware&lt;br /&gt;
&lt;br /&gt;
Or if this is already done update the repo (from nodemcu-firmware folder)&lt;br /&gt;
&lt;br /&gt;
 sudo git pull&lt;br /&gt;
&lt;br /&gt;
# If necessary, change directory to the nodemcu-firmware project&lt;br /&gt;
&lt;br /&gt;
 cd /nodemcu-firmware/&lt;br /&gt;
&lt;br /&gt;
# Put ESP8266 into flash mode by connecting GPIO-0 to ground and then apply power (or power cycle)&lt;br /&gt;
Note: connecting GND and GPIO0 to different grounds on RPi (pins 6 and 14) did not register as GPIO0=low (went into some sort of non responsive mode). Therefore, GND and GPIO0 should use a common ground (be directly connected)&lt;br /&gt;
&lt;br /&gt;
# Run uploader specifying the serial port and firmware that was included in the git clone (from the nodemcu-firmware root folder):&lt;br /&gt;
sudo tools/esptool.py --port /dev/ttyS0 write_flash 0x00000 pre_build/latest/nodemcu_latest.bin&lt;br /&gt;
&lt;br /&gt;
 Success!&lt;br /&gt;
&lt;br /&gt;
 Connecting...&lt;br /&gt;
 Erasing flash...&lt;br /&gt;
 Writing at 0x00060a00... (100 %)&lt;br /&gt;
&lt;br /&gt;
 Leaving...&lt;br /&gt;
&lt;br /&gt;
The ESP is now ready to be configured for lua scripting. I’ll be taking advantage of MQTT for sending simple messages around my home.&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=Talk:ESP8266/Ideas&amp;diff=587</id>
		<title>Talk:ESP8266/Ideas</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=Talk:ESP8266/Ideas&amp;diff=587"/>
		<updated>2016-04-14T02:25:50Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: Created page with &amp;quot;Maybe somebody can fix my ordered list of steps. It&amp;#039;s just showing 1. rather than incrementing them.&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Maybe somebody can fix my ordered list of steps. It&#039;s just showing 1. rather than incrementing them.&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
	<entry>
		<id>https://wiki.playfulexploration.com/index.php?title=ESP8266/Ideas&amp;diff=586</id>
		<title>ESP8266/Ideas</title>
		<link rel="alternate" type="text/html" href="https://wiki.playfulexploration.com/index.php?title=ESP8266/Ideas&amp;diff=586"/>
		<updated>2016-04-14T02:24:07Z</updated>

		<summary type="html">&lt;p&gt;45.31.182.136: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:r2a2]][[category:ESP]]&lt;br /&gt;
&lt;br /&gt;
== working with Windows ==&lt;br /&gt;
&lt;br /&gt;
Driver for FTDI interface&lt;br /&gt;
:*[https://www.silabs.com/products/mcu/Pages/USBtoUARTBridgeVCPDrivers.aspx FTDI driver for Windows]&lt;br /&gt;
&lt;br /&gt;
Applications to program the ESP8266&lt;br /&gt;
&lt;br /&gt;
NODElua&lt;br /&gt;
&lt;br /&gt;
ESP8266 as an Arudino device&lt;br /&gt;
&lt;br /&gt;
== Options ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;htmlet&amp;gt;ESP8266-DiagramDraft02&amp;lt;/htmlet&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Connecting ESP8266 to Raspberry Pi ==&lt;br /&gt;
&lt;br /&gt;
Turn off aLaMode (don’t know if this is necessary)&lt;br /&gt;
Connect Tx, Rx, GND directly to GPIO pins&lt;br /&gt;
Connect VCC, CH_PD, to 3v3&lt;br /&gt;
&lt;br /&gt;
Device is accessible via /dev/ttyS0 on 9600 baud. Used Arduino IDE serial monitor.&lt;br /&gt;
&lt;br /&gt;
Used a variety of AT commands. Verified that I could connect to its Access Point (open wifi)&lt;br /&gt;
Connected it to home wifi network&lt;br /&gt;
&lt;br /&gt;
Pinged repeatedly. Power off/on time is &amp;lt; 1 second&lt;br /&gt;
&lt;br /&gt;
____________&lt;br /&gt;
&lt;br /&gt;
Flashing ESP from RPi using NODEMCU firmware&lt;br /&gt;
&lt;br /&gt;
Steps:&lt;br /&gt;
&lt;br /&gt;
# Ensure /dev/ttyS0 port is a functioning serial port&lt;br /&gt;
This may already be setup. Mine was configured when installing aLaMode ArduinoIDE support.&lt;br /&gt;
&lt;br /&gt;
# Install python library pyserial (used by firmware uploader tool)&lt;br /&gt;
 sudo pip install serial&lt;br /&gt;
# Baud rate. This presented a problem the first time around. But the nodemcu firmware uploader tool is open source so I was able to figure out the problem myself. Here’s the code that prevented the firmware from uploading to my ESP:&lt;br /&gt;
&lt;br /&gt;
 #Default baudrate. The ROM auto-bauds, so we can use more or less whatever we want.&lt;br /&gt;
 ESP_ROM_BAUD = 115200&lt;br /&gt;
&lt;br /&gt;
(Might want to check the assumption on this one.)&lt;br /&gt;
&lt;br /&gt;
My ESP has the original firmware installed and does not auto-sense baud rate like some of the later versions do. The NODEMCU tool uses 115200, so I had to change the baud rate from 9600 (default) to 115200.&lt;br /&gt;
AT+CIOBAUD=115200&lt;br /&gt;
&lt;br /&gt;
#. Start a new clone of nodemcu-firmware from git&lt;br /&gt;
&lt;br /&gt;
 sudo git clone https://github.com/nodemcu/nodemcu-firmware&lt;br /&gt;
&lt;br /&gt;
Or if this is already done update the repo (from nodemcu-firmware folder)&lt;br /&gt;
&lt;br /&gt;
 sudo git pull&lt;br /&gt;
&lt;br /&gt;
# If necessary, change directory to the nodemcu-firmware project&lt;br /&gt;
&lt;br /&gt;
 cd /nodemcu-firmware/&lt;br /&gt;
&lt;br /&gt;
# Put ESP8266 into flash mode by connecting GPIO-0 to ground and then apply power (or power cycle)&lt;br /&gt;
Note: connecting GND and GPIO0 to different grounds on RPi (pins 6 and 14) did not register as GPIO0=low (went into some sort of non responsive mode). Therefore, GND and GPIO0 should use a common ground (be directly connected)&lt;br /&gt;
&lt;br /&gt;
# Run uploader specifying the serial port and firmware that was included in the git clone (from the nodemcu-firmware root folder):&lt;br /&gt;
sudo tools/esptool.py --port /dev/ttyS0 write_flash 0x00000 pre_build/latest/nodemcu_latest.bin&lt;br /&gt;
&lt;br /&gt;
Success!&lt;br /&gt;
&lt;br /&gt;
 Connecting...&lt;br /&gt;
 Erasing flash...&lt;br /&gt;
 Writing at 0x00060a00... (100 %)&lt;br /&gt;
&lt;br /&gt;
 Leaving...&lt;br /&gt;
&lt;br /&gt;
The ESP is now ready to be configured for lua scripting. I’ll be taking advantage of MQTT for sending simple messages around my home.&lt;/div&gt;</summary>
		<author><name>45.31.182.136</name></author>
	</entry>
</feed>