COM1 voltage level
#1
Posted 22 September 2012 - 03:05 PM
#2
Posted 22 September 2012 - 03:06 PM
Netduino Mini sends 3.3V signals on this UART, but can understand incoming 5V signals as well.Hi,
it seems to me the netduino mini COM1 port (pin 11-12) use 5V for TTL signals.
But it should use 3.3V, right?
Since I'm not that hardware-expert, would be really nice if somebody can check his netduino mini COM1 port, which voltage level is used.
Chris
#3
Posted 22 September 2012 - 03:14 PM
#4
Posted 22 September 2012 - 03:48 PM
Hmm, 5V output on that pin shouldn't be possible. If you sample another pin, do they all show as 5V? There are no pullup resistors enabled on the UART.I'm looking with an oscilloscope on pin 12 and it's at 5V. Is there a pull-up resitor or something like that?
A device which I want to connect to COM1 has problems with this 5V. The connected device is powered up by netduinos pin 12, even if I turned the device's on/off switch to off.
To stop feeding power to the other module via the pin, create an OutputPort and set its state to false (off). Also the pullups are enabled during boot...if this is a concern, you'll want to use a small circuit to disable the IO until you want to enable it.
Chris
#5
Posted 22 September 2012 - 04:22 PM
The deployed program is:
public static void Main() { Thread.Sleep(Timeout.Infinite); }
Voltage samples:
Pin 1: -6V
Pin 2: -6V
Pin 3: -6V
Pin 5: 3.3V
Pin 6: 3.3V
Pin 7: 3.3V
Pin 8: 3.3V
Pin 9: 1.7V
Pin 10: 1.7V
Pin 11: 3.3V
Pin 12: 5V
Pin 12: 3.3V
Pin 13: 3.3V
Pin 14: 3.3V
Pin 15: 3.3V
Pin 16: 3.3V
Pin 17: 3.3V
Pin 18: 3.3V
Pin 19: 3.3V
Pin 20: 3.3V
Pin 21: 5V
Pin 22: 3.3V
Pin 24: 4.5V
#6
Posted 22 September 2012 - 08:26 PM
Since I'm not that hardware-expert, would be really nice if somebody can check his netduino mini COM1 port, which voltage level is used.
pins 11 and 12 on my mini both output 3.3V
#7
Posted 22 September 2012 - 09:16 PM
Thanks for checking.pins 11 and 12 on my mini both output 3.3V
Really strange: I have two netduino minis, both have 5V on pin 12.
#8
Posted 22 September 2012 - 09:20 PM
That is really strange. It shouldn't be possible. Can you take a photo of your Mini attached to the multimeter/oscilloscope?Really strange: I have two netduino minis, both have 5V on pin 12.
Also just to confirm--you can turn pin 12 on and off via OutputPort, correct?
Chris
#9
Posted 23 September 2012 - 08:12 AM
I took a photo using a multimeter[...] Can you take a photo of your Mini attached to the multimeter/oscilloscope?
I realized I can't switch any GPIO on nor off.Also just to confirm--you can turn pin 12 on and off via OutputPort, correct?
The following code should turn pin 5 definitely off:
public static void Main() { OutputPort pin5 = new OutputPort(Cpu.Pin.GPIO_Pin5, false); pin5.Write(false); Thread.Sleep(Timeout.Infinite); }
Attached Files
#10
Posted 23 September 2012 - 08:55 AM
#11
Posted 23 September 2012 - 05:34 PM
I'm not ashamed to say that I have slipped up on this several times now. I blame Visual Studio's IntelliSense which always shows the Cpu.Pin first. Don't even get me started on the Cpu.AnalogChannel and Cpu.PWMChannel...
Also...to turn on/off pins, use the Pins.GPIO_##### enumeration, not Cpu.Pin.GPIO_Pin5. They look similar, but Cpu.Pin refers to the pins on the microcontroller itself (rather than the pin #s on the Netduino Mini).
Chris
Steve
Twiiter: https://twitter.com/Gutworks
#12
Posted 23 September 2012 - 07:12 PM
Hi,Hi awaiK,
Since pin 12 is the UART_RX pin, the FTDI USB-TTL converter chip on that board is most likely putting a 5V signal to pin 12.
Also...to turn on/off pins, use the Pins.GPIO_##### enumeration, not Cpu.Pin.GPIO_Pin5. They look similar, but Cpu.Pin refers to the pins on the microcontroller itself (rather than the pin #s on the Netduino Mini).
Chris
using the right enum I can toggle the pins on/off...
Turning pin 12 off and on via OutputPort, the pin is at 3.3V.
Disposing the OutputPort it switchs back to 5V.
So...it is broken and I need to buy some new ones?
#13
Posted 23 September 2012 - 07:43 PM
It is not broken. You forgot to mention that you are using SK Pang Netduino Mini Dev Board (shown in the photo), so there is some external circuitry that affects the pin voltage levels. As you can see in the schematics, Netduino Mini pin #12 is connected to FT232R TXD output and this IC is powered by 5V. So disposing OutputPort switches Netduino pin back to input and you measure 5V from FT232R TXD output (as suggested by Chris above).So...it is broken and I need to buy some new ones?
IMHO you should not be doing that - FT232R TXD is output too, so you are mixing its logic levels with Netduino's 3.3V output.Turning pin 12 off and on via OutputPort, the pin is at 3.3V.
#14
Posted 23 September 2012 - 08:31 PM
#15
Posted 23 September 2012 - 11:15 PM
It is not broken. You forgot to mention that you are using SK Pang Netduino Mini Dev Board (shown in the photo), so there is some external circuitry that affects the pin voltage levels. As you can see in the schematics, Netduino Mini pin #12 is connected to FT232R TXD output and this IC is powered by 5V. So disposing OutputPort switches Netduino pin back to input and you measure 5V from FT232R TXD output (as suggested by Chris above).
IMHO you should not be doing that - FT232R TXD is output too, so you are mixing its logic levels with Netduino's 3.3V output.
You beat me too it. I might add that SK Pang may want to re look at that design. According to the datasheet if you just hook to 3v3out to vccio you will drive 3.3v output levels. Hooking to vccio to vcc drives output at 5v levels. It's a simple change, and it could probably be an easy mod - cut one trace and add a jumper wire.
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users