Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
V
VIZ.ElectricRabbit
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
刘龙飞
VIZ.ElectricRabbit
Commits
e455f67a
Commit
e455f67a
authored
Jan 31, 2023
by
liulongfei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
部分逻辑调整
parent
59830c15
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
8 additions
and
7 deletions
+8
-7
VIZ.ElectricRabbit.Connection/SerialPort/Output/Signal/Send/OutputPackage_data.cs
+2
-2
VIZ.ElectricRabbit.Module/MainView/Controller/Output/OutputController.cs
+1
-0
VIZ.ElectricRabbit.Module/MainView/View/MainView.xaml
+2
-2
VIZ.ElectricRabbit.Module/MainView/ViewModel/MainViewModel.cs
+1
-1
VIZ.ElectricRabbit/config/config.ini
+2
-2
No files found.
VIZ.ElectricRabbit.Connection/SerialPort/Output/Signal/Send/OutputPackage_data.cs
View file @
e455f67a
...
@@ -89,7 +89,7 @@ namespace VIZ.ElectricRabbit.Connection
...
@@ -89,7 +89,7 @@ namespace VIZ.ElectricRabbit.Connection
/// <summary>
/// <summary>
/// 校验和
/// 校验和
/// (序号1+……+序号
52
)&0xFF
/// (序号1+……+序号
49
)&0xFF
/// </summary>
/// </summary>
[
ConnBitLength
(
8
)]
[
ConnBitLength
(
8
)]
public
byte
Check
{
get
;
set
;
}
public
byte
Check
{
get
;
set
;
}
...
@@ -100,7 +100,7 @@ namespace VIZ.ElectricRabbit.Connection
...
@@ -100,7 +100,7 @@ namespace VIZ.ElectricRabbit.Connection
/// <returns>二进制数据</returns>
/// <returns>二进制数据</returns>
public
override
byte
[]
ToBuffer
()
public
override
byte
[]
ToBuffer
()
{
{
byte
[]
buffer
=
new
byte
[
53
];
byte
[]
buffer
=
new
byte
[
49
];
int
index
=
0
;
int
index
=
0
;
// 同步帧头 1
// 同步帧头 1
...
...
VIZ.ElectricRabbit.Module/MainView/Controller/Output/OutputController.cs
View file @
e455f67a
...
@@ -102,6 +102,7 @@ namespace VIZ.ElectricRabbit.Module
...
@@ -102,6 +102,7 @@ namespace VIZ.ElectricRabbit.Module
package
.
HelpCommand_PN
=
this
.
Support
.
AlgorithmDifferenceValue
<
0
?
(
byte
)
1
:
(
byte
)
0
;
package
.
HelpCommand_PN
=
this
.
Support
.
AlgorithmDifferenceValue
<
0
?
(
byte
)
1
:
(
byte
)
0
;
package
.
HelpCommand
=
(
UInt16
)
Math
.
Abs
(
this
.
Support
.
AlgorithmDifferenceValue
);
package
.
HelpCommand
=
(
UInt16
)
Math
.
Abs
(
this
.
Support
.
AlgorithmDifferenceValue
);
package
.
Heart
=
(
byte
)
this
.
heart
;
package
.
Heart
=
(
byte
)
this
.
heart
;
package
.
Check
=
package
.
GetCheckValue
();
this
.
heart
++;
this
.
heart
++;
if
(
this
.
heart
>
255
)
if
(
this
.
heart
>
255
)
...
...
VIZ.ElectricRabbit.Module/MainView/View/MainView.xaml
View file @
e455f67a
...
@@ -61,11 +61,11 @@
...
@@ -61,11 +61,11 @@
<!-- 提示区域 -->
<!-- 提示区域 -->
<Grid>
<Grid>
<Grid.RowDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="
3
0"></RowDefinition>
<RowDefinition Height="
5
0"></RowDefinition>
<RowDefinition Height="*"></RowDefinition>
<RowDefinition Height="*"></RowDefinition>
</Grid.RowDefinitions>
</Grid.RowDefinitions>
<!-- 中心值 -->
<!-- 中心值 -->
<TextBlock Text="{Binding Path=AlgorithmCenterX}" VerticalAlignment="Bottom" HorizontalAlignment="Center" Foreground="Red" FontSize="
16
"></TextBlock>
<TextBlock Text="{Binding Path=AlgorithmCenterX}" VerticalAlignment="Bottom" HorizontalAlignment="Center" Foreground="Red" FontSize="
24
"></TextBlock>
<!-- 箭头 -->
<!-- 箭头 -->
<fcommon:FlashingBorder IsFlashingEnabled="{Binding Path=SettingViewModel.IsFlashingEnabled}" Grid.Row="1"
<fcommon:FlashingBorder IsFlashingEnabled="{Binding Path=SettingViewModel.IsFlashingEnabled}" Grid.Row="1"
...
...
VIZ.ElectricRabbit.Module/MainView/ViewModel/MainViewModel.cs
View file @
e455f67a
...
@@ -348,7 +348,7 @@ namespace VIZ.ElectricRabbit.Module
...
@@ -348,7 +348,7 @@ namespace VIZ.ElectricRabbit.Module
double
center
=
left
+
(
right
-
left
)
/
2d
;
double
center
=
left
+
(
right
-
left
)
/
2d
;
this
.
DifferenceValue
=
center
-
this
.
SettingViewModel
.
SafeAxis
;
this
.
DifferenceValue
=
center
-
this
.
SettingViewModel
.
SafeAxis
;
this
.
AlgorithmCenterX
=
msg
.
center_x
;
this
.
AlgorithmCenterX
=
msg
.
center_x
;
this
.
AlgorithmDifferenceValue
=
center
-
this
.
AlgorithmCenterX
;
this
.
AlgorithmDifferenceValue
=
this
.
SettingViewModel
.
SafeAxis
-
msg
.
center_x
;
// 更新FPS
// 更新FPS
this
.
AlgorithmFPS
.
CalcFps
();
this
.
AlgorithmFPS
.
CalcFps
();
...
...
VIZ.ElectricRabbit/config/config.ini
View file @
e455f67a
...
@@ -35,4 +35,4 @@ CLIENT_RIGHT_COLOR=#00000000
...
@@ -35,4 +35,4 @@ CLIENT_RIGHT_COLOR=#00000000
; 箭头安全颜色(格式:#AARRGGBB)
; 箭头安全颜色(格式:#AARRGGBB)
CLIENT_SAFE_COLOR
=
#00000000
CLIENT_SAFE_COLOR
=
#00000000
; 输出串口号
; 输出串口号
CLIENT_OUTPUT_SERIAL_PORT=COM1
CLIENT_OUTPUT_SERIAL_PORT=COM3
\ No newline at end of file
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment