This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Connecting to a scale for cattle via USB (com3) port

We have to connect a scale for cattle via a USB (defined COM3) with ACUCOBOL 10.1.5.

The command and the answer are in the image.

Somebody experience with this matter?

Kind regards

  • 0

    Hi. At first glance it looks like a straight forward ASCII string communication.

    In order to communicate you will need to convert the USB to RS232 communication. This can be achieved through either 3rd party software or a physical USB adaptor; it seems you may already have done that.

    I have extensive experience in communicating to serial devices like cash registers, scales, Point of Sale devices etc and am sure I - or anybody else with this specific experience - can get you going.

    That said, sometimes the scale manufacturers provide a driver as an alternative; possibly an ActiveX component.

    What is your time zone?  I am GMT+2

  • 0 in reply to 

    GMT+1

    Next week we get the test unit and cable which are the same as the ordered one by our customer.

    I'll keep in touch and let you know.

    Kind regards

  • 0

    The setup for the scale works with the test-program Hercules.

    I have to send the commands R (read) and PID (calibrated weight) and then read the answers.

    Communication over COM3

    Anyone a suggestion how to write and read COM3

  • Suggested Answer

    0 in reply to 

    Are you up for using an ActiveX control?  MSCOMMlib.MSComm

  • Suggested Answer

    0 in reply to 

    You will require the windows MSCOMM32.OCX

  • 0 in reply to 

    How can I use that in ACU

    Kind regards

  • Suggested Answer

    0 in reply to 

    Unfortunately I do not have an example for you as I use a 3rd part code generator (FlexGen).
    You will have to study the manual unless there is some kind soul who can help with an example (are you using traditional coding or Acubench). May also be an example provided by MF

    I can tell you that it boils down to (1) setting the port open properties and opening the port; (2) output; (3) input and (4) closing the port. (properties and methods)

    Navigate to      Help and Search "sample activeX" .  Choose ActiveX Examples. It should also provide a link to example Media_Player.zip in the support area of the MicroFocus Web site.