Category: Software Development

Seismometer Project

A friend asked me if I had a seismometer. Nope. But I might be able to build one…

One approach would be to build a more traditional weight-and-spring kind of thing, but I thought I could do it more easily with a MEMS accelerometer. I had one laying around, so I decided to try it out.

I hooked up an LSM303DLH 6DOF accelerometer/magnetometer to an ESP-01 running an ESP8266 processor.

There are a few points of interest / investigation in this project:

  • What is the frequency response of this kind of accelerometer?
  • What are the frequencies of interest to this friend?
  • What sampling rates are possible for this device?
  • How to filter / smooth the raw data
  • Is calibration required?
  • How to present the data?

In this post, I’m just going to address one possibility for the last item. I will eventually log the data with timestamps into a file on a removable drive, but right now I want to see the data.

Cutting to the chase, here’s what it looks like. Click on it to see the chart move. (Whee!)

The web page is restricted to my home network, but you are welcome to the code.

Here’s a snapshot of the main Arduino program. The functions updateWebPage_root, updateWebSocket, and updateWebSocketArray are the ones you want to look at.

Updating some, but not all, old technology

Lightning strikes. It struck near me, and fried a component of my old X10 home-control system.

X10 is a power-line-based communications network. Data is sent (slowly) over the house power lines by injecting a 120 kHz signal into the 60 Hz AC signal just after the zero-crossing of that signal. One bit per cycle is sent by either adding or withholding a short pulse of the 120 kHz.

[Read More...]

Experiment with CircuitPython, Jupyter, and WordPress

I’m trying to embed a Jupyter notebook page as a blog post. I saved it as html, and copied an pasted that html below. I don’t think that’s the best way to do it.

We are exploring the Adafruit Metro M4 Express

[Read More...]

Thoughts on serial communications

Maybe these issues have been solved in the past. I don’t think there is necessarily a very good solution, though.

The problem is that serial communications is imperfect. Characters get messed up in transit between two devices. When they do, that in turn messes up carefully thought out protocols, like “Capture characters in a buffer until you see the linend; then process the buffer as a single message.”

[Read More...]

Teensy, touch sensing, and ESP8266 – via MQTT and Raspberry Pi

Whee!

I have a demo/development setup on a small breadboard which powers an ESP-01 ( the small, cheap, 8-pin breakout board for an ESP8266 chip ). In addition to being a programming board, it has 3v3 voltage regulation, a pot, a temperature sensor, a simple LED, and a WS2812 3-color LED. I have the installed ESP8266 running a program to subscribe to an MQTT broker and light the LEDs according to publications on a certain topic.

[Read More...]

Instrumenting and Analyzing My Solar Tracker

I’m an instrumentation and data collection geek. I love the challenge of developing ways to monitor the systems of my house and making sure they’re working properly. I’ve had a couple bad experiences where systems failed and not knowing it soon enough caused problems.

[Read More...]