fanmingyu212 If I want to type annotate device arguments (e.g. ad9910 or ttl) in ARTIQ python, how should I do it? I tried to use the corresponding device classes in artiq.coredevice, but the complier raised an error.
lriesebos this might help out https://gitlab.com/duke-artiq/dax/-/wikis/ARTIQ/Kernel-typing but in essence, you have to use ARTIQ types (e.g. TInt32) for typing functions that the ARTIQ compiler touches, otherwise the ARTIQ compiler does not accept the type. If more flexibility is required (e.g. when trying to satisfy a type checker like mypy), a type comment can be used.
fanmingyu212 lriesebos thanks for the reply. I guess I might need to use a type comment to annotate devices used as arguments in kernel functions, since ARTIQ python types does not seem to include the AD9910 (or other custom classes).
sb10q I tried to use the corresponding device classes in artiq.coredevice, but the complier raised an error. Such type annotations work with NAC3, but there are currently other problems with it that may or may not be worse for your application.