Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
RC1250-ACPackingStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 61eb4022
由
LN
编写于
2019-12-20 19:38:38 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
1
1 个父辈
6b4a395d
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
20 行增加
和
123 行删除
source/Common/util/AcSerialBean.cs
source/DeviceLibrary/ACPackingStore/HumitureBean.cs
source/DeviceLibrary/ACPackingStore/StoreManager.cs
source/DeviceLibrary/StoreConfig/BoxConfig_1.csv
source/DeviceLibrary/StoreConfig/BoxConfig_2.csv
source/DeviceLibrary/StoreConfig/linePositions_1.csv
source/Common/util/AcSerialBean.cs
查看文件 @
61eb402
...
@@ -53,35 +53,7 @@ namespace OnlineStore.Common
...
@@ -53,35 +53,7 @@ namespace OnlineStore.Common
}
}
#
endregion
#
endregion
#
region
默认构造函数
///// <summary>
///// 默认构造函数,操作COM1,速度为9600,没有奇偶校验,8位字节,停止位为1 "COM1", 9600, Parity.None, 8, StopBits.One
///// </summary>
//public SerialBean()
//{
// _serialPort = new SerialPort();
//}
#
endregion
#
region
构造函数
///// <summary>
///// 构造函数,
///// </summary>
///// <param name="comPortName"></param>
//public SerialBean(string comPortName)
//{
// _serialPort = new SerialPort(comPortName);
// _serialPort.BaudRate = 9600;
// _serialPort.Parity = Parity.Even;
// _serialPort.DataBits = 8;
// _serialPort.StopBits = StopBits.One;
// _serialPort.Handshake = Handshake.None;
// _serialPort.RtsEnable = true;
// _serialPort.ReadTimeout = 2000;
// setSerialPort();
//}
#
endregion
#
region
构造函数
,
可以自定义串口的初始化参数
#
region
构造函数
,
可以自定义串口的初始化参数
/// <summary>
/// <summary>
/// 构造函数,可以自定义串口的初始化参数
/// 构造函数,可以自定义串口的初始化参数
...
@@ -224,56 +196,7 @@ namespace OnlineStore.Common
...
@@ -224,56 +196,7 @@ namespace OnlineStore.Common
}
}
#
endregion
#
endregion
#
region
发送数据
string
类型
//public void SendData(string data)
//{ //发送数据
// if (_serialPort.IsOpen)
// {
// lock (lockObj)
// {
// _serialPort.Write(data);
// System.Threading.Thread.Sleep(10);
// }
// }
//}
#
endregion
#
region
发送数据
byte
类型
///// <summary>
///// 数据发送
///// </summary>
///// <param name="data">要发送的数据字节</param>
//public void SendData(byte[] data, int offset, int count)
//{
// string strSend = "";
// for (int i = 0; i < data.Length; i++)
// {
// strSend += string.Format("{0:X2} ", data[i]);
// }
// LOGGER.Debug("【" + _serialPort.PortName + "】发送数据【" + strSend + "】");
// lock (lockObj)
// {
// try
// {
// if (_serialPort.IsOpen)
// {
// _serialPort.DiscardInBuffer();//清空接收缓冲区
// _serialPort.Write(data, offset, count);
// System.Threading.Thread.Sleep(10);
// }
// }
// catch (Exception ex)
// {
// _serialPort.DiscardOutBuffer();
// LogUtil.error(LOGGER, "SendData ERROR:" + ex.ToString(), 21);
// }
// }
//}
#
endregion
#
region
发送命令
#
region
发送命令
/// <summary>
/// <summary>
/// 发送命令
/// 发送命令
...
@@ -414,31 +337,8 @@ namespace OnlineStore.Common
...
@@ -414,31 +337,8 @@ namespace OnlineStore.Common
#
endregion
#
endregion
#
region
获取串口
/// <summary>
/// 获取所有已连接短信猫设备的串口
/// </summary>
/// <returns></returns>
public
string
[]
serialsIsConnected
()
{
List
<
string
>
lists
=
new
List
<
string
>();
string
[]
seriallist
=
getSerials
();
foreach
(
string
s
in
seriallist
)
{
}
return
lists
.
ToArray
();
}
#
endregion
#
region
获取当前全部串口资源
/// <summary>
/// 获得当前电脑上的所有串口资源
/// </summary>
/// <returns></returns>
public
string
[]
getSerials
()
{
return
SerialPort
.
GetPortNames
();
}
#
endregion
#
region
字节型转换
16
#
region
字节型转换
16
/// <summary>
/// <summary>
/// 把字节型转换成十六进制字符串
/// 把字节型转换成十六进制字符串
...
...
source/DeviceLibrary/ACPackingStore/HumitureBean.cs
查看文件 @
61eb402
...
@@ -18,10 +18,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -18,10 +18,7 @@ namespace OnlineStore.DeviceLibrary
this
.
Name
=
deviceName
;
this
.
Name
=
deviceName
;
this
.
PortName
=
port
;
this
.
PortName
=
port
;
}
}
public
bool
Init
()
{
return
HumitureController
.
Init
(
PortName
);
}
public
HumitureParam
QueryData
()
public
HumitureParam
QueryData
()
{
{
HumitureParam
param
=
HumitureController
.
QueryData
(
PortName
);
HumitureParam
param
=
HumitureController
.
QueryData
(
PortName
);
...
...
source/DeviceLibrary/ACPackingStore/StoreManager.cs
查看文件 @
61eb402
...
@@ -189,7 +189,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -189,7 +189,7 @@ namespace OnlineStore.DeviceLibrary
return
false
;
return
false
;
}
}
ShelfPosition
sp
=
CSVPositionReader
<
ShelfPosition
>.
GetPositon
(
param
.
ShelfPosID
);
ShelfPosition
sp
=
CSVPositionReader
<
ShelfPosition
>.
GetPositon
(
param
.
ShelfPosID
);
if
(
sp
==
null
&&
needCheckShelf
)
if
(
sp
==
null
&&
needCheckShelf
)
{
{
LogUtil
.
error
(
box
.
Name
+
"GetPositon["
+
param
.
ShelfPosID
+
"]=null,没有库位不能执行出入库"
);
LogUtil
.
error
(
box
.
Name
+
"GetPositon["
+
param
.
ShelfPosID
+
"]=null,没有库位不能执行出入库"
);
return
false
;
return
false
;
...
@@ -215,7 +215,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -215,7 +215,7 @@ namespace OnlineStore.DeviceLibrary
p
.
InOut_P11
=
box
.
Config
.
InOutAxis_P11_Position
;
p
.
InOut_P11
=
box
.
Config
.
InOutAxis_P11_Position
;
p
.
Middle_P11
=
box
.
Config
.
MiddleAxis_P11
;
p
.
Middle_P11
=
box
.
Config
.
MiddleAxis_P11
;
p
.
UpDown_P11
=
box
.
Config
.
UpDownAxis_P11
;
p
.
UpDown_P11
=
box
.
Config
.
UpDownAxis_P11
;
p
.
UpDown_P12
=
box
.
Config
.
UpDownAxis_P12
;
p
.
UpDown_P12
=
box
.
Config
.
UpDownAxis_P12
;
p
.
ComPress_P2
=
box
.
Config
.
GetComP2
(
position
.
BagHigh
).
TargetComP2
();
p
.
ComPress_P2
=
box
.
Config
.
GetComP2
(
position
.
BagHigh
).
TargetComP2
();
p
.
ComPress_P3
=
position
.
ComAxis_P3
;
p
.
ComPress_P3
=
position
.
ComAxis_P3
;
...
...
source/DeviceLibrary/StoreConfig/BoxConfig_1.csv
查看文件 @
61eb402
...
@@ -56,9 +56,9 @@ PRO,升降轴(轴2)P1待机点/扫码放料低点,UpDownAxis_P1,309300,,,,,,,
...
@@ -56,9 +56,9 @@ PRO,升降轴(轴2)P1待机点/扫码放料低点,UpDownAxis_P1,309300,,,,,,,
PRO,升降轴(轴2)P2扫码放料高点缓冲点,UpDownAxis_P2,415000,,,,,,,
PRO,升降轴(轴2)P2扫码放料高点缓冲点,UpDownAxis_P2,415000,,,,,,,
PRO,旋转轴(轴1)P1待机点/扫码放料点,MiddleAxis_P1,268093,,,,,,,
PRO,旋转轴(轴1)P1待机点/扫码放料点,MiddleAxis_P1,268093,,,,,,,
PRO,进出轴(轴3)P1待机点,InOutAxis_P1_Position,1000,,,,,,,
PRO,进出轴(轴3)P1待机点,InOutAxis_P1_Position,1000,,,,,,,
PRO,压紧轴(轴4)P1待机点,CompAxis_P1_Position,
100
00,,,,,,,
PRO,压紧轴(轴4)P1待机点,CompAxis_P1_Position,
979
00,,,,,,,
PRO,压紧轴(轴4)P3压紧前点,CompAxis_P3_Position,
100
00,,,,,,,
PRO,压紧轴(轴4)P3压紧前点,CompAxis_P3_Position,
979
00,,,,,,,
PRO,压紧轴(轴4)P4目标压紧点,CompAxis_P4_Position,10000,,,,,,,
PRO,压紧轴(轴4)P4目标压紧点,CompAxis_P4_Position,10000
0
,,,,,,,
PRO,压紧轴(轴4)压紧确认信号收到之后下降的位置,CompAxis_Down_Position,2000,,,,,,,
PRO,压紧轴(轴4)压紧确认信号收到之后下降的位置,CompAxis_Down_Position,2000,,,,,,,
PRO,压紧轴(轴4)P2压紧点范围对应值(8=1000;2000#),CompAxis_P2_List,8=1000;2000#12=2001;3000#16=3001;4000#20=4001;5000#22=5001;6000#24=6001;7000# ,,,,,,,
PRO,压紧轴(轴4)P2压紧点范围对应值(8=1000;2000#),CompAxis_P2_List,8=1000;2000#12=2001;3000#16=3001;4000#20=4001;5000#22=5001;6000#24=6001;7000# ,,,,,,,
,,,,,,,,,,
,,,,,,,,,,
...
@@ -92,17 +92,17 @@ PRO,升降轴(轴2)P2速度,UpDownAxis_P2_Speed,250,,,,,,,
...
@@ -92,17 +92,17 @@ PRO,升降轴(轴2)P2速度,UpDownAxis_P2_Speed,250,,,,,,,
PRO,升降轴(轴2)P3速度,UpDownAxis_P3_Speed,250,,,,,,,
PRO,升降轴(轴2)P3速度,UpDownAxis_P3_Speed,250,,,,,,,
PRO,升降轴(轴2)P4速度,UpDownAxis_P4_Speed,150,,,,,,,
PRO,升降轴(轴2)P4速度,UpDownAxis_P4_Speed,150,,,,,,,
PRO,升降轴(轴2)P5速度,UpDownAxis_P5_Speed,250,,,,,,,
PRO,升降轴(轴2)P5速度,UpDownAxis_P5_Speed,250,,,,,,,
PRO,升降轴(轴2)P6速度,UpDownAxis_P6_Speed,
1
00,,,,,,,
PRO,升降轴(轴2)P6速度,UpDownAxis_P6_Speed,
2
00,,,,,,,
PRO,升降轴(轴2)P7速度,UpDownAxis_P7_Speed,
1
00,,,,,, ,
PRO,升降轴(轴2)P7速度,UpDownAxis_P7_Speed,
2
00,,,,,, ,
PRO,升降轴(轴2)P8速度,UpDownAxis_P8_Speed,
1
00,,,,,,,
PRO,升降轴(轴2)P8速度,UpDownAxis_P8_Speed,
2
00,,,,,,,
PRO,旋转轴(轴1)P1速度,MiddleAxis_P1_Speed,120,,,,,,,
PRO,旋转轴(轴1)P1速度,MiddleAxis_P1_Speed,120,,,,,,,
PRO,旋转轴(轴1)P2速度,MiddleAxis_P2_Speed,120,,,,,,,
PRO,旋转轴(轴1)P2速度,MiddleAxis_P2_Speed,120,,,,,,,
PRO,进出轴(轴3)P1速度,InOutAxis_P1_Speed,
1
00,,,,,,,
PRO,进出轴(轴3)P1速度,InOutAxis_P1_Speed,
2
00,,,,,,,
PRO,进出轴(轴3)P2速度,InOutAxis_P2_Speed,
1
00,,,,,,,
PRO,进出轴(轴3)P2速度,InOutAxis_P2_Speed,
2
00,,,,,,,
PRO,进出轴(轴3)P3速度,InOutAxis_P3_Speed,
10
00,,,,,,,
PRO,进出轴(轴3)P3速度,InOutAxis_P3_Speed,
2
00,,,,,,,
PRO,压紧轴(轴4)P1速度,CompAxis_P1_Speed,
1
00,,,,,,,
PRO,压紧轴(轴4)P1速度,CompAxis_P1_Speed,
3
00,,,,,,,
PRO,压紧轴(轴4)P2速度,CompAxis_P2_Speed,
1
00,,,,,,,
PRO,压紧轴(轴4)P2速度,CompAxis_P2_Speed,
3
00,,,,,,,
PRO,压紧轴(轴4)P3速度,CompAxis_P3_Speed,
1
00,,,,,,,
PRO,压紧轴(轴4)P3速度,CompAxis_P3_Speed,
3
00,,,,,,,
,,,,,,,,,,
,,,,,,,,,,
PRO,升降轴(轴2)P101速度,UpDownAxis_P101_Speed,100,,,,,, ,
PRO,升降轴(轴2)P101速度,UpDownAxis_P101_Speed,100,,,,,, ,
PRO,升降轴(轴2)P102速度,UpDownAxis_P102_Speed,100,,,,,,,
PRO,升降轴(轴2)P102速度,UpDownAxis_P102_Speed,100,,,,,,,
...
...
source/DeviceLibrary/StoreConfig/BoxConfig_2.csv
查看文件 @
61eb402
...
@@ -96,7 +96,7 @@ PRO,旋转轴(轴1)P1速度,MiddleAxis_P1_Speed,120,,,,,,,
...
@@ -96,7 +96,7 @@ PRO,旋转轴(轴1)P1速度,MiddleAxis_P1_Speed,120,,,,,,,
PRO,旋转轴(轴1)P2速度,MiddleAxis_P2_Speed,120,,,,,,,
PRO,旋转轴(轴1)P2速度,MiddleAxis_P2_Speed,120,,,,,,,
PRO,进出轴(轴3)P1速度,InOutAxis_P1_Speed,100,,,,,,,
PRO,进出轴(轴3)P1速度,InOutAxis_P1_Speed,100,,,,,,,
PRO,进出轴(轴3)P2速度,InOutAxis_P2_Speed,100,,,,,,,
PRO,进出轴(轴3)P2速度,InOutAxis_P2_Speed,100,,,,,,,
PRO,进出轴(轴3)P3速度,InOutAxis_P3_Speed,100
0
,,,,,,,
PRO,进出轴(轴3)P3速度,InOutAxis_P3_Speed,100,,,,,,,
PRO,压紧轴(轴4)P1速度,CompAxis_P1_Speed,100,,,,,,,
PRO,压紧轴(轴4)P1速度,CompAxis_P1_Speed,100,,,,,,,
PRO,压紧轴(轴4)P2速度,CompAxis_P2_Speed,100,,,,,,,
PRO,压紧轴(轴4)P2速度,CompAxis_P2_Speed,100,,,,,,,
PRO,压紧轴(轴4)P3速度,CompAxis_P3_Speed,100,,,,,,,
PRO,压紧轴(轴4)P3速度,CompAxis_P3_Speed,100,,,,,,,
...
...
source/DeviceLibrary/StoreConfig/linePositions_1.csv
查看文件 @
61eb402
此文件的差异被折叠,
点击展开。
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论