a round of CareLink fixes (suspend/resumes, basals, settings)

@kentquirk @jh-bate This is ready for review, including tests. I'm going to start commenting in line.
This is the perfect place for a comment in the source code -- both here and for jellyfish, ideally -- as to what's going on. Otherwise someone is going to "fix" it someday.