(instead of brick and devices)
After internal discussion:
- This way we need to maintain only one fake API.
- Autocomplete can pick up the right brick/devices.
- Explicit is better than implicit.
We should not encourage users to use the numerical values (i.e. 2 for Stop.hold or 65 for Port.A)
This also keeps the door open for using qstrings for some enums (Color, Button).
Sphinx and read the docs seem to require RST. This works well for this sample code.
Unfortunately, vscode code preview seems to require markdown (For the tables. Other RST seems to work.)
Observations:
* Type annotations tend to be verbose, for example:
blink(color1: typing.Union[pblight.Color, pblight.RGB, NoneType], color2: typing.Union[pblight.Color, pblight.RGB, NoneType], pattern: pblight.Pattern) → None
* There seems to be a bug with .. autodata::