sven-oxionics
2d017a05a1
Fix panic when receiving empty strings in rpc calls
...
Receiving an empty string in an RPC call currently panics.
When `length` is zero, a call to the `alloc` function (as implemented in `artiq/firmware/runtime/session.rs`) returns a null pointer. Constructing a `CMutSlice` from a null pointer panics.
A `CMutSlice` consists of a pointer and the length. Rust's documentation of the `core::ptr` module states: "The canonical way to obtain a pointer that is valid for zero-sized accesses is `NonNull::dangling`."
This commits adds a check for the length of a string received in an RPC call. Only for lengths greater than zero a memory allocation is performed. For zero-length strings, a dangling pointer is used.
Test plan:
Invoke the following experiment, which returns an empty string over RPC:
```
class ReturnEmptyString(artiq.experiment.EnvExperiment):
def build(self):
self.core: Core = self.get_device("core")
@kernel
def run(self):
x = self.do_rpc()
print(x)
@rpc
def do_rpc(self) -> TStr:
return ""
```
Signed-off-by: Sven Over (Oxford Ionics) <sven.over@oxionics.com>
2023-07-18 12:01:44 +08:00
Florian Agbuya
c73601b4b3
gui/experiments: cast Qt timestamp to int preventing float type error
2023-07-14 16:34:24 +08:00
mwojcik
9e6ffcfa30
fix missing DIFF_TERM for Sampler and Mirny inputs
2023-06-02 17:21:42 +08:00
Sebastien Bourdeauducq
837dffb56c
fix IBUFDS_GTE2 parameters
2023-05-30 11:52:07 +08:00
Charles Baynham
76e93dc591
worker: Wait until datasets are written before quitting
...
Avoids a race condition in worker_impl.py where HDF5 dataset saving was
cut off before it finished for large datasets.
2023-05-24 07:00:09 +08:00
Jonathan Coates
cfc396cbc8
dma: fix off-by-one error in RawSlicer ( #2090 )
...
Signed-off-by: Jonathan Coates <jonathan.coates@oxionics.com>
2023-05-23 11:16:35 +08:00
Hartmann Michael (IFAG PSS SIS SCE QSE)
9c12d8b1de
doc: conda installation notes
2023-05-12 17:45:38 +08:00
Ikko Eltociear Ashimine
8bd1f5c8b9
fix typo in comm_analyzer.py
...
error_occured -> error_occurred
occured -> occurred
2023-04-02 09:27:21 +08:00
Ikko Eltociear Ashimine
671ed8ac77
fix typo in developing_a_ndsp.rst
...
occurence -> occurrence
2023-03-11 18:33:06 +08:00
火焚 富良
b50d30ba5b
compiler: fix const str/bytes handling ( #1990 )
2022-11-11 13:16:55 +08:00
cc78078
1b3fa3429d
kasli: relocate the SatelliteBase Error LED code ( #1955 )
2022-08-12 13:42:59 +08:00
cc78078
004e7e7461
kasli: add Error LED to MasterBase and SatelliteBase
2022-08-11 15:08:52 +08:00
Sebastien Bourdeauducq
ad37be40c7
typo
2022-07-21 11:58:50 +08:00
Sebastien Bourdeauducq
a3ca686305
doc: update channels to legacy
2022-07-19 17:36:15 +08:00
Deepskyhunter
20dc923c9e
Bugfix: Add missing item inside state to solve KeyError
...
KeyError raised when trying to load default_state()
due to missing Key "seed" in "RangeScan" and "CenterScan" in
state. Add {"seed": None} to resolve the bug.
2022-06-14 11:43:22 +08:00
Sebastien Bourdeauducq
83af3b756d
Revert "compiler: Fix #1871 (array() breaks math functions)"
...
This reverts commit 8786b137a3
.
2022-04-23 19:06:30 +08:00
Sebastien Bourdeauducq
3bc5a0dfb7
Revert "test: Fixup 6b5c390d4
typo"
...
This reverts commit 73371931fc
.
2022-04-23 19:06:28 +08:00
David Nadlinger
73371931fc
test: Fixup 6b5c390d4
typo
2022-04-22 09:00:46 +08:00
David Nadlinger
8786b137a3
compiler: Fix #1871 (array() breaks math functions)
...
GitHub: Fixes #1871 .
2022-04-22 09:00:39 +08:00
Leon Riesebos
ca67ae8365
browser: support datasets that use h5 group notation
...
Signed-off-by: Leon Riesebos <leon.riesebos@duke.edu>
2022-04-07 18:17:03 +08:00
Leon Riesebos
0226259e2b
browser: cleanup datasets panel for empty h5 files
...
this fix makes sure the datasets panel is cleared if an h5 file is empty or the datasets and archive groups are empty
2022-04-07 18:17:03 +08:00
pca006132
c6a7b8a8dd
compiler: fixed embedding annotation evaluation
2022-03-17 22:13:04 +08:00
pca006132
66b6555c72
compiler: allows string annotation
...
According to PEP484, type hint can be a string literal for forward
references. With PEP563, type hint would be preserved in annotations in
string form.
2022-03-17 22:12:58 +08:00
Sebastien Bourdeauducq
58f69cc96e
mgmt: fix config write error message
2022-03-16 08:28:55 +08:00
mwojcik
2e65574c5f
artiq_flash: fix satman fw for satellite1 etc boards
2022-03-10 16:22:13 +08:00
ciciwu
66ea41a81c
phaser: fix docstring formatting ( #1866 )
2022-03-08 19:21:39 +08:00
Sebastien Bourdeauducq
56b8c3c096
dashboard: fix typo ( #1858 )
2022-02-26 08:57:28 +08:00
Steve Fan
f941e17107
dashboard: prioritize min as part of default value resolution ( #1839 )
2022-01-27 17:49:21 +08:00
Steve Fan
d7838e16dd
comm_kernel: fix RPC exception handling ( #1801 )
2022-01-12 15:24:55 +08:00
Steve Fan
57e2ec629b
comm_kernel: check if elements are within bounds for RPC list ( #1824 )
2022-01-11 17:17:57 +08:00
Peter Drmota
4f87531565
gateware.test.suservo: Fix tests for python >=3.7
...
Closes #1748
2022-01-11 17:17:57 +08:00
Steve Fan
64347290fb
comm_kernel: fix off-by-one error for numeric value range check
2022-01-11 17:17:57 +08:00
Harry Ho
f49f1fcbfc
sayma_amc: add option to generate a 9MHz sq wave on the MCXs
2021-12-21 18:43:36 +08:00
Harry Ho
86fcd97416
sayma_amc: add option to force outputs on the MCXs
2021-12-21 18:43:36 +08:00
Steve Fan
759f00416b
llvm_ir: move stacksave before lltag alloca in build_rpc
...
Signed-off-by: Steve Fan <sf@m-labs.hk>
2021-12-19 12:09:19 +08:00
Harry Ho
5818bc0878
mmcspi: fix timeout on detecting CS_n
2021-12-18 11:31:58 +08:00
Harry Ho
44171258f5
mmcspi: add timeout on detecting edges & data
2021-12-18 00:33:00 +08:00
Harry Ho
bc249c32df
sayma: fallback default MAC address if MMCSPI fails
2021-12-17 19:20:34 +08:00
Harry Ho
949917cc9c
jdcg: fix missing JESD reset & JDAC re-init
2021-12-17 19:12:42 +08:00
Harry Ho
dc411d55be
jdcg: allow <=2 retries upon SYSREF test failure
2021-12-17 19:12:42 +08:00
Harry Ho
40e7b6058e
sayma: support reading EUI48 from MMCSPI
2021-12-16 21:23:29 +08:00
Harry Ho
105af644bd
libboard_misoc: add MMCSPI bitbanging driver
...
* Requires changes to Sayma AMC openMMC firmware as in https://github.com/HarryMakes/openMMC/commits/sayma-devel-fix/eui
* Primary supports reading EUI48 broadcasted from the MMC
2021-12-16 21:23:29 +08:00
Harry Ho
04ee775a9f
sayma_amc: adopt MMCSPI bitbanging GPIO core
...
* Requires changes to migen as in https://github.com/HarryMakes/migen/commits/sayma-mmcspi
2021-12-16 21:23:29 +08:00
Sébastien Bourdeauducq
9547a15162
Merge pull request #1796 from HarryMakes/release-6
...
Metlino/Sayma: fix DDS sync & upgrade SAWG to 1 GS/s
2021-12-13 10:58:49 +08:00
Harry Ho
d3869c966e
examples: fix RTIO clocks to 125 MHz
2021-12-13 10:42:23 +08:00
Harry Ho
77c4d2f013
siphaser: remove support for 150 MHz RTIO clock
...
* Sayma AMC no longer uses 150 MHz RTIO clock after 1 GS/s upgrade.
2021-12-13 10:37:50 +08:00
Harry Ho
23f5796d67
sayma: fix FTW for SyncDDS
2021-12-10 12:13:09 +08:00
Harry Ho
34e89a3777
gth_ultrascale: fix TX/RX_CLK25_DIV for 125 MHz GTREFCLK0
2021-12-10 12:13:06 +08:00
Harry Ho
a14666bc15
ad9154: re-adjust LMFCDel & LMFCVar for 1 GS/s (K=32)
...
* @HarryMakes performed 25 consecutive power-cycles of Sayma, in 2-min intervals:
* Results: MinDelay = 8, FALL_COUNT_Delay = 10
2021-12-10 12:13:03 +08:00
Harry Ho
2f49a1a412
sayma: 600 MS/s -> 1 GS/s
...
* Merged from 'sayma1g' (d74cd24d
)
2021-12-10 12:12:43 +08:00