Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 32f38ef12d87eeea7959dd412443fdd6a48d2527
Ticket: 218817ffffffffffffffffffffffffffffffffff
The 'read' command alternately returns a single character or
User & Date: nobody on 2000-10-26 01:05:55
Changes

  1. assignee changed to: "nobody"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    OriginalBugID: 2217 Bug
    Version: 8.1.1
    SubmitDate: '1999-06-15'
    LastModified: '1999-07-08'
    Severity: CRIT
    Status: Released
    Submitter: techsupp
    ChangedBy: redman
    RelatedBugIDs: 1980
    OS: Windows 95
    Machine: X86
    FixedDate: '1999-07-08'
    FixedInVersion: 8.2b1
    ClosedDate: '2000-10-25'
    
    
    Name:
    David Graczyk
    
    ReproducibleScript:
    I have only tested this from the Windows platform.
    
        With a modem connected to Comm Port 1 on my PC, the following test
        script (serial.tcl) produced the results that follow:
    
        # Open and configure the serial comm port
        set fileID [open COM1: r+]
        fconfigure $fileID -blocking 0 -buffering line -mode 9600,n,8,1 -translation {crlf cr} -eofchar {}
    
        for {set i 1} {$i < 22} {incr i} {
        # Send "AT" command
        puts $fileID AT
        # Wait 2 seconds for "OK" response
        after 2000
        # Display loop iteration and comm port buffer contents
        puts "$i [read $fileID 80]"
        }
    
        close $fileID
    
        % source serial.tcl
        1
        2 A
        3
        4 T
        5
        6
        7
        8
        9
        10
    
        11
        12 O
        13
        14 K
        15
        16
        17
        18
    
        19
        20 A
        21
        %
    
        It seems that nothing was read on the odd numbered lines (loop
        iterations),
        the "cr" character was read on lines 6,8 & 16 and the "lf" character
        was
        read lines on 10 & 18.  Line 19 begins a repeat of the characters from
        line
        1 to 18.
    
        The results of running the script on version 8.0.5 look like this:
    
        16 AT
        OK
    
        17 AT
        OK
    
        18 AT
        OK
    
        19 AT
        OK
    
        20 AT
        OK
    
        21 AT
        OK
    
        22 AT
        OK
    
        23 AT
        OK
    
        %
    
        (The first 15 iterations scrolled off the screen.)
    
    DesiredBehavior:
    See 6.
    
    
    
    New implementation sent in for review.
    
    -- 06/29/1999 redman
    
    New implementation from Rolf Schroedter was applied and appears to be working properly.
    
    -- 07/08/1999 redman
    
    
    
  4. foundin changed to: "final: 8.1.1"
  5. priority changed to: "5 Medium"
  6. resolution changed to: "None"
  7. status changed to: "Open"
  8. submitter changed to: "nobody"
  9. subsystem changed to: "69. Other"
  10. title changed to:
    The 'read' command alternately returns a single character or
    
  11. type changed to: "Bug"