zerbzhang Posted April 16, 2021 Share Posted April 16, 2021 By writing C language, using the "Command" command to read a configuration file, build and download it. I passed the query command, but the parameter was not assigned correctly. Command("system gpascii -2 -i/win/MYSETUP.txt"); Is this statement wrong? Or is there an introduction document for the API function Command/system gpascii. I need to customize some functions, and I hope the administrator can send me some documents about these introductions. "WRITING C FUNCTIONS AND PROGRAMS IN POWER PMAC" is just an introduction, there is no introduction of functions and commands. Link to comment Share on other sites More sharing options...
JeffLowe Posted April 16, 2021 Share Posted April 16, 2021 Log in with putty and verify that gpascii correctly downloads your text file, and the syntax in the text file is correct. Link to comment Share on other sites More sharing options...
zerbzhang Posted April 19, 2021 Author Share Posted April 19, 2021 Jeff, thanks for your reply. I don't know much about gpascii communication, I just started to learn to use Power Pmac. Can you provide some information for my study and reference? Thanks very much for your help. Link to comment Share on other sites More sharing options...
JeffLowe Posted April 19, 2021 Share Posted April 19, 2021 The syntax you are using is for calling gpascii from a c program. If you are in a script plc it is simply System"gpascii -2 -i/var/ftp/whateverfile.txt" gpascii is just a linux command that opens up a pmac terminal and can accept any PMAC command that can be typed into the terminal window in the IDE. the -2 switch tells it to use the project variable names such as those defined in Global Includes. The -i is for opening a file and reading and interpreting its content. At the end of a successful load of the file you will get an EOF line, or if errors it will flag the error and line number. Link to comment Share on other sites More sharing options...
zerbzhang Posted April 20, 2021 Author Share Posted April 20, 2021 Jeff, thanks Link to comment Share on other sites More sharing options...
Recommended Posts