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

Create a basic SunSpec window #26

Open
3 tasks
altendky opened this issue Jan 27, 2021 · 0 comments
Open
3 tasks

Create a basic SunSpec window #26

altendky opened this issue Jan 27, 2021 · 0 comments

Comments

@altendky
Copy link
Owner

altendky commented Jan 27, 2021

This goes along with #25. As a first exercise in integrating SunSpec functionality into the GUI let's start simple. The window should be able to do the following things.

  • Allow user specification of a Modbus TCP server to connect to
  • Be able to cyclically read a user specified data point from the server
  • Be able to write a user specified data point to the server on user request

Or, maybe we want to break this up into three tickets... Anyways, there is existing code in the tests that shows creation and connection of a SunSpec client outside of Qt.

@pytest.fixture(name="unscanned_sunspec_client")
async def unscanned_sunspec_client_fixture(
sunspec_server: SunSpecServerFixtureResult,
) -> typing.AsyncIterator[ssst.sunspec.client.Client]:
async with ssst.sunspec.client.open_client(
host=sunspec_server.host,
port=sunspec_server.port,
) as client:
yield client
@pytest.fixture(name="sunspec_client")
async def sunspec_client_fixture(
unscanned_sunspec_client: ssst.sunspec.client.Client,
) -> ssst.sunspec.client.Client:
await unscanned_sunspec_client.scan()
return unscanned_sunspec_client

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

1 participant