Here's my session with Arasan (latest i-taks with
minor unrelated changes for dir param).

     p=. 'jtask'conew~ 'cmd /c arasanx.exe';'D:\Tools\Arasan'
     write__p 'help',LF
1
     wait__p 1
1459
     read__p ''
Arasan 8.4 Copyright 1997-2005 by Jon Dart
Using book file book.bin
analyze:         enter Winboard analyze mode
black:           set computer to play Black
...

     write__p 'e2e4',LF
1
     wait__p 3
22
     read__p ''
1. e2e4
1. ... c7c5

     write__p ;,&LF each;:'Nf3 d4 Nxd4 Nc3 Be2 f4'
1
     wait__p 3
124
     read__p ''
2. Nf3
2. ... d7d6
3. d4
3. ... c5d4
4. Nxd4
4. ... g8f6
5. Nc3
5. ... e7e6
6. Be2
6. ... f8e7
7. f4
7. ... o-o

   NB.  write__p 'quit',LF
     close__p''
0
     wait__p 3
6
     read__p ''
quit

     destroy__p''



--- JC Coez <[EMAIL PROTECTED]> wrote:

>    load 'c:\task.ijs'
> 
>    p=: 'jtask'conew~ 'c:\arion\arion.exe'
>      write__p 'e2e4',LF
> 1
>      wait__p 1
> 0
>      read__p ''
> 0
>      write__p 10$'test ',LF
> 1
>      wait__p 3
> 0
>      $read__p ''
> 0
>      write__p 'bye',LF
> 1
>      close__p''
> 0
>      wait__p 3
>      $read__p ''
> 
> +---------------------------+
> | Arion 1.7   chess program |
>  .....JCC> more lines displayed when starting the program
> - launch Arion with 'dv x' argument to modify the draw value 'x'
>   ex: 'arion.exe dv -10'
> ......JCC > it calculates a good move to reply to 'e2e4'
> Arion> 1      -23 0 1  g8h6
> 1      -10 0 2  g8f6
> .......
> - time : 5.016s
> - speed : 569Kn/s
> - ht :  52%
> move e7e5
> 
> .......JCC > loop because the 'test' subcommand is bad
> Arion> - unknown command, missing parameter or illegal move
> - Please, type 'help' or ' /?'just after the command name for more 
> informations
> ..........
> Arion> - unknown command, missing parameter or illegal move
> - Please, type 'help' or ' /?'just after the command name for more 
> informations
> 
> Arion> - unknown command, missing par
> 
>      destroy__p''
> ......JCC > the program continues to read until I cancel it manually ( 
> windows task manager)
> - Please, type 'help' or ' /?'just after the command name for more 
> informations
> 
> Arion> - unknown command, missing parameter or illegal move
>  ............
> Arion> - unknown command, missing parameter or illegal move
> - Please, type 'help' or ' /?'just after the command name for more 
> informations
> 
> Arion> - unknown command,
> 
> ----- Original Message ----- 
> From: "Oleg Kobchenko" <[EMAIL PROTECTED]>
> To: "Programming forum" <[email protected]>
> Sent: Tuesday, April 03, 2007 10:01 PM
> Subject: Re: [Jprogramming] stdin/stdout
> 
> 
> > Can we be sure that the chess program does not
> > use stderr for some operations instead of stdout?
> 
>     I don't think and I am pretty sure
> >
>  > At any rate, what if, even without the response
> > there, try to send other commands like "quit",
> > will it act on it?
> >
> Yes, the command to quit the program is 'bye' and at that time I can get all 
> the output from the beginning. It seems that the read or readpeek does not 
> read at all...
> 
> I believe that the goal is not very far...at least I hope so.
> JCC 
> 
> 
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
> 



 
____________________________________________________________________________________
No need to miss a message. Get email on-the-go 
with Yahoo! Mail for Mobile. Get started.
http://mobile.yahoo.com/mail 
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to