Skip to content

Conversation

@felipediel
Copy link
Collaborator

Proposed change

Rename the newly added state parameters for MP1s to align with the state parameters used in the SP4 family.

For instance, in an SP4 payload, the parameters are as follows: {'pwr': 0, 'ntlight': 1, 'indicator': 1, 'usbpwr': 0, 'maxworktime': 0, 'usbmaxworktime': 0, 'ntlbrightness': 59, 'current': 0, 'volt': -1, 'power': 0, 'totalconsum': -1, 'overload': -1}.

So we are basically renaming "voltage" to "volt" and "power_consumption" to "totalconsum" in mp1s.get_state() to make it easier to integrate. The function name is also being changed from get_status to get_state.

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New device
  • New product id (the device is already supported with a different id)
  • New feature (which adds functionality to an existing device)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests
  • Documentation

Additional information

  • This PR fixes issue: fixes #
  • This PR is related to:
  • Link to documentation pull request:

Checklist

  • The code change is tested and works locally.
  • The code has been formatted using Black.
  • The code follows the Zen of Python.
  • I am creating the Pull Request against the correct branch.
  • Documentation added/updated.

@felipediel felipediel merged commit cacebe7 into mjg59:dev Apr 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant