ETA RWF encoding

Hi,

We try to retrieve streaming realtime data via ETA C in RWF format from our local deployed RTDS.

There is a sample code for using ETA C VAConsumer what we used:

./VAConsumer -webSocket {
{HOST}}:{
{PORT}} {
{SERVICE}} mp:EUR= -uname {
{USER_NAME}} -aid {
{APPID}} -x -protocolList rssl.rwf

We received the following message:

Error text: <rwsReadResponseHandshake:1921> Invalid HTTP response, status code 400

When we use the default tr_json2 protocol with this request, then we receive data in json format.

./VAConsumer -webSocket {
{HOST}}:{
{PORT}} {
{SERVICE}} mp:EUR= -uname {
{USER_NAME}} -aid {
{APPID}} -x

Please advise how to find the reason of this error? Is it possible that we have to change some settings in ADS/ADH?

Thanks for your help in advance.

Best regards

Best Answer

  • @marton.brosig

    I tested it with several versions of ADS.

    1. ADS 3.5.1.L1: I got the following error.

    Connection down, reconnecting.  Channel fd=18446744073709551615
            Error text: <rwsReadResponseHandshake:1921> Invalid HTTP response, status code 400


    Connection down, reconnecting.  Channel fd=18446744073709551615
            Error text: <rwsReadResponseHandshake:1921> Invalid HTTP response, status code 400

    2. ADS 3.6.3.L1 and ADS 3.7.0.L1: I can get the data properly.

    You may need to upgrade ADS.

Answers

  • Hi @marton.brosig,

    Please use -tcp flag for the RWF format.


  • Thank you for your answer @Gurpreet,

    Is it absolutely not possible to use the RWF format with websocket, or is it only the example application that can't do this?

    Thanks in advance



  • Hello @marton.brosig

    I can use ETA VAConsumer C (RTSDK 2.0.7.L1, quite old) to connect to my local ADS Pop (3.7.1.L1) WebSocket connection using the following parameters:

    -webSocket localhost:15000 ELEKTRON_DD mp:/THB= -uname wasin -x -protocolList rssl.rwf 

    Result:

    vaconsumer.png

    Could you please give me more details about your environment?

    • What ETA version you are using?
    • Which RTSDK edition (C/C++, Java, or C#)?
    • ADS version
    • More log messages when the problem occur.
    • Are you using the VAConsumer "as is" or modified something?
  • @wasin.w
    I'm using RTSDK C++/C Release 2.1.1.L1 (Jun 9, 2023),
    ADS version: 3.4,
    VAConsumer is unmodified,
    I don't get any additional log messages other than

    Connection down, reconnecting.  Channel fd=-1
        Error text: <rwsReadResponseHandshake:1921> Invalid HTTP response, status code 400

    on the console, I did not found any other log files.
    Thanks in advance!

  • Hi @marton.brosig

    While its possible to get RWF over websocket connection as shown by my colleagues; it does not offer any advantages compared to the traditional RSSL connection for a local deployed RTDS. Did you have any specific use case in mind?
  • customers have the opportunity to share their opinions, suggestions, and experiences related to their recent visits to Lowe's stores.

  • Hi @marton.brosig

    I agree with @Gurpreet , the RSSL connection aims for high data distribution. It provides a better performance then the WebSocket connection.