Using the string of the robotiq wrist cam barcode scanner

Hello,
I am using the robotiq wrist cam to scan barcodes.
After the scanning I want the barcodes to be saved in an excel document

  • I want to transmit the information to another Cobot
  • I want to make a decision based on the barcode scanned (means the same type of product will have a some same numbers in the barcode which I want to compare and make a decision of which program will follow)

For that I need to send the information from the cobot to the computer and another cobot.
But how can I do that? I don’t know where the information is saved in the registers of the cobot.
I tried to save the string in a register to read the register from the computer via modbus but unfortunatly this isn’t possible.

It is possible to save the data in the URCab local on USB but I need to get the information while the program is running.

Thank you a lot if someone has an idea how I can do that.

the Barcode string is saved into the global variable rq_code_string.

Why do you ned to send it to a computer?
you can set up Modbus direct from 1 robot to another.
If you convert the string to a number and assign it to a Modbus register both robots can see it
qr_Data = to_num(rq_code_string)

hope this helps

Unfortunately the bar code is mixed with numbers and letters.
So I can’t use the to_num function, because it can only be used if the string only consists of numbers.

But thank you

Uou could seperate the string out into letters and numbers
using str_find(rq_code_string,“Text to find”)
see script manual
https://www.universal-robots.com/download/manuals-e-series/script/script-manual-e-series-sw-511/

you could then translate the letters to ascii code and send it to the other robot and decode it once its recieved.

Thank you, i will look into that!