Posts Tagged ‘lists’

h1

Things I want

September 24, 2014

I suspect that these this exist. Or that I could build them if they don’t. And yet, I’d rather someone send me a link where I can just buy them.

  • A tiny board that I can hook to my computer to download sounds, then hook to a button + battery to play them. My neighbor down the street has some action figures that would be hilarious to mess with. Should run for a long time off a coin cell battery. Also, possible bonus points for making it BTLE updatable (but cheap is important too so it is only possible bonus points). [Update: Adafruit just announced what I want: Audio FX Sound Board. It is a little bigger than I’d hoped but everything else is pretty good. I just hope they get on with the rest of my list.]
  • A USB rechargeable ring of battery, 3.3V and at least 350 mAh. Would be nice if it was already the right size (and shape, with connectors) to plug a MicroView into. And by “ring”, I mean, should fit my index or thumb.
  • An LED that follows along with music, can tell me if my singing along is sharp or flat. Must work in the car, with the radio. Second version should work in shower, no external music, just whether I’m in a key (any key).
  • A handheld microphone that wirelessly (BTLE? iphone dongle?) connects to my phone to be used in live podcast recording. Also, an app with few bells and whistles but the ability to reliably record. Bonus points for an accelerometer in the mic that causes two channels to be recorded separately, depending on angle of mic.
  • 2 and 4 AA battery holder with (very efficient) power switchers that provide clean 3.3V power.

Let me know when you finish or find them.

 

 

 

h1

Beagles in Paris

September 24, 2014

I’ve been working on a way to demonstrate a networking feature. I should tell you all about the networking feature but let’s just pretend that, like all routing protocols, we don’t really care about how it works.

Actually, that is why it is hard to demo networking protocols: either the demos do something and everyone says, “oh, I could do that over TCP/IP” or they don’t have any interface other than wireshark and everyone says, “wow, I’m bored.”

Yeah, I’ve been working in networking and missing my microprocessors quite a lot.

ANYWAYS… the demo! I have:

  • 8 BeagleBone Black, rev Cs
  • 8 LCD screen capes (these are absolutely marvelous)
  • 8 Webcameras
  • 8 brochure stands
  • 2 100W power supplies (each feeding four units, 5V 2A)
  • 1 hub to rule them all
  • 1 laptop to run the obligatory wireshark
  • Assorted cables (Power, Ethernet, one USB for config/debug)

We’re running something that acts like Dropbox so they all share the same data. (Seriously, I could tell you how but I’d use phrases like “Bit Torrent for the Internet” and get dirty looks from my workplace or crossed eyes from you.)

Before I go on with a few details about the build, how would you demonstrate Dropbox? As a walk-up, show-n-tell style demo on a crowded expo floor? Something that makes sense once you use it is remarkably complex for a demo.

For my demo, every second, each BBB takes a picture. It displays it on its screen and puts it in the shared directory. In another window, it uses a slideshow program to look at all of the pictures in the shared directory. Think of it like a security system, I show you what I see and what everyone else sees. This setup lets people see the how fast files are sync’d and the Ethernet traffic that passes on the wire to implement the protocol (look wireshark, no TCP traffic!).

Beagles

The main difficulty I have working with the single board computers like BBB and Raspberry Pi is that I don’t know the overly crowded space. Good software might have terrible websites, yet vaporware always looks real. It took me a multiple hours of research and testing to settle on streamer to take still pictures and on feh to display them.

For the most part I used three units to do the setup and testing. Eventually, I got it working well-enough to go ahead and set up on all eight units. That was when most of the problems actually showed up, of course.

My pictures kept getting overexposed. They’d start out ok but get lighter all the time until all images turned white if the system was left alone. Of course, it took some time to figure out that the exposure setting was the problems since if I interacted with the units, it took much longer to get to white. Eventually I searched for possible causes, downloaded v4l-utils so I could try v4l2-ctl which communicates with the camera to change settings.  I added it to my start script and apt-get installed on all 8 units.

However, my pictures kept being overexposed at the top, for the top 20%. It wasn’t due to light flicker, pointing at a window (or covering the lens) got the same top part lighter than the rest image. It was definitely the image capture program. I’d put camorama as a step to verify the webcam worked from the display (it is a touch display, so pretty, so nice).  It didn’t have the same problem, but it doesn’t get stills. So I tried a different capture program: fswebcam. That didn’t help the problem and all a change of each control parameter didn’t help. However, fswebcam lets me take a bigger picture and then crop it down. So… problem solved-ish, once I apt-get installed on all 8 units.

