microsoft / jacdac

Device and service catalogs for Jacdac.
https://aka.ms/jacdac
Creative Commons Attribution 4.0 International
66 stars 25 forks source link

button should have a frac unit #20

Closed pelikhan closed 3 years ago

mmoskal commented 4 years ago

You mean you want a button with pressure reading?

pelikhan commented 4 years ago

It does not have a reading right now. But yes a pressure button might be nice but different beast.


From: Michał Moskal notifications@github.com Sent: Wednesday, August 19, 2020 11:52:23 AM To: microsoft/jacdac jacdac@noreply.github.com Cc: Peli de Halleux jhalleux@microsoft.com; Author author@noreply.github.com Subject: Re: [microsoft/jacdac] button should have a frac unit (#20)

You mean you want a button with pressure reading?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmicrosoft%2Fjacdac%2Fissues%2F20%23issuecomment-676055778&data=02%7C01%7Cjhalleux%40microsoft.com%7C64e49ed5cf3e4682efcc08d84425928a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637334275442845649&sdata=rNg7Li%2BCKXkj6JqZD8i4U0qWP2CErCDMtXJ5Relxr2Y%3D&reserved=0, or unsubscribehttps://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAA73QKNHPSY4AZHDRQJQ64DSBOOFPANCNFSM4QAIZDMA&data=02%7C01%7Cjhalleux%40microsoft.com%7C64e49ed5cf3e4682efcc08d84425928a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637334275442855644&sdata=VHwIwWv%2Bu1Z4D42PE8mQR7OFGnGr56ffrxF5CFX%2BAsk%3D&reserved=0.

jamesadevine commented 4 years ago

Hopefully a pressure button would be a separate specification that inherits from the button spec?

mmoskal commented 4 years ago

It does heave a boolean reading - https://github.com/microsoft/jacdac/blob/master/services/button.md#registers

You want to change that to say u8 frac? so the derivation makes sense?

pelikhan commented 4 years ago

Let's keep the button simpled. We could have a new register "pressure" in a derived button that provides a u8. I got dumb and didn't connect that boolean didn't need a unit. will fix the ui.