Time Tracking with a Disney Infinity USB NFC Reader
While browsing my local thrift store, I stumbled upon a little gadget that I decided to repurpose:
It was only $6 USD, so I thought it would be a fun project.
I searched for ‘Disney Infinity Linux’ to see if any work had been done toward decoding it or making it work. I found various sources that suggested that Playstation or Wii versions work fine, but the X-Box version was challenging. Fortunately, among the 5 they had, one was the Wii/Playstation version so I bought it.
Hardware
Disney Infinity USB NFC Reader
Here you can see the NFC sticker.
NFC tags
I purchased a set of 10 NFC tags for this. After some reading, I decided on the Thonsen 10PC NFC Stickers
<<<<<<< HEAD
These are stickers, so I could easily just stick them on to each face, but I don’t want to waste the dry erase capability by doing that, so I insert them behind the dry erase part of the cube. These NFC tags are universal so they should work with any NFC reader. I was able to read them on my iPhone 12 Pro Max with the NFC Tools app.
These are stickers, so I could easily just stick them on to each face, but I don’t want to waste the dry erase capability by doing that.
dde45fd09851c2f0153ec5ff62f8a2b4421bc0db
Haptic Toggle Device
I needed something more elegant than just swapping stickers onto the NFC Reader. My first thought was to make a paper dodecahedron, cube or something similar. I kept it in mind for my visits to the local thrift store figuring that I might find a toy or some other item that would work.
While browsing around my local dollar store, Shannon spotted the perfect item:
A dry erase toy foam cube for $1 USD
Being a cube meant that I would have six faces on which I could place an NFC tag. I couldn’t easily think of more than 6 modes of time to track, so it was perfect for the project. In hindsight, I should have picked up 3 of these cubes considering that the Disney Infinity has 3 NFC pads. That would provide me with 7 (one for each of the 6 sides, plus no-nfc tag present) possible modes on each of the 3 pads. My math is probably wrong, but I think this provides for 3^7 combinations, or 2,187.
Since I only bought one cube, I’m not working with theory. The reality is that I have 7 time tracking modes possible (for now).
They are:
- Work
- Consulting
- Lunch
- Break
- Unassigned 1
- Unassigned 2
- Not tracking / No Tag
The other really useful feature of this foam cube is that it has dry erase areas on each side. This means I can draw unicorns, write words or symbols on each face and I can change them at any time.
I’ll have to coordinate each side/NFC tag ID with the writing on each face.
Someday I may get more granular by adding Project / Stories or Clients specific tags and adding more foam cubes.
Software
Now that I have a haptic interface (foam cube) and an NFC reader (Disney Infinity), I need to integrate it all with some software.
HID Driver
The first step after getting the device was to figure out what it was and how it worked. This is what came up in lsusb
:
1 | root@ns-01:~# lsusb |
The useful bit here is the ID: 0e6f:0129
That’s the VendorID:ProductID.
Probing further, I get this detail from usb-devices
:
1 | T: Bus=01 Lev=02 Prnt=02 Port=02 Cnt=01 Dev#= 3 Spd=12 MxCh= 0 |
I’m no computer expert, but it appears that Disney Interactive has their own USB Vendor ID. From that they obviously created the Product ID.
These line break down as follows:
- T: Bus, Speed and Port information
- D: USB Version and some other things I don’t know
- P: Vendor ID, Product ID, Revision
- S: Vendor / Manufacturer human readable text and Product human readable text strings
- C: Power information?
- I: Interface type. In this case I see HID which is Human Interface Device.
We can go further down the rabbit hole using usbhid-dump
:
1 | cbergeron@ns-01:~/github/infinity $ sudo usbhid-dump |
This descriptor can be decoded using a USB Descriptor and Request Parser:
1 | 0x06, 0x00, 0xFF, // Usage Page (Vendor Defined 0xFF00) |
Great. We’ve confirmed it’s an HID device. Let’s interact with it.
The Glue
Now that I had some working code to interface with the device, I needed some code to talk to it. Fortunately, there was some work done toward it, but it wasn’t comprehensive. I found come Python 2 code that I was able to easily update for Python 3.
You can view the code here in the Disney Infinity USB Repo.
The interactive example app here responds to device removal or replacement.
1 | <<<<<<< HEAD |
I can also change the colors of the LEDS from the app based on events or os triggers. I’ll expand on this post in the future if there is interest.
<<<<<<< HEAD
The Time Tracker
=======
dde45fd09851c2f0153ec5ff62f8a2b4421bc0db
Scope Creep / Future Features
NFCs are neat little radio devices. Most modern phones have NFC reading capability, so it would be easy to create a phone shortcut to read the cube and update the time app when I’m away from the Disney Infinity reader.
I could also add more granularity to the current time tracking capability. For example, If I used 3 cubes, I could have Consulting, CLIENT NAME, and project stage (DISCOVERY, IMPLEMENTATION, NEXT STEPS, etc).
Conclusion
I used this little gadget for a little time-tracking proof of concept project, but there are many other potential uses. A few that come to mind could be:
- A little device that sends your sweetie a text message (draw a smiley, a heart, or angry face)
- A childs learning toy
- An intrusion device (nfc sticker inside of a cabinet with a reader inside)
What would you do with 3 NFC readers and a few NFC readers? Feel free to Comment below 👇
Time Tracking with a Disney Infinity USB NFC Reader
https://chrisbergeron.com/2022/01/08/Time-Tracking-with-a-Disney-Infinity-USB-NFC-Reader/