RFID login on a Mac?
December 26, 2007 1:58 PM   Subscribe

How can I use RFID to login to my Mac running Leopard

I have a PhidgetRFID device. I want to be able to control my computer with it (i.e. login, open a program when a tag is detected, etc.) I have no programming skills at all (I know some html and css). I am using Leopard.
posted by ooklala to Computers & Internet (6 answers total) 1 user marked this as a favorite
 
You're going to need programming skills, even if only Automator-level to make it do anything. I strongly doubt you'll get it to login for you, as for obvious reasons Apple hasn't left that open for developers to jones about with.
posted by bonaldi at 2:24 PM on December 26, 2007


Response by poster: I've looked around but other than xcode, there is no option to use it with the mac. I use automator, actually and some basic applescript (I neglected to mention that).
posted by ooklala at 2:28 PM on December 26, 2007


I work with that Phidgets RFID reader through Java on Leopard. I have no idea how you'd go about setting up logins (and doubt you could, honestly), but it shouldn't be difficult to set up a Java console app that executes a pre-configured command when a particular tag is read. I'm obviously biased because it's what I'm familiar with, but Java seems like a not-entirely-horrible way to do this sort of thing. You might want to look into Processing, which wraps some of the complexities of Java in a neat little package. All the same, the code you'll need to interface with the Phidgets reader and launch apps will not be part of Processing, so you might do better starting with real nuts-and-bolts Java.

As for how to start with Java, it's been so long that I don't think I can offer anything contemporary. There's something called New2Java on the Sun website which might help you get up to speed, but I didn't take that path and can't vouch for its accessibility to a programing newcomer.

Note that a lot of people are going to say "Wait, it's OS X, you should be learning C or Objective C." They're probably right, but I suffer from that condition where, when you're carrying a hammer, everything looks like a nail. ;) Wish I could speak to Obj-C, but I have very little familiarity there.
posted by Alterscape at 2:43 PM on December 26, 2007


You can do just about everything you mention except logging in with a Processing sketch that makes clever use of the "osascript" command-line tool. "osascript" lets you run Applescript commands, and Processing can run command-line tools. With Applescript you can control just about any Mac program, including launching and quitting them.
posted by todbot at 8:00 PM on December 26, 2007


Response by poster: But how do I get Java/AppleScript to interface with the rfid?
I have pretty much abandoned the login idea, I just want to be able to launch programs and such.
posted by ooklala at 1:24 PM on December 27, 2007


As Todbot said, osascript is king. I have some sample code I can show you, if you like. Email's in the profile.
posted by Alterscape at 4:06 PM on January 2, 2008


« Older My Cateye does not compute. I need new ideas.   |   Single man on the prowl Newer »
This thread is closed to new comments.