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

[Feature] Make unique device identifier readable #1640

Open
laurensvalk opened this issue May 20, 2024 · 1 comment
Open

[Feature] Make unique device identifier readable #1640

laurensvalk opened this issue May 20, 2024 · 1 comment
Labels
enhancement New feature or request software: pybricks-micropython Issues with Pybricks MicroPython firmware (or EV3 runtime) topic: motors Issues involving motors topic: sensors Issues involving sensors

Comments

@laurensvalk
Copy link
Member

Is your feature request related to a problem? Please describe.
Sometimes it can be useful to tell motors and sensors apart, beyond their device type ID. For example:

  • to inventory parts
  • to tell different robotic attachments apart despite using the same motor type

This was requested by @biasedlogic.

Describe the solution you'd like
Some devices have a unique device identifier. We could make it readable in the PUPDevice.info() dictionary, which is intended precisely for this sort of thing.

@laurensvalk laurensvalk added enhancement New feature or request topic: motors Issues involving motors topic: sensors Issues involving sensors software: pybricks-micropython Issues with Pybricks MicroPython firmware (or EV3 runtime) labels May 20, 2024
@biasedlogic
Copy link

I have two 'user stories' for this:

  1. I first thought about the IDs themselves when I was doing a lecture on robotics where in one part I'm assembling a demo robot going module by module and explaining what each one does. Doing that I plugged something I had two of, I think the colour sensors, the wrong way around and obviously the whole thing didn't work. So I thought: would it be possible to actually tell the sensors apart and dynamically reassign ports? If I could read the IDs I could tie a physical sensor (or motor) to its function rather than to the port it's plugged into. Then I could even plug everything in at random. Sure, swapping a sensor out suddenly gets harder, but it's not about replacing the port assignments, but expanding possibilities of identifying connected peripherals.
  2. The idea of using internal IDs for tracking components came up as a loaned set (not robotics) came back with an PU XL motor that was very suspect (worn and banged up). This brought me to the question of whether the motors and sensors have serial numbers that can be read out to identify them as 'mine' or 'changeling' and prove someone was an a**.
    This lead to the idea of actually using the digital IDs instead of any stickers also for lab inventory keeping, as stickers can peel off and are cumbersome to apply on everything anyway, so if one could just plug it in to identify and register in inventory tracking software we could forgo inventory stickers on these devices altogether.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request software: pybricks-micropython Issues with Pybricks MicroPython firmware (or EV3 runtime) topic: motors Issues involving motors topic: sensors Issues involving sensors
Projects
None yet
Development

No branches or pull requests

2 participants