esp32使用emac时,gpio0作为EXT_OSC_CLK,如何避免进入下载模式
esp32使用emac时,gpio0作为EXT_OSC_CLK,如何避免进入下载模式
使用emac时使用了外部的有源晶振,gpio0作为EXT_OSC_CLK,rst重启时总是进入下载模式,如何避免?
-
- Posts: 9757
- Joined: Thu Nov 26, 2015 4:08 am
Re: esp32使用emac时,gpio0作为EXT_OSC_CLK,如何避免进入下载模式
Yo will need to make sure the level on GPIO0 is high after reboot, otherwise the ESP32 enable download mode. Are you sure that whatever you have connected to this pin doesn't also pull it low when the ESP32 is reset?
Re: esp32使用emac时,gpio0作为EXT_OSC_CLK,如何避免进入下载模式
gpio0管脚作为50m的emac外部信号输入,50m信号上电就会产生,rst期间可能会被gpio判断为低电平,有其他解决方案吗?比如有什么方法可以强制进入flash.启动模式
-
- Posts: 8
- Joined: Tue Nov 24, 2015 2:19 am
Re: esp32使用emac时,gpio0作为EXT_OSC_CLK,如何避免进入下载模式
Hi,
You can add an external pull-up resistor of GPIO0 to make sure that it won't be pulled down by EXT_OSC_CLK.
If problem still exists, please let us know.
Thanks.
You can add an external pull-up resistor of GPIO0 to make sure that it won't be pulled down by EXT_OSC_CLK.
If problem still exists, please let us know.
Thanks.
Re: esp32使用emac时,gpio0作为EXT_OSC_CLK,如何避免进入下载模式
该现象不是每次都出现,大概有1/3的机会会进下载模式,接了10k的上拉电阻,效果不明显,上拉阻值多少合适
Re: esp32使用emac时,gpio0作为EXT_OSC_CLK,如何避免进入下载模式
晶振用的是有源晶振,没有示波器不确定波形以及峰谷电压,正常启动后,emac可以工作,晶振频率应该没有问题
-
- Posts: 9757
- Joined: Thu Nov 26, 2015 4:08 am
Re: esp32使用emac时,gpio0作为EXT_OSC_CLK,如何避免进入下载模式
I'm gonna respond in English; if you cannot understand the explanation because of that please tell me and I will have someone translate it into Chinese.
Just to check if I understand it correctly: You have an external 50MHz clock source and want to feed that signal into GPIO0 to feed the Ethernet MAC inside the ESP32, right? The problem is that GPIO0 on startup also is a bootstrap pin: making it low on reset (power-on, external or RTC watchdog SoC reset) makes the ESP32 boot into UART download mode. With a 50MHz sine applied to this pin, there is a chance this happens inadvertently, as you saw.
Unfortunately, we haven't got a tested way around these issues yet. What you could try is to add a mosfet or something to the GPIO0 line, which normally pulls it high. The gate of the mosfer could then be connected to a different GPIO, so the ESP32 can dis-engage it once it's running.
Just to check if I understand it correctly: You have an external 50MHz clock source and want to feed that signal into GPIO0 to feed the Ethernet MAC inside the ESP32, right? The problem is that GPIO0 on startup also is a bootstrap pin: making it low on reset (power-on, external or RTC watchdog SoC reset) makes the ESP32 boot into UART download mode. With a 50MHz sine applied to this pin, there is a chance this happens inadvertently, as you saw.
Unfortunately, we haven't got a tested way around these issues yet. What you could try is to add a mosfet or something to the GPIO0 line, which normally pulls it high. The gate of the mosfer could then be connected to a different GPIO, so the ESP32 can dis-engage it once it's running.
Re: esp32使用emac时,gpio0作为EXT_OSC_CLK,如何避免进入下载模式
等待你们官方的emac使用电路吧,时钟信号上面加控制电路,想着都怕怕,原本是问问你们有没有什么其他的手段可以使esp32强制进入flash运行模式,如果只有强制上拉这一条路,那也没有办法
-
- Posts: 8
- Joined: Tue Nov 24, 2015 2:19 am
Re: esp32使用emac时,gpio0作为EXT_OSC_CLK,如何避免进入下载模式
Hi,
Please help confirm if GPIO0 is connected to output of the oscillator or clkout of the phy?
You can try to connect GPIO0 to clk output of the oscillator and make enable pin of the oscillator can be controlled by ESP32. When ESP32 is powered on or reset, EN_OSC should be low at first and once applications run, EN_OSC will be pulled high.
Please help confirm if GPIO0 is connected to output of the oscillator or clkout of the phy?
You can try to connect GPIO0 to clk output of the oscillator and make enable pin of the oscillator can be controlled by ESP32. When ESP32 is powered on or reset, EN_OSC should be low at first and once applications run, EN_OSC will be pulled high.
Who is online
Users browsing this forum: No registered users and 179 guests