Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Flipper 6.0 Help File - <b>icom_read()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
ICOM_READ()
   Reads a response to a command from the plotter.

   Syntax
         cString = ICOM_READ(cPlotterCmd [,cStopChar] [,nWaitTime])

   Arguments
         cPlotterCmd  Plotter command to output some information

         OPTIONAL PARAMETERS
         cStopChar    Terminate character. [Default: CR or ASCII 13 ]
         nWaitTime    The time you wish to wait for the returns from the
                      Plotter. [Default: 36 clock ticks or 2 seconds]

   Returns
         cString      The string sent back from the plotter.

   Description
         ICOM_READ() allows you to send an HPGL function requesting
         information from the plotter. The routine will continue reading
         information until the cStopChar is reached. The plotter by
         default send a carriage return (ASCII 13) when it completes
         sending the requested information. When the carriage return is
         detected, the information is returned in cString. If no characters
         are received within the nWaitTime period then the read function
         will return with nothing in cString.

         The cStopChar can be changed if desired. The nWaitTime can also
         be changed. The time is in clock ticks which occur 18.2 times
         per second.

   Examples

               cString = ICOM_READ("OE;")   && Output Error
               cString = ICOM_READ("OI;")   && Output ID, cString = 7475A
               cString = ICOM_READ("OO;")   && Output Options
                                              && cString = 0,1,0,0,1,0,0,0
                cString = ICOM_READ(chr(27)+".E;")   && Extended error

   Note: See your plotter manual for other instructions.

See Also: ICOM_R_BUF() ICOM_R_CNT() ICOM_S_BUF() ICOM_S_CNT() ICOM_WRITE()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson