The content of this blog is my personal opinion only. Although I am an employee - currently of Nvidia, in the past of other companies such as Iagination Technologies, MIPS, Intellectual Ventures, Intel, AMD, Motorola, and Gould - I reveal this only so that the reader may account for any possible bias I may have towards my employer's products. The statements I make here in no way represent my employer's position, nor am I authorized to speak on behalf of my employer. In fact, this posting may not even represent my personal opinion, since occasionally I play devil's advocate.

See http://docs.google.com/View?id=dcxddbtr_23cg5thdfj for photo credits.

Friday, January 01, 2016

Metronome for Walking Pace/Cadence while listening to Podcast or Audiobooks


Looking for a metronome app to provide cadence while walking and listening to podcasts and audiobooks. iPhone can't, but Android can.

FAIL: I felt all good about kuewlsoft's Metronome app - but on the first longish walk I learned that it turns off when the phone is locked.  Trying other Android apps. So I created the table at Metronome Comparison Spreadsheet.

I thought that I was narrowing down to Rhythmic Metronome, Zenom Metronome, and B'Metronome - but after a week I switched back to kuewlsoft's Metronome app.  kuewlsoft's good metronome features - a tolerable click that does not offend my ears, the ability to specify emphasis clicks, volume controllable separately from the overall volume of the podcast - make up fr the problem of turning ff when I lock the phone.

I cope with kuewlsoft's Metronome turning off if I lock the phone by not locking the phone - after all, it is not my real phone, just an old Android phone (because iPhone can't mix two sound sources). At first when I put it in my pocket I had problems with accidentally hitting screen buttons - but my low-tech solution to that is to have a stuff piece of cardboard that covers the screen.

I can live with kuewlsoft Metronome, but I would still like to find a better Metronome app.  Must-have wants: simultaneous, works when locked, sounds nice, emphasis, 3:4 time, rates 100-160 bpm.  Wanna haves: controllable volume and rate from my headset.  In my dreams: a "smart" metronome that adjusts to encourage me to be faster, even if I slow down climbing a hill.

Haven't looked at pay apps. Some of the free but $ upgrade app$ look interesting, but I don't have time to search all.  Looking for software sucks.


