Skip to main content

Excursions in Datalogging

Well, it’s been far too long since I’ve blogged… well, anything. So I wanted to drop a quick line to mention three interesting datalogging examples I’ve hit upon during the last few months. In some cases, these are only ideas to be built upon, but they should give you food for thought on datalogging with the NXT. All these images are up in my Brickshelf gallery if you want to look – plus more.

First, I was contacted by someone who wanted to know if it was possible to use the NXT to log the accelerations of a Hulahoop. So I said “I don’t know”… and tried it.

The first task was trying to get a semi-balanced hoop with the weight of the NXT. So I used the best thing I could to counterbalance an NXT… another NXT. Using duct tape (a lot of duct tape) I taped one NXT with a Hitechnic accelerometer to one side, and another NXT to the other side as a counterbalance. OK, now the next problem… I can’t Hula-hoop. At all. And a hula-hoop with a dozen AA batteries duct-taped to it isn’t the easiest thing to work with in the first place. But I was able to get it to at least spin around my neck… until the NXT slammed into my skull (note: this hurts. A lot. I was seeing stars for a few seconds, and had a huge goose-egg). In the end, I did get some interesting data from spinning it around my wrist in a vertical orientation (far safer), and found you could see both the rotation of the hoop (about one rotation every 4 seconds) as well as the revolution of the center of the hoop around my wrist (every fifth of a second or so… yes, I labeled the graph the wrong way around, I think). The folks who originally asked me about this work on electrically illuminated hula-hoops triggered by internal sensors, and I hope they were able to use some of this information practically… but even if they didn’t I had a lot of fun trying to get the data.

Another fun project was actually not mine, but my sons. I firmly believe that a science fair project should be the job of the student, not the parent. In this case Ben wanted to determine who was noisiest in the school hallway (his hunch was the 6th graders), and decided after watching me, to do it with an NXT. He and I played around with using the US sensor or the light sensor, and eventually came up with a way to both “count” people and keep the system very well hidden from curious students. The idea was to use a very low-power laser (class I – a very low-power laser similar to what you see in a supermarket barcode scanner, for safety) next to the NXT at floor level, directed off a tiny inconspicuous mirror on the far side of the hallway and back onto the light sensor (set in “ambient” mode). Now every time someone walking down the hallway broke the beam of light, the NXT would add one to a “count” variable, recording the value of that variable and the average sound level detected during that interval every so often. Since the “system” was just an NXT with two sensors (with an ingenuous sliding positioning system for the light sensor) and a separate “super laser pointer”, it was easy to hide behind a box or under a video cart, and the laser spot was so dim it wasn’t noticed by students on their feet. All in all, a really interesting automated way to get information about traffic flow in the school hallways. And everything was done by my 10-year-old: designing the hardware, selecting the method, programming the datalogging, downloading everything & analysis. Oh, and he found the morning announcements by the principle were the loudest thing on most days, a fact he gleefully pointed out to her. My only contribution was soldering up a laser system that would run off AA batteries – the rest was his, and I was very proud of the result.

Finally, for another project I’m working on (more later), I was curious if you could use the NXT as a simple pedometer, logging each footstep. Most pedometers simply keep a running count – by the end of the day, you might know how many footsteps you’ve taken, but you’d have no idea if you’d done those at the beginning, middle, or end of the day. Since the NXT can be fitted with an acceleration sensor, it should in theory be able to determine the moment every footstep happens, and record that information any way you like – not just the running total, but details like how the footstep frequency changes throughout the day (when you get tired), or when you were sitting still, etc. Here’s a quick test of this idea, with the NXT logging the total acceleration measured about 50 times a second. At this resolution each footstep is clearly visible, and you could probably pick out details like how the acceleration changes when walking up or down stairs. Now, can my NXT record an entire hike for later…

--
Brian Davis

Popular posts from this blog

ROBOTMAK3RS Review: LEGO River Steamboat

I thought the LEGO River Steamboat would be an interesting set for a ROBOTMAK3R review for a few reasons. First, the LEGO designer of the model is Marina Stampoli, a long-time collaborator of the late ROBOTMAK3R Vassilis Chryssanthakopoulo s. From earlier collaborations with Vassilis, I  knew Marina was incredibly talented, with an eye for aesthetics and functionality. Her background in architecture is particularly useful for her relatively new position at LEGO. Her other sets include the Magic of Disney (21352), Message Board (41839), and Red London Telephone Box (21347). Second, watching Marina's reveal video  and reading her designer interview made this set even more tempting to build. The gearing mechanisms running through the model gave way to many opportunities for automation using LEGO robotics elements. Since ROBOTMAK3RS is all about adding interactivity and automation to LEGO brick, I thought it would be fun to see where and how LEGO robotics could be added to this s...

Celebrating 25 Years of MINDSTORMS

In celebration of the 25th Anniversary of MINDSTORMS, we take a trip through history. Please also visit ROBOTMAK3RS Community every week as we highlight different projects all through 2023 in celebration of the anniversary. Some of the early history is based on the content shared by  Coder Shah  in our  MINDSTORMS EV3 Community Group . Some of the text and links may have been edited from his original posts for consistency and clarity.  1984 - Kjeld Kirk Kristiansen watched a TV program called "Talking Turtle," where MIT professor Seymour Papert demonstrated how children could control robot "turtles" using LOGO, a programming language he developed. 1988 - The collaboration between MIT and LEGO resulted in LEGO TC Logo in 1988, which allowed students to control LEGO models using computer commands. The video shows Papert demonstrating TC Logo. 1990 - LEGO TC Logo was hampered since the robots you built had to be tethered to a personal computer. LEGO and MIT...

Ghostbusters R.T.V Remix

Nino Guba is from Torrance, California, USA. He played with LEGO as a kid, but growing up in the Philippines, it wasn’t something he had easy access to. He only got reintroduced to LEGO when he moved to the US and had kids of his own. When his sons were younger, they received LEGO sets as gifts, but as they grew older, the sets got put into storage as their interest faded. Fast forward a few years, he started coming up with his own product ideas and thought about how he could quickly prototype them. That’s when he discovered LEGO MINDSTORMS—and was hooked! He raided his kids’ old collection, got everything organized, and now he's designing and building his own creations, blending his coding skills with LEGO robotics to bring ideas to life. Tell us about your Ghostbusters Remote Trap Vehicle (R.T.V) project. This project is a LEGO Technic adaptation of the Ghostbusters R.T.V.—a ghost trap converted into a remote-controlled vehicle. Its companion build is a prop replica of the Futaba...