I have an FM receiver (EN803) module that works with 3.3V. I wanted to control the volume and seek pins using an Arduino Uno R3. Please see the image below. I want to replace the physical buttons with an Arduino Uno R3 GPIO. I can think of 2 ways to achieve this.
Use a logic level shifter to the GPIO pins and use logic HIGH/LOW (digital output) and HIGH-Z (make digital pin to input).
Use an NPN transistor with 3.3V Collector, 5V GPIO Base. (will it work?)
Thanks for the picture but lots is missing.
Words are not the way to tell.
Where's the trasistor You mention? Were are the level shifters?
Please creat real schematics. Pen and paper usually works well.
Thanks @lastchancename for the hints! Now I am thinking to use a voltage divider to convert Uno 5V GPIO to 3.3V to connect with the SEEK or VOL pin. I guess NPN transistor is ruled out since this is a tri-state circuit.
@Railroader thanks for your guidance. The pen/paper actually made me think better.
Will the tri-state work as the following pin states?
Uno GPIO : HIGH (digital output)
Uno GPIO: LOW (digital output)
Uno GPIO: High Impedance (digital input)
I think this would not work. When the Uno GPIO is at high Impedance the SEEK pin would be connected to Ground via the 10K resistor and it would trigger the SEEK in the lower frequency direction.
If it was my EN803, I would try your plan #1. But I would run the UNO at 3.3V after the upload. So no level shifter. You disconnect the EN803 from the UNO, upload the sketch, and reconnect the UNO to 3.3V... I would try the ON/OFF button first.
Connecting the 5V pin to a 3.3V source.(USB disconnected)
That's dangerous.
If you forget to disconnect the USB or 3.3V, or you connect anything to Vin, you will certainly burn something.
Much safer to use the NPN/PNP
Plus it will not run at 16MHz