[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vip /vp / vr / w / wg / wsg / wsr / x / y ] [Search | Home]
4Archive logo
Sup /diy/
If images are not shown try to refresh the page. If you like this website, please disable any AdBlock software!

You are currently reading a thread in /diy/ - Do It yourself

Thread replies: 8
Thread images: 1
File: 1432232958470.png (312 KB, 506x662) Image search: [iqdb] [SauceNao] [Google]
1432232958470.png
312 KB, 506x662
Sup /diy/
My bro's birthday is coming up next month and I'm making him a handheld emulator for NES, Gameboy, etc., and I'm doing it with a Raspberry pi. The most interesting part is going to be the controls, for which I have bought an arduino pro mini. Ideally, I would like it to have 11 buttons on it (A, B, X, Y, L, R, up, down, left, right) and also a joystick. The arduino can handle all of those inputs, however my problem is that it doesn't have enough empty headers to use on the GPIO on the Raspberry pi (nor does the RPi contain enough empty GPIO pins for all those buttons). I was thinking of using only 1 digital output on the Arduino and sending a few bytes at a time containing all of the button states to the Raspberry Pi for it to know if a button is pressed or not. I guess my question is can I even do this? Is there a better way to do it?

tl;dr can I use an Arduino board using only digital out to be a controller for an emulator?
>>
>>942226
Whoops, said 11 buttons and mentioned 10. It should probably have a start button too. I can answer any questions if they would help. Thanks in advance anons
>>
That's the way to do it.
Parallel load the button states then "shift" them out in serial.
If you use 2 8bit shift registers hook 'em in series.

Use a second pin for the register clock.
Another pin for load/shift select
>>
I2c, usart or spi can solve the problem, no need to bit bang a serial bus.
Are you going to use an rpi zero? Or the normal model? What kind of lcd are you thinking on?
>>
Sounds like a lot of work for a bro, either your actual brother or you're a homo. I don't even give my friends gifts
>>
>>942252
It's the Pi 2 model b
>>
>>942252
Oh and I have a 3.5 inch PiTFT display for it
>>
>>942254
Yes he's my actual brother. I'm doing it mostly for my own pleasure, but I doubt I'll play a lot of games on it anyway, so I'll end up giving it to him
Thread replies: 8
Thread images: 1
Thread DB ID: 498925



[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vip /vp / vr / w / wg / wsg / wsr / x / y] [Search | Home]

[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vip /vp / vr / w / wg / wsg / wsr / x / y] [Search | Home]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the shown content originated from that site. This means that 4Archive shows their content, archived. If you need information for a Poster - contact them.
If a post contains personal/copyrighted/illegal content, then use the post's [Report] link! If a post is not removed within 24h contact me at [email protected] with the post's information.