I don’t know if that was an artifact of the camera I chose (the fairly expensive Microsoft LifeCam HD-3000). I tried a $6 from the random-cheap bin at Central Computer and it worked fine though the stills didn’t look as nice so I put it in a drawer, forgot about it. I may try to see if it causes the top-image-light problem but since I’m locked into the gear I have for this month, the only way is forward.

Though the slideshow program has been the stable and reliable part of the system for the last few weeks, I’m not sure I like feh. It has a term that will cause it to reload the image. So if I am on Charlie, looking at Alpha’s pictures, feh can reload every second so it shows the latest of Alpha’s pictures. Well, it can do that only if it is not also in automatic slideshow mode. It can reload images or change images. It is as though there exists only one timer in the world and feh must do the best it can with its feeble resources.

It is open source, I could download the code, understand it, fix it, and copy it to all of my units. Or I can make the slideshow a little faster so you are never stuck on one unit for too long.

The slideshow already gets a bit frenetic. Even with only three units it is a bit dizzying: the BBBs bright blue blinking lights, the screen’s orange blinking light and green shining one, the slideshow updating its window every second or ten, and the captured image updating every second. I had five units working Wednesday and will have seven or eight working all at once tomorrow.

I’m not sure how many they will run in Paris, it is ok with me if they only unpack three. And, I’m not sure I’ll have all eight working in the lab tomorrow because DeltaPuppy seems sick. Who gets a kernel oops in a mv command? I sort of expected that when I named GolfPuppy and HotelPuppy, those sound like slackers. Delta has spent more time getting its hardware put on different mountings so maybe it just got knocked around too much. (Yesterday, the mechE turned down my offer of ESD bag and carrying box, popped it into his bag; I begin to see why Delta is sick. Though, maybe this isn’t a sick puppy, just a victim of happenstance, he isn’t always sick…)

Our intern is going to Paris to herd the demo along (and a couple other dogsbody duties [omg, pun totally intended, snicker]). He didn’t even flinch when I gave him the two page long “here’s how you run it” instructions. Not even when I gave him the five page long “here’s how you build the system”, told him he needed to know in case anything went wrong. I think he’s really excited about going. I hope he brings me back something French.

I’m not going. I thought I might want to go. But things here are keeping me here and that’s ok.

The multi page instructions have been replaced with an expect script. Now it takes N lines to set up N units. And you don’t have to look up their identifiers, just know the first eight letters of the international phonetic alphabet. (The intern doesn’t know about this improvement yet, I’m looking forward to surprising him.) Also, expect is wonderful. I haven’t used it in years but it really is efficient. Now I know why my coworker asked why I was typing things instead of making a script.

Speaking of scripts, I wish I could turn off all the cruft that starts with the BBB. There are all these programs and I don’t really want them running (heck, I don’t want them there). I know I could edit init.d but I’m a little worried about breaking something. I haven’t yet seen a good guide to stripping down the BBB Debian system to the bare bones. Anyone have any suggestions?

Overall, I like the BBBs, I love these screens, I’m indifferent about the webcams, and I’m uncertain about the final mounting. I retain my Linux-is-hard-because-nothing-quite-works feeling. There is little standardization (one program likes to use man, another info, another has a sparse man page but gives a nicely detailed output with a command line –help invocation). And I like that this demo is built from off the shelf components, only a bit of extra software (most of which the demo team will provide in tutorial sessions). It has an “I built it, so can you” vibe going for it.

h1

Manatee photos

April 23, 2014

I usually say that if I am not blogging about my personal projects, I’m not working on them. That isn’t true this week.

I’m afraid that if I take the time to write everything that is bursting in my head, I won’t get to continue working. So I’m going to just put up some photos. These aren’t build instructions, maybe they are just place holders for all the stuff that should (and some that shouldn’t) be in the ayok build notes.

Choosing an LED has been tough. In that pic there are two RGB LEDs, both the same power but the big one (10mm) has a diffuser. The three little ones are red, yellow, green individual LEDs. They are from LilyPad which means they are built to be sewn into things.

Elizabeth made a manatee prototype, including the diffuse LED as a nose and the smaller three as buttons.

For the nose, the question of how to attach it to the fabric came up. Hot glue seems to be my solution for everything but that does make fabric feel yucky so I cut out a perfboard. Elizabeth then used the holes in that to build a prototype nose.

