Wrong number args to PDL function

Homepage Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Wrong number args to PDL function

  • Creator
    Topic
  • #50994
    Anthony Kirk
    Participant

    Whenever I attempt to split an outbound message on pipe and send each one as a message segment, I get the following error message:

    Connection – NC_PAS

    (NC      100BB0|NC1017185879E                                                            00000000005  06      )

    MsgList = ({NC      100BB0} {NC1017185879E                                                            00000000005  06      })

    List length = 2

    MsgData = (NC      100BB0)

    {outdata {literal {NC      100BB0}}} {outbuffsequ {literal 001}} {outtransequ {literal 001}} {outeor {literal NLS}}

    {ok write.getResponse} {error write.error} {timeout {10000 write.timeout}}

    MsgData = (NC1017185879E                                                            00000000005  06      )

    {outdata {literal {NC1017185879E                                                            00000000005  06      }}} {outbuffsequ {literal 002}} {outtransequ {literal 001}} {outeor {literal END}}

    {ok write.getResponse} {error write.error} {timeout {10000 write.timeout}}

    06/22/2009 11:54:39

    [pdl :PDL :ERR /0:       NC_PAS] assertion violated: ARGC == *pc++

    06/22/2009 11:54:39

    [pdl :PDL :ERR /0:       NC_PAS] in pdl.cpp:1027

    06/22/2009 11:54:39

    [pdl :PDL :ERR /0:       NC_PAS] Wrong number args to PDL function

    06/22/2009 11:54:39

    [pdl :PDL :ERR /0:       NC_PAS] PDL signaled exception: code -1, msg PDL error: Wrong number args to PDL function

    The part of the pdl that processes these segments is as follows:

    proc hci_pd.write { info } {

    global Transaction TranSequence BuffSequence TranSequence MsgContent NLSEND segcount segheader seg1 seg2 seg3 segsub

    keylget info message MsgId ; # Read The Message Handle    

        set MsgList [split [msgget $MsgId] |] ; # Read The Message Data

    echo “MsgList = ($MsgList)”

    set segcount [llength $MsgList]

    echo “List length = $segcount”

    incr TranSequence

    if {$TranSequence > 999} {set TranSequence 1}

    #set BuffSequence 0

    foreach MsgData $MsgList {

    echo “MsgData = ($MsgData)”

        incr BuffSequence

        set tsequ [format “%03d” $TranSequence]

        set bsequ [format “%03d” $BuffSequence]

        if {$BuffSequence == $segcount} {

    set NLSEND END

    set BuffSequence 0

        } {

    set NLSEND NLS

        }

        set     MsgContent

      ] ; # Message  to data

          lappend MsgContent

        ; # Sequence within Transaction

            lappend MsgContent

          ; # Rolling Transaction Number

              lappend MsgContent

            ; # Literal END or NLS

                write.data    

            }

            }

            Whenever there is only one segment i.e. no pipe, there is no error.  Where have I gone wrong?  Is it my attempt to write data multiple times?

          Viewing 2 reply threads
          • Author
            Replies
            • #68325
              garry r fisher
              Participant

              Hi Anthony,

              I’d split my message in an outbound TPS rather than in a PDL.

              Regards

              Garry

            • #68326
              Anthony Kirk
              Participant

              Sending the message in several parts was part of our original approach. Each data message generated a “header” segment, continued as a message, then the data (segment 2) was continued as another message.

              The problem we had was several messages attempting to be sent simultaneously. Data1 and Data2 would arrive on the outbound thread. Data1 generated Header1, Data2 generated Header2. The receiving system would receive Header2 before Data1, assume the content of Header2 was actually Data1, get in a tizz and stop handling our messages (oh the joys of CLINiCOM !)

              I think our next step would be to add the header into all our xlates, unless anyone has a better solution…

            • #68327
              garry r fisher
              Participant

              Hi Anthony,

              I remember the joys of CLINiCOM – I used to work for SMS/Torex/iSOFT.

              I think you should add the header to your xlates and split the CLINiCOM transactions in an outbound TPS. I wrote a standard one when I worked for SMS et al that you should have called splitTrans.tcl.

              Regards

              Garry

          Viewing 2 reply threads
          • The forum ‘Cloverleaf’ is closed to new topics and replies.

          Forum Statistics

          Registered Users
          5,115
          Forums
          28
          Topics
          9,290
          Replies
          34,422
          Topic Tags
          286
          Empty Topic Tags
          10