Skip to main content
srm
Associate II
July 6, 2017
Question

PC Connection detect using FTDI chip

  • July 6, 2017
  • 1 reply
  • 1399 views

Posted on July 06, 2017 at 15:40

Hello,

I am working on Stm32l073 series controller. I have small question regarding the deep sleep and exit from deepsleep modes when device is not plugged to PC i must make the device go to sleep. As the Block Diagram I can make it clear. Now my question is that i would like to detect wether my device is connected to pc or not. Using some GPIO pins or an interrupt. If its connected to PC wake up the device from deep sleep or else make the device go to deep sleep mode. I had tried using the pin CBUS 3 on FTDI whenever there is high or low detection indicates connection status. But was unable to achieve. Is there any way how can I detect the status of my device connection using external interrupt or may be any ideas that I can implement through software. 

0690X00000607SkQAI.png

This topic has been closed for replies.

1 reply

AvaTar
Senior III
July 6, 2017
Posted on July 06, 2017 at 15:51

A separate GPIO to VBUS, with pull-down, to function as EXTI ?

Or would the FTDI chip give you any line status information ?

srm
srmAuthor
Associate II
July 6, 2017
Posted on July 06, 2017 at 16:04

Sperate GPIO line with pullup 10k ohm resistor. As per the data sheet 10k ohm resistor in pullup mode yeah i am able to detect the status line to be always high even after unplugged. 

Tesla DeLorean
Guru
July 6, 2017
Posted on July 06, 2017 at 16:29

How is a pull-up going to help, you'll see 3.3V vs 5V, both high, so no surprise there.

A weak pull-down, associated with the USB supply on the FTDI, that would be the way to go.

A little potential divider might work even better, and you wouldn't be jamming 5V into the L0 device.

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..