EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024 
<== Date ==> <== Thread ==>

Subject: Re: Attocube AMC100
From: "Lang, Keenan C. via Tech-talk" <tech-talk at aps.anl.gov>
To: "Ivashkevych, Oksana" <oksana at bnl.gov>, Tech-talk <tech-talk at aps.anl.gov>
Date: Mon, 17 Oct 2022 21:55:05 +0000
I didn't experience this with the device I originally tested on, but I do know that Dave Cyl here at the APS did end up running into a similar issue with a more recent AMC100. We think that there were API changes causing behavior changes, but haven't been able to fully test out changes.

What he ended up changing:

Add the following to the move function, after the send(request) line that sends a request for "com.attocube.amc.move.setControlTargetPosition"

local request = {
                        jsonrpc = "2.0",
                        method = "com.attocube.amc.control.setControlMove",
                        params = { AXIS ,true },
                        id = AXIS,
                        api = 2 }
send(request)


Add the following to the poll function, after it checks if limits have been reached:

if (status == "in target range") then
               local request = {
                        jsonrpc = "2.0",
                        method = "com.attocube.amc.control.setControlMove",
                        params = { AXIS ,false },
                        id = AXIS,
                        api = 2 }
        send(request)
end


Keenan

From: Ivashkevych, Oksana <oksana at bnl.gov>
Sent: Monday, October 17, 2022 2:31 PM
To: Lang, Keenan C. <klang at anl.gov>; Tech-talk <tech-talk at aps.anl.gov>
Subject: RE: Attocube AMC100
 

Hi Keenan at al,

 

It looks like I can not move the motors from the EPICS interface.  The  commanded position changes, but the readback does not.  No errors in the epics shell.

 

 

It seems the driver tries to moves it judging by Mtr.MOVN changing value, but the motor does not move.

If I exit the epics while motor is commanded to move and still makes attempts, I see these  errors:

 

2022/10/17 15:29:07.609 asynMotorController:writeFloat64 error, status=3 axis=0, function=1, value=1468813.000000

2022/10/17 15:29:07.609 devMotorAsyn::asynCallback: XF:18IDB-ES{Comp-m1}Mtr pasyn{Float64,Int32}->write returned

 

I have motors with sensors, I can move them from the vendor application.

 

Left only single motor configured  for now. Any ideas what could be wrong, or how I can troubleshoot it?

Thank you

 

iocScriptMotor]$ more motor.substitutions.Attocube_AMC

file "$(MOTOR)/db/asyn_motor.db"

{

  pattern

  {P,                M,  DTYP,        PORT,     ADDR,  DESC,    EGU,      DIR,  VMAX,  VELO,  VBAS,  ACCL,  BDST,     BVEL,  BACC,     MRES,      PREC,  DHLM,       DLLM,   INIT}

  {XF:18IDB-ES,     "{Comp-m1}Mtr", "asynMotor", AMC-1,   0,    "CLp Motor1",    mm,       Pos,  15.,   3.,    .05,    .5,    0,       1.0,    2, .025,    5,   0,       0,  ""}

##  {XF:18IDB-ES,     "{Comp-m2}Mtr", "asynMotor", AMC-1,   1,    "CLp Motor2",    mm,       Pos,  15.,   3.,    .05,    .5,    0,       1.0,    2, .025,    5,   0,       0,  ""}

##  {XF:18IDB-ES,     "{Comp-m3}Mtr", "asynMotor", AMC-1,   2,    "CLp Motor3",    mm,       Pos,  15.,   3.,    .05,    .5,    0,       1.0,    2, .025,    5,   0,       0,  ""}

}

 

file "$(TOP)/db/ScriptMotorReload.db"

{

  pattern

  {P,               PORT}

  {XF:18IDB-ES:,    AMC-1}

}

 

 

 

(base) [oksana@xf18idb-ioc1 iocScriptMotor]$ ./st.cmd.Attocube_AMC

#!../../bin/linux-x86_64/scriptMotor

< envPaths

epicsEnvSet("IOC","iocScriptMotor")

epicsEnvSet("TOP","/epics/devel/support/motor/modules/motorScriptMotor/iocs/scriptMotorIOC")

epicsEnvSet("MOTOR","/epics/devel/support/motor")

epicsEnvSet("ASYN","/epics/devel/support/asyn")

