RF red light is always on even though I am not running any code, I am not sure what the problem is, please help me, my firmware and software are bete version of artiq-6.
So far, I have seen the switch, m-labs says I am suservo, but I don't know if I really am, I have also tried the methods they gave me, but they are not very effective, the following is my current situation and my device_db.py file.


core_addr = "192.168.1.75"
device_db = {
"core": {
"type": "local",
"module": "artiq.coredevice.core",
"class": "Core",
"arguments": {"host": core_addr, "ref_period": 1e-09, "target": "rv32g"},
},

"core_log": {
"type": "controller",
"host": "::1",
"port": 1068,
"command": "aqctl_corelog -p {port} --bind {bind} " + core_addr
},

"core_moninj": {
"type": "controller",
"host": "::1",
"port_proxy": 1383,
"port": 1384,
"command": "aqctl_moninj_proxy --port-proxy {port_proxy} --port-control {port} --bind {bind} " + core_addr
},

"core_cache": {
"type": "local",
"module": "artiq.coredevice.cache",
"class": "CoreCache"
},

"core_dma": {
"type": "local",
"module": "artiq.coredevice.dma",
"class": "CoreDMA"
},

"i2c_switch0": {
"type": "local",
"module": "artiq.coredevice.i2c",
"class": "I2CSwitch",
"arguments": {"address": 0xe0}
},

"i2c_switch1": {
"type": "local",
"module": "artiq.coredevice.i2c",
"class": "I2CSwitch",
"arguments": {"address": 0xe2}
},
}

# standalone peripherals
device_db["ttl0"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLInOut",
"arguments": {"channel": 0x000000},
}

device_db["ttl1"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLInOut",
"arguments": {"channel": 0x000001},
}

device_db["ttl2"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLInOut",
"arguments": {"channel": 0x000002},
}

device_db["ttl3"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLInOut",
"arguments": {"channel": 0x000003},
}

device_db["ttl4"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000004},
}

device_db["ttl5"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000005},
}

device_db["ttl6"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000006},
}

device_db["ttl7"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000007},
}

device_db["ttl8"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000008},
}

device_db["ttl9"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000009},
}

device_db["ttl10"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x00000a},
}

device_db["ttl11"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x00000b},
}

device_db["ttl12"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x00000c},
}

device_db["ttl13"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x00000d},
}

device_db["ttl14"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x00000e},
}

device_db["ttl15"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x00000f},
}

device_db["ttl16"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000010},
}

device_db["ttl17"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000011},
}

device_db["ttl18"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000012},
}

device_db["ttl19"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000013},
}

device_db["ttl20"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000014},
}

device_db["ttl21"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000015},
}

device_db["ttl22"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000016},
}

device_db["ttl23"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000017},
}

device_db["suservo0_ch0"] = {
"type": "local",
"module": "artiq.coredevice.suservo",
"class": "Channel",
"arguments": {"channel": 0x000018, "servo_device": "suservo0"}
}

device_db["suservo0_ch1"] = {
"type": "local",
"module": "artiq.coredevice.suservo",
"class": "Channel",
"arguments": {"channel": 0x000019, "servo_device": "suservo0"}
}

device_db["suservo0_ch2"] = {
"type": "local",
"module": "artiq.coredevice.suservo",
"class": "Channel",
"arguments": {"channel": 0x00001a, "servo_device": "suservo0"}
}

device_db["suservo0_ch3"] = {
"type": "local",
"module": "artiq.coredevice.suservo",
"class": "Channel",
"arguments": {"channel": 0x00001b, "servo_device": "suservo0"}
}

device_db["suservo0_ch4"] = {
"type": "local",
"module": "artiq.coredevice.suservo",
"class": "Channel",
"arguments": {"channel": 0x00001c, "servo_device": "suservo0"}
}

device_db["suservo0_ch5"] = {
"type": "local",
"module": "artiq.coredevice.suservo",
"class": "Channel",
"arguments": {"channel": 0x00001d, "servo_device": "suservo0"}
}

device_db["suservo0_ch6"] = {
"type": "local",
"module": "artiq.coredevice.suservo",
"class": "Channel",
"arguments": {"channel": 0x00001e, "servo_device": "suservo0"}
}

device_db["suservo0_ch7"] = {
"type": "local",
"module": "artiq.coredevice.suservo",
"class": "Channel",
"arguments": {"channel": 0x00001f, "servo_device": "suservo0"}
}

device_db["suservo0"] = {
"type": "local",
"module": "artiq.coredevice.suservo",
"class": "SUServo",
"arguments": {
"channel": 0x000020,
"pgia_device": "spi_sampler0_pgia",
"cpld_devices": ['urukul0_cpld', 'urukul1_cpld'],
"dds_devices": ['urukul0_dds', 'urukul1_dds']
}
}

device_db["spi_sampler0_pgia"] = {
"type": "local",
"module": "artiq.coredevice.spi2",
"class": "SPIMaster",
"arguments": {"channel": 0x000021}
}

device_db["spi_urukul0"] = {
"type": "local",
"module": "artiq.coredevice.spi2",
"class": "SPIMaster",
"arguments": {"channel": 0x000022}
}

