adccommunitymod (AutomationDirect) asked a question.

DL05 data movement

Created Date: August 20,2000

Created By: torben

**** This post has been imported from our legacy forum. Information in this post may be outdated and links contained in the post may no longer work.****

I am using the serial port to connect a OCR-reader. The scanned signal, e.g. A-BC-D will be stored in V memory from address V2000. A scanned signal could be V2000: 0080 (stored, otherwise "0 ") V2001: 2D41 (-A) V2002: 4342 (CB) V2003: 442D (D-) V2004: 0A0D (Carriage return and line feed) I would like to MOVE these characters to another location in the format ABCD - that is without the dashes. Anyone got an idea ? It would be much appreciated. Regards, Torben Christiansen, Vaegtgruppen, Denmark


  • adccommunitymod (AutomationDirect)

    Created Date: April 22,2015

    Created by: mleclerc

    I am using the serial port to connect a OCR-reader. The scanned signal, e.g. A-BC-D will be stored in V memory from address V2000.

    A scanned signal could be

    V2000: 0080 (stored, otherwise "0 ")

    V2001: 2D41 (-A)

    V2002: 4342 (CB)

    V2003: 442D (D-)

    V2004: 0A0D (Carriage return and line feed)

    I would like to MOVE these characters to another location in the format ABCD - that is without the dashes. Anyone got an idea ? It would be much appreciated.

    Regards, Torben Christiansen, Vaegtgruppen, Denmark

    torben, What model OCR reader are you using. I may be trying to read in a LCD screen to compare and verify the text.

    Expand Post
  • adccommunitymod (AutomationDirect)

    Created Date: August 20,2000

    Created by: torben

    I am using the serial port to connect a OCR-reader. The scanned signal, e.g. A-BC-D will be stored in V memory from address V2000.

    A scanned signal could be

    V2000: 0080 (stored, otherwise "0 ")

    V2001: 2D41 (-A)

    V2002: 4342 (CB)

    V2003: 442D (D-)

    V2004: 0A0D (Carriage return and line feed)

    I would like to MOVE these characters to another location in the format ABCD - that is without the dashes. Anyone got an idea ? It would be much appreciated.

    Regards, Torben Christiansen, Vaegtgruppen, Denmark

    Expand Post
  • adccommunitymod (AutomationDirect)

    Created Date: August 21,2000

    Created by: Mike McClanahan

    Why don't you try this

    LD V2001

    And K00FF

    Out Vxxxx

    for each location you need to do.

    To swap the CB locations:

    LD V2002

    AND K00FF

    OUT Vxxxx

    LD V2002

    SHFR K8 (move the the upper 8 bits to the lower 8 bits)

    OUT Vxxx

    To get the last data:

    LD V2003

    SHFR K8 (move the the upper 8 bits to the lower 8 bits)

    OUT Vxxx

    Hope this helps,

    Mike

    Expand Post