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

Additional info on state changes of buttons #59

Closed
wants to merge 3 commits into from

Conversation

sven-bock
Copy link

DigitalIO and Navigators

This little improvement enables you to see which buttons was pressed in your callback function.
Therefore you need only one callback function for all your buttons.
e.g.:

from baxter_interface.digital_io import DigitalIO
def updateState(*args):
    print "button pressed", args
button = DigitalIO("left_shoulder_button")
button.state_changed.connect(updateState)    

Camera

The current implementation raises an exception, if the camera is currently closed. I think it is useful in the camera controller to check, if the camera is opened or closed. Also in the past the service call to the camera list yielded all 3 cameras, which is not the case any more. Therefore I recommend to change the condition of the if in the init

…camera is not opened. This is useful to check, if a camera is opened or closed.
…wheel" and the button id or wheel position is sent in the arguments.

This is useful to use one callback for all buttons.
@rethink-imcmahon
Copy link
Contributor

Great pull request @sven-bock! I'll review it and get back to you. In the meantime could you rebase and PR into development? Thanks!

@rethink-imcmahon
Copy link
Contributor

superseded by #62

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

Successfully merging this pull request may close these issues.

2 participants