Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
ACSingleStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit d5595c80
由
几米阳光
编写于
2018-09-14 11:09:32 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
轴三复位时,如果已经原点返回过且原点信号亮,需要先向前走一点再原点返回
1 个父辈
9a6597be
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
13 个修改的文件
包含
137 行增加
和
283 行删除
source/ACSingleStore/ACSingleStore.csproj
source/ACSingleStore/App.config
source/ACSingleStore/FrmStoreBox.Designer.cs
source/ACSingleStore/FrmStoreBox.cs
source/ACSingleStore/记录.txt
source/Common/Setting_Init.cs
source/DeviceLibrary/PanasonicServo/ACCMDManager.cs
source/DeviceLibrary/PanasonicServo/ACServerManager.cs
source/DeviceLibrary/PanasonicServo/ACServerManager_Partial.cs
source/DeviceLibrary/StoreConfig/AC/StoreConfig.csv
source/DeviceLibrary/StoreConfig/AC/linePositions.csv
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean.cs
source/DeviceLibrary/store/StoreManager.cs
source/ACSingleStore/ACSingleStore.csproj
查看文件 @
d5595c8
...
...
@@ -85,12 +85,6 @@
<Compile Include="FrmIOStatus.Designer.cs">
<DependentUpon>FrmIOStatus.cs</DependentUpon>
</Compile>
<Compile Include="FrmLogin.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmLogin.Designer.cs">
<DependentUpon>FrmLogin.cs</DependentUpon>
</Compile>
<Compile Include="FrmStoreBox.cs">
<SubType>Form</SubType>
</Compile>
...
...
@@ -112,9 +106,6 @@
<EmbeddedResource Include="FrmIOStatus.resx">
<DependentUpon>FrmIOStatus.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmLogin.resx">
<DependentUpon>FrmLogin.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmStoreBox.resx">
<DependentUpon>FrmStoreBox.cs</DependentUpon>
</EmbeddedResource>
...
...
source/ACSingleStore/App.config
查看文件 @
d5595c8
<?
xml
version
=
"1.0"
?>
<
configuration
>
<
configSections
>
<
section
name
=
"log4net"
type
=
"log4net.Config.Log4NetConfigurationSectionHandler,log4net"
/>
<
section
name
=
"log4net"
type
=
"log4net.Config.Log4NetConfigurationSectionHandler,log4net"
/>
</
configSections
>
<
appSettings
>
<!--是否开机自动启动料仓-->
<
add
key
=
"App_AutoRun"
value
=
"
0"
/>
<
add
key
=
"App_Title"
value
=
"AC_SA_料仓"
/>
<
add
key
=
"scanner_start_command"
value
=
"S"
/>
<
add
key
=
"App_AutoRun"
value
=
"
1"
/>
<
add
key
=
"App_Title"
value
=
"AC_SA_料仓"
/>
<
add
key
=
"scanner_start_command"
value
=
"S"
/>
<!-- 开始吹气的判断值(配置值=服务器发送的湿度值-开始吹气值)-->
<
add
key
=
"StartBlowValue"
value
=
"4"
/>
<
add
key
=
"StartBlowValue"
value
=
"4"
/>
<!-- 停止吹气的判断值(配置值=服务器发送的湿度值-停止吹气值)-->
<
add
key
=
"StopBlowValue"
value
=
"4"
/>
<
add
key
=
"StopBlowValue"
value
=
"4"
/>
<!--
Server
address
-->
<!--<
add
key
=
"http.server"
value
=
"http://localhost:80/"
/>-->
<!--
storeType
-->
<
add
key
=
"store_count"
value
=
"1"
/>
<
add
key
=
"store_count"
value
=
"1"
/>
<!--
start
one
store
config
-->
<
add
key
=
"Store_Position_Config"
value
=
"\StoreConfig\AC\linePositions.csv"
/>
<
add
key
=
"Store_ConfigPath"
value
=
"\StoreConfig\AC\StoreConfig.csv"
/>
<
add
key
=
"Store_Type"
value
=
"RC_AC_SA"
/>
<
add
key
=
"Store_CID"
value
=
"
ac1"
/>
<
add
key
=
"Store_Position_Config"
value
=
"\StoreConfig\AC\linePositions.csv"
/>
<
add
key
=
"Store_ConfigPath"
value
=
"\StoreConfig\AC\StoreConfig.csv"
/>
<
add
key
=
"Store_Type"
value
=
"RC_AC_SA"
/>
<
add
key
=
"Store_CID"
value
=
"
bjac1"
/>
<!--
end
one
store
config
-->
<!--康泰克运动默认参数:速度倍率,起始速度,目标速度,加速时间,减速时间,
SSpeed
,目标位置,默认运动轴-->
<
add
key
=
"KTK_MOVE_ResolveSpeed"
value
=
"10"
/>
<
add
key
=
"KTK_MOVE_StartSpeed"
value
=
"1000"
/>
<
add
key
=
"KTK_MOVE_TargetSpeed"
value
=
"20000"
/>
<
add
key
=
"KTK_MOVE_AccelTime"
value
=
"500"
/>
<
add
key
=
"KTK_MOVE_lDecelTime"
value
=
"500"
/>
<
add
key
=
"KTK_MOVE_SSpeed"
value
=
"5000"
/>
<
add
key
=
"KTK_MOVE_Distance"
value
=
"10000"
/>
<
add
key
=
"KTK_MOVE_AxisNo"
value
=
"1"
/>
<!--摄像机名称列表配置,用
#分割-->
<
add
key
=
"CameraName"
value
=
"codeCamera"
/>
<!--摄像机名称列表配置,用
#分割-->
<
add
key
=
"CameraName"
value
=
"codeCamera"
/>
<!--二维码类型列表配置,用
#分割-->
<
add
key
=
"CodeType"
value
=
"QR Code"
/>
<
add
key
=
"CodeType"
value
=
"QR Code"
/>
<!--<
add
key
=
"CodeType"
value
=
"Data Matrix ECC 200"
/>-->
<!--二维码参数文件所在路径,文件名与二维码类型名一样-->
<
add
key
=
"CodeParamPath"
value
=
"\StoreConfig\AC\"
/>
<
add
key
=
"CodeParamPath"
value
=
"\StoreConfig\AC\"
/>
</
appSettings
>
<
log4net
>
<
appender
name
=
"RollingLogFileAppender"
type
=
"log4net.Appender.RollingFileAppender"
>
<
file
value
=
"logs/
SingleStore.log"
/>
<
appendToFile
value
=
"true"
/>
<
rollingStyle
value
=
"Date"
/>
<
datePattern
value
=
"yyyy-MM-dd"
/>
<
layout
type
=
"log4net.Layout.PatternLayout"
>
<
conversionPattern
value
=
"[%date][%t]%-5p %m%n"
/>
<
file
value
=
"logs/
BJACStore.log"
/>
<
appendToFile
value
=
"true"
/>
<
rollingStyle
value
=
"Date"
/>
<
datePattern
value
=
"yyyy-MM-dd"
/>
<
layout
type
=
"log4net.Layout.PatternLayout"
>
<
conversionPattern
value
=
"[%date][%t]%-5p %m%n"
/>
</
layout
>
</
appender
>
<
root
>
<
level
value
=
"Info"
/>
<
appender
-
ref
ref
=
"RollingLogFileAppender"
/>
<
level
value
=
"Info"
/>
<
appender
-
ref
ref
=
"RollingLogFileAppender"
/>
</
root
>
</
log4net
>
<
startup
>
<
supportedRuntime
version
=
"v4.0"
sku
=
".NETFramework,Version=v4.
0"
/>
<
supportedRuntime
version
=
"v4.0"
sku
=
".NETFramework,Version=v4.
6.1"
/>
</
startup
>
<!-- 部署服务库项目时,必须将配置文件的内容添加到
主机的
app
.
config
文件中。
System
.
Configuration
不支持库的配置文件。 -->
<
system
.
serviceModel
>
...
...
@@ -69,13 +56,13 @@
<
service
name
=
"AcStoreWCF.CWSMDBox"
>
<
endpoint
address
=
""
binding
=
"basicHttpBinding"
contract
=
"AcStoreWCF.ICWSMDBox"
>
<
identity
>
<
dns
value
=
"localhost"
/>
<
dns
value
=
"localhost"
/>
</
identity
>
</
endpoint
>
<
endpoint
address
=
"mex"
binding
=
"mexHttpBinding"
contract
=
"IMetadataExchange"
/>
<
endpoint
address
=
"mex"
binding
=
"mexHttpBinding"
contract
=
"IMetadataExchange"
/>
<
host
>
<
baseAddresses
>
<
add
baseAddress
=
"http://localhost:8733/Design_Time_Addresses/AcStoreWCF/CWSMDBox/"
/>
<
add
baseAddress
=
"http://localhost:8733/Design_Time_Addresses/AcStoreWCF/CWSMDBox/"
/>
</
baseAddresses
>
</
host
>
</
service
>
...
...
@@ -85,13 +72,13 @@
<
behavior
>
<!-- 为避免泄漏元数据信息,
请在部署前将以下值设置为
false
-->
<
serviceMetadata
httpGetEnabled
=
"True"
httpsGetEnabled
=
"True"
/>
<
serviceMetadata
httpGetEnabled
=
"True"
httpsGetEnabled
=
"True"
/>
<!-- 要接收故障异常详细信息以进行调试,
请将以下值设置为
true
。在部署前设置为
false
以避免泄漏异常信息 -->
<
serviceDebug
includeExceptionDetailInFaults
=
"False"
/>
<
serviceDebug
includeExceptionDetailInFaults
=
"False"
/>
</
behavior
>
</
serviceBehaviors
>
</
behaviors
>
</
system
.
serviceModel
>
</
configuration
>
</
configuration
>
\ No newline at end of file
source/ACSingleStore/FrmStoreBox.Designer.cs
查看文件 @
d5595c8
此文件的差异被折叠,
点击展开。
source/ACSingleStore/FrmStoreBox.cs
查看文件 @
d5595c8
...
...
@@ -1226,5 +1226,11 @@ namespace OnlineStore.ACSingleStore
FrmCodeLearn
learn
=
new
FrmCodeLearn
();
learn
.
ShowDialog
();
}
private
void
btnReadHomeSingle_Click
(
object
sender
,
EventArgs
e
)
{
int
value
=
ACServerManager
.
GetHomeSingle
(
GetPortName
(),
GetSlaveAddr
());
this
.
txtHomeSingle
.
Text
=
value
.
ToString
();
}
}
}
source/ACSingleStore/记录.txt
查看文件 @
d5595c8
...
...
@@ -12,4 +12,6 @@
料叉上的信号检测:复位时不检测此信号,等到复位完成再检测,如果料仓有信号,需要打开门让人把物料拿走
轴三运动时要判断气缸到位
\ No newline at end of file
轴三运动时要判断气缸到位
出库时等待拿走料盘与等待10秒有一个条件到达就完成
轴三复位时,如果已经原点返回过且原点信号亮,需要先相对走5000才能原点返回
\ No newline at end of file
source/Common/Setting_Init.cs
查看文件 @
d5595c8
...
...
@@ -19,81 +19,14 @@ namespace OnlineStore.Common
/// <summary>
/// 系统主界面标题
/// </summary>
public
static
string
App_Title
=
"App_Title"
;
/// <summary>
/// 配置表中表示料门位置的层数
/// </summary>
public
static
int
modbus_door_num
=
1000
;
public
static
string
modbus_door_high_position
=
"modbus_door_high_position"
;
public
static
string
modbus_door_low_position
=
"modbus_door_low_position"
;
//电钢配置
/// <summary>
/// 串口号
/// </summary>
public
static
string
modbus_portName
=
"modbus_portName"
;
/// <summary>
/// 波特率
/// </summary>
public
static
string
modbus_portBaudrate
=
"modbus_portBaudrate"
;
/// <summary>
/// 奇偶校验
/// </summary>
public
static
string
modbus_portParity
=
"modbus_portParity"
;
/// <summary>
/// 停止位
/// </summary>
public
static
string
modbus_stopBits
=
"modbus_stopBits"
;
/// <summary>
/// 控制模式
/// </summary>
public
static
string
modbus_controlMode
=
"modbus_controlMode"
;
/// <summary>
/// 移动位置
/// </summary>
public
static
string
modbus_position
=
"modbus_position"
;
/// <summary>
/// 移动速度
/// </summary>
public
static
string
modbus_velocity
=
"modbus_velocity"
;
/// <summary>
/// 板卡卡号
/// </summary>
public
static
string
pci_board_id
=
"pci_board_id"
;
/// <summary>
/// 板卡运动默认速度
/// </summary>
public
static
string
pci_axis_move_speed
=
"pci_axis_move_speed"
;
/// <summary>
/// 电缸运动默认速度
/// </summary>
public
static
string
modbus_move_speed
=
"modbus_move_speed"
;
public
static
string
App_Title
=
"App_Title"
;
/// <summary>
/// 扫码枪开始命令发送给socket的消息
/// </summary>
public
static
string
scanner_start_command
=
"scanner_start_command"
;
/// <summary>
/// 预警温度
/// </summary>
public
static
string
alert_temperate
=
"alert.temperate"
;
/// <summary>
/// 预警湿度
/// </summary>
public
static
string
alert_humidity
=
"alert.humidity"
;
/// <summary>
/// 温度传感器端口号
/// </summary>
public
static
string
temperate_port
=
"temperate.port"
;
public
static
string
ClientSettingsProvider_ServiceUri
=
"ClientSettingsProvider.ServiceUri"
;
public
static
string
app_cid
=
"app.cid"
;
public
static
string
plc_no
=
"plc.no"
;
public
static
string
http_server
=
"http.server"
;
public
static
string
Store_CID
=
"Store_CID"
;
/// <summary>
/// 料仓数量
...
...
@@ -103,107 +36,9 @@ namespace OnlineStore.Common
/// 料仓类型,1=在线料仓
/// </summary>
public
static
string
Store_Type
=
"Store_Type"
;
/// <summary>
/// l料仓上下运动轴(轴或者电钢从站地址)
/// </summary>
public
static
string
Store_UpDown_AxisOrSlv
=
"Store_UpDown_AxisOrSlv"
;
/// <summary>
/// 料仓对应料盘旋转轴,中轴
/// </summary>
public
static
string
Store_Middle_Rotate_AxisNo
=
"Store_Middle_Rotate_AxisNo"
;
/// <summary>
/// 料仓对应扫码枪IP
/// </summary>
public
static
string
Store_Scanner_IP
=
"Store_Scanner_IP"
;
/// <summary>
/// 料仓对应扫码枪端口
/// </summary>
public
static
string
Store_Scanner_Port
=
"Store_Scanner_Port"
;
/// <summary>
/// 料仓对应温湿度传感器的地址(多个)
/// </summary>
public
static
string
Store_Temperate_ServerAddress
=
"Store_Temperate_ServerAddress"
;
public
static
string
Store_ForwardMove_DI
=
"Store_ForwardMove_DI"
;
public
static
string
Store_BackMove_DI
=
"Store_BackMove_DI"
;
public
static
string
Store_RotateMove_DI
=
"Store_RotateMove_DI"
;
public
static
string
Store_ReturnHome_DI
=
"Store_ReturnHome_DI"
;
public
static
string
Store_DoorUpSOL_DI
=
"Store_DoorUpSOL_DI"
;
public
static
string
Store_DoorDownSOL_DI
=
"Store_DoorDownSOL_DI"
;
public
static
string
Store_ForwardMove_DO
=
"Store_ForwardMove_DO"
;
public
static
string
Store_BackMove_DO
=
"Store_BackMove_DO"
;
public
static
string
Store_RotateMove_DO
=
"Store_RotateMove_DO"
;
public
static
string
Store_ReturnHome_DO
=
"Store_ReturnHome_DO"
;
public
static
string
Store_DoorUpSOL_DO
=
"Store_DoorUpSOL_DO"
;
public
static
string
Store_DoorDownSOL_DO
=
"Store_DoorDownSOL_DO"
;
public
static
string
Store_StartOrStopBlow_DO
=
"Store_StartOrStopBlow_DO"
;
public
static
string
Store_DoorSignal_DI
=
"Store_DoorSignal_DI"
;
public
static
string
Store_Board_Id
=
"Store_Board_Id"
;
public
static
string
Store_CID
=
"Store_CID"
;
public
static
string
Store_Run_Sign
=
"Store_Run_Sign"
;
//设备运行可
public
static
string
Store_AutoRun_HddLed
=
"Store_AutoRun_HddLed"
;
//设备自动运行指示灯
public
static
string
Store_Alarm_HddLed
=
"Store_Alarm_HddLed"
;
//设备报警指示灯
public
static
string
Store_SuddenStop_BTN
=
"Store_SuddenStop_BTN"
;
//设备急停按钮
public
static
string
Store_Reset_BTN
=
"Store_Reset_BTN"
;
//设备复位按钮
public
static
string
Store_MiddleAxis_Move_Speed
=
"Store_MiddleAxis_Move_Speed"
;
//中轴转动速度
public
static
string
Store_Updown_Move_Speed
=
"Store_Updown_Move_Speed"
;
//上下轴移动速度
public
static
string
Store_Updown_Move_Speed_Low
=
"Store_Updown_Move_Speed_Low"
;
//上下轴慢运动速度(托起料盘和放下料盘使用此速度)
//以下为康塔克料仓特殊配置
public
static
string
Store_PI_BoardName
=
"Store_PI_BoardName"
;
public
static
string
Store_PO_BoardName
=
"Store_PO_BoardName"
;
public
static
string
Store_Middle_BoardName
=
"Store_Middle_BoardName"
;
public
static
string
Store_UpDown_BoardName
=
"Store_UpDown_BoardName"
;
/// <summary>
/// 康泰克IO输入卡名称
/// </summary>
public
static
string
KTK_PI_BoardName
=
"KTK_PI_BoardName"
;
/// <summary>
/// 康泰克IO输出卡名称
/// </summary>
public
static
string
KTK_PO_BoardName
=
"KTK_PO_BoardName"
;
/// <summary>
/// 康泰克运动版卡名称
/// </summary>
public
static
string
KTK_SMC_BoardName
=
"KTK_SMC_BoardName"
;
public
static
string
KTK_MOVE_ResolveSpeed
=
"KTK_MOVE_ResolveSpeed"
;
public
static
string
KTK_MOVE_StartSpeed
=
"KTK_MOVE_StartSpeed"
;
public
static
string
KTK_MOVE_TargetSpeed
=
"KTK_MOVE_TargetSpeed"
;
public
static
string
KTK_MOVE_AccelTime
=
"KTK_MOVE_AccelTime"
;
public
static
string
KTK_MOVE_lDecelTime
=
"KTK_MOVE_lDecelTime"
;
public
static
string
KTK_MOVE_SSpeed
=
"KTK_MOVE_SSpeed"
;
public
static
string
KTK_MOVE_Distance
=
"KTK_MOVE_Distance"
;
public
static
string
KTK_MOVE_AxisNo
=
"KTK_MOVE_AxisNo"
;
//以下为流水线料仓的配置
public
static
string
Store_ConfigPath
=
"Store_ConfigPath"
;
public
static
string
Store_Position_Config
=
"Store_Position_Config"
;
public
static
string
UserName
=
"UserName"
;
public
static
string
UserPwd
=
"UserPwd"
;
//双层在线料仓新加配置
public
static
string
ManchineID
=
"ManchineID"
;
public
static
string
RemoteURL
=
"RemoteURL"
;
public
static
string
RemoteUsername
=
"RemoteUsername"
;
public
static
string
RemotePassword
=
"RemotePassword"
;
/// <summary>
/// 过滤 条件
/// </summary>
public
static
string
FileListerFilter
=
"FileListerFilter"
;
public
static
string
ProgramConfig
=
"ProgramConfig"
;
public
static
string
RemoteWriteURL
=
"RemoteWriteURL"
;
public
static
string
LineNoWaitSingle
=
"LineNoWaitSingle"
;
public
static
string
TheLineId
=
"TheLineId"
;
public
static
string
File_UpdateTime
=
"File_UpdateTime"
;
/// <summary>
/// 摄像机名称,多个中间使用#分割
/// </summary>
...
...
@@ -212,10 +47,7 @@ namespace OnlineStore.Common
/// 需要识别的二维码类型,多个中间使用#分割
/// </summary>
public
static
string
CodeType
=
"CodeType"
;
/// <summary>
/// 当叉子不在待机位,升降轴可以走的最远距离,目标距离-当前距离的最大值,超过此值不允许升降
/// </summary>
public
static
string
UpdownMaxValue
=
"UpdownMaxValue"
;
/// <summary>
/// 开始吹气的判断值(配置值=服务器发送的湿度值-开始吹气值)
/// </summary>
...
...
@@ -229,7 +61,6 @@ namespace OnlineStore.Common
/// 配置文件路径 Data Matrix ECC 200.dcm
/// </summary>
public
static
string
CodeParamPath
=
"CodeParamPath"
;
}
}
source/DeviceLibrary/PanasonicServo/ACCMDManager.cs
查看文件 @
d5595c8
...
...
@@ -8,6 +8,11 @@ namespace OnlineStore.DeviceLibrary
public
class
ACCMDManager
{
/// <summary>
/// 0132h 原点接近传感器输入 (HOME) 状态 ReadOnly 0: 输入 OFF 1: 输入 ON
/// </summary>
public
static
string
Home_Single
=
"0132"
;
/// <summary>
///速度 4601
/// </summary>
public
static
string
Speed_Addr
=
"4601"
;
...
...
source/DeviceLibrary/PanasonicServo/ACServerManager.cs
查看文件 @
d5595c8
...
...
@@ -301,17 +301,17 @@ namespace OnlineStore.DeviceLibrary
if
(
portName
.
Equals
(
ACStoreManager
.
store
.
Config
.
Middle_Axis
.
DeviceName
))
{
UpdateBlock
(
portName
,
slvAddr
,
ACCMDManager
.
Block_HomeMove0
);
LogUtil
.
debug
(
"旋转轴原点返回方向:正方向"
);
LogUtil
.
info
(
"旋转轴原点返回方向:正方向"
);
}
else
if
(
portName
.
Equals
(
ACStoreManager
.
store
.
Config
.
InOut_Axis
.
DeviceName
))
{
UpdateBlock
(
portName
,
slvAddr
,
ACCMDManager
.
Block_HomeMove0
);
LogUtil
.
debug
(
"进出轴原点返回方向:正方向"
);
LogUtil
.
info
(
"进出轴原点返回方向:正方向"
);
}
else
{
UpdateBlock
(
portName
,
slvAddr
,
ACCMDManager
.
Block_HomeMove1
);
LogUtil
.
debug
(
"升降轴原点返回方向:反方向"
);
LogUtil
.
info
(
"升降轴原点返回方向:反方向"
);
}
Thread
.
Sleep
(
SleepMSendons
);
OpenAndCloseSTB
(
portName
,
slvAddr
);
...
...
source/DeviceLibrary/PanasonicServo/ACServerManager_Partial.cs
查看文件 @
d5595c8
...
...
@@ -484,6 +484,14 @@ namespace OnlineStore.DeviceLibrary
return
GetCoilData
(
portName
,
reviceData
,
ACCMDManager
.
HOME_CMP_Status
);
}
public
static
int
GetHomeSingle
(
string
portName
,
int
slvAddr
)
{
PreReadCoilAddr
=
ACCMDManager
.
Home_Single
;
byte
[]
dataArray
=
ACCMDManager
.
GetWriteData
(
slvAddr
,
ACCMDManager
.
CMD_ReadCoil
,
ACCMDManager
.
Home_Single
,
"0000"
,
1
);
byte
[]
reviceData
=
SendCommand
(
portName
,
dataArray
,
100
,
6
);
return
GetCoilData
(
portName
,
reviceData
,
ACCMDManager
.
Home_Single
);
}
}
/// <summary>
/// 记录最后一次获得的寄存器的值
...
...
source/DeviceLibrary/StoreConfig/AC/StoreConfig.csv
查看文件 @
d5595c8
...
...
@@ -37,14 +37,13 @@ AXIS,(轴三)进出轴,InOut_Axis,1,COM5,0,,,,
PRO,温湿度传感器地址,Temperate_ServerAddress,192.168.200.14,,,,,,
PRO,扫码枪IP,Scanner_Ip,192.168.200.13,,,,,,
PRO,扫码枪端口号,Scanner_Port,51236,,,,,,
PRO,升降轴 进料口取料点 P1,UpDownAxis_DoorOPosition_P1,687000,,,,,,
PRO,升降轴 进料口出料前点 P2,UpDownAxis_DoorIPosition_P2,705000,,,,,,
PRO,升降轴 进料口取料缓冲点 P7,UpDownAxis_DoorOBPosition_P7,705000,,,,,,
PRO,升降轴 进料口出料缓冲点 P8,UpDownAxis_DoorIBPosition_P8,688000,,,,,,
,进出轴进料口取料点 P2,InOutAxis_DoorPosition_P2,28500,,,,,,
PRO,旋转轴(轴1)P1 待机原位点,MiddleAxis_P1_Position,229500,,,,,,
PRO,进出轴(轴3)P1待机原位点,InOutAxis_P1_Position,-4800,,,,,,
PRO,押金轴(轴4)P1待机原位点,CompressAxis_P1_Position,360,,,,,,
PRO,升降轴 进料口取料点 P1,UpDownAxis_DoorOPosition_P1,421300,,,,,,
PRO,升降轴 进料口出料前点 P2,UpDownAxis_DoorIPosition_P2,452000,,,,,,
PRO,升降轴 进料口取料缓冲点 P7,UpDownAxis_DoorOBPosition_P7,452000,,,,,,
PRO,升降轴 进料口出料缓冲点 P8,UpDownAxis_DoorIBPosition_P8,421300,,,,,,
PRO,旋转轴(轴1)P1 待机原位点,MiddleAxis_P1_Position,-200450,,,,,,
PRO,进出轴(轴3)P1待机原位点,InOutAxis_P1_Position,500,,,,,,
PRO,押金轴(轴4)P1待机原位点,CompressAxis_P1_Position,0,,,,,,
PRO,是否使用定位气缸,IsHasLocationCylinder,1,,,,,,
PRO,是否有左右侧门,IsHasDoorLimit,0,,,,,,
PRO,是否使用压紧轴(1=使用),IsHasCompress_Axis,0,,,,, ,
...
...
@@ -54,36 +53,36 @@ PRO,温湿度传感器地址,TemperateServer_Port,9001,,,,,,
PRO,预警温度,WarnTemperate,80,,,,,,
PRO,预警湿度,WarnHumidity,80,,,,,,
PRO,(轴一)旋转轴目标速度,MiddleAxis_TargetSpeed,40,,,,,,
PRO,(轴一)旋转轴加速度,MiddleAxis_AddSpeed,
5
000,,,,,,
PRO,(轴一)旋转轴减速度,MiddleAxis_DelSpeed,
5
000,,,,,,
PRO,(轴一)旋转轴原点低速度,MiddleAxis_HomeLowSpeed,
1
0,,,,,,
PRO,(轴一)旋转轴加速度,MiddleAxis_AddSpeed,
2
000,,,,,,
PRO,(轴一)旋转轴减速度,MiddleAxis_DelSpeed,
2
000,,,,,,
PRO,(轴一)旋转轴原点低速度,MiddleAxis_HomeLowSpeed,
80
0,,,,,,
PRO,(轴一)旋转轴原点高速,MiddleAxis_HomeHighSpeed,60,,,,,,
PRO,(轴一)旋转轴原点加速度,MiddleAxis_HomeAddSpeed,500,,,,,,
PRO,(轴二)升降轴轴目标速度,UpdownAxis_TargetSpeed,40,,,,,,
PRO,(轴二)升降轴轴加速度,UpdownAxis_AddSpeed,
3
00,,,,,,
PRO,(轴二)升降轴轴减速度,UpdownAxis_DelSpeed,
3
00,,,,,,
PRO,(轴二)升降轴轴加速度,UpdownAxis_AddSpeed,
10
00,,,,,,
PRO,(轴二)升降轴轴减速度,UpdownAxis_DelSpeed,
10
00,,,,,,
PRO,(轴二)升降轴轴原点低速度,UpdownAxis_HomeLowSpeed,100,,,,,,
PRO,(轴二)升降轴轴原点高速,UpdownAxis_HomeHighSpeed,200,,,,,,
PRO,(轴二)升降轴轴原点加速度,UpdownAxis_HomeAddSpeed,200,,,,,,
PRO,(轴三)进出轴目标速度,InoutAxis_TargetSpeed,40,,,,,,
PRO,(轴三)进出轴加速度,InoutAxis_AddSpeed,
3
00,,,,,,
PRO,(轴三)进出轴减速度,InoutAxis_DelSpeed,
3
00,,,,,,
PRO,(轴三)进出轴加速度,InoutAxis_AddSpeed,
15
00,,,,,,
PRO,(轴三)进出轴减速度,InoutAxis_DelSpeed,
15
00,,,,,,
PRO,(轴三)进出轴原点低速,InoutAxis_HomeLowSpeed,20,,,,,,
PRO,(轴三)进出轴原点高速,InoutAxis_HomeHighSpeed,60,,,,,,
PRO,(轴三)进出轴原点加速度,InoutAxis_HomeAddSpeed,200,,,,,,
PRO,升降轴(轴2)P1速度,UpDownAxis_P1_Speed,
12
00,,,,,,
PRO,升降轴(轴2)P2速度,UpDownAxis_P2_Speed,
10
00,,,,,,
PRO,升降轴(轴2)P3速度,UpDownAxis_P3_Speed,
10
00,,,,,,
PRO,升降轴(轴2)P4速度,UpDownAxis_P4_Speed,
3
00,,,,,,
PRO,升降轴(轴2)P5速度,UpDownAxis_P5_Speed,
10
00,,,,,,
PRO,升降轴(轴2)P6速度,UpDownAxis_P6_Speed,
3
00,,,,,,
PRO,升降轴(轴2)P1速度,UpDownAxis_P1_Speed,
8
00,,,,,,
PRO,升降轴(轴2)P2速度,UpDownAxis_P2_Speed,
8
00,,,,,,
PRO,升降轴(轴2)P3速度,UpDownAxis_P3_Speed,
8
00,,,,,,
PRO,升降轴(轴2)P4速度,UpDownAxis_P4_Speed,
2
00,,,,,,
PRO,升降轴(轴2)P5速度,UpDownAxis_P5_Speed,
8
00,,,,,,
PRO,升降轴(轴2)P6速度,UpDownAxis_P6_Speed,
2
00,,,,,,
PRO,升降轴(轴2)P7速度,UpDownAxis_P7_Speed,200,,,,,,
PRO,升降轴(轴2)P8速度,UpDownAxis_P8_Speed,200,,,,,,
PRO,旋转轴(轴1)P1速度,MiddleAxis_P1_Speed,400,,,,,,
PRO,旋转轴(轴1)P2速度,MiddleAxis_P2_Speed,
3
00,,,,,,
PRO,进出轴(轴3)P1速度,InOutAxis_P1_Speed,1
5
0,,,,,,
PRO,进出轴(轴3)P2速度,InOutAxis_P2_Speed,1
2
0,,,,,,
PRO,进出轴(轴3)P3速度,InOutAxis_P3_Speed,1
2
0,,,,,,
PRO,旋转轴(轴1)P2速度,MiddleAxis_P2_Speed,
4
00,,,,,,
PRO,进出轴(轴3)P1速度,InOutAxis_P1_Speed,1
8
0,,,,,,
PRO,进出轴(轴3)P2速度,InOutAxis_P2_Speed,1
8
0,,,,,,
PRO,进出轴(轴3)P3速度,InOutAxis_P3_Speed,1
8
0,,,,,,
PRO,(轴一)旋转轴停止时可误差的脉冲数的最小值,MiddleAxis_ErrorCountMin,10,,,,,,
PRO,(轴二)升降轴轴停止时可误差的脉冲数的最小值,UpdownAxis_ErrorCountMin,10,,,,,,
PRO,(轴三)进出轴停止时可误差的脉冲数的最小值,InoutAxis_ErrorCountMin,10,,,,,,
...
...
@@ -100,7 +99,7 @@ PRO,(轴三)进出轴最小限位,InoutAxis_PositionMin,0,,,,,,
PRO,(轴一)旋转轴最大限位,MiddleAxis_PositionMax,0,,,,,,
PRO,(轴二)升降轴最大限位,UpdownAxis_PositionMax,0,,,,,,
PRO,(轴三)进出轴最大限位,InoutAxis_PositionMax,0,,,,,,
PRO,需要吹气的温度(温度标准),Max_Temperature,
2
0,,,,,,
PRO,需要吹气的温度(温度标准),Max_Temperature,0,,,,,,
PRO,需要吹气的湿度(湿度标准),Max_Humidity,10,,,,,,
PRO,每次吹气的时间(分钟),BlowAir_Time,10,,,,,,
PRO,两次吹气间隔(分钟),BlowAir_Interval,10,,,,,,
source/DeviceLibrary/StoreConfig/AC/linePositions.csv
查看文件 @
d5595c8
此文件的差异被折叠,
点击展开。
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean.cs
查看文件 @
d5595c8
...
...
@@ -324,17 +324,10 @@ namespace OnlineStore.DeviceLibrary
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
BOX_H_InOutBack
);
ACAxisHomeMove
(
Config
.
InOut_Axis
);
LogUtil
.
info
(
LOGGER
,
StoreName
+
"开始原点返回,先把进出轴回原点"
);
//设置速度
SetShuokeSpeed
();
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
2000
));
}
private
void
SetShuokeSpeed
()
{
if
(!
IsHasCompress_Axis
)
{
return
;
}
}
public
void
MoveToP1
()
{
//压紧轴回原点,叉子回到P1,关闭门旋转轴和升降轴回到P1
...
...
@@ -391,13 +384,13 @@ namespace OnlineStore.DeviceLibrary
}
if
(
IsHasCompress_Axis
||
Config
.
IsHasLocationCylinder
.
Equals
(
0
))
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
BOX_H_InOutBack
);
LogUtil
.
info
(
LOGGER
,
StoreName
+
"开始复位,先把进出轴回原点"
);
InoutStartReset
();
//StoreMove.NextMoveStep(StoreMoveStep.BOX_H_InOutBack);
//LogUtil.info(LOGGER, StoreName + "开始复位,先把进出轴回原点");
ACAxisHomeMove
(
Config
.
InOut_Axis
);
//硕科压紧轴回原点
SetShuokeSpeed
();
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
2000
));
//ACAxisHomeMove(Config.InOut_Axis);
//StoreMove.WaitList.Add(WaitResultInfo.WaitTime(2000));
}
else
{
...
...
@@ -408,7 +401,27 @@ namespace OnlineStore.DeviceLibrary
}
isInPro
=
false
;
}
private
void
InoutStartReset
()
{
string
portName
=
Config
.
InOut_Axis
.
DeviceName
;
int
slvAddr
=
Config
.
InOut_Axis
.
GetAxisValue
();
if
(
ACServerManager
.
GetHomeEndStatus
(
portName
,
slvAddr
).
Equals
(
1
)
&&
ACServerManager
.
GetHomeSingle
(
portName
,
slvAddr
).
Equals
(
1
))
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
BOX_H_InOutMove
);
LogUtil
.
info
(
LOGGER
,
StoreName
+
"复位中,进出轴原点亮且已经原点返回过,先相对走3000"
);
int
currPos
=
ACServerManager
.
GetActualtPosition
(
portName
,
slvAddr
);
int
targetPos
=
currPos
+
3000
;
ACAxisMove
(
Config
.
InOut_Axis
,
targetPos
,
Config
.
InoutAxis_HomeLowSpeed
);
}
else
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
BOX_H_InOutBack
);
LogUtil
.
info
(
LOGGER
,
StoreName
+
"复位中,进出轴开始原点返回"
);
ACAxisHomeMove
(
Config
.
InOut_Axis
);
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
2000
));
}
}
/// <summary>
/// 复位处理
/// </summary>
...
...
@@ -425,9 +438,16 @@ namespace OnlineStore.DeviceLibrary
switch
(
StoreMove
.
MoveStep
)
{
case
StoreMoveStep
.
BOX_H_LocationCylinderBack
:
//StoreMove.NextMoveStep(StoreMoveStep.BOX_H_InOutBack);
//ACAxisHomeMove(Config.InOut_Axis);
//LogUtil.info(LOGGER, StoreName + "复位中:进出轴回原点。。");
//StoreMove.WaitList.Add(WaitResultInfo.WaitTime(2000));
InoutStartReset
();
break
;
case
StoreMoveStep
.
BOX_H_InOutMove
:
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
BOX_H_InOutBack
);
ACAxisHomeMove
(
Config
.
InOut_Axis
);
LogUtil
.
info
(
LOGGER
,
StoreName
+
"复位中:进出轴
回原点。。
"
);
LogUtil
.
info
(
LOGGER
,
StoreName
+
"复位中:进出轴
开始原点返回
"
);
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
2000
));
break
;
case
StoreMoveStep
.
BOX_H_InOutBack
:
...
...
@@ -746,14 +766,16 @@ namespace OnlineStore.DeviceLibrary
this
.
alarmType
=
alarmType
;
if
(
alarmType
.
Equals
(
StoreAlarmType
.
AxisAlarm
)
|
alarmType
.
Equals
(
StoreAlarmType
.
AxisMoveError
))
{
LogUtil
.
error
(
LOGGER
,
StoreName
+
"轴报警,关闭轴,打开报警灯"
);
LogUtil
.
error
(
LOGGER
,
StoreName
+
"轴报警,关闭刹车,停止运动,关闭轴,打开报警灯"
);
KNDIOMove
(
IO_Type
.
Axis_Brake
,
IO_VALUE
.
LOW
);
StopMove
();
CloseAllAxis
();
}
else
if
(
alarmType
==
StoreAlarmType
.
SuddenStop
)
{
isInSuddenDown
=
true
;
LogUtil
.
error
(
LOGGER
,
StoreName
+
"收到急停信号,关闭所有轴卡,关闭所有IO,停止所有运动"
);
LogUtil
.
error
(
LOGGER
,
StoreName
+
"收到急停信号,关闭刹车,停止运动,关闭轴,打开报警灯 "
);
KNDIOMove
(
IO_Type
.
Axis_Brake
,
IO_VALUE
.
LOW
);
StopMove
();
CloseAllAxis
();
StoreMove
.
EndMove
();
...
...
@@ -762,7 +784,8 @@ namespace OnlineStore.DeviceLibrary
else
if
(
alarmType
.
Equals
(
StoreAlarmType
.
NoAirCheck
))
{
isNoAirCheck
=
true
;
LogUtil
.
error
(
LOGGER
,
StoreName
+
" 未检测到气压信号 ,关闭所有轴卡,关闭所有IO,停止所有运动"
);
LogUtil
.
error
(
LOGGER
,
StoreName
+
" 未检测到气压信号 ,打开刹车,停止运动,关闭轴,打开报警灯 "
);
KNDIOMove
(
IO_Type
.
Axis_Brake
,
IO_VALUE
.
LOW
);
StopMove
();
CloseAllAxis
();
StoreMove
.
EndMove
();
...
...
@@ -1131,7 +1154,7 @@ namespace OnlineStore.DeviceLibrary
//在回原点,复位,出入库时,检测报警间隔减小
if
(
storeRunStatus
.
Equals
(
StoreRunStatus
.
Busy
)
||
storeRunStatus
.
Equals
(
StoreRunStatus
.
HomeMoving
)
||
storeRunStatus
.
Equals
(
StoreRunStatus
.
Reset
))
{
if
(
span
.
TotalSeconds
<
1
)
if
(
span
.
TotalSeconds
<
0.5
)
{
return
false
;
}
...
...
source/DeviceLibrary/store/StoreManager.cs
查看文件 @
d5595c8
...
...
@@ -211,14 +211,16 @@ namespace OnlineStore.DeviceLibrary
/// 料仓原点返回和重置步骤,,定位气缸下降
/// </summary>
BOX_H_LocationCylinderBack
=
010
,
/// <summary>
/// 料仓原点返回和重置步骤,
,轴三进出轴先返回原点
/// 料仓原点返回和重置步骤,
轴三先相对走3000
/// </summary>
BOX_H_InOut
Back
=
011
,
BOX_H_InOut
Move
=
011
,
/// <summary>
/// 料仓原点返回和重置步骤,,轴三进出轴
返回原点后,需要等待500毫秒,然后再清空
/// 料仓原点返回和重置步骤,,轴三进出轴
先返回原点
/// </summary>
//BOX_H_InOutBackWait = 012,
BOX_H_InOutBack
=
012
,
/// <summary>
/// 料仓原点返回和重置步骤,,轴三返回P1点
/// </summary>
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论