dan-hankins@cup.portal.com (Daniel B Hankins) (09/02/90)
Can anyone provide advice on how to use ARexx to access the serial port? Can Arexx keep up with 2400 baud (on a stock 68K Amiga)? I'd like to write a program similar to uucp, but in ARexx and for the BB systems I frequent. Is there a version of xmodem (or y or z) that's invokable from the CLI (or more specifically, from an ARexx program that already has control of the serial port)? I'd heard that Larry Phillips had written a program called SerMod which does at least -some- of what I'm looking for. If so, where can I find it? Any assistance on this will be greatly appreciated. Dan Hankins dan-hankins@cup.portal.com dan-hankins@pro-realm.cts.com It is impossible to both understand and appreciate Intel CPUs - forgotten
stevem@hal.CSS.GOV (Steve Masters) (09/03/90)
dan-hankins@cup.portal.com (Daniel B Hankins) writes: > Can anyone provide advice on how to use ARexx to access the serial port? >Can Arexx keep up with 2400 baud (on a stock 68K Amiga)? I have written an Arexx system that access an electronic barometer in real time across the Amiga serial port. I hit several stumbling blocks you may be interested in. The bigest single problem was the behavior of the READCH function. The statement a=READCH('ser',1) /* 'ser' was previously opened as SER: */ will hang until a character is received by the serial port. This caused me a major headache since my barometer does not always respond to each character sent...you must often repeat a command two or three times to get a response. Thus, a ( send command...wait for response) loop would not work. What I needed was a function that 'read a character from an open file, return a null string (or error indication) if no character is available.' This behavior would be similar to the INKEY$ function in BASIC. I never found such a function. If one exists (or can be easily duplicated) I would be quite interested. My solution was to start two processes. Process A (the main program) sends commands to the serial port, which it has opened for output. Process B simply listens to the serial port, which it has opened for input. When it receives a character, it sends the character to process A via the ADDRESS command. Process A periodically checks its port via GETPKT(), which will return a null string if nothing has been sent. This solution taught me quite a bit about ARexx message passing, but was tricky to program without frequently hanging one task or the other. I would prefer a more straightforward approach. Based on my experience, my solution would not keep up with a steady 2400 baud transmission. If a more traditional approach would work, I think it MIGHT work as long as ARexx wasn't having to contend with too many other tasks. > I'd heard that Larry Phillips had written a program called SerMod which >does at least -some- of what I'm looking for. If so, where can I find it? I would also be interested in any Rexx/SER: interfacing programs or info. Steve Masters stevem@hal.CSS.GOV ENSCO, Inc. Melbourne, FL 32940 USA (407) 254 4122
Martin.Schwab@p25.f17.n246.z2.UUCP (Martin Schwab) (09/07/90)
AREA:COMP.SYS.AMIGA.TECH Hi Dan, > Is there a version of xmodem (or y or z) that's invokable from the CLI > (or more specifically, from an ARexx program that already has control of > the serial port)? Yep, there is one. It`s called XPRTransmit. It should be on the new fishes anyway (#369, if I remember well). It uses the XPR*.Libraries. Using this little program it should be possible to have X,y,z-Modem and Kermit running from the cli. I use it to poll a german net and it works just fine. The author can be reached via 2:507/406@fidonet (Andreas Schildbach). If needed, I`m able to redirect e-mails to him. cu Martin -- UUCP: ...!doitcr!rcafe!17.25!Martin.Schwab Martin Schwab 2:246/17@FidoNet