Walking is my main form of exercise. (One hour+ per day, 3+ miles per day; because I have a dog; because my knees are shot from too much hill running and soccer stomping in my youth; because I live next to many miles of beautiful trails in Portland's Forest Park.  I also swim and climb, but I do not live next to a swimming pool or a climbing wall.)

I love walking in quiet wilderness - but in a city like Portland, the woods are often not so quiet.   Plus, 2 hours a day really impacts other things, like continuing education. So I often walk while listening to podcasts (NPR news, computer security), or audiobooks.

Plus: when I do exercise in a gym (elliptical, treadmill, rowing), I was bored out of my skull until I stated listening to podcasts.

Problem: listening to human conversational voices, in news, podcasts, audiobooks or lectures, leads to a moderate, sauntering, walking/jogging/running pace.  Too slow a rate of exercise.

Now, folks who listen to music while exercising often choose songs with a target beats per minute rate.   But, I prefer learning to listening to music.

I have tried podcast players that compress, speeding up.   Unsatisfactory.

ISO Metronome for Exercise Cadence

I decided to try having a metronome tick or ... at my target cadence and gait, while listening to my podcasts.  How hard can that be?

I tried running such a periodic metronome on my Pebble watch, buzzing 100-120 times per second.   Drains the battery much too fast.

So, instead let's put the metronome on my phone. iPhone - I wish.

There are many, many, metronome apps for iPhone or Android.  Most for music, some specialized for running or hiking.

Annoyingly, apparently iPhone iOS is incapable of having both a podcast app and a metronome app running at the same time, and combining (mixing) their audio output.   Start the metronome playing, then start the podcast, and the metronome app stops, and vice versa.

Annoying but not necessarily surprising, given what I know about iOS.  Android is more of a real, multitasking OS, so is much more likely to be able to play sound from two apps simultaneously.

Gives me a reason to revive one of my old Android phones, to use as a dedicated podcast player and metronome.   Especially since I have not found any iPhone podcast player that is as useful as BeyondPod on Android.  Lossage:  my iPhone won't be able to act as a phone on my walks - but most of my walks in Portland's hills have no or little cell phone contact.   Actually, the biggest lossage is not so much the cell phone functionality, as having another device to have to keep charged, and having to pair my bluetooth headsets between Android and iPhone.

Note: I do not want to do my own audio mixing.  I might if I were playing music, but I tend to listen to podcasts or audiobooks once and then never again.  Plus I want to be able to dynamically adjust.

Note: real audio mixing, combining output from two apps, might be most desirable.   Require separate volume control.  Might be nice to be able to overlay arbitrary music on my podcasts and audiobooks.  But, metronomes are a special case, and may not require full mixing.

What I have found and am using

Anyway: 6-12 hors of research, and evaluation of Android apps.  Here is what I have ended up using:

FAIL: can't find a way to play both a metronome and Podcast/Audiobook on iPhone

FAIL: metronome app on Pebble watch causes battery to drain too quickly. (If battery life were not a problem, I think that I would very much like the Pebble watch as a pacemaker.)

WIN: old Android phone, with the "Metronome" app by keuwlsoft, with BeyondPod and Audible audiobooks.

Metronome by Keuwlsoft:
  • no ads
  • no permissions
  • adjustable beats: major, minor, muting, subbeats
  • adjustable rate beats per minute
  • 3 sound effects
For my purpose, the visual effects are useless - the phone is in my pocket, the sound plays in my earphones.

This is what I homed in on for my current use.

FAIL: I felt all good about keuwlsoft's Metronome app - but on the first longish walk I learned that it turns off when the phone is locked.  Certain other Android apps do not. :-) See Metronome Comparison Spreadsheet. But after a month, I am still using keuwlsoft Metronome, with a kluge (a stiff piece of cardboard to cover the screen)  to cope with keuwlsoft turning off if I lock the screen.

Criteria for Exercise Metronome
  • Simultaneous metronome and other audio source
  • Ability to adjust metronome rate.  
    • NICE: dynamically.   
    • NICER: dynamically, hands free. 
      • I don't know any app that does this.
  • Separate volume control
    • not quite must have, but pretty darn close
  • Separate ticks in each ear, for left/right foot
    • NICE?  helps keeping pace
  • Metronome sound
    • Many metronome apps have a single, hardwired, beep/click/chirp.
      • This may work for practicing piano
      • But it is not good if this chirp makes it impossible to hear the podcast or audiobook
    • VERY NICE, almost ESSENTIAL: ability to select a more pleasant sound
      • Possibly nice if you have a wide selection, or can provide your own
      • However, the metronome app I chose, keuwlsoft, had only 3 hardwired choices - 2 of which were acceptable.
  • Beat patterns
    • at first I thought that only a fixed beat pattern would be sufficient.
      • Q: tick every foot, or only on left foot?
    • but I quickly learned that a pattern of major/minor beats is helpful
      • NOT 1/2 time - not major every left, minor every right - seems to cause asymmetric gait
      • BETTER 3/4 waltz time: TICK-tock-tock-TICK-tock-tock - so that major beat alternates feet.
        • 3/4 time is a bit of a misnomer - the 1/4 is irrelevant.   It is really just a cycle of 3 beats, with different ephasis.
        • After a few days I figured that TICK-TICK-tock works better that TICK-tock-tock.  Go figure.

Ads and permissions: 
  • many metronome apps (and apps in general) require excessive permissions and serve obnoxious ads
  • it may be reasonable to allow a metronome app permission to
    • write files (to save carefully crafted rhythms, e.g. if you are a drummer)
    • read files - in particular, sound clips that you want to be use for the ticking
    • automatically mute when the phone rings
  • but I chose the keuwlsoft Metronome app that required no such permissions
Advanced Features for an "Exercise Cadence Metronome"
  • Accelerando
    • if you are trying to speed up, as I am, it might be nice to start at a first rate, say 100bpm, and smoothly accelerate to 120bpm over the space of a half hour or so
    • some musician oriented metronomes, such as the keuwlsoft Metronome app I chose have such an accelerando feature, but the timescales are not so appropriate to exercise
    • I am doing "long term gradual accelerando", trying to add 1 step per minute to my pace - every so often.
  • Rate programming
    • ramp up/down
    • intervals
  • Dynamic Rate Feedback
    • Some running oriented metronomes can detect your running speed, and compare it to your desired goal.  
    • I can imagine real dynamic feedback
      • trying to gradually accelerate to desired goal
      • with warmup and cooldown
      • possibly with adjustment according to incline
    • Feedback with heart rate and/or landspeed
    • After use, my main hope for feedback is
      • Detect the rate I am stepping at, and time clicks to try to encourage me to be just a bit faster
      • It may not be appropriate to just click at 128 spm when I am walking at 127 spm
      • I think that it might be better to dynamicaly adjust by phase: e.g. to advance a tick by a small amount - 1ms? - perjaps non-uniformly through my step cycle.  Not increasing rate before it looks likely that I can match it.
    • I would live to have dynamic cadence adjustment that
      • adjusts automatically if I slow down to walk up a hill, or other
I have noticed that my cadence varies during my walks, according to conditions: hill, hard vs soft surface, fatigue. I can walk faster in the morning than just before bed.
     It is a bit of a pain to adjust this, since it is a pain to have to take my phone out of my pocket.  I wish that I could adjust it from the headset that I wear to listen to the podcast and metronome, or possibly from my smartwatch.  

Thoughts about Wearable Devices

UI devices: phone (rectangular slab of glass with touchscreen); watch (wrist mounted display, with vibes, buttons and/or touch); headset (sound output, sound input, buttons and/or touch in several places.  Voice control with audible feedback, but that's hard to get right.)

More and more I wish to avoid having to click on my phone.   It may be okay for the phone in my pocket to be my "personal server", connected to devices like headset and watch by wireless like BlueTooth.  The phone is big, can hold a big battery, and probably diffuse more heat.  The big screen is okay for interaction when I want to browse the web.  But I really wish that I could do more, control more, without the phone.

I can control overall volume using my headset.  But I cannot control the volume of the metronome separately from the podcast - I have to pull out my phone to do that. :-(

I can skip forward or back in podcast from my headset.   I can stop/start the podcast from my headset.   But I cannot styart/stop the metronome.

I wish I could adjust the metronome rate from my headset.

My headset is cheap.  It has essentially 5 controls: on/off, with long presses for extra control.  Volume up/down.  Select forward/back. All of these contyrols are on one ear.
     I would gladly be willing to pay a bit extra to get 5 more controls on the other ear.

Or perhaps I should try to get these controls from my SmartWatch.   I.e. use watch and headset in conjunction.   The watch display gives a more dunamic selection of controls.   More irritating that just touching a button on my headset, but more variety, and less irritating than having to pull my phone out of my pocket, unlock it, and then interact.

I have done limited amounts of Siri voice control handsfree from my headset, but Siri requires too much screen interaction.

How many Steps per Minute?

     Note: writers differ as to whether you would walk at 60 steps per minute or 120.  The factor of two difference is due to counting steps by both feet or not.


    Heart rate more important than speed or steps per minute. Mix it up. Interval training.

    LEVEL 1: VERY INACTIVE: 80-100 steps per minute = 2 mph (30 minute mile)

    Some widely referenced studies talk about 100spm as moderate exercise.

    LEVEL 2: LIGHTLY ACTIVE: 120 steps per minute = 3 mph (20 minute mile)

    Weight loss: slow, 3 mph, 60-70% MHR (Maximum Heart Rate). Not aerobic. 1-2 hours a day. 120 steps per minute. 

    LEVEL 3: MODERATELY ACTIVE: 130 steps per minute = 3.5 mph (17-18 minute mile)

    LEVEL 4: ACTIVE: 140 steps per minute = 4 mph (15 minute mile)

    Aerobic: 75% MHR. 20-30 3x/week. 140 steps per minute. 

    LEVEL 5: VERY ACTIVE: 150 steps per minute = 4.3 mph (14 minute mile)

    Jogging, or race walking.

    LEVEL 6: EXCEPTIONALLY ACTIVE: 160 steps per minute = 4.6 mph (13 minute mile)

    Endurance/Fitness/Speed: 80-90% MHR. 160 steps per minute,

    LEVEL 7: ATHLETE: 170 steps per minute = 5 mph (12 minute mile) 

    Most walkers need at least a year to develop paces of 170 spm (12 minute mile) or faster. 

    LEVEL 8: ATHLETE : 180 steps per minute = 5.5 mph (11 minute mile)

    LEVEL 9: ATHLETE: 190 steps per minute = 6.0 mph (9-10 minute mile)

    Using CUA ^C/^X/^V as well as command-C/X/V on Mac

    I have been using my MacBook as my primary computer for a year now - and I still have trouble typing command-C/X/V for copy/cut/paste, rather than the Windows like control-C/X/V.

    More precisely, perhaps, the CUA, Common User Access, key bindings, that date back to Xerox PARC (and earlier, I think). http://en.wikipedia.org/wiki/IBM_Common_User_Access

    Oddly enough, I had managed to make the transition in my first few weeks or so, perhaps a month, on the Mac - up until I got a proper emacs working on my Mac. Now, I do NOT use ^C/^X/^V key bindings on Emacs.  But for some reason using Emacs pushed any new key bindings out of my cache, and I found that I started experiencing control/command confusion on Mac apps more often. Perhaps this happened because emacs uses SO MANY control key bindings - and I decided not to use any of the several ways of having emacs treat Mac command key as equivalent of control in standard emacs key bindings. (TBD: notes on this: briefly, doesn't always work).   So control is in the front of my mind when using emacs, even on a Mac.   Or perhaps this confusion became more prominent because when I am using emacs I work faster - so the errors waste a greater fraction of my time.

    Sometime over Xmas this became really frustrating, so I set out to fix it.

    Now, I do not want to globally swap command and control.  I want to use standard Mac key bindings as much as possible.  Also, globally swapping command and control messes up other apps, such as Windows RDP.   No, instead all I want to do is to take the keys that are problematic - typing ^C instead of command+C, etc., in my web browser - and remap only those keys.  While leaving the standard command+C/X/V bindings unaffected.

    Ideally, do this in only the apps where I am constantly making these errors - mainly, cutting and pasting between my web browser and emacs.   Or do it globally, but ideally without affecting the existing emacs keybindings - i.e. have ^C behave like command+C in my web browser, and in most other places, but not in emacs or any place where the standard Mac bindings do not apply.

    Here's a post along these lines:


    Here's a great webpage about Apple Cocoa key bindings:


    Surprisingly, Apple's Cocoa key binding mechanism is almost as powerful as EMACS'.  It permits nearly any key to be rebound, it allows emacs-style multiple key sequences to be bound, and it allows multiple bindings to the same command.

    Surprising or not, most Apple key binding tools do not provide anywhere near this control.  Why not?  I conjecture that this is a carry-over from NeXT, from the old days when Men were Men, and Power Users wanted real keyboard control.  But that it has fallen into disuse with the rise of mass market non-power-user computing, and "usability" gurus who deprecate functionality.

    Also, while the remapping facility is powerful, it only applies to Cocoa apps.  It is not ubiquitous.  Apple has a long history of "software model tunnel vision", reflected in security bugs such as the "We assume that everyone is using Objective C,and cannot forge message names".

    Anyway, here's what I ended up doing: placing the following in ~/Library/KeyBindings/DefaultKeyBinding.dict

        "^a"        = "selectAll:";                     /* C-a  Select all */
        "^x"        = "cut:";                           /* C-x   Cut */
        "^c"        = "copy:";                          /* C-c          Copy */
        "^v"        = "paste:";                         /* C-v          Paste */
        "^z"        = "undo:";                          /* C-z          Undo */
        "^y"        = "redo:";                          /* C-y          Redo */ 
    Now, this provides the mappings in all Cocoa apps. No ability to say "do this only in Chrome".  But it seems good enough for now.