The example below is an alternative the INPUT command in the ACR controller. The routine will read one ASCII character at a time from the PC or other device. To end the transmission from the third-party controller, we look for a carriage return (ASC 13) as in IF (ASC($V0)=13) within the ReceiveData subroutine. This can then allow the programmer to continue program execution if desired as compared to the INPUT command which inhibits program execution.
Notes: The ACR9000's USB port uses Stream1. If using Ethernet, ACR-View will connect to the first available of the 4 streams (Stream2 - 5).
To see the stream number when connected, type STREAM
Below sample uses Stream#3 while leaving ACR-View with Stream#2 connected. This will not run from ACR-View's terminal emulator. Use connect via HyperTerminal or Putty (use Port 5002 which is the ASCII port)
If testing with PBOOT within the program, use ACR-View and CLOSE #3 before doing a REBOOT command to test the power-up function.
_ReceiveData