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

Higher-level functionality #27

Open
9 of 17 tasks
ItsHarper opened this issue Apr 26, 2023 · 2 comments
Open
9 of 17 tasks

Higher-level functionality #27

ItsHarper opened this issue Apr 26, 2023 · 2 comments

Comments

@ItsHarper
Copy link
Contributor

ItsHarper commented Apr 26, 2023

  • Auto-scheduling of keep-alives
  • RevHub class gets these members:
    • isParent field
  • Method to create a RevHub should auto-open the serial port and query all known interfaces
    • Should accept serialNumber, parentAddress as parameters (children are added by calling a separate method)
    • Will find correct serial port for the serial number, open it, and start keepalives and query interfaces for all children
    • Returns singular RevHub object with children field populated
    • Closing parent RevHub closes all children and serial port
    • Closing any RevHub stops keepalives
    • Closing child RevHub removes from parent
  • Method to do discovery on a given serial number
  • Method to do discovery on all connected Expansion Hubs
  • ParentRevHub#addChildByAddress(int address): RevHub (also adds to children array)
  • RevHub#discoverChildren(): RevHub[] (replaces children object contents)
    • Must NOT replace existing RevHub instances who were also found in discovery
    • Takes an options object as a parameter with a removeDisconnectedChildren field
  • Not sure of how RHSPLib handles this, but changing a hub's address needs to auto-update all the appropriate fields, ensure keepalives keep working, and check for conflicts (both via discovery and via assumed toplogy) before sending the address change command
@LandryNorris
Copy link
Contributor

#30 adds the children property. #29 adds the discover all hubs method. Others will be added.

@ItsHarper
Copy link
Contributor Author

ItsHarper commented Jul 25, 2023

I updated this issue description with checkboxes, updated some things, and checked off completed items. Discovery is still a big place that this library is lacking. When we add better discovery support, the sample needs to be updated to make specifying a parent address optional.

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

No branches or pull requests

2 participants