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

Unclear documentation in is_contactor_opened #406

Closed
raoulKalkman opened this issue May 14, 2024 · 1 comment
Closed

Unclear documentation in is_contactor_opened #406

raoulKalkman opened this issue May 14, 2024 · 1 comment

Comments

@raoulKalkman
Copy link

This is about the functions in iso15118/secc/controller/interface.py

The functions are written as if they are checks for the contactor, however the documentation is unclear.

Especially the is_contactor_opened confuses me while making an implementation.

I would suggest either changing the function name in case it actually opens the contactor (this would surprise me)
or writing a doc as something like "Check if the contactor is opened. (open contactor -> terminated energy flow)"

That of course is a draft, but I hope you get the gist of it.

    @abstractmethod
    async def is_contactor_opened(self) -> bool:
        """
        Sends a command to the SECC to get the contactor status is opened to terminate
        energy flow

        Relevant for:
        - all protocols
        """
        raise NotImplementedError
    @abstractmethod
    async def is_contactor_closed(self) -> Optional[bool]:
        """
        Sends a command to the SECC to get the contactor status is closed

        Relevant for:
        - all protocols
        """
        raise NotImplementedError
@shalinnijel2
Copy link
Contributor

Hi @raoulKalkman,
Yes, the comment is misleading. Thank you for pointing this out. Have updated it in master now. PR.
Kind regards,
Shalin.

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