I have an arduino with a sensor. According to some values of the sensor, a PIN is programmed to bright/connect a LED.
Instead of that LED, I want to connect that arduino's PIN into a GPIO of the Raspberry.
That GPIO is allready programmed with a push button. When I push that button, some scripts start runnging on the Raspberry Pi. Now, I want to replace that button with the triggered PIN of the arduino.
I can't figure out how to make that.
Can you please help me with the most simple schematic?
I would like to avoid the Opto-coupler.
A normal resistor should work... But I'm not sure about the wiring...How to connect. I don't know if I need to connect the Ground of the raspberry to the Ground of the Arduino.... Or just a simple wire (with a resistor) directly connected from the Output PIN of Arduino to the Input PIN of the raspberry..??
eluis:
I would like to avoid the Opto-coupler.
A normal resistor should work... But I'm not sure about the wiring...How to connect. I don't know if I need to connect the Ground of the raspberry to the Ground of the Arduino.... Or just a simple wire (with a resistor) directly connected from the Output PIN of Arduino to the Input PIN of the raspberry..??
Stop!
I said TRANSISTOR!!!
with just a resistor you'll end up with a broken RPI or arduino...
opto-couplers are the way to go in this situation.
With a normal TRANSISTOR you do need to conect the ground of the RPI to the ground of the arduino...
You can do it with two resistors.
From the arduino output have a 510R resistor going into the Raspberry Pi input GPIO pin.
Also from the Raspberry Pi input GPIO pin have a 1K resistor going to ground.
Connect the grounds of the Arduino and Pi together.
Mike, I made that sketch quickly just as reference.
Look up the word reference. It is a thing that you can referrer to, it is not a rough half arsed idea. What you posted is not only next to useless but if some one followed exactly what you have posted it could end up damaging their hardware.
When you post information you have a responsibility to try and make it correct.
Besides which it was a very poor diagram anyway and why resurrect a two year old thread to add such dross?
Sorry Mike for that, I will look up the word reference then. I will edit and delete the sketch.
I resurrected the old thread because it is what I really need for my attiny85 project and rbpi. I did not understand the logic of the connection that's all. Sorry for the inconveniences.