Smart Bot and generic Operation

7 Posts
2 Users
0 Likes
49 Views
(@admin_doc72)
Posts: 493
Member Admin
Topic starter
 

Hi All

I am afraid it seems that it is impossible to create a Generic bot ?
I hope I missed something !

Thanks

Nico

 
Posted : 17/05/2023 9:43 pm
 AT
(@a-tanarcinfo-com)
Posts: 15
Eminent Member
 

Hi,

By generic, may I know what you are trying to do?

Best regards,
Andy Tan

 
Posted : 24/05/2023 4:45 pm
(@admin_doc72)
Posts: 493
Member Admin
Topic starter
 

Hello,
I work for Nicolas who wrote this post. We try for example to get variables from several different machines, but with the Bot we can only get one specific variable and not make this variable change according to a zone.

 
Posted : 24/05/2023 9:00 pm
 AT
(@a-tanarcinfo-com)
Posts: 15
Eminent Member
 

Hi,

Do correct me if I am wrong, but here's what I understood from your requirements.

1. You have multiple different zones with the same equipment.
2. When a user walks into one of the zones, they will be able to get the reading from the said equipment using a generic Bot.

So, at the end of the day, what you need is a method to dynamically pass the Variable Branch to the Smart Bot.
Is that correct?

Best regards,
Andy Tan

 
Posted : 25/05/2023 12:41 pm
(@admin_doc72)
Posts: 493
Member Admin
Topic starter
 

Hi,
Yes i need a method to dynamically pass the Variable Branch to the Smart Bot.

 
Posted : 25/05/2023 1:36 pm
 AT
(@a-tanarcinfo-com)
Posts: 15
Eminent Member
 

Hi,

To answer the very first question, it is indeed possible to create a generic Smart Bot.
As to how to do it, it would not be straight forward as there are a few steps that needs to be done.

When a user enters a zone, there needs to be a method for the user to send their location to PcVue.
For example, there could be a tile on SnapVue that sends the string Zone01 to an internal variable (let's give it a name Info.ZoneName) on PcVue.
The Smart Bot would be constantly be monitoring Info.ZoneName for any change of value using the Trigger state.
Once the Smart Bot has detected a change of value on the variable Info.ZoneName, it would then read the text value on the variable and save it to memory.

From here onwards there are two ways you can proceed.
First method is to use the operation convert value where in input for the operation is the text value of Info.ZoneName.
The operation would then convert the text string into a predefined Branch.
For example:
Zone01 = Branch01.Zone01
Zone02 = Branch01.Zone02
Zone03 = Branch02.Zone03

The second method would be more convoluted where there would be a predefined database of information that associates the string from Info.ZoneName to a Branch as shown in the example above. This could be achieved using operations like Convert Excel file to database and Find in Database. It is more complex to do, but more scalable over the long run when there are a lot of Branches.

Once the branch name has been saved to memory (let's call it Key_BranchName), the operation Call procedure can be used to call on a Generic Smart Bot and pass the value stored in Key_BranchName to the generic bot.
Then, on the Generic Bot, on the variable field, you would just need to put in the Variable Name and it would automatically concatenate the value.
For example:
Branch from Call procedure = Branch01.Zone01
Variable field on Generic Bot = Register01
End result = Branch01.Zone01.Register01

If you don't want to use the Branch field on the Call procedure operation, it is also possible to pass Key_BranchName as a argument in the Key and Value field on the Parameter list.
As such, when entering the variable name in the Generic Bot, you can do the following "@{Key_BranchName}.Register01" (without the double quotes).

To sum things up, you would need two bots.
One to act as a dictionary to read the Zone location given by the user by tapping on the tile on SnapVue (or any other similar method) and parse the value as a Branch.
The second bot would then take in the parsed Branch and use it to get the value of the variable.

Best regards,
Andy Tan

 
Posted : 31/05/2023 11:06 am
(@admin_doc72)
Posts: 493
Member Admin
Topic starter
 

Thanks Andy I am sure that Bastien will work on the second case and I hope he'will camme with you with hgis feedback

Nicolas

 
Posted : 31/05/2023 1:12 pm