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

seeking for your help about @No0ne fork #100

Open
lionB777 opened this issue Mar 6, 2021 · 12 comments
Open

seeking for your help about @No0ne fork #100

lionB777 opened this issue Mar 6, 2021 · 12 comments

Comments

@lionB777
Copy link

lionB777 commented Mar 6, 2021

#Hi @No0ne,
I made one piso from your fork, but I don't have the key 2 working, just joystick up and down as expected, what check should I do to get it working ? thanks

@lionB777 lionB777 changed the title seeking for your help about your fork seeking for your help about @No0ne fork Mar 6, 2021
@No0ne
Copy link
Contributor

No0ne commented Mar 8, 2021

No0ne@dbb8a5f#diff-560156d3a7c437865b720d969a0fda0eebd224fb7df6fb1901c60b3b2c994e81

As you can see here, there are three buttons defined. The select key should be mapped to the button when you press the joystick in. Like on a Playstation controller the joystick is also a button.

@lionB777
Copy link
Author

lionB777 commented Mar 8, 2021

ok, I missed that, because I made a custom case for it and the way it's made I have missed that. thanks for your help. I'm just a beginner swift coder so I can barely understand your code. Is there a chance that this push button and button 2 or other will work together? because definitely I'll not be able to code it myself. thanks

@No0ne
Copy link
Contributor

No0ne commented Mar 8, 2021

Do you use the Waveshare 1.3inch OLED HAT or something else?

@lionB777
Copy link
Author

lionB777 commented Mar 8, 2021 via email

@No0ne
Copy link
Contributor

No0ne commented Mar 8, 2021

Hardware approach: solder a wire from pin 33 to pin 38.
https://www.waveshare.com/w/upload/c/c8/1.3inch-OLED-HAL-Schematic.pdf

Software approach one button: change the line
let select_input = Pin::new(13);
to
let select_input = Pin::new(20);

Software approach both buttons: this would require more code changes!

@lionB777
Copy link
Author

lionB777 commented Mar 8, 2021

is it possible to do something with a "or" condition ?

@No0ne
Copy link
Contributor

No0ne commented Mar 8, 2021

You need to do the initialization and listen for button presses separately for each pin.

@lionB777
Copy link
Author

lionB777 commented Mar 8, 2021

the matter is not that I don't want to compile, it's more that I don't know how, even if if change the pin to 20 like you suggested in the source file

@lionB777
Copy link
Author

lionB777 commented Mar 8, 2021

but I'm willing to learn how, if you don't mind to suggest a how to, please

@No0ne
Copy link
Contributor

No0ne commented Mar 8, 2021

Its documented here: https://github.com/ALSchwalm/pISO/blob/master/README.md

@No0ne
Copy link
Contributor

No0ne commented Mar 8, 2021

If you don't want to code or compile, the hardware approach with a wire between pin 33 and pin 38 on the gpio header or waveshare board should be the easiest solution.

@lionB777
Copy link
Author

lionB777 commented Mar 8, 2021

ok I'll try, and I keep the hardware approach in mind, thank you.

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