LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

URL endpoint in LV8.6

We have an old version of LabView, 8.6.

 

Trying to set the end point for a URL.  I cannot find a way to do it.  It's for a UDP packet.

 

We can send messages to an address OK (ie. xxx.xxx.xxx.xxx ).  But if I add an endpoint (xxx.xxx.xxx.xxx/Endpoint) the address is now unresolved.  I know I need to generate the endpoint, but how.  I have searched the pallets and examples but no joy.

 

Any advice?

0 Kudos
Message 1 of 7
(2,459 Views)

This will not work. It is up to the receiving end to map the destination port to a service.

 

(If the listener is based on LabVIEW and under your control, you could put encoded instructions inside the message, for example)

 

If you are trying to talk to some external device, please shows us the relevant sections of the manual. I am sure you misunderstood.

0 Kudos
Message 2 of 7
(2,421 Views)

@F4 wrote:

 

Trying to set the end point for a URL.  I cannot find a way to do it. 


Could it be you are talking about datasocket open? In that case you can create a URL by specifying the correct protocol (e.g. pspdstp opc ftphttp, and file)...

 

0 Kudos
Message 3 of 7
(2,412 Views)

I have attached a vi to explain.

 

We have telematics devices reporting CoAP messages to our "listeners" on our backend servers.  Generally our other devices are sent to just a port and address.  They are all UDP messages.  We build simulators for all our devices so we can work on back end items without burning cell time.

 

We have a new device that sends CoAP messages (basically JSON formed packets but still UDP).  These devices are sending to an address and an endpoint (like xxx.xxx.xxx.xxx/CoAPEvent).

 

The attached vi works fine for sending to a port/address.  But when adding the /endpoint, the address no longer resolves from the strip IP function.

 

I found vi's for setting endoints but on the version we have (8.6) I cannot find them.

 

Anyway, thanks for looking at it, let me know what you think (anyone).

 

 

0 Kudos
Message 4 of 7
(2,358 Views)

A UDP address is a U32 integer, nothing else. On each device, you have a listening port which is U16, giving you 6 bytes of targeting information, nothing more. Everything else needs to be encoded in the payload in a form both sides agree on.

 

A hostname can be translated into an IP address using name services.

Similarly, port numbers can be locally assigned to a nice string, so you might have a local service that translates Strings such as "CoAPEvent" into port numbers. All this needs to happen before the message is sent.

 


@F4 wrote:

 

We have a new device that sends CoAP messages (basically JSON formed packets but still UDP).  These devices are sending to an address and an endpoint (like xxx.xxx.xxx.xxx/CoAPEvent).

Can you attach a manual where this is described. CoAP is an application protocol, so you need to have either a driver suite or implement the RFC yourself, which would then translate CoAP  into low level UDP.

 


@F4 wrote:

I found vi's for setting endoints but on the version we have (8.6) I cannot find them.


Most likely these are from a third party toolkit. What are the name of these VIs. Is there an online manual? Were they written in-house? See also this discussion.

0 Kudos
Message 5 of 7
(2,352 Views)

One example I found:

 

http://zone.ni.com/reference/en-XX/help/371361J-01/lvconcepts/endpointurls/

 

I don't see these functions in my pallets.

 

 

0 Kudos
Message 6 of 7
(2,342 Views)

Hi F4,

 

these are NetworkStream functions, a feature not available in LV8.6.

(They are NOT based on UDP, but use TCP instead…)

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 7 of 7
(2,338 Views)