putty【cmd命令】

  1. 登陆串口,并且记录log
https://blog.csdn.net/hansel/article/details/114682539

putty -serial COMxxx -sercfg 115200,8,n,1,N -sessionlog xxxx.log
  1. 更加复杂的操作
https://stackoverflow.com/questions/27477658/save-putty-output-to-file-from-command-line

Enter Host Name, Name the session, Go to Logging Option in the left top corner, select all sessions, provide log file name and location, 
go back to Session tab, click on the save button. Done, you have saved a session
Now open CMD and write the command as below enter image description here
putty -l User -pw Password -load "MyServer" -m CommandFile.ext
You are done. Every time this session is invoked, the commands and output will be logged. Hope this helps.
posted @ 2022-01-13 17:09  该显示昵称已被使用了  阅读(257)  评论(0编辑  收藏  举报