-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for phyMotion IO cards #5
Comments
@kmpeters Regard, |
@Baokangwen, I don't have any personal experience with phytron controllers, so I can't be 100% certain, but it looks like the primary difference between the I1AM01 and I1AM02 is that the 02 has an integrated amplifier. I would expect the I1AM02 to work with the existing EPICS support. |
@MarkRivers Best Regards, --------------------------my st.cmd file--------------------------------------- #phytronCreateAxis(phytronPort, module, axis) file "$(TOP)/db/Phytron_motor.db" } ################################################################################ ################################################################################ medmInit: Unable to load font widgetDM_4 medmInit: Unable to load font widgetDM_6 medmInit: Unable to load font widgetDM_8 medmInit: Unable to load font widgetDM_10 medmInit: Unable to load font widgetDM_12 medmInit: Unable to load font widgetDM_14 medmInit: Unable to load font widgetDM_16 medmInit: Unable to load font widgetDM_18 medmInit: Unable to load font widgetDM_20 medmInit: Unable to load font widgetDM_22 medmInit: Unable to load font widgetDM_24 medmInit: Unable to load font widgetDM_30 medmInit: Unable to load font widgetDM_36 medmInit: Unable to load font widgetDM_40 medmInit: Unable to load font widgetDM_48 medmInit: Unable to load font widgetDM_60 |
Hi Kangwen,
These messages are not serious, they just mean that medm will not use the correct fonts:
```
medmInit: Unable to load font widgetDM_4
Trying default (fixed) instead
medmInit: Unable to load font widgetDM_6
Trying default (fixed) instead
medmInit: Unable to load font widgetDM_8
Trying default (fixed) instead
```
You can fix that by installing the correct entries in a fonts.alias file as described in the medm documentation.
The white fields in medm just mean that it cannot reach the PVs in the IOC. There can be several reasons for that.
- Make sure the PV names that medm is looking are the same as the PV names in the IOC. At the IOC prompt type "dbl" to see the names of the PVs. In medm right click outside any widget and then click "PV info" on a widget. That will show you the name of the PV medm is looking for.
- Make sure there is no firewall running, or that the firewall has the exceptions for Channel Access.
- Test whether the command line tool "caget" can read the motor PVs. If not the problem is probably a firewall.
Mark
|
@MarkRivers Best Regards, |
@MarkRivers Best Regard, |
That means that the driver polling function is setting the limit status of the motors. You need to figure out why. Do you have limit switches connected or cheat those inputs? You will not be able to move the motor until you solve that problem. |
@MarkRivers Epics phytron_i1am1O.db file records(picture 2)also can choose mode 0 without limit switch. |
The problem is that the controller may ignore the limit in that mode, but it is still passing the bad limit status to the motor record. The motor record won't let you move the motor if it is at a limit, even if the controller will let it move. You need to connect a switch or just a jumper wire so the EPICS software does not see the limit condition. |
@MarkRivers I will connect a jumper as soon as possible to see if I can solve the problem. |
@MarkRivers How does epics motor set up the encoder, I turned on the switch of the encoder in medm, clicked run no feedback value, I want to learn how to configure the encoder. At the same time, I haven't learned the linkage of multiple motor shafts, I hope you can give me a direction to learn, I don't know how to do this. Best Regards, |
The use encoder (UEIP) field of the motor record determines whether the raw motor position (RMP) or the raw encoder position (REP) is used as the raw readback position (RRBV) for the axis. I suggest testing an axis with UEIP to "No" first. If the REP field doesn't change when the motor is moved, UEIP should not be set to "Yes." |
@kmpeters ----------------------run epiccs ioc--------------------------- drvAsynIPPortConfigure("testRemote","10.50.10.120:22222",0,0,1) phytronCreateController ("phyMotionPort", "testRemote", 100, 100, 1000) phytronCreateAxis("phyMotionPort", 1, 1) < save_restore.cmd save_restoreSet_status_prefix("P=phytron:") save_restoreSet_Debug(0) save_restoreSet_IncompleteSetsOk(1) save_restoreSet_DatedBackupFiles(1) save_restoreSet_NumSeqFiles(3) save_restoreSet_SeqPeriodInSeconds(300) set_savefile_path("/home/guest/EPICS/synApps_6_1/support/motor-R7-1/modules/motorPhytron/iocs/phytronIOC/iocBoot/iocPhytron", "autosave") set_requestfile_path("/home/guest/EPICS/synApps_6_1/support/motor-R7-1/modules/motorPhytron/iocs/phytronIOC/iocBoot/iocPhytron", "") set_pass0_restoreFile("auto_settings.sav") EPICS R3.15.9.1-DEVEPICS Base built Jul 26 2022############################################################################ save_restore: Can't open save file.iocRun: All initialization complete create_monitor_set("auto_setting.req",30,"P=phytron:") -----------------------save_restore.cmd------------------------------ save_restoreSet_Debug(0) save_restoreSet_IncompleteSetsOk(1) save_restoreSet_DatedBackupFiles(1) save_restoreSet_NumSeqFiles(3) save_restoreSet_SeqPeriodInSeconds(300) set_savefile_path("$(TOP)/iocBoot/$(IOC)", "autosave") set_requestfile_path("$(TOP)/iocBoot/$(IOC)", "") set_pass0_restoreFile("auto_settings.sav") < envPaths ##Register all support components dbLoadDatabase("../../dbd/phytron.dbd",0,0) phytron_registerRecordDeviceDriver(pdbbase) dbLoadTemplate("motor.substitutions.phytron") drvAsynIPPortConfigure("testRemote","10.50.10.120:22222",0,0,1) phytronCreateController ("phyMotionPort", "testRemote", 100, 100, 1000) phytronCreateAxis("phyMotionPort", 1, 1) < save_restore.cmd iocInit() create_monitor_set("auto_setting.req",30,"P=phytron:")Best Regards, |
@MarkRivers I'd like to ask, there are 8 motors connected to one controller, and I control them separately with epics, which can be controlled. Best Regards, |
The "save_restore: Can't open file" errors are normal the first time the IOC is run after autosave is added to it. The files will eventually be created by the IOC. If the errors continue after the IOC has been running for more than a minute, write permission to the autosave folder might need to be added. |
There are several ways to do this, depending on the application. The synApps "optics" module (https://github.com/epics-modules/optics) has a "table" record that is designed for tables with up to 6 degrees of freedom. It lets you adjust height, pitch, and roll. It just connects to the real motor records. The "virtual" motors in that case are not motor records, they are different PVs. You can also use softmotors to do it, and implement the geometry logic yourself. The motor module contains some examples of databases for coordinate transformations: This is an example of using an SNL program to implement the geometry code: |
@MarkRivers I loaded this db file into my st.cmd file and ran it with two error How should I solve this? |
You are missing the transform record, which is part of the epics "calc" module. |
That is not correct. What you need to do is to add CALC to motorPhytron/iocs/phytronIOC/configure/RELEASE.local. Then in motorPhytron/iocs/phytronIOC/phytronApp/src/Makefile you need to add these lines:
|
@MarkRivers |
Please attach the complete output when the IOC starts. |
@MarkRivers =====================================This is one of my records================================= |
You need to add these lines to iocs/phytronIOC/phytronApp/src/Makefile
In general your problem is that you are using the Phytron example IOC for features it is not built with (like CALC and Soft Channel). It is better to build your own IOC outside of the motorPhytron directory. |
Thank you Mark. Best withes, |
@MarkRivers |
I am not sure what you are asking. What happens when you load this db file into the IOC. |
@MarkRivers -c ../phytronAxisMotor.cpp |
@MarkRivers How to add Renishaw's readhead and encoder to this control module. Best Regards, |
If the driver supports encoders then no additional software should be needed. It is just a hardware connection and configuration setting. |
incremental encoder |
Incremental encoders don’t require any other software. However I a not an expert on the Phytron controllers. |
The support was discussed in this pull request:
#3
and can be found here:
https://github.com/bkuner/ioPhytron.git
The text was updated successfully, but these errors were encountered: