paulscherrerinstitute / pcaspy

Portable Channel Access Server in Python
BSD 3-Clause "New" or "Revised" License
32 stars 24 forks source link

if i could use pcaspy module in python to read/write the pvs on other computers in the same local area network? #61

Closed xlgforever closed 3 years ago

xlgforever commented 5 years ago

i have learned about this module, the tuttorial of the module shows that it read or write pvs according to the base name, without the prefix. According to my understand, the prefix is equivalent to the user name of the PC that the PVs belong to.I'm not sure if I can access PVS on other PCs in the same local aera network without the prefix

xiaoqiangwang commented 5 years ago

According to my understand, the prefix is equivalent to the user name of the PC that the PVs belong to.

The prefix can be arbitrary. The only requirement is that the prefix + base name is unique in the LAN.

I'm not sure if I can access PVS on other PCs in the same local aera network without the prefix.

The Driver.setParam in PCASpy can only write the local PVs created by SimpleServer.createPV. So the base name is enough. To read/write PVs in other IOCs, you have to access them explicitly via channel access.

xlgforever commented 5 years ago

According to my understand, the prefix is equivalent to the user name of the PC that the PVs belong to.

The prefix can be arbitrary. The only requirement is that the prefix + base name is unique in the LAN.

I'm not sure if I can access PVS on other PCs in the same local aera network without the prefix.

The Driver.setParam in PCASpy can only write the local PVs created by SimpleServer.createPV. So the base name is enough. To read/write PVs in other IOCs, you have to access them explicitly via channel access.

well, I don't how to access other IOCs or PVs explicitly by using pcaspy. could you please tell me how to do it?

xiaoqiangwang commented 5 years ago

pcaspy is a channel access server module. It requires a channel access client module to read/write PVs on other IOCs.

There are many channel access client modules in Python, see https://epics.anl.gov/extensions/index.php. In the section CA and PVA Client Interfaces to other tools and languages -> Python.