Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: m-labs/artiq
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 8bbffab8c8f1
Choose a base ref
...
head repository: m-labs/artiq
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 4467f91cbfef
Choose a head ref
  • 3 commits
  • 6 files changed
  • 1 contributor

Commits on Feb 29, 2016

  1. fix indentation

    sbourdeauducq committed Feb 29, 2016

    Verified

    This commit was signed with the committer’s verified signature.
    headius Charles Oliver Nutter
    Copy the full SHA
    785691a View commit details
  2. Copy the full SHA
    572c49f View commit details
  3. Copy the full SHA
    4467f91 View commit details
Showing with 44 additions and 42 deletions.
  1. +2 −2 artiq/coredevice/comm_generic.py
  2. +1 −1 artiq/frontend/artiq_flash.py
  3. +1 −1 artiq/gateware/targets/kc705.py
  4. +1 −1 artiq/master/scheduler.py
  5. +2 −2 artiq/runtime/main.c
  6. +37 −35 examples/master/device_db.pyon
4 changes: 2 additions & 2 deletions artiq/coredevice/comm_generic.py
Original file line number Diff line number Diff line change
@@ -158,7 +158,7 @@ def _read_bytes(self):
return self._read_chunk(self._read_int32())

def _read_string(self):
return self._read_bytes()[:-1].decode('utf-8')
return self._read_bytes()[:-1].decode("utf-8")

#
# Writer interface
@@ -242,7 +242,7 @@ def get_log(self):

self._read_header()
self._read_expect(_D2HMsgType.LOG_REPLY)
return self._read_chunk(self._read_length).decode("utf-8")
return self._read_chunk(self._read_length).decode("utf-8", "replace")

def clear_log(self):
self._write_empty(_H2DMsgType.LOG_CLEAR)
2 changes: 1 addition & 1 deletion artiq/frontend/artiq_flash.py
Original file line number Diff line number Diff line change
@@ -37,7 +37,7 @@ def get_argparser():
""")
parser.add_argument("-t", "--target", default="kc705",
help="target board, default: %(default)s")
parser.add_argument("-m", "--adapter", default="qc2",
parser.add_argument("-m", "--adapter", default="clock",
help="target adapter, default: %(default)s")
parser.add_argument("-f", "--storage", help="write file to storage area")
parser.add_argument("-d", "--dir", help="look for files in this directory")
2 changes: 1 addition & 1 deletion artiq/gateware/targets/kc705.py
Original file line number Diff line number Diff line change
@@ -315,7 +315,7 @@ def main():
"+ NIST Ions QC1/CLOCK/QC2 hardware adapters")
builder_args(parser)
soc_kc705_args(parser)
parser.add_argument("-H", "--hw-adapter", default="qc1",
parser.add_argument("-H", "--hw-adapter", default="clock",
help="hardware adapter type: qc1/clock/qc2 "
"(default: %(default)s)")
args = parser.parse_args()
2 changes: 1 addition & 1 deletion artiq/master/scheduler.py
Original file line number Diff line number Diff line change
@@ -198,7 +198,7 @@ async def _do(self):
await self.pool.state_changed.wait()
elif isinstance(run, float):
await asyncio_wait_or_cancel([self.pool.state_changed.wait()],
timeout=run)
timeout=run)
else:
if run.flush:
run.status = RunStatus.flushing
4 changes: 2 additions & 2 deletions artiq/runtime/main.c
Original file line number Diff line number Diff line change
@@ -137,9 +137,9 @@ static void network_init(void)
struct ip4_addr gateway_ip;

init_macadr();
fsip_or_default(&local_ip, "ip", 192, 168, 0, 42);
fsip_or_default(&local_ip, "ip", 192, 168, 1, 50);
fsip_or_default(&netmask, "netmask", 255, 255, 255, 0);
fsip_or_default(&gateway_ip, "gateway", 192, 168, 0, 1);
fsip_or_default(&gateway_ip, "gateway", 192, 168, 1, 1);

lwip_init();

72 changes: 37 additions & 35 deletions examples/master/device_db.pyon
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# This is an example device database that needs to be adapted to your setup.
# The RTIO channel numbers here are for NIST QC1 on KC705.
# The RTIO channel numbers here are for NIST CLOCK on KC705.

{
"comm": {
"type": "local",
"module": "artiq.coredevice.comm_tcp",
"class": "Comm",
"arguments": {"host": "192.168.0.42"}
"arguments": {"host": "kc705.lab.m-labs.hk"}
},
"core": {
"type": "local",
@@ -15,73 +15,70 @@
"arguments": {"ref_period": 1e-9}
},

"pmt0": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLInOut",
"arguments": {"channel": 0}
},
"pmt1": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLInOut",
"arguments": {"channel": 1}
},

"ttl0": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 2},
"arguments": {"channel": 0},
"comment": "This is a fairly long comment to test word wrapping in GUI."
},
"ttl1": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 3},
"arguments": {"channel": 1},
"comment": "Hello World"
},
"ttl2": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 4}
"arguments": {"channel": 2}
},
"ttl3": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 5}
"class": "TTLInOut",
"arguments": {"channel": 3}
},

"ttl4": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 6}
"arguments": {"channel": 4}
},
"ttl5": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 7}
"arguments": {"channel": 5}
},
"ttl_sma": {
"ttl6": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"arguments": {"channel": 6}
},
"ttl7": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLInOut",
"arguments": {"channel": 17}
"arguments": {"channel": 7}
},
"led": {


"ttl_sma": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLOut",
"class": "TTLInOut",
"arguments": {"channel": 18}
},
"ttl15": {

"led": {
"type": "local",
"module": "artiq.coredevice.ttl",
"class": "TTLClockGen",
"class": "TTLOut",
"arguments": {"channel": 19}
},

@@ -94,21 +91,21 @@
"dds0": {
"type": "local",
"module": "artiq.coredevice.dds",
"class": "AD9858",
"arguments": {"sysclk": 1e9, "channel": 0},
"class": "AD9914",
"arguments": {"sysclk": 3e9, "channel": 0},
"comment": "Comments work in DDS panel as well"
},
"dds1": {
"type": "local",
"module": "artiq.coredevice.dds",
"class": "AD9858",
"arguments": {"sysclk": 1e9, "channel": 1}
"class": "AD9914",
"arguments": {"sysclk": 3e9, "channel": 1}
},
"dds2": {
"type": "local",
"module": "artiq.coredevice.dds",
"class": "AD9858",
"arguments": {"sysclk": 1e9, "channel": 2}
"class": "AD9914",
"arguments": {"sysclk": 3e9, "channel": 2}
},

"qc_q1_0": {
@@ -160,7 +157,12 @@
"ttl_out": "ttl0",
"ttl_out_serdes": "ttl0",

"pmt": "pmt0",
"loop_out": "ttl0",
"loop_in": "ttl3",
#"loop_clock_out": "TODO",
"loop_clock_in": "ttl7",

"pmt": "ttl3",
"bd_dds": "dds0",
"bd_sw": "ttl0",
"bdd_dds": "dds1",