!$Author: fredfox $ !$Date: 2006-11-29 18:03:53 $ !$Revision: 1.9 $ !$Source: /weru/cvs/weps/weps.src/manage/dooper.for,v $ subroutine dooper (sr) ! + + + PURPOSE + + + ! Dooper reads in any coefficients associated with the ! operation. ! + + + KEYWORDS + + + ! tillage, operation, management ! + + + PARAMETERS AND COMMON BLOCKS + + + include 'p1werm.inc' include 'manage/oper.inc' include 'manage/man.inc' include 'manage/mproc.inc' ! + + + ARGUMENT DECLARATIONS + + + integer sr ! + + + ARGUMENT DEFINITIONS + + + ! sr - the subregion number ! + + + ACCESSED COMMON BLOCK VARIABLE DEFINITIONS + + + ! odir - operation direction (degrees from NORTH) ! ospeed - operation speed ! + + + LOCAL VARIABLES + + + character*256 line character*1 opdumy ! ! + + + SUBROUTINES CALLED + + + ! + + + FUNCTIONS CALLED + + + ! + + + DATA INITIALIZATIONS + + + ! + + + END SPECIFICATIONS + + + ! write(*,*) '*>dooper line |', mtbl(mcur(sr)), '|' read(mtbl(mcur(sr)), 1001) opdumy, opcode, opname 1001 format(a1,1x,i2,1x,a) if( (opcode.eq.0).and.(mcount(sr).gt.0) ) then opskip = 1 print*, 'SR',sr,' Skip operation', opcode,' ',opname else print*, 'SR',sr,' Do operation', opcode,' ',opname end if if( opcode.eq.1 ) then ! get additional line of data mcur(sr) = mcur(sr) + 1 line = mtbl(mcur(sr)) ! read tillage speed and direction read(line(2:len_trim(line)), *, err=901) ospeed, odir, & & ostdspeed, ominspeed, omaxspeed end if ! initialize row spacing to zero. It is needed by P51, (set in P3 or P5) ! but may be set and not cleared by a previous operation. imprs = 0.0 return ! Error stops 901 write(0,9901) mtbl(mcur(sr)) 9901 format ('DOOPER: Error reading line ->', a) call exit (1) end