32 lines
774 B
C#
32 lines
774 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
|
|
namespace Deiniu.win.elelab
|
|
{
|
|
public class coms
|
|
{
|
|
internal static int com_count = 20;
|
|
public static ease[] com_manage = new ease[com_count];
|
|
internal static void initSys()
|
|
{
|
|
for (int i = 0; i < com_count; i++)
|
|
{
|
|
|
|
if (com_manage[i] == null)
|
|
com_manage[i] = new ease() ;
|
|
}
|
|
}
|
|
internal static bool initCom(int com, bool modify)
|
|
{
|
|
if (com_manage[com].port_state == false)
|
|
{
|
|
com_manage[com].init(com, modify);
|
|
return true;
|
|
}
|
|
return false;
|
|
}
|
|
}
|
|
}
|