<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Arcpad Auxillary Serial Port (starter codes to read and write) in ArcPad Questions</title>
    <link>https://community.esri.com/t5/arcpad-questions/arcpad-auxillary-serial-port-starter-codes-to-read/m-p/123061#M856</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have a custom arcpad applet that will read data sent over the serial port. The code to read from the serial port I inherited and has worked flawlessly till now. A new bluetooth instrument has replaced the old cabled system. All of the serial port settings are the same, but the code will only read selective pieces of data. I have a simple text word "start" to read first, and then a few seconds later the following string is read.&amp;nbsp; DATA$,#,#,#,....,# 167. I can read the start string but I don't ever get the DATA string is never read! My feeling is the code is still working fine but the timing is off.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I need help quickly and any help would be greatly appreciated.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;'From APA File&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;OnComm=Call Trigger&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-------------------------------------------------------------------------------&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Set Timer1 = Application.Timer&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;' Subroutines control communication with Microcontroller&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Private Sub Timer 'Starts Timer to Wait for Input&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; Call ParseInput&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End Sub&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Sub Trigger 'Trigger for Timer when receiving data for Microcontroller&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Timer1.Interval = 1000&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Timer1.Enabled = True&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End Sub&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Sub ParseInput&amp;nbsp;&amp;nbsp; 'OnTimer Event&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Subroutines reads COM port and dumps everything to a string&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Dim test&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Do While Aux.InBufferCount &amp;gt; 0&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; test = Aux.Read(Aux.InBufferCount, False)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; msg = msg &amp;amp; test&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Loop&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Timer1.Enabled = False&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; If msg="Microcontroller" Then&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; MsgBox msg &amp;amp; " successfully communicated with ArcPad", vbInformation, "Communication is Ok"&amp;nbsp; 'Communication Check Acknowledgement&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; msg = ""&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Else&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; 'MsgBox msg, vbInformation, "Communication is Ok"&amp;nbsp; 'Communication Check Acknowledgement&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; Call Decision&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; End If&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End Sub&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 11 Jul 2011 20:52:25 GMT</pubDate>
    <dc:creator>MichaelWallace</dc:creator>
    <dc:date>2011-07-11T20:52:25Z</dc:date>
    <item>
      <title>Arcpad Auxillary Serial Port (starter codes to read and write)</title>
      <link>https://community.esri.com/t5/arcpad-questions/arcpad-auxillary-serial-port-starter-codes-to-read/m-p/123061#M856</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have a custom arcpad applet that will read data sent over the serial port. The code to read from the serial port I inherited and has worked flawlessly till now. A new bluetooth instrument has replaced the old cabled system. All of the serial port settings are the same, but the code will only read selective pieces of data. I have a simple text word "start" to read first, and then a few seconds later the following string is read.&amp;nbsp; DATA$,#,#,#,....,# 167. I can read the start string but I don't ever get the DATA string is never read! My feeling is the code is still working fine but the timing is off.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I need help quickly and any help would be greatly appreciated.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;'From APA File&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;OnComm=Call Trigger&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-------------------------------------------------------------------------------&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Set Timer1 = Application.Timer&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;' Subroutines control communication with Microcontroller&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Private Sub Timer 'Starts Timer to Wait for Input&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; Call ParseInput&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End Sub&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Sub Trigger 'Trigger for Timer when receiving data for Microcontroller&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Timer1.Interval = 1000&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Timer1.Enabled = True&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End Sub&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Sub ParseInput&amp;nbsp;&amp;nbsp; 'OnTimer Event&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Subroutines reads COM port and dumps everything to a string&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Dim test&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Do While Aux.InBufferCount &amp;gt; 0&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; test = Aux.Read(Aux.InBufferCount, False)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; msg = msg &amp;amp; test&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Loop&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Timer1.Enabled = False&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; If msg="Microcontroller" Then&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; MsgBox msg &amp;amp; " successfully communicated with ArcPad", vbInformation, "Communication is Ok"&amp;nbsp; 'Communication Check Acknowledgement&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; msg = ""&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Else&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; 'MsgBox msg, vbInformation, "Communication is Ok"&amp;nbsp; 'Communication Check Acknowledgement&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; Call Decision&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; End If&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End Sub&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Jul 2011 20:52:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/arcpad-auxillary-serial-port-starter-codes-to-read/m-p/123061#M856</guid>
      <dc:creator>MichaelWallace</dc:creator>
      <dc:date>2011-07-11T20:52:25Z</dc:date>
    </item>
  </channel>
</rss>

