@@ -55,10 +55,6 @@ The old defined constants are still supported for backwards compatibility.
5555.Example:
5656[source,python]
5757----
58- # Old (deprecated) style:
59- comp.newpin("in-a", hal.HAL_FLOAT, hal.HAL_IN)
60-
61- # New style:
6258comp.newpin("in-a", hal.Type.REAL, hal.Dir.IN)
6359----
6460
@@ -71,22 +67,22 @@ The `hal.Type` enum is used to specify the type of pin, parameter and signal:
7167* `hal.Type.UINT` - An unsigned quantity with range 0...+2^64^-1
7268* `hal.Type.REAL` - A floating point quantity of range ±1.80×10^308^
7369* `hal.Type.PORT` - An opaque quantity representing a communication channel (pins only)
74- * `hal.Type.S32` - A signed quantity with range -2^31^...+2^31^-1 (see notes below)
75- * `hal.Type.U32` - An unsigned quantity with range 0...+2^32^-1 (see notes below)
7670
7771There are aliases in the `hal.Type` enum for all types with the `HAL_` prefix (e.g. `hal.Type.HAL_BOOL`, etc.).
7872
7973[NOTE]
8074====
81- The constants previously used (`hal.HAL_BIT`, `hal.HAL_FLOAT`, etc.) are still available .
75+ The constants previously used (`hal.HAL_BIT`, `hal.HAL_FLOAT`, etc.) are deprecated and emit a warning .
8276You should upgrade your code to use the enumerated types with the new names instead.
83- ====
8477
85- [IMPORTANT]
86- ====
87- The 32-bit types will soon be replaced by 64-bit types.
88- The names will remain for some time, but they will map to the larger type automatically.
89- The `S32` and `U32` names will then no longer be unique and the range will be larger.
78+ [source,python]
79+ ----
80+ # Old (deprecated) style:
81+ comp.newpin("in-a", hal.HAL_FLOAT, hal.HAL_IN)
82+
83+ # New style:
84+ comp.newpin("in-a", hal.Type.REAL, hal.Dir.IN)
85+ ----
9086====
9187
9288==== HAL direction
@@ -105,7 +101,10 @@ Also the direction enums are available with the `HAL_` prefix (like `hal.Dir.HAL
105101==== Old style HAL constants (deprecated)
106102
107103Old style constants (deprecated):
108- `hal.HAL_BIT`, `hal.HAL_S32`, `hal.HAL_U32`, `hal.HAL_S64`, `hal.HAL_U64`, `hal.HAL_FLOAT`, `hal.HAL_PORT`.
104+ `hal.HAL_BOOL`, `hal.HAL_SINT`, `hal.HAL_UINT`, `hal.HAL_REAL`, `hal.HAL_PORT`.
105+
106+ Deprecated constants:
107+ `hal.HAL_BIT`, `hal.HAL_S64`, `hal.HAL_U64`, `hal.HAL_FLOAT`.
109108
110109Old style deprecated pin direction constants (deprecated):
111110`hal.HAL_IN`, `hal.HAL_OUT`, `hal.HAL_IO`.
@@ -271,8 +270,8 @@ Textual representations are case insensitive.
271270.Example:
272271[source,python]
273272----
274- hal.set_p("mycomp.0.bit ", True)
275- hal.set_p("mycomp.0.float ", 99.99)
273+ hal.set_p("mycomp.0.bool ", True)
274+ hal.set_p("mycomp.0.real ", 99.99)
276275----
277276
278277hal.set_s(_name_:string, _value_:mixed)::
@@ -429,12 +428,10 @@ Each data sample may contain up to twenty (20) values.
429428The type of the values in a sample must be configured and specified in a type string.
430429anchor:type-string[]The type string consists of the following characters (case insensitive):
431430
432- * `b` - Boolean
433- * `s` - Signed 32-bit
434- * `u` - Unsigned 32-bit
435- * `l` - Signed 64-bit
436- * `k` - Unsigned 64-bit
437- * `f` - Floating point (real)
431+ * `b` - Boolean (bool)
432+ * `s`, `l` - Signed 64-bit (sint)
433+ * `u`, `k` - Unsigned 64-bit (uint)
434+ * `f`, `r` - Floating point (real)
438435
439436Two components are available, 'streamer' and 'sampler'.
440437The 'streamer' component writes a set of pins from non-real-time data pushed into a stream.
@@ -576,7 +573,7 @@ result = hal.query.pin("my.pin.name")
576573result = {
577574 "haltype" : "pin",
578575 "name" : "my.pin.name",
579- "type" : hal.Type.<BOOL,REAL,SINT,UINT,PORT,S32,U32 >,
576+ "type" : hal.Type.<BOOL,REAL,SINT,UINT,PORT>,
580577 "dir" : hal.Dir.<IN,OUT,IO>,
581578 "value" : <bool, int or float>,
582579 "alias" : "alias.name"|None,
@@ -597,7 +594,7 @@ result = hal.query.param("my.param.name")
597594result = {
598595 "haltype" : "parameter",
599596 "name" : "my.param.name",
600- "type" : hal.Type.<BOOL,REAL,SINT,UINT,S32,U32 >,
597+ "type" : hal.Type.<BOOL,REAL,SINT,UINT>,
601598 "dir" : hal.Dir.<RO,WR>,
602599 "value" : <bool, int or float>,
603600 "alias" : "alias.name"|None,
@@ -617,7 +614,7 @@ result = hal.query.signal("my.signal.name")
617614result = {
618615 "haltype" : "signal",
619616 "name" : "my.signal.name",
620- "type" : hal.Type.<BOOL,REAL,SINT,UINT,PORT,S32,U32 >,
617+ "type" : hal.Type.<BOOL,REAL,SINT,UINT,PORT>,
621618 "value" : <bool, int or float>,
622619 "writers" : <int>,
623620 "readers" : <int>,
0 commit comments