epicsEnvSet("SNCSEQ","/epics/devel/support/seq")

epicsEnvSet("BUSY","/epics/devel/support/busy")

epicsEnvSet("IPAC","/epics/devel/support/ipac")

epicsEnvSet("EPICS_BASE","/epics/devel/epics-base")

epicsEnvSet("SUPPORT","/epics/devel/support")

epicsEnvSet("LUA","/epics/devel/support/lua")

< /epics/common/xf18idb-ioc1-netsetup.cmd

# BEGIN ANSIBLE MANAGED BLOCK

epicsEnvSet("EPICS_CA_AUTO_ADDR_LIST",         "NO")

epicsEnvSet("EPICS_CA_ADDR_LIST",              "10.66.139.255")

epicsEnvSet("EPICS_CAS_AUTO_BEACON_ADDR_LIST", "NO")

epicsEnvSet("EPICS_CAS_BEACON_ADDR_LIST",      "10.66.139.255")

epicsEnvSet("EPICS_CAS_INTF_ADDR_LIST",        "10.66.139.26")

# END ANSIBLE MANAGED BLOCK

dbLoadDatabase("/epics/devel/support/motor/modules/motorScriptMotor/iocs/scriptMotorIOC/dbd/scriptMotor.dbd")

scriptMotor_registerRecordDeviceDriver(pdbbase)

epicsEnvSet("LUA_SCRIPT_PATH", "./scripts")

#epicsEnvSet("IP_ADDRESS", "123.456.789.000")

epicsEnvSet("IP_ADDRESS", "10.66.138.124")

# Connect to virtual motor controller server

drvAsynIPPortConfigure("AMC","10.66.138.124:9090", 0, 0, 0)

#ScriptControllerConfig( "PORT_NAME", num_axes, "lua_script", "PARAMS=")

##ScriptControllerConfig("AMC-1", 3, "Attocube_AMC.lua", "PORT=AMC")

ScriptControllerConfig("AMC-1", 1, "AMC100.lua", "PORT=AMC")

ScriptAxisConfig("AMC-1", 0, "OPEN_LOOP='NO'")

##ScriptAxisConfig("AMC-1", 1, "OPEN_LOOP='NO'")

##ScriptAxisConfig("AMC-1", 2, "OPEN_LOOP='NO'")

#ScriptAxisConfig("AMC-1", 0, "OPEN_LOOP='YES'")

dbLoadTemplate("motor.substitutions.Attocube_AMC")

dbLoadRecords("/epics/devel/support/asyn/db/asynRecord.db", "P=XF:18IDB-ES{MCS:14}, R=Asyn, PORT=AMC, ADDR=0, OMAX=256, IMAX=256")

#asynSetTraceMask("MCS2", 0, 255)

asynSetTraceIOMask("MCS2", -1, 0x8)

asynManager:connectDevice port MCS2 not found

iocInit

Starting iocInit

############################################################################

## EPICS R7.0.5

## Rev. R7.0.5

############################################################################

cas warning: Configured TCP port was unavailable.

cas warning: Using dynamically assigned TCP port 40293,

cas warning: but now two or more servers share the same UDP port.

cas warning: Depending on your IP kernel this server may not be

cas warning: reachable with UDP unicast (a host's IP in EPICS_CA_ADDR_LIST)

iocRun: All initialization complete

epics>

 

 

From: Lang, Keenan C. <klang at anl.gov>
Sent: Wednesday, October 12, 2022 5:46 PM
To: Tech-talk <tech-talk at aps.anl.gov>; Ivashkevych, Oksana <oksana at bnl.gov>
Subject: Re: Attocube AMC100

 

This is a known issue with the current master branch of lua

 

Hello, When I run IOC of AMC100, I found this issue. Connect to virtual motor controller server drvAsynIPPortConfigure(&quot;AMC-1_IP&quot;,&quot;192.168.0.110:9090&quot;, 0, 0, 0) #ScriptControlle...

github.com

 

 

You can either use the latest tagged version instead, or define CXX11_SUPPORT=NO in CONFIG_SITE.local.Linux


From: Tech-talk <tech-talk-bounces at aps.anl.gov> on behalf of Ivashkevych, Oksana via Tech-talk <tech-talk at aps.anl.gov>
Sent: Wednesday, October 12, 2022 4:14 PM
To: Tech-talk <tech-talk at aps.anl.gov>
Subject: Attocube AMC100

 

Hello,

We have a new Attocube AMC 100 unit.

 

I found the following communication about support of the new AMC controllers

https://epics.anl.gov/tech-talk/2021/msg01321.php

 

I built lua, motorScriptMotor within motor, and found st.cmd.Attocube_AMC startup script.

 

I am getting nullptr error and the core dump.

 

I have tried using AMC100.lua script (as was suggested in the link above) instead of Attocube_AMC.lua; renamed the port, thinking that some characters could be the culprit, yet I have same error and the core dump.

When I use vmc.lua I do not have the core dump. Just errors.

 

Thanks

 

iocScriptMotor]$ ../../bin/linux-x86_64/scriptMotor st.cmd.Attocube_AMC

