docs(s7): wide-type/Timer-Counter support — CLI help + driver-specs + S7 driver doc
Drop the "not yet implemented / BadNotSupported" stale note from all three S7 CLI --type option descriptions (ReadCommand, WriteCommand, SubscribeCommand) and replace with accurate help listing the full supported type set, byte-anchored addressing for wide types, and Timer/Counter read-only status. docs/v2/driver-specs.md §5: add Supported Data Types table, Byte-Anchored Addressing table (DBB/MB/IB/QB + examples), Timer/Counter read section with the Counter-BCD known-limitation, and Deferrals list. docs/drivers/S7.md: expand Data types to a full table, add "Wide types & Timer/Counter" section (byte-anchored addressing, Timer/Counter read-only, Counter BCD known-limitation, deferrals), update Address forms table and 1-D array Deferrals note.
This commit is contained in:
@@ -20,13 +20,13 @@ public sealed class ReadCommand : S7CommandBase
|
||||
IsRequired = true)]
|
||||
public string Address { get; init; } = default!;
|
||||
|
||||
// Driver.S7.Cli-002: help text trimmed to the types the driver actually implements.
|
||||
// Int64 / UInt64 / Float64 / String / DateTime are defined in S7DataType but the driver
|
||||
// raises NotSupportedException (→ BadNotSupported) on reads of those types.
|
||||
// Driver.S7.Cli-002: help text reflects the types the driver currently implements.
|
||||
/// <summary>Gets the data type to interpret the address as.</summary>
|
||||
[CommandOption("type", 't', Description =
|
||||
"Bool / Byte / Int16 / UInt16 / Int32 / UInt32 / Float32 (default Int16). " +
|
||||
"Int64, UInt64, Float64, String, and DateTime are not yet implemented and will return BadNotSupported.")]
|
||||
"Bool / Byte / Int16 / UInt16 / Int32 / UInt32 / Float32 / Int64 / UInt64 / Float64 / String / DateTime (default Int16). " +
|
||||
"Wide types (Int64, UInt64, Float64/LReal, String, DateTime) are byte-anchored: address must use the B suffix " +
|
||||
"(e.g. DB1.DBB8, MB4) pointing at the first byte; width comes from the DataType. " +
|
||||
"Timer (T{n}) reads elapsed seconds as Float64 (read-only). Counter (C{n}) reads the count as Int32 (read-only).")]
|
||||
public S7DataType DataType { get; init; } = S7DataType.Int16;
|
||||
|
||||
/// <summary>Gets the maximum string length for string-type reads.</summary>
|
||||
|
||||
@@ -17,10 +17,12 @@ public sealed class SubscribeCommand : S7CommandBase
|
||||
public string Address { get; init; } = default!;
|
||||
|
||||
/// <summary>Gets the data type of the address.</summary>
|
||||
// Driver.S7.Cli-002: help text trimmed to the types the driver actually implements.
|
||||
// Driver.S7.Cli-002: help text reflects the types the driver currently implements.
|
||||
[CommandOption("type", 't', Description =
|
||||
"Bool / Byte / Int16 / UInt16 / Int32 / UInt32 / Float32 (default Int16). " +
|
||||
"Int64, UInt64, Float64, String, and DateTime are not yet implemented and will return BadNotSupported.")]
|
||||
"Bool / Byte / Int16 / UInt16 / Int32 / UInt32 / Float32 / Int64 / UInt64 / Float64 / String / DateTime (default Int16). " +
|
||||
"Wide types (Int64, UInt64, Float64/LReal, String, DateTime) are byte-anchored: address must use the B suffix " +
|
||||
"(e.g. DB1.DBB8, MB4) pointing at the first byte; width comes from the DataType. " +
|
||||
"Timer (T{n}) reads elapsed seconds as Float64 (read-only). Counter (C{n}) reads the count as Int32 (read-only).")]
|
||||
public S7DataType DataType { get; init; } = S7DataType.Int16;
|
||||
|
||||
/// <summary>Gets the polling interval in milliseconds.</summary>
|
||||
|
||||
@@ -20,13 +20,12 @@ public sealed class WriteCommand : S7CommandBase
|
||||
public string Address { get; init; } = default!;
|
||||
|
||||
/// <summary>Gets or sets the data type of the value to write.</summary>
|
||||
// Driver.S7.Cli-002: help text trimmed to the types the driver actually implements.
|
||||
// Int64 / UInt64 / Float64 / String / DateTime are defined in S7DataType but the driver
|
||||
// raises NotSupportedException (→ BadNotSupported) on any read/write of those types;
|
||||
// advertising them misleads operators who then see BadNotSupported with no explanation.
|
||||
// Driver.S7.Cli-002: help text reflects the types the driver currently implements.
|
||||
[CommandOption("type", 't', Description =
|
||||
"Bool / Byte / Int16 / UInt16 / Int32 / UInt32 / Float32 (default Int16). " +
|
||||
"Int64, UInt64, Float64, String, and DateTime are not yet implemented and will return BadNotSupported.")]
|
||||
"Bool / Byte / Int16 / UInt16 / Int32 / UInt32 / Float32 / Int64 / UInt64 / Float64 / String / DateTime (default Int16). " +
|
||||
"Wide types (Int64, UInt64, Float64/LReal, String, DateTime) are byte-anchored: address must use the B suffix " +
|
||||
"(e.g. DB1.DBB8, MB4) pointing at the first byte; width comes from the DataType. " +
|
||||
"Timer (T{n}) and Counter (C{n}) are read-only — writes to them return BadNotWritable.")]
|
||||
public S7DataType DataType { get; init; } = S7DataType.Int16;
|
||||
|
||||
/// <summary>Gets or sets the value to write.</summary>
|
||||
|
||||
Reference in New Issue
Block a user