But before I show you how she put it together, here is the base-model manatee. The pattern came from cationdesigns.

It sits up unaided (thanks to some sand weights in the tail and lower belly). It is soft and utterly adorable.

But less so when you add an LED schnoze. That manatee body doesn’t have any stuffing but, even so, not the look we were going for.

The button style LEDs are kind of boring. And since they don’t color mix we lose a lot of flexibility. (All GPIOs are the Electric Imp are used!)

Using conductive thread seemed neat but the interface between pins and wires is not easy. To get the LEDs to light, I ended up knotting all the plus and all the minus sides.

Of course, the thing the thread likes to do most is make knots so that part was easy. I wasn’t thrilled by the look or the electronics side of those buttons.

Putting the tummy in the empty cavity of the body looked nice but that isn’t exactly realistic, the LED can’t just float around in open (deflated) air.

Elizabeth suggested that since we are using a double layer fabric, we could put it between layers . So I unraveled some of her work and shoved it in a newly opened seam in the back.

With the LED in between the two layers of fabric, t gave a nice glow. We are going to try that some more, to give it a tummy glow. I hope that works. It is better than our fallback plan of making the big diffuse LED into some sort of tophat.

The new manatee model also came with a pocket for electronics so we could make things fit. But before we see that, let’s look at the electronics build.

First a parts list in graphic form. This is also in a SparkFun wishlist.

Next I tried to show how things would get assembled. I don’t think I want to do a step by step assembly. The soldering isn’t too tough… But here is what I took while I built it.

First attach headers!

Next, attach red to ground and black to power. Sigh, that is really what happened in the next pic.

I figured it out two days later when the fuel gauge would not work, not even after I fixed its I2C lines. So, maybe this pic won’t go into the instructions.

I need an extra set of I2C pins and another ground pin. I devised this stupidly complex way to go about it involving another breadboard.

I’m not sure how to explain that you can follow this tutorial even if you solder like a drunken sailor. In high winds. Also, you don’t have to do this because you don’t need all these pins that I thought you might want.

Happily at this point we can go back to the manateee. Which I’ve named Hugh. At least this one is.

He’s got a pocket in his butt. This is what needs to fit.


From another angle…

I have more electronics than will fix, though it isn’t too far off. The problem comes from using up-down headers. With right angle headers, this would have worked better. So do I go back and re-do it with right angles?

Because while I jammed everything in there, it appears that Hugh has some unsightly wires coming from his, um, backside.


Ok, this one I took for twitter because I was getting Hugh’s Electric Imp to work. I found a short with the I2C connection (bad solder joint) and then the fuel gauge ground/power swap.


There are some software oddnesses with running two Impees from one account. It took me awhile to get it running. I’m still not sure how to differentiate between the two units (though I’m pretty sure there is a way).

Having gotten it working, I took some pictures today to help explain the wiring. The power subsystem could all be be stuck together: hot glue!

Actually, I wanted that foamy double stick tape but couldn’t find any. Note that only two sets of wires go out of the frame: I2C SDA (green) and SCL (yellow); power (red) and ground (black).

Those go to the Electric Imp board. Two bundles of wires then come off the Electric Imp board: the LED and the accelerometer. The LED has a red (Imp pin 2), green (Imp 5), and blue wire (Imp 7).

The LED pins are:

  • the longest is ground (black)
  • the short one next to that is red
  • the remaining inside one is green
  • the last one, outside, opposite red is blue

The accelerometer has power (red), SDA (green) , SCL (yellow), (nothing), Wakeup (violet), and ground. These all go back to the Imp board.

Finally, the un-taped, un-hotglued ball of wires on my desk.

So you can see, progress is being made.

The second set of electronics work. I have enough drawings and pictures to describe how to do the build (if not enough to do the stuffed animal). The code is working though I have some tweaks (multiple users need different names, handle email, and separate test from real code then comment it).

But Elizabeth is getting this set of electronics this weekend so expect another manatee soon (and maybe another set of electronics).

h1

Almost feature complete

March 31, 2014

My little are-you-ok widget tweets when it has been tapped or moved. It also tweets if it hasn’t been moved in 10 minutes. (You probably don’t want to follow @ayok_status, the timeouts change when I’m testing; that little guy can tweet a lot.)

But that’s the main functionality: tweeting when it doesn’t move. Setting 10 minute or 24 hours is just a parameter. I’m done!

Well, not exactly. Like many software projects, even though the main features are in place, 75% of the work remains to be done.

