Discussion Forums  >  Plugins, Customizing, Source Code

Replies: 12    Views: 97

Angry Ninja
Aspiring developer
Profile
Posts: 1045
Reg: Aug 25, 2013
Maine
17,150
07/05/15 03:22 PM (9 years ago)

NEW PLUGIN - Pedometer

Here's a little plugin that I needed to create for one of my apps, and thought others might find it useful as well. As far as I can tell, it's the only plugin utilizing Apple's Healthkit right now. This means that your app doesn't need to be open to record the steps you have taken, which is HUGE. This plugin will track your daily steps, and pulls the info directly from the device's Health app. Pedometer Plugin: https://www.buzztouch.com/plugins/plugin.php?pid=26ED711DB82F0323051F012
 
Niraj
buzztouch Evangelist
Profile
Posts: 2943
Reg: Jul 11, 2012
Cerritos
37,930
like
07/05/15 08:19 PM (9 years ago)
Sweet mama! :-)
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
07/05/15 10:24 PM (9 years ago)
Nicely done! Cheers! -- Smug
 
LA
Aspiring developer
Profile
Posts: 3278
Reg: Aug 16, 2012
Jerseyville, IL
42,880
like
07/06/15 01:05 PM (9 years ago)
Nice! LA
 
Angry Ninja
Aspiring developer
Profile
Posts: 1045
Reg: Aug 25, 2013
Maine
17,150
like
07/06/15 01:12 PM (9 years ago)
Thanks guys. I was a little hesitant about using Healthkit, since it's iOS 8.0and above, but I found it amazing that over 80% of iOS users are up to date (over 82% for iPhone only... stats are from https://david-smith.org/iosversionstats ). Granted, I could have used CoreMotion to include all iOS versions (for iPhone 5s and above, using the M7 chip), but it's based on regular motion and isn't nearly as accurate, and after seeing that over 80% of the market can use Healthkit, I went that route. Keep an eye out for my new Plugin called "Fitness" that will be coming out soon. It will have the Pedometer function built in, as well as distance walked/ran, and a few other Healthkit tidbits in it as well... possibly heart rate, and a few other things. iOS 9's Healthkit will enable the ability to add sexual health and menstrual cycles as well, but I don't see those being included in the Fitness plugin, at least not right away, unless I include every possible option of Healthkit and have the developer choose what to display in the control panel... that's a possibility.
 
AppOne
buzztouch Evangelist
Profile
Posts: 348
Reg: Apr 03, 2012
London
13,980
like
07/06/15 03:31 PM (9 years ago)
Awesome that you're tackling the healthkit stuff, Ninja! I'm working on a health-related app but all my time is going on overall design and content of product. Wish I was able to tackle these new kits as they come out. I've been using the Activity app on the Apple Watch and part of me really wants to be on the bleeding edge of all this stuff as it comes out :)
 
Angry Ninja
Aspiring developer
Profile
Posts: 1045
Reg: Aug 25, 2013
Maine
17,150
like
07/06/15 04:04 PM (9 years ago)
Yeah, same here. I'm actually adding some watchkit stuff to an app as we speak, which is why I needed the HealthKit stuff. I plan on adding glances to the apple watch for steps taken and distance walked/ran for the day, and watch notifications based on geo fencing will be next. Hopefully Chris's GeoFence plugin will do the heavy lifting for me on that end. Unfortunately an apple watch plugin will be a little more difficult than most, as it requires special entitlements and files, but I'll look into it after I get it hard coded and working in my app. Pulling the data from HealthKit was the first step though, which I was able to do.
 
NCbuzz
Code is Art
Profile
Posts: 575
Reg: Sep 11, 2013
Lillington, NC
11,100
like
07/06/15 05:55 PM (9 years ago)
I haven't been on the BT site for awhile with Summer in full-swing. Saw this and sounds cool to be using the Health Kit. Way to go Ninja! Looking forward to your fitness plugin also.
 
CMCOFFEE
Android Fan
Profile
Posts: 2017
Reg: Jan 04, 2013
Amarillo, Texas
26,670
like
07/07/15 02:11 PM (9 years ago)
Cool!
 
Angry Ninja
Aspiring developer
Profile
Posts: 1045
Reg: Aug 25, 2013
Maine
17,150
like
07/08/15 02:23 PM (9 years ago)
I just uploaded version 1.1, which enables tracking of total miles or kilometers walked or ran for the day, in addition to just the total number of steps taken.
 
Becky
I hate code!
Profile
Posts: 269
Reg: Aug 08, 2012
NYC
6,140
like
07/09/15 10:57 AM (9 years ago)
Sweet...I can definitely put this to good use! Thank you, thank you!
 
Angry Ninja
Aspiring developer
Profile
Posts: 1045
Reg: Aug 25, 2013
Maine
17,150
like
07/12/15 04:32 PM (9 years ago)
I've updated the plugin. It now tracks total steps taken, distance walked or ran (in miles or kilometers) and total flights of stairs climbed. I've also updated all the screen shots on the plugin page to reflect the new changes. Click below to see the new update ============================================================== PEDOMETER PLUGIN: https://www.buzztouch.com/plugins/plugin.php?pid=26ED711DB82F0323051F012 ==============================================================
 
Angry Ninja
Aspiring developer
Profile
Posts: 1045
Reg: Aug 25, 2013
Maine
17,150
like
07/17/15 01:14 PM (9 years ago)
Looks like I'll be holding off on the "Fitness" plugin, at least for now. Stuck on some code for the heart rate stuff, and nobody responded to my stack overflow question on it (located at http://stackoverflow.com/questions/31440205/heart-rate-with-apples-healthkit ), so I moved on to the calorie burning part, and also ran into some issues. I might come back to it at some point, but for now, I'm just going to be supporting the Pedometer plugin, which has total steps, distance ran/walked, and flights of stairs climbed.
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.