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

On is false and off is true #2

Open
enebybrygg opened this issue Dec 19, 2014 · 5 comments
Open

On is false and off is true #2

enebybrygg opened this issue Dec 19, 2014 · 5 comments

Comments

@enebybrygg
Copy link

Hi again, sorry for bothering you again. I asked about fixing the boolean value half a year ago since the setSwitchState was not consistent with the getSwitchState. Now they are consistent which is good, thanks. The problem is now that setSwitchState(true) does not turn the switch on. That is, it does not open the drain PIO pin. It actually closes it. setSwitchState(false) will on the other hand close the switch (activate the sink capability of the pin). One could argue about what boolen value means open or closed (and on or off) but you own example suggest you share my view that true means on (means closed). This means in short that I think my original comment was wrong, it was not the getSwitchState() that was in error but actually the setSwitchState().

dustin added a commit that referenced this issue Dec 20, 2014
Possible fix for #2
@dustin
Copy link
Owner

dustin commented Dec 20, 2014

I don't have a DS2406 handy. Can you see if this does the right thing?

@enebybrygg
Copy link
Author

Great, Ill have a go at it this weekend. Btw are you into Go engines? Saw such repositories on your profile.

Skickat från min mobil,
Håkan W

-------- Originalmeddelande --------
Från: Dustin Sallings notifications@github.com
Datum:
Till: dustin/arduino-2406 arduino-2406@noreply.github.com
Kopia: Håkan Westrin hakan@westrins.se
Rubrik: Re: [arduino-2406] On is false and off is true (#2)

I don't have a DS2406 handy. Can you see if this does the right thing?


Reply to this email directly or view it on GitHub.

@dustin
Copy link
Owner

dustin commented Dec 20, 2014

I write a lot of code in the go programming language. I was unfamiliar with go engines. I use mostly brushless electric motors. :)

@enebybrygg
Copy link
Author

Oh I thought it was about the game Go :-) Software engines that plays Go (like chess computers) is an interesting field. They still dont beat good humans. 
I use brushless engines too :-)

Skickat från min mobil,
Håkan W

-------- Originalmeddelande --------
Från: Dustin Sallings notifications@github.com
Datum:
Till: dustin/arduino-2406 arduino-2406@noreply.github.com
Kopia: Håkan Westrin hakan@westrins.se
Rubrik: Re: [arduino-2406] On is false and off is true (#2)

I write a lot of code in the go programming language. I was unfamiliar with go engines. I use mostly brushless electric motors. :)


Reply to this email directly or view it on GitHub.

@enebybrygg
Copy link
Author

Hi, I finally got around to testing, sorry for the delay. It works fine now, thanks for the effort.
Cheers!

Håkan Westrin

20 december 2014, Dustin Sallings notifications@github.com skrev:

I don't have a DS2406 handy. Can you see if this does the right thing?—
Reply to this email directly or view it on GitHub #2 (comment).

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