I need to do the battery stuff, putting the electric imp to sleep but waking up to monitor the current battery status with the fuel gauge. I also need to tweet when the batteries are low, probably have the device check-in every hour (or four) to verify it is still alive, even if it hasn’t gotten any attention. I can add battery level to that. Also, I need to check how much power the unit is using in different states (and make sure the accel goes to sleep too!) to verify my battery will last a long time.

And then I need to make a webpage to set all the parameters.

– How often do you need proof of life? Every 12, 24, or 48 hours? My 10 minute version is only for testing, I’ll probably switch it to 12 hours for the days I don’t spend at my computer.

– What do you want it to say when it doesn’t get anything? Do you want a tweet @ you? Or a DM (I don’t know how to do that programmatically but I’m pretty sure it is possible.)

– Twitter is easy but do you prefer email, twitter, or text? (Text is the hardest, I know Twilio offers this but I haven’t dug into it. I suspect email isn’t tough, the most difficult part will be deciding if it comes from embedded.fm or logicalelegance.com.)

– Is there more than one person who should get a notification? Do they each want to configure their info separately?

– For email and tweets, what should it say? I currently have several strings it randomly chooses from and then tweets. Will users want to be able to enter their own? How many?

local stringOptions = [
     "No one has played with me since ",
     "I need to be pet but haven't been since ",
     "The last time someone filled my cuddle tank was ",
     "It's been eons since my last hug: ",
     "I'm so lonely, no one has paid attention to me for so long: ",
     "I'm hungry, hungry for hugs! Last feeing was "
 ];
 
 local d = date(lastCheckInTime, 'u'); // UTC time
 local day = ["Sun", "Mon", "Tues", "Wed", "Thurs", "Fri", "Sat"];
 local datestr = format(" %02d:%02d:%02d", d.hour, d.min, d.sec) 
 local choice = math.rand() % stringOptions.len();
 twitter.update_status(stringOptions[choice] + day[d.wday] + datestr);

– Should there be a method (button on the webpage?) to show when the device last checked in and its battery level? Should it also show when it last interacted with its user or should that be private?

What other parameters should the user be able to configure? I’m not that good with web pages so having a definite plan would be good.

And then, there is the testing: needing to let time pass, waiting for things to happen. I suppose that means it is time for another cup of coffee. In the meantime, I can dream of shipping it.

Right “shipping it” is a can of worms unto itself. Well, worry about these things first. And then maybe how to make it nice looking. And then shipping it.

 

h1

Step 1: Make a list of steps toward the goal

March 28, 2014

I was at a small start up, complaining that they were building a science project instead of a product. They seemed a bit confused by the difference. I made a list of milestones with concrete demos to show what I meant by obvious and measurable progress. The first few focused on the single working unit they had, but starting to prove software control of hardware (electrical and mechanical). The next few focused on making sure multiple of the expensive-ish units could be built; there was some subtext about making software tools to verify different units behavior. In the product world, that was about identifying manufacturing steps. The final few milestones were more directed toward some of the software algorithms and toward larger scale manufacturing.

Darth modified for demo

Sadly, after we defined and met the first demo, the other engineers realized just how (not) far we were along the path. The start up has closed its doors, trying to regroup. I feel sad about this, I know I instigated the crisis. But it was coming anyway so I don’t feel totally awful for speeding its arrival.

As I’m working on the are-you-ok widget, I’m struck by how often I want to have milestones, something that acts as a demo, that shows progress.  Since this is a personal project and it would be more short-term fun to read a novel, I try to keep myself engaged by having interesting deliverables.

Yesterday, I got the accelerometer working so that the LED color depended on orientation (RGB  set via XYZ). It was fairly amusing, though hard to demo without a video.

Green is Y

Red is X
Blue is Z

For today? Well, I think I want the device to wake up when it is moved, read the accel, tweet that it moved, turn on the color based on accel, ramp down over a second if no additional motion, and go to sleep.

I also want to try out the new couch. And solder the motor boards (they came! finally!). And verify the old couch’s new location is as nice as I thought. Have lunch with Rob. Go out to dinner with my hubby to celebrate our wedding anniversary. Find my to-do list and cross something off of it (none of these things are on it since I lost it). Buy bread and benedryl. Practice my EELive IoT talk. Maybe even practice the teardown with Jen. Buy new jeans as these have a hole. Oh, shower, that I should probably do before lunch. And exercise. Fold the laundry.

Where was I going? I have no clue. But I should probably get started soon.