Results 1 to 3 of 3

Thread: Serial code kaput with new type PDA

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Sep 2006
    Posts
    29

    Thumbs up Serial code kaput with new type PDA

    Guys

    My evb3 code works fine for HP IPAQ HX2790, but when the code is used for the new HP IPAQ 212, it breaks down. I tuned the code everywhere, no work.


    The sensor data into the serial data is like this:
    Code:
    2008 09 11 18 36 48   -15.5    59.2    99.1  25.5  25.5  25.5  27  27  26 100   77.6   0.8   0.4  2.1  0.0  0.0  25.64  0.000    0.000  14.2   1.0    4.0  27  28  27
    My code is like this:
    Code:
    Private Sub Comm1_OnComm()
    Dim sTemp As String
    Select Case Comm1.CommEvent
    Case comEvReceive
        sTemp = Comm1.Input
        If Not (sTemp = "" Or IsNull(sTemp)) Then
            Buffer = Buffer & sTemp
            Timer1.Enabled = False
            Timer1.Enabled = True          
        End If 
    End Select
    End Sub
    
    Private Sub Timer1_Timer()
        If bFirstData = False Then
             ProcessData        
        End If
        Buffer = ""
        bFirstData = False
        Timer1.Enabled = False
    End Sub
    
    Private Sub ProcessData
    label1.Caption = Buffer
    End Sub
    
     Begin CECOMMCtl.Comm Comm1 
          Left            =   960
          Top             =   0
          _cx             =   1400
          _cy             =   1000
          CommPort        =   1
          Settings        =   "9600,n,8,1"
          InputLen        =   0
          InputMode       =   0
          NullDiscard     =   0   'False
          ParityReplace   =   "?"
          RThreshold      =   1
          SThreshold      =   0
          Handshaking     =   0
          DTREnable       =   -1  'True
          RTSEnable       =   -1  'True
       End
    
     Begin VBCE.Timer Timer1 
          Left            =   1320
          Top             =   120
          _cx             =   847
          _cy             =   847
          Enabled         =   0   'False
          Interval        =   500
       End
    My codes used to work with the old IPAQ HX2790 but with the new IPAQ 212, it doesnt work anymore, the string obtained is short

    and with inconsitent length like below:
    Code:
    2008 09 11 21 14 48    51  25.5 28  26 1 0.0  1.9      0.2   1.027
    
    2008 09 11 21 15 03   -708  25.5    26 100.0  2.3      0.0   1.0  
    
    2008 09 11 21 15 13  -1085.5  25.   80.8  0.3  0.00    0.  4.0  26  27  27
    
    2008 09 11 21 15 18   -171  25.5 27  26 1 0.0  1.00    0.  4.0  26  28  26
    .
    .
    .
    I adjusted comm1 properties everywhere, and adjusted timer1 from 200 to 1500ms but no help. It seems like I missed something.

    What should I do, guys?

    Advance thanks.

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: Serial code kaput with new type PDA

    Quote Originally Posted by irb4
    My codes used to work with the old IPAQ HX2790 but with the new IPAQ 212, it doesnt work anymore.....What should I do, guys?
    Contact the company that makes the device and ask them for some suggestions.

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Sep 2006
    Posts
    29

    Thumbs up Re: Serial code kaput with new type PDA

    Quote Originally Posted by Hack
    Contact the company that makes the device and ask them for some suggestions.
    Thanks. I tried a sample serial port code from BASIC4PPC which uses the .NET version2 framework. Same problem of intermitently not receiving the serial string fully.

    So I will ask the manufacturer.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width