2 ; param1 = this macro filename
3 ; param2 = pathname of file to write in SD_CARD
4 ; param3 = /C = default COM saved in TERATERM.INI with all its parameters.
6 basename fname param2 ; fname = file.ext of param2
7 strinsert fname 1 '\' ; fname = \file.ext, to force absolute path
10 if result=0 connect param3
12 sendln ' $0A BASE ! ECHO STOP' ; blanks are added to pass LPMx wake up time...
14 inputbox 'here you can add a path to the file: ' 'Send a File to SD_CARD target' fname
16 sendln 'TERM2SD" ' inputstr '"' ; send to FastForth the command TERM2SD" \file.ext" ...with optionnal path added in inputbox
18 sendfile param2 0 ; binary flag = 0 to send text file
20 sendln #4 ; send ETX to ask FastForth to close file