mirror of
https://github.com/Binary-Coalescence/motorDSM.git
synced 2025-08-04 21:55:40 -05:00
Merge branch 'dev'
This commit is contained in:
69
README.md
69
README.md
@@ -1,14 +1,11 @@
|
|||||||
motorDSM
|
motorDSM
|
||||||
==========
|
==========
|
||||||
|
|
||||||
EPICS motor drivers for the following [Dynamic Structures and
|
EPICS motor drivers for the following [Dynamic Structures and Materials](https://www.dynamic-structures.com/) motor controllers: MD-90
|
||||||
Materials](https://www.dynamic-structures.com/) motor controllers: MD-90
|
|
||||||
|
|
||||||
[](https://github.com/Binary-Coalescence/motorDSM/actions/workflows/ci-scripts-build.yml)
|
[](https://github.com/Binary-Coalescence/motorDSM/actions/workflows/ci-scripts-build.yml)
|
||||||
|
|
||||||
motorDSM is a submodule of [motor](https://github.com/epics-modules/motor).
|
motorDSM is a submodule of [motor](https://github.com/epics-modules/motor). When motorDSM is built in the ``motor/modules`` directory, no manual configuration is needed.
|
||||||
When motorDSM is built in the ``motor/modules`` directory, no manual
|
|
||||||
configuration is needed.
|
|
||||||
|
|
||||||
motorDSM can also be built outside of motor by copying it's ``configure/EXAMPLE_RELEASE.local`` file to ``RELEASE.local`` and defining the paths to ``EPICS_BASE``, ``MOTOR``, and itself.
|
motorDSM can also be built outside of motor by copying it's ``configure/EXAMPLE_RELEASE.local`` file to ``RELEASE.local`` and defining the paths to ``EPICS_BASE``, ``MOTOR``, and itself.
|
||||||
|
|
||||||
@@ -22,19 +19,17 @@ for one attached MD-90 controller, or
|
|||||||
|
|
||||||
$ ../../bin/linux-x86_64/dsm st.cmd.md90.multi
|
$ ../../bin/linux-x86_64/dsm st.cmd.md90.multi
|
||||||
|
|
||||||
for eight attached MD-90 controllers.
|
for eight attached MD-90 controllers. You may need to change the path(s) for the serial port(s) in ``st.cmd.md90`` or ``st.cmd.md90.multi`` if the MD-90 is not attached at ``/dev/ttyUSB0``.
|
||||||
|
|
||||||
------------------------
|
------------------------
|
||||||
|
|
||||||
To set up a full EPICS stack for development and testing, install and configure
|
To set up a full EPICS stack for development and testing, install and configure all of the following dependencies:
|
||||||
all of the following dependencies:
|
|
||||||
|
|
||||||
------------------------
|
------------------------
|
||||||
epics-base
|
epics-base
|
||||||
------------------------
|
------------------------
|
||||||
|
|
||||||
Install make, gcc, and perl packages if not already installed, then clone and
|
Install make, gcc, and perl packages if not already installed, then clone and build epics-base:
|
||||||
build epics-base:
|
|
||||||
|
|
||||||
$ export SUPPORT=/path/to/install/directory
|
$ export SUPPORT=/path/to/install/directory
|
||||||
$ cd $SUPPORT
|
$ cd $SUPPORT
|
||||||
@@ -51,18 +46,17 @@ asyn
|
|||||||
$ cd $SUPPORT
|
$ cd $SUPPORT
|
||||||
$ git clone git@github.com:epics-modules/asyn.git
|
$ git clone git@github.com:epics-modules/asyn.git
|
||||||
|
|
||||||
Needed to install (on Arch Linux) ``rpcsvc-proto`` package to get ``rpcgen``
|
You may need to install (on Arch Linux) ``rpcsvc-proto`` package to get ``rpcgen`` binary needed to make asyn.
|
||||||
binary needed to make asyn.
|
|
||||||
|
|
||||||
In ``asyn/configure``, copy ``RELEASE`` to ``RELEASE.local`` and set ``SUPPORT``
|
In ``asyn/configure``, create the file ``RELEASE.local`` with contents:
|
||||||
and ``EPICS_BASE`` paths.
|
SUPPORT=/path/to/install/directory
|
||||||
|
EPICS_BASE=/path/to/epics-base
|
||||||
|
|
||||||
In ``asyn/configure``, create ``CONFIG_SITE.local`` file with the line:
|
In ``asyn/configure``, create ``CONFIG_SITE.local`` file with the line:
|
||||||
TIRPC=YES
|
TIRPC=YES
|
||||||
if appropriate header files are in ``/usr/include/tirpc/rpc`` instead
|
if appropriate header files are in ``/usr/include/tirpc/rpc`` instead of ``/usr/include/rpc``.
|
||||||
of ``/usr/include/rpc``.
|
|
||||||
|
|
||||||
$ cd asyn
|
$ cd $SUPPORT/asyn
|
||||||
$ make clean
|
$ make clean
|
||||||
$ make
|
$ make
|
||||||
|
|
||||||
@@ -74,15 +68,13 @@ seq
|
|||||||
$ cd $SUPPORT
|
$ cd $SUPPORT
|
||||||
$ git clone git@github.com:ISISComputingGroup/EPICS-seq.git seq
|
$ git clone git@github.com:ISISComputingGroup/EPICS-seq.git seq
|
||||||
|
|
||||||
Install the ``re2c`` package (Arch).
|
Install the ``re2c`` package (Arch) if needed.
|
||||||
|
|
||||||
Create ``seq/configure/RELEASE.local`` and set path for ``EPICS_BASE``.
|
Create ``seq/configure/RELEASE.local`` and set path for ``EPICS_BASE``. (Note this package seems to forget to git-ignore the .local file.)
|
||||||
(Note this package seems to forget to git-ignore the .local file.)
|
|
||||||
|
|
||||||
Edit ``seq/configure/RELEASE`` to add the missing '-' before include for ``ISIS_CONFIG``
|
Edit ``seq/configure/RELEASE`` to add the missing '-' before the ``include`` for ``ISIS_CONFIG`` on the next to last line. This seems to be a typo.
|
||||||
on the next to last line. Seems to be a typo.
|
|
||||||
|
|
||||||
$ cd seq
|
$ cd $SUPPORT/seq
|
||||||
$ make clean
|
$ make clean
|
||||||
$ make
|
$ make
|
||||||
|
|
||||||
@@ -94,24 +86,9 @@ motor
|
|||||||
$ cd $SUPPORT
|
$ cd $SUPPORT
|
||||||
$ git clone git@github.com:epics-modules/motor.git
|
$ git clone git@github.com:epics-modules/motor.git
|
||||||
|
|
||||||
Optionally, if you want to install additional motor drivers:
|
Create ``motor/configure/RELEASE.local`` and set ``SUPPORT``, ``ASYN``, ``SNCSEQ``, and ``EPICS_BASE`` to the appropriate paths.
|
||||||
|
|
||||||
$ cd motor
|
$ cd $SUPPORT/motor
|
||||||
$ git submodule init
|
|
||||||
$ git submodule update modules/motorAcs
|
|
||||||
$ git submodule update modules/foo
|
|
||||||
$ git submodule update modules/bar
|
|
||||||
|
|
||||||
Optionally, edit ``motor/modules/Makefile`` and comment out all unused driver
|
|
||||||
submodules.
|
|
||||||
|
|
||||||
Optionally, create ``motor/config/CONFIG_SITE.local`` with the line:
|
|
||||||
BUILD_IOCS = YES
|
|
||||||
|
|
||||||
Create ``motor/config/RELEASE.local`` and set ``SUPPORT``, ``ASYN``, ``SNCSEQ``,
|
|
||||||
and ``EPICS_BASE`` to the appropriate paths.
|
|
||||||
|
|
||||||
$ cd motor
|
|
||||||
$ make distclean
|
$ make distclean
|
||||||
$ make
|
$ make
|
||||||
|
|
||||||
@@ -123,17 +100,13 @@ motorDSM (this package)
|
|||||||
$ cd $SUPPORT
|
$ cd $SUPPORT
|
||||||
$ git clone git@github.com:Binary-Coalescence/motorDSM.git
|
$ git clone git@github.com:Binary-Coalescence/motorDSM.git
|
||||||
|
|
||||||
In ``motorDSM/configure``, copy ``EXAMPLE_RELEASE.local`` to ``RELEASE.local``
|
In ``motorDSM/configure``, copy ``EXAMPLE_RELEASE.local`` to ``RELEASE.local`` and set paths for ``EPICS_BASE``, ``MOTOR``, and ``MOTOR_DSM``.
|
||||||
and set paths for ``EPICS_BASE``, ``MOTOR``, and ``MOTOR_DSM``.
|
|
||||||
|
|
||||||
In ``motorDSM/configure``, copy ``EXAMPLE_CONFIG_SITE.local``
|
In ``motorDSM/configure``, copy ``EXAMPLE_CONFIG_SITE.local`` to ``CONFIG_SITE.local`` and uncomment to set:
|
||||||
to ``CONFIG_SITE.local`` and set:
|
|
||||||
BUILD_IOCS = YES
|
BUILD_IOCS = YES
|
||||||
|
|
||||||
In ``motorDSM/iocs/dsmIOC/configure``, copy ``EXAMPLE_RELEASE.local`` to
|
In ``motorDSM/iocs/dsmIOC/configure``, copy ``EXAMPLE_RELEASE.local`` to ``RELEASE.local``. Comment out the "if built inside motor" lines, uncomment the "if built outside motor" lines, and set the path for ``MOTOR_DSM``.
|
||||||
``RELEASE.local``. Comment out the "if built inside motor" lines, uncomment the
|
|
||||||
"if built outside motor" lines, and set the path for ``MOTOR_DSM``.
|
|
||||||
|
|
||||||
$ cd motorDSM
|
$ cd $SUPPORT/motorDSM
|
||||||
$ make distclean
|
$ make distclean
|
||||||
$ make
|
$ make
|
||||||
|
@@ -8,21 +8,15 @@ dsm_registerRecordDeviceDriver(pdbbase)
|
|||||||
# Network device
|
# Network device
|
||||||
#!drvAsynIPPortConfigure("serial0", "192.168.1.16:4002",0,0,0)
|
#!drvAsynIPPortConfigure("serial0", "192.168.1.16:4002",0,0,0)
|
||||||
# Local serial port
|
# Local serial port
|
||||||
#!drvAsynSerialPortConfigure("serial0", "/dev/ttyUSB0", 0, 0, 0)
|
drvAsynSerialPortConfigure("serial0", "/dev/ttyUSB0", 0, 0, 0)
|
||||||
drvAsynSerialPortConfigure("serial0", "/tmp/motorport", 0, 0, 0)
|
|
||||||
asynSetOption("serial0", 0, "baud", "115200")
|
asynSetOption("serial0", 0, "baud", "115200")
|
||||||
asynSetOption("serial0", 0, "bits", "8")
|
asynSetOption("serial0", 0, "bits", "8")
|
||||||
asynSetOption("serial0", 0, "parity", "none")
|
asynSetOption("serial0", 0, "parity", "none")
|
||||||
asynSetOption("serial0", 0, "stop", "1")
|
asynSetOption("serial0", 0, "stop", "1")
|
||||||
|
|
||||||
# not sure if these two are needed or what they should be set to:
|
|
||||||
#!asynSetOption("serial0", 0, "clocal", "Y")
|
|
||||||
#!asynSetOption("serial0", 0, "crtscts", "Y")
|
|
||||||
|
|
||||||
asynOctetSetInputEos("serial0", 0, "\r")
|
asynOctetSetInputEos("serial0", 0, "\r")
|
||||||
asynOctetSetOutputEos("serial0", 0, "\r")
|
asynOctetSetOutputEos("serial0", 0, "\r")
|
||||||
asynSetTraceIOMask("serial0", 0, 2)
|
asynSetTraceIOMask("serial0", 0, 2)
|
||||||
#asynSetTraceMask("serial0", 0, 255)
|
|
||||||
|
|
||||||
# Turn on the power supply and set the deadband
|
# Turn on the power supply and set the deadband
|
||||||
asynOctetConnect("initConnection", "serial0", 0)
|
asynOctetConnect("initConnection", "serial0", 0)
|
||||||
@@ -34,7 +28,6 @@ MD90CreateController("MD900", "serial0", 1, 100, 5000)
|
|||||||
|
|
||||||
### Motors
|
### Motors
|
||||||
dbLoadTemplate "motor.substitutions.md90"
|
dbLoadTemplate "motor.substitutions.md90"
|
||||||
|
|
||||||
dbLoadRecords("$(ASYN)/db/asynRecord.db", "P=DSM:,R=serial0,PORT=serial0,ADDR=0,OMAX=80,IMAX=80")
|
dbLoadRecords("$(ASYN)/db/asynRecord.db", "P=DSM:,R=serial0,PORT=serial0,ADDR=0,OMAX=80,IMAX=80")
|
||||||
|
|
||||||
iocInit
|
iocInit
|
||||||
|
Reference in New Issue
Block a user