Back to Four Js Website
Four Js Customer Forum
Subscribe for automatic updates:
RSS
Sign in for full access
|
Help
Four Js Development Tools Forum
>
Discussions by product
>
Genero BDL
>
Hl7 protocol problem
Most recent posts
Pages: [
1
]
« previous
next »
Reply
|
Print
Author
Topic: Hl7 protocol problem (Read 8912 times)
Claudio B.
Posts: 6
Hl7 protocol problem
«
on:
January 22, 2018, 11:10:33 am »
I'm trying to implement software to interface with a clinical chemistry machine in hl7.
I'm finding it difficult to use the hl7 protocol because the ch.dataAvailable () and ch.readLine () statements fail to intercept the check characters of the h7 and <VT> ascii (11).
the program can no longer understand when the transmitters have finished and the genero program is still listening without being able to read anything (empty string).
Only when the sender permanently closes the tcp channel, then I receive everything at once.
Reuben B.
Posts: 1126
Re: Hl7 protocol problem
«
Reply #1 on:
January 25, 2018, 05:20:17 am »
I would try the following. Use ch.setDelimiter() to set the delimiter to the last characters of the message <FS>,<CR> (from my reading <VT> is the first character, I want the characters you know signify the end)
Use ch.read not ch.readLine, that will read the whole message upto the delimiter into the 4gl variable. From that position use base.StringTokenizer or stringbuffer methods to dice up the HL7 message into the constituent parts.
Is there a tool similar to SoapUI you can use to emulate messages received? If you wanted support to look further, a tool like that would be useful.
Reuben
Product Consultant (Asia Pacific)
Developer Relations Manager (Worldwide)
Author of
https://4js.com/ask-reuben
Contributor to
https://github.com/FourjsGenero
Claudio B.
Posts: 6
Re: Hl7 protocol problem
«
Reply #2 on:
February 08, 2018, 04:16:26 pm »
Thanks for your answer.
I'm trying to communicate lab machinery (Mindray BC-5380).
The mindray is a client and I a server.
I wait the connection with commands:
LET ch = base.Channel.create ()
CALL ch.openServerSocket (null, "2575", "ub")
LET rigaw = ch.readLine ()
after the readline () everything stops until the machine corce connection close.
At this point I read everything at once, but the handshaking fail.
I think the problem is caused by the lack of EOF from the machine and therefore the readline does not intercept the incoming data.
The HL7 protocol only provides control characters <VT> HL7 Message <FS> <CR> (HL7 Minimum Layer Protocol (MLP) )
Claudio B.
Posts: 6
Re: Hl7 protocol problem
«
Reply #3 on:
February 08, 2018, 04:17:04 pm »
I'm trying to communicate lab machinery (Mindray BC-5380).
The mindray is a client and I a server.
I wait the connection with commands:
LET ch = base.Channel.create ()
CALL ch.openServerSocket (null, "2575", "ub")
LET rigaw = ch.readLine ()
after the readline () everything stops until the machine corce connection close.
At this point I read everything at once, but the handshaking fail.
I think the problem is caused by the lack of EOF from the machine and therefore the readline does not intercept the incoming data.
The HL7 protocol only provides control characters <VT> HL7 Message <FS> <CR> (HL7 Minimum Layer Protocol (MLP) )
Pages: [
1
]
Reply
|
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
General
-----------------------------
=> General Discussion
=> Ask Reuben
=> WWDC21
-----------------------------
Discussions by product
-----------------------------
=> Products announcements
=> Genero BDL
=> GWS
=> GAS and GBC
=> GDC
=> Genero Mobile for Android or iOS
=> Genero Studio
=> Reporting tools (GRW, GRE)
-----------------------------
Jobs
-----------------------------
=> Jobs
Powered by SMF 1.1.21
|
SMF © 2015, Simple Machines
Loading...