Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow boards to change the "CircuitPython" text in their USB interface description. #2283

Merged

Conversation

theacodes
Copy link
Collaborator

In cases where more than one board is connected to a single computer it can become pretty hard to figure out which board you're actually talking to. For example, if you have several MIDI-compatible boards they all show up as "CircuitPython MIDI". This change allows boards to replace the "CircuitPython" part of their USB descriptors with more specific text, for example, "CircuitPython Feather" or just "Feather". This will let folks more easily tell boards apart.

The new option is named USB_INTERFACE_NAME and is available in mkconfigboard.mk. For example:

USB_INTERFACE_NAME = "Feather"

…e description.

In cases where more than one board is connected to a single computer it can become pretty hard to figure out which board you're actually talking to. For example, if you have several MIDI-compatible boards they all show up as "CircuitPython MIDI". This change allows boards to replace the "CircuitPython" part of their USB descriptors with more specific text, for example, "CircuitPython Feather" or just "Feather". This will let folks more easily tell boards apart.

The new option is named `USB_INTERFACE_NAME` and is available in `mkconfigboard.mk`. For example:

```
USB_INTERFACE_NAME = "Feather"
```
Copy link
Member

@jepler jepler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes sense and the checks pass.

Testing performed: Locally set for metro m4, built, and grepped through lsusb output:

      iInterface              4 Handsome Devil CDC control

@jepler jepler merged commit 66148ee into adafruit:master Nov 13, 2019
@theacodes theacodes deleted the allow-changing-usb-interface-names branch November 13, 2019 21:21
@theacodes
Copy link
Collaborator Author

Thank you, @jepler!

tyomitch pushed a commit to tyomitch/circuitpython that referenced this pull request Apr 30, 2021
This adds an initial specification of the machine.PWM class, to provide a
way to generate PWM output that is portable across the different ports.
Such functionality may already be available in one way or another (eg
through a Timer object), but because configuring PWM via a Timer is very
port-specific, and because it's a common thing to do, it's beneficial to
have a top-level construct for it.

The specification in this commit aims to provide core functionality in a
minimal way.  It also somewhat matches most existing ad-hoc implementations
of machine.PWM.

See discussion in adafruit#2283 and adafruit#4237.

Signed-off-by: Damien George <damien@micropython.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants