Is it possible to send the content of text file over PuTTY over a serial port?

China☆狼群 提交于 2019-12-18 06:14:12

问题


I'd like to send the text content of a file over the serial port, over PuTTY. I know that extensions exists such as Xmodem and Zmodem, but they all use some checksum protocols to confirm that a file is sent over the port.

However, my requirements are more simple. I'd like to simply send a bunch of text (in a file) over the serial port in Windows (under Linux this would be must more simple), but my preferred terminal program is PuTTY. Is this possible? Is there another terminal program that has this type of feature built it?


回答1:


Use Plink (a command-line connection tool from PuTTY suite). It's a console application intended to automate connection tasks, like yours. Being a console application, you can redirect its input from a text file:

plink.exe -serial -sercfg ... < input.txt

See Using the command-line connection tool Plink

See also related How to execute remote command using PuTTY over Telnet.



来源:https://stackoverflow.com/questions/30826002/is-it-possible-to-send-the-content-of-text-file-over-putty-over-a-serial-port

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!