device_db["urukul0_cpld"] = {
"type": "local",
"module": "artiq.coredevice.urukul",
"class": "CPLD",
"arguments": {
"spi_device": "spi_urukul0",
"refclk": 125000000.0,
"clk_sel": 2
}
}

device_db["urukul0_dds"] = {
"type": "local",
"module": "artiq.coredevice.ad9910",
"class": "AD9910",
"arguments": {
"pll_n": 32,
"chip_select": 3,
"cpld_device": "urukul0_cpld"
}
}

device_db["spi_urukul1"] = {
"type": "local",
"module": "artiq.coredevice.spi2",
"class": "SPIMaster",
"arguments": {"channel": 0x000023}
}

device_db["urukul1_cpld"] = {
"type": "local",
"module": "artiq.coredevice.urukul",
"class": "CPLD",
"arguments": {
"spi_device": "spi_urukul1",
"refclk": 125000000.0,
"clk_sel": 2
}
}

device_db["urukul1_dds"] = {
"type": "local",
"module": "artiq.coredevice.ad9910",
"class": "AD9910",
"arguments": {
"pll_n": 32,
"chip_select": 3,
"cpld_device": "urukul1_cpld"
}
}

device_db["spi_zotino0"] = {
"type": "local",
"module": "artiq.coredevice.spi2",
"class": "SPIMaster",
"arguments": {"channel": 0x000024}
}

device_db["ttl_zotino0_ldac"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000025}
}

device_db["ttl_zotino0_clr"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000026}
}

device_db["zotino0"] = {
"type": "local",
"module": "artiq.coredevice.zotino",
"class": "Zotino",
"arguments": {
"spi_device": "spi_zotino0",
"ldac_device": "ttl_zotino0_ldac",
"clr_device": "ttl_zotino0_clr"
}
}

device_db["led0"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000027}
}

device_db["led1"] = {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 0x000028}
}

Initialize it.

  • Jim replied to this.

    rjo Initialize it? What does that mean? What should I do, please

    What @rjo probably means is that you have to initialize the Urukul devices (https://m-labs.hk/artiq/manual/core_drivers_reference.html#artiq.coredevice.urukul.CPLD.init and https://m-labs.hk/artiq/manual/core_drivers_reference.html#artiq.coredevice.ad9910.AD9910.init) after you power-cycle the Kasli. You can do this by executing

    self.urukul0_cpld.init()
    self.urukul0_dds.init()

    and similiar commands for the other DDS units. If this is working, it is also a good idea to add these commands to the startup program on the crate (https://m-labs.hk/artiq/manual/configuring.html#flash-idle-and-or-startup-kernel), so they are executed after power-cycling the system.

    • Jim replied to this.

      steine01 Thank you for your reply. I tried your suggestion but reported the following error to me
      Traceback (most recent call last):
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\master\worker_db.py", line 78, in get
      desc = self.get_desc(name)
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\master\worker_db.py", line 69, in get_desc
      return self.ddb.get(name, resolve_alias=True)
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\master\databases.py", line 29, in get
      desc = self.data.raw_view[key]
      KeyError: 'urukul_cpld0'

      The above exception was the direct cause of the following exception:

      Traceback (most recent call last):
      File "D:\anaconda3\envs\artiq\Scripts\artiq_run-script.py", line 9, in <module>
      sys.exit(main())
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\frontend\artiq_run.py", line 225, in main
      return run(with_file=True)
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\frontend\artiq_run.py", line 211, in run
      raise exn
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\frontend\artiq_run.py", line 202, in run
      exp_inst = _build_experiment(device_mgr, dataset_mgr, args)
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\frontend\artiq_run.py", line 188, in _build_experiment
      return get_experiment(module, args.class_name)(managers)
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\language\environment.py", line 244, in init
      self.build(*args, **kwargs)
      File "dds_sample.py", line 8, in build
      self.setattr_device("urukul_cpld0")
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\language\environment.py", line 328, in setattr_device
      setattr(self, key, self.get_device(key))
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\language\environment.py", line 321, in get_device
      return self.__device_mgr.get(key)
      File "D:\anaconda3\envs\artiq\lib\site-packages\artiq\master\worker_db.py", line 81, in get
      .format(name)) from e
      artiq.master.worker_db.DeviceError: Failed to get description of device 'urukul_cpld0'

      Here's my code
      from artiq.experiment import*
      class DDSOutputTest(EnvExperiment):

      def build(self):
          self.setattr_device("core")  
          self.setattr_device("suservo0")
          self.setattr_device("urukul_cpld0")
          self.setattr_device("suservo0_ch0")
      
      @kernel
      def run(self):
          self.core.break_realtime()
          self.core.reset()
          
      
          self.suservo0.init()
          self.urukul0_cpld.init()
          self.urukul0_dds.init()
          delay(10*ms)
      
          freq = 80*Hz
          profile = 0
          offset = 0.0
      
          self.suservo0_ch0.set_dds(profile, freq, offset)
      
          self.suservo0_ch0.set(en_out=1)
          delay(100*s)
      
          self.suservo0_ch0.set(en_out=0)

        Jim the device is called "urukul0_cpld" and not "urukul_cpld0"