libfitbit fixes

120 views
Skip to first unread message

Reed

unread,
Dec 31, 2011, 3:08:25 AM12/31/11
to openyou
2 entire weeks off work and a dull rainy day leads to geeky success--


Needs more testing but I seem to have sorted out a lot of the problems
I was having with libfitbit.

https://github.com/reedwade/libfitbit

I've made the logging a little more sensible to me and a little more
verbose. I've also added a wrapper around the client runner so it
spins every 15 minutes even if the last attempt generated an
exception.

The 2 meaningful changes were:
- increasing the wait time after a reset command to 1.0 from 0.6
seconds which cleared up a lot of failures for me; taking it to 2.0
seconds was too long (never heard from the fitbit device) and I'm
assuming there's some window after reset when you can send it the
configuration commands
- dropping the 0x80 reset check in ANTlibusb.__init__() for some
reason resolved a lot of exceptions that otherwise appeared to be
lower level usb related. I haven't looked closely at why or what's
going on there.

-reed

Daniel Hauber

unread,
Jul 24, 2012, 8:12:32 AM7/24/12
to ope...@googlegroups.com
Hey Reed:

Thanks for this update to libfitbit.  It seems to work better (or at all) for me than the original.

Wanted to ask your help though -- I'd like to install this as a program on ubuntu. I'd installed the original (qdot) libfitbit using apt-get and a PPA for the qdot download.  Do you know how I'd go about replacing it with your version?  I've already downloaded the zip file, and can run the Python scripts successfully.  Just would like to get them going as background processes, running all the time.

Thanks again.
-Dan
Reply all
Reply to author
Forward
0 new messages