< envPaths

epicsEnvSet("IOC","iocScriptMotor")

epicsEnvSet("TOP","/epics/devel/support/motor/modules/motorScriptMotor/iocs/scriptMotorIOC")

epicsEnvSet("MOTOR","/epics/devel/support/motor")

epicsEnvSet("ASYN","/epics/devel/support/asyn")

epicsEnvSet("SNCSEQ","/epics/devel/support/seq")

epicsEnvSet("BUSY","/epics/devel/support/busy")

epicsEnvSet("IPAC","/epics/devel/support/ipac")

epicsEnvSet("EPICS_BASE","/epics/devel/epics-base")

epicsEnvSet("SUPPORT","/epics/devel/support")

epicsEnvSet("LUA","/epics/devel/support/lua")

< /epics/common/xf18idb-ioc1-netsetup.cmd

# BEGIN ANSIBLE MANAGED BLOCK

epicsEnvSet("EPICS_CA_AUTO_ADDR_LIST",         "NO")

epicsEnvSet("EPICS_CA_ADDR_LIST",              "10.66.139.255")

epicsEnvSet("EPICS_CAS_AUTO_BEACON_ADDR_LIST", "NO")

epicsEnvSet("EPICS_CAS_BEACON_ADDR_LIST",      "10.66.139.255")

epicsEnvSet("EPICS_CAS_INTF_ADDR_LIST",        "10.66.139.26")

# END ANSIBLE MANAGED BLOCK

dbLoadDatabase("/epics/devel/support/motor/modules/motorScriptMotor/iocs/scriptMotorIOC/dbd/scriptMotor.dbd")

scriptMotor_registerRecordDeviceDriver(pdbbase)

epicsEnvSet("LUA_SCRIPT_PATH", "./scripts")

#epicsEnvSet("IP_ADDRESS", "123.456.789.000")

epicsEnvSet("IP_ADDRESS", "10.66.138.144")

# Connect to virtual motor controller server

drvAsynIPPortConfigure("AMC","10.66.138.144:9090", 0, 0, 0)

#ScriptControllerConfig( "PORT_NAME", num_axes, "lua_script", "PARAMS=")

ScriptControllerConfig("AMC-1", 2, "Attocube_AMC.lua", "PORT=AMC")

scriptMotor: ../../../luaApp/src/luaaa/luaaa.hpp:979: luaaa::LuaClass< <template-parameter-1-1> >::LuaClass(lua_State*, const char*, const luaL_Reg*) [with TCLASS = _apdWrapper; lua_State = lua_State; luaL_Reg = luaL_Reg]: Assertion `klassName == nullptr' failed.

Aborted (core dumped)

 

 


Replies:
RE: Attocube AMC100 Ivashkevych, Oksana via Tech-talk
References:
Attocube AMC100 Ivashkevych, Oksana via Tech-talk
Re: Attocube AMC100 Lang, Keenan C. via Tech-talk
RE: Attocube AMC100 Ivashkevych, Oksana via Tech-talk

Navigate by Date:
Prev: I/O interrupts documentation Pierrick M Hanlet via Tech-talk
Next: Streamdevice discards part of message Brown, Garth via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024 
Navigate by Thread:
Prev: RE: Attocube AMC100 Ivashkevych, Oksana via Tech-talk
Next: RE: Attocube AMC100 Ivashkevych, Oksana via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024 
ANJ, 18 Oct 2022 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·