I am using a function module to communicate from ABAP to a device connected on the serial port. It is based on the MSCOMM ActiveX Control and uses the MSCOMM properties to read/write values. Unfortunately, I need to send hex strings to the device because of the communication protocol. I am unable to do that. When I try to send a string of hex values, it is sending the ASCII values of the hex values on the serial port.
For example, I want to send the following hex values on the serial port: 01 24 56. I created an XSTRING in ABAP and has the value 012456, which is ok, but the serial port receives the following hex values: 30 31 32 34 35 36, which are the converted ASCII values for the components of the string sent from ABAP.
I saw that in VisualBasic, for example, to the string can be applied a cast to hex before sending it.
Can anybody tell me if it is possible to send hex strings through the serial port from this function module based on MSCOMM in ABAP without using a third-party software?
Thanks in advance, S.