I can open a new cmd window and connect with plink and serial port through Python.
import os
import subprocess
os.system("start cmd /k plink.exe -serial COM4 -sercfg 115200,8,n,1,N")
Still good here, but when I want to run ifconfig, it didn't work.
os.system("ifconfig")