Example use at the summercamp
example-use with ESP-12
Go to Examples/ esp-mqtt-arduino and open mqtt-pub. (if you added the library while running the IDE, restart the IDE so it recognizes the added library)
this sketch publishes the data (sends the data) to MQTT.
MQTT myMqtt(CLIENT_ID, “192.168.1.50”, 1883);
“192.168.1.50” should be changed to the IP address of your device running Musquitto broker.
const char* ssid = "ssid";
const char* password = "ssid_password";
You will need to change “ssid” to the network name you are using. For example if your are using the wifi network called studio_one then change it to
const char* ssid = “studio_one”;
Also, you will need to type in the password for the wifi network. If your password is 1234_QYhe then
const char* password = “1234_QYhe”;
Now you will need to upload this Arduino Sketch to the ESP module. For this, see the “Hardware setup”.
example use of ESP-01 with Attiny (serial communication)
soft-breakout for ESP-12
ESP devices originally come with SMD connections and only some of them are on the breakout pins. And even if it is on the breakout pins, it is not in the most convenient shape if you want to use it with eTextiles. Here we document the pinout of the devices, the pinout for the programming environments and how we explored the possible breakout design for eTextile devices.
Connecting with textile stretch sensor made with eeonyx stretch fabric fused on non-conductive stretch fabric. It is made into tube shape to wear on your elbow. In this model, I needed 560k ohm pullup resister.
To program the ESP module, you need to access GND/VCC/RST/GPO0/RX/TX of the device. As I did not want to add header on the breakout as it increases size and is “hard”. Instead we came up with the idea to modify fabric pinches, adding copper tape traces that fits to the traces on the fabric breakout. This is the first prototype, and needs much more refinement (like marking which port is what) but as a principle, it works. We did re-program the ESP12 with this connector.
ESP-12 fabric circuit try-outs. The width of the fabric traces and the placements had to be readjusted couple of times to get the working prototype. The traces are copper conductive fabric, fused with heatbond (from Rachel) and cut with Vinyl cutter.
The second generation ESP-12 fabric circuit. It has ADC, VCC (for connecting pull-up resister) and GND connection with poppers. The last model’s connection point was too close to each other and was making false connection. This version got a bit wider to avoid the problem.