Other implementations of TOTP just call the HOTP generation function with the time as described above.  

So I'd expect TOTP to look something like this:

```python
class TOTP(object):
    def __init__(self, key, length, time_step, backend):
       … # implementation elided
       self._hotp = HOTP(key, length, backend)

    def generate(self, timestamp):
        return self._hotp.generate(int(time // 30))

    … # verify
```

At which point it seems like it'd make the most sense to just parameterize the hash algorithm in the HOTP constructor.