CircuitGizmos

Electronic Products for Creative Minds

  • Home
  • Gizmo Store/Products
  • Documentation/Datasheets
  • Projects/Libraries
  • GizmoBlog
  • Services/Contact
    • Design
    • Contact Gizmo!
  • Your Gizmo Cart
    • Your Account

February 5, 2009 by robert Leave a Comment

Linux code for U401 (Make Magazine Blog)

usb_motion_page

Today on the Make blog was a posting (it was from the Make forum) by “pmgeahan”. It talks about the U401 use in Make#16:

Thought others might be interested in this; I built the USB motion detector in MAKE 16. The driver program provided was for Windows and was used to make a presentation work.

In my case, I’m a Linux guy, so I hacked together an executable to drive the detector. Strictly speaking, at least on Ubuntu, there’s already a HID driver for the USBMicro interface, but it doesn’t do anything. This program triggers on the motion and, in this case, takes a photo with your webcam. A security system, if you will.

Anyhow, the program is pretty simple, all told. Couple of caveats: First, this has been tested on an Ubuntu box running 2.6.27-11 only. You need libusb to make this thing work. Also, you need privileges on the USB device. I wasn’t able to find exactly how to make this work on my box (couldn’t figure out which /dev entry to make readable/writable). I chose to run it suid root. I know, not the greatest idea, but it works. If you can figure out what to do, lemme know.

The source code can be downloaded here

I will be exploring more Linux programming.

Filed Under: Uncategorized Tagged With: Linux, Motion detection, PIR, programming, u401

A Ton of Documentation

Open all | Close all

Projects made by Gizmo, Friends, and Members

open all | close all

Recent GizmoBlog Musings

  • Altair 8800 using a ColorMax!
  • Re-energizing the ColorMax, Pt. 3

Visit us!

  • Facebook

Electronic Products for Creative Minds

CircuitGizmos is your source for electronic products that help you create your embedded projects. Here at CircuitGizmos.com you will find a friendly store filled with creative products and all of the documentation that you need to use these gizmos.

We create devices that we believe make electronics fun, but we also know that our products are used for professional designs. For decades we have designed products for commercial, military, and medical industries. Our gizmos here are great for engineers and hobbyists alike.

Copyright © 2008+ CircuitGizmos, L.L.C. All rights reserved

Image already added

Recently Viewed Products

Copyright © 2023 · Generate Pro Theme on Genesis Framework · WordPress · Log in