Skip to content

Commit c50ddf3

Browse files
committed
proxyclient: Increase CPU frequency on A7-A11 when using physical UART proxy
The default CPU frequency on A7-A11 is too slow for baudrate 1500000, so increase the CPU frequency before switching to baudrate 1500000. Signed-off-by: Nick Chan <towinchenmi@gmail.com>
1 parent c5fcd26 commit c50ddf3

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

proxyclient/m1n1/proxyutils.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -554,6 +554,14 @@ def bootstrap_port(iface, proxy):
554554
do_baud = False
555555

556556
if do_baud:
557+
try:
558+
chip_id = proxy.get_chipid()
559+
# These chips are too slow for baudrate 1500000 at their default frequency
560+
if chip_id in (0x8960, 0x7000, 0x7001, 0x8000, 0x8001, 0x8003, 0x8010, 0x8011, 0x8015):
561+
proxy.cpufreq_init()
562+
# Old m1n1 version, assume they are not one of those chips
563+
except ProxyCommandError: {}
564+
557565
try:
558566
iface.nop()
559567
proxy.set_baud(1500000)

0 commit comments

Comments
 (0)