using System.Text.Json.Serialization;
|
using System.Collections.Generic;
|
|
namespace WIDESEAWCS_S7Simulator.Core.Entities
|
{
|
/// <summary>
|
/// 内存区域配置
|
/// </summary>
|
public class MemoryRegionConfig
|
{
|
/// <summary>
|
/// M区大小(字节),默认1KB
|
/// </summary>
|
[JsonPropertyName("mRegionSize")]
|
public int MRegionSize { get; set; } = 1024;
|
|
/// <summary>
|
/// DB块数量,默认100个
|
/// </summary>
|
[JsonPropertyName("dbBlockCount")]
|
public int DBBlockCount { get; set; } = 100;
|
|
/// <summary>
|
/// 指定需要创建的 DB 块号列表(例如 50,900,901)。
|
/// 配置后只会初始化这些 DB 块。
|
/// </summary>
|
[JsonPropertyName("dbBlockNumbers")]
|
public List<int> DBBlockNumbers { get; set; } = new();
|
|
/// <summary>
|
/// 每个DB块大小(字节),默认1KB
|
/// </summary>
|
[JsonPropertyName("dbBlockSize")]
|
public int DBBlockSize { get; set; } = 1024;
|
|
/// <summary>
|
/// I区大小(字节),默认256字节
|
/// </summary>
|
[JsonPropertyName("iRegionSize")]
|
public int IRegionSize { get; set; } = 256;
|
|
/// <summary>
|
/// Q区大小(字节),默认256字节
|
/// </summary>
|
[JsonPropertyName("qRegionSize")]
|
public int QRegionSize { get; set; } = 256;
|
|
/// <summary>
|
/// T区数量,默认64个
|
/// </summary>
|
[JsonPropertyName("tRegionCount")]
|
public int TRegionCount { get; set; } = 64;
|
|
/// <summary>
|
/// C区数量,默认64个
|
/// </summary>
|
[JsonPropertyName("cRegionCount")]
|
public int CRegionCount { get; set; } = 64;
|
}
|
}
|