Tachyon 3 sending DLE characters?

I am posting here because the original Tachyon 3 thread hasn't seen much activity recently, as everyone (else) has moved on to newer version.
I am on Tachyon 3 because first efforts with newer version where showing stack discipline issues in my I/O codes, and I needed to keep the instrument running.

So...
I have an instrument that communicates with a host Win program (115200 baud) and operates 8 ADC and 8 DAC channels. Normally all is well, but at random times the board will respond to an ADC read (all 8 channels) with some valid integer readings (usually 4 characters each, separated by spaces), followed by groups of 4 DLE (ASCII 16) characters (also separated by spaces). Once the DLEs show up, the serial port has to be disconnected in software, reconnected (which resets the QuickStart) and then it always works, until it doesn't.

I am trying to decide if the DLE characters are coming from Tachyon (unlikely), the serial port driver, or the interface code (Lazarus Serial). They seem to be signalling the end-of-operation for the program.

Is there any reason that Tachyon 3 would send such nicely formated DLE characters?

Thanks!

Comments

  • 3 Comments sorted by Date Added Votes
  • I am posting here because the original Tachyon 3 thread hasn't seen much activity recently, as everyone (else) has moved on to newer version.
    I am on Tachyon 3 because first efforts with newer version where showing stack discipline issues in my I/O codes, and I needed to keep the instrument running.

    So...
    I have an instrument that communicates with a host Win program (115200 baud) and operates 8 ADC and 8 DAC channels. Normally all is well, but at random times the board will respond to an ADC read (all 8 channels) with some valid integer readings (usually 4 characters each, separated by spaces), followed by groups of 4 DLE (ASCII 16) characters (also separated by spaces). Once the DLEs show up, the serial port has to be disconnected in software, reconnected (which resets the QuickStart) and then it always works, until it doesn't.

    I am trying to decide if the DLE characters are coming from Tachyon (unlikely), the serial port driver, or the interface code (Lazarus Serial). They seem to be signalling the end-of-operation for the program.

    Is there any reason that Tachyon 3 would send such nicely formated DLE characters?

    Thanks!

    The only clue is that it sends 4 characters with a space like the other readings which might indicate that there is some b bug in the conversion. But if you have stack issues in the newer version then there must be an issue in your code that shows up as 4 DLE characters. If you can't post the code here, just pm me with a link and I will treat it as private and get back to you.




    Tachyon Forth - compact, fast, forthwright and interactive
    useforthlogo-s.png
    --->CLICK THE LOGO for more links<---
    Latest binary V5.4 includes EASYFILE +++++ Tachyon Forth News Blog
    P2 SHORTFORM DATASHEET +++++ TAQOZ documentation
    Brisbane, Australia
  • Thanks Peter. Tomorrow I am going to force readings that are 2 or three chars long, and see what the DLE count is.
    I can post the code, but let me see if the stack is the issue. I had ruled it out before, but the problem is so sporadic that I may have not tested long enough.

    A clue that I should have mentioned is that Windows code that only requests the ADCs readings never faults; it is only when I set some DACs, then a few reads of the ADCs later it may fault out. Very sporadic, and I am wondering now if this is a sign of a hardware issue in talking to the DACs.
  • Got it. It turns out I was getting sends overlapping with the 'ok' receives, and this clobbered something. Fixed the end-of-message recognition code on Win and it is running as smoothly as you could imagine.

    Thanks Peter!
Sign In or Register to comment.