ModbusHelper去掉单例

This commit is contained in:
maqiao 2024-11-28 11:34:17 +08:00
parent 8ea3075d3c
commit 47d2d9c475
1 changed files with 8 additions and 0 deletions

View File

@ -35,6 +35,14 @@ namespace DM_Weight.Port
}
public static ModbusHelper GetInstance()
{
//if (instance == null)
//{
// lock (objLock)
// {
// if (instance == null)
// instance = new ModbusHelper();
// }
//}
if (instance == null)
{
lock (objLock)