|  | 
| 4 | 4 | 
 | 
| 5 | 5 | from fastcs.backends.epics.backend import EpicsBackend | 
| 6 | 6 | from fastcs.backends.epics.gui import EpicsGUIFormat | 
| 7 |  | -from fastcs.backends.epics.ioc import EpicsIOCOptions, PvNamingConvention | 
|  | 7 | +from fastcs.backends.epics.ioc import EpicsIOCOptions | 
|  | 8 | +from fastcs.backends.epics.util import EpicsNameOptions, PvNamingConvention | 
| 8 | 9 | 
 | 
| 9 | 10 | from ._version import __version__ | 
| 10 | 11 | from .gui import PandaGUIOptions | 
|  | 
| 15 | 16 | 
 | 
| 16 | 17 | 
 | 
| 17 | 18 | def ioc( | 
| 18 |  | -    prefix: EpicsName, | 
|  | 19 | +    epics_prefix: EpicsName, | 
| 19 | 20 |     hostname: str, | 
| 20 | 21 |     screens_directory: Path | None = None, | 
| 21 |  | -    poll_period: float = DEFAULT_POLL_PERIOD, | 
| 22 | 22 |     clear_bobfiles: bool = False, | 
|  | 23 | +    poll_period: float = DEFAULT_POLL_PERIOD, | 
|  | 24 | +    naming_convention: PvNamingConvention = PvNamingConvention.CAPITALIZED, | 
|  | 25 | +    pv_separator: str = ":", | 
| 23 | 26 | ): | 
|  | 27 | +    name_options = EpicsNameOptions( | 
|  | 28 | +        pv_naming_convention=naming_convention, pv_separator=pv_separator | 
|  | 29 | +    ) | 
|  | 30 | +    epics_ioc_options = EpicsIOCOptions(terminal=True, name_options=name_options) | 
|  | 31 | + | 
| 24 | 32 |     controller = PandaController(hostname, poll_period) | 
| 25 |  | -    epics_ioc_options = EpicsIOCOptions( | 
| 26 |  | -        terminal=True, pv_naming_convention=PvNamingConvention.CAPITALIZED | 
|  | 33 | +    backend = EpicsBackend( | 
|  | 34 | +        controller, pv_prefix=str(epics_prefix), ioc_options=epics_ioc_options | 
| 27 | 35 |     ) | 
| 28 |  | -    backend = EpicsBackend(controller, pv_prefix=str(prefix), options=epics_ioc_options) | 
| 29 | 36 | 
 | 
| 30 | 37 |     if clear_bobfiles and not screens_directory: | 
| 31 | 38 |         raise ValueError("`clear_bobfiles` is True with no `screens_directory`") | 
|  | 
0 commit comments