Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
autoCar
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李远洪
autoCar
Commits
d3c9a7c6
Commit
d3c9a7c6
authored
Apr 26, 2020
by
liyuanhong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加了方向角随GPS轨迹自动变化的功能
parent
0ab2f500
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
201 additions
and
227 deletions
+201
-227
lib/socket/service/AutoCarService.py
lib/socket/service/AutoCarService.py
+30
-0
result.txt
result.txt
+170
-226
start.py
start.py
+1
-1
No files found.
lib/socket/service/AutoCarService.py
View file @
d3c9a7c6
...
...
@@ -6,6 +6,7 @@
import
binascii
import
datetime
import
json
import
math
import
os
import
random
import
threading
...
...
@@ -39,6 +40,7 @@ class AutoCarService():
self
.
sn
=
1
#消息流水号
self
.
oilExpend
=
10
#设置汽车每升能跑多少公里
self
.
carSpeed
=
60
#设置车速度
self
.
directAngle
=
59
#定义默认方向角
# 定义要发送的obd数据
self
.
OBDdata
=
{
"fireStatus"
:
1
,
"ACCStatus"
:
0
,
"engineSpeed"
:
300
,
"speed"
:
0
,
"meterMileage"
:
6000
,
"totailMileage"
:
600
,
"totalOilExpen"
:
30
,
"totalRunTime"
:
10
}
# 定义初始的obd数据,与上面的OBD数据保持一致,主要用于汽车行驶过程中数据变化量的计算
...
...
@@ -323,6 +325,7 @@ class AutoCarService():
gpsObj
=
GPSReport_protocol
(
DEV_ID
=
self
.
carId
,
WATER_CODE
=
self
.
sn
)
gpsObj
.
setLatitude
(
latitude
)
gpsObj
.
setLongitude
(
longtitude
)
gpsObj
.
setDirectionAngle
(
self
.
getDirAngle
())
timeS
=
int
(
time
.
time
())
-
8
*
3600
timeArray
=
time
.
localtime
(
timeS
)
UTCTime
=
time
.
strftime
(
"
%
Y-
%
m-
%
d
%
H:
%
M:
%
S"
,
timeArray
)
...
...
@@ -335,6 +338,7 @@ class AutoCarService():
gpsObj
=
GPSReport_protocol
(
DEV_ID
=
self
.
carId
,
WATER_CODE
=
self
.
sn
)
gpsObj
.
setLatitude
(
latitude
)
gpsObj
.
setLongitude
(
longtitude
)
gpsObj
.
setDirectionAngle
(
self
.
getDirAngle
())
timeS
=
int
(
time
.
time
())
-
8
*
3600
timeArray
=
time
.
localtime
(
timeS
)
UTCTime
=
time
.
strftime
(
"
%
Y-
%
m-
%
d
%
H:
%
M:
%
S"
,
timeArray
)
...
...
@@ -433,6 +437,32 @@ class AutoCarService():
with
open
(
path
,
"w"
,
encoding
=
'utf-8'
)
as
fi
:
fi
.
write
(
data
)
###########################################################
# 获取方向角
###########################################################
def
getDirAngle
(
self
):
dire
=
self
.
directAngle
if
self
.
gpsLineIndex
==
0
:
return
int
(
self
.
directAngle
)
lngCut
=
(
float
(
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lng"
])
-
float
(
self
.
gpsLine
[
self
.
gpsLineIndex
-
1
][
"lng"
]))
*
1000000
latCut
=
(
float
(
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lat"
])
-
float
(
self
.
gpsLine
[
self
.
gpsLineIndex
-
1
][
"lat"
]))
*
1000000
if
latCut
==
0
:
# 除数维度不能为0
latCut
=
1
if
lngCut
==
0
or
latCut
==
0
:
return
int
(
self
.
directAngle
)
val
=
lngCut
/
latCut
dire
=
math
.
atan2
(
1
,
val
)
*
180
/
math
.
pi
if
lngCut
>
0
and
latCut
>
0
:
dire
=
90
-
dire
if
lngCut
<
0
and
latCut
>
0
:
dire
=
270
+
180
-
dire
elif
latCut
<
0
and
lngCut
>
0
:
dire
=
270
-
dire
elif
lngCut
<
0
and
latCut
<
0
:
dire
=
180
+
90
-
dire
self
.
directAngle
=
dire
return
int
(
dire
)
#临时定义的一个测试函数
def
testOpenfile
(
self
):
with
open
(
"data/protocolTools/carData/"
+
self
.
carId
+
".json"
,
"r"
,
encoding
=
"utf-8"
)
as
fi
:
...
...
result.txt
View file @
d3c9a7c6
[2020-04-21 15:31:16] 建立了连接
[2020-04-21 15:31:16] 进行了登录操作
[2020-04-21 15:31:17] 发送了版本信息
[2020-04-21 15:31:17] 当前设置了GPS轨迹:gpsLine1111.txt
[2020-04-21 15:31:18] 发送了点火事件
[2020-04-21 15:31:20] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:21] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:22] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:23] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:24] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:25] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:26] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:27] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:28] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:30] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:31] 纬度:29.585448 经度:106.279711
[2020-04-21 15:31:32] 纬度:29.586623 经度:106.287903
[2020-04-21 15:31:33] 纬度:29.586608 经度:106.289041
[2020-04-21 15:31:34] 纬度:29.586631 经度:106.293958
[2020-04-21 15:31:35] 纬度:29.586603 经度:106.296643
[2020-04-21 15:31:36] 纬度:29.586588 经度:106.29702
[2020-04-21 15:31:37] 纬度:29.586625 经度:106.297076
[2020-04-21 15:31:38] 纬度:29.586675 经度:106.297116
[2020-04-21 15:31:40] 纬度:29.58674 经度:106.297148
[2020-04-21 15:31:41] 纬度:29.586818 经度:106.297161
[2020-04-21 15:31:42] 纬度:29.586906 经度:106.297168
[2020-04-21 15:31:43] 纬度:29.58793 经度:106.297275
[2020-04-21 15:31:44] 纬度:29.588408 经度:106.297461
[2020-04-21 15:31:45] 纬度:29.588835 经度:106.297783
[2020-04-21 15:31:46] 纬度:29.589848 经度:106.298863
[2020-04-21 15:31:47] 纬度:29.59043 经度:106.299571
[2020-04-21 15:31:48] 纬度:29.590666 经度:106.30007
[2020-04-21 15:31:50] 纬度:29.59083 经度:106.300655
[2020-04-21 15:31:51] 纬度:29.59091 经度:106.301408
[2020-04-21 15:31:52] 纬度:29.590925 经度:106.301695
[2020-04-21 15:31:53] 纬度:29.590928 经度:106.303111
[2020-04-21 15:31:54] 纬度:29.590958 经度:106.30319
[2020-04-21 15:31:55] 纬度:29.591001 经度:106.30325
[2020-04-21 15:31:56] 纬度:29.59106 经度:106.303288
[2020-04-21 15:31:57] 纬度:29.591125 经度:106.303306
[2020-04-21 15:31:58] 纬度:29.591196 经度:106.303311
[2020-04-21 15:32:00] 纬度:29.59202 经度:106.303321
[2020-04-21 15:32:01] 纬度:29.594665 经度:106.303418
[2020-04-21 15:32:02] 纬度:29.596323 经度:106.303493
[2020-04-21 15:32:03] 纬度:29.597693 经度:106.30351
[2020-04-21 15:32:04] 纬度:29.598776 经度:106.303563
[2020-04-21 15:32:05] 纬度:29.600776 经度:106.303651
[2020-04-21 15:32:06] 纬度:29.600776 经度:106.303651
[2020-04-21 15:32:07] 纬度:29.6027 经度:106.303735
[2020-04-21 15:32:08] 纬度:29.605561 经度:106.303841
[2020-04-21 15:32:09] 纬度:29.605611 经度:106.30389
[2020-04-21 15:32:11] 纬度:29.605648 经度:106.303936
[2020-04-21 15:32:12] 纬度:29.605683 经度:106.303988
[2020-04-21 15:32:13] 纬度:29.605698 经度:106.30405
[2020-04-21 15:32:14] 纬度:29.605718 经度:106.304203
[2020-04-21 15:32:15] 纬度:29.605741 经度:106.307615
[2020-04-21 15:32:16] 纬度:29.605716 经度:106.309696
[2020-04-21 15:32:17] 纬度:29.605715 经度:106.309731
[2020-04-21 15:32:18] 纬度:29.605721 经度:106.313746
[2020-04-21 15:32:19] 纬度:29.605693 经度:106.31563
[2020-04-21 15:32:21] 纬度:29.605731 经度:106.320446
[2020-04-21 15:32:22] 纬度:29.605701 经度:106.325616
[2020-04-21 15:32:23] 纬度:29.605626 经度:106.3258
[2020-04-21 15:32:24] 纬度:29.605285 经度:106.326526
[2020-04-21 15:32:25] 纬度:29.605265 经度:106.326736
[2020-04-21 15:32:26] 纬度:29.605301 经度:106.326958
[2020-04-21 15:32:27] 纬度:29.605343 经度:106.327066
[2020-04-21 15:32:28] 纬度:29.605686 经度:106.327813
[2020-04-21 15:32:29] 纬度:29.605711 经度:106.328125
[2020-04-21 15:32:31] 纬度:29.605706 经度:106.328805
[2020-04-21 15:32:32] 纬度:29.605946 经度:106.335046
[2020-04-21 15:32:33] 纬度:29.606455 经度:106.339763
[2020-04-21 15:32:34] 纬度:29.606618 经度:106.342376
[2020-04-21 15:32:35] 纬度:29.606541 经度:106.346018
[2020-04-21 15:32:36] 纬度:29.606423 经度:106.34853
[2020-04-21 15:32:37] 纬度:29.606235 经度:106.352298
[2020-04-21 15:32:38] 纬度:29.606015 经度:106.357856
[2020-04-21 15:32:40] 纬度:29.605968 经度:106.359951
[2020-04-21 15:32:41] 纬度:29.605978 经度:106.360195
[2020-04-21 15:32:42] 纬度:29.605978 经度:106.360195
[2020-04-21 15:32:43] 纬度:29.60598 经度:106.360341
[2020-04-21 15:32:44] 纬度:29.605988 经度:106.360453
[2020-04-21 15:32:45] 纬度:29.606005 经度:106.360515
[2020-04-21 15:32:46] 纬度:29.606036 经度:106.360578
[2020-04-21 15:32:47] 纬度:29.606081 经度:106.360638
[2020-04-21 15:32:48] 纬度:29.606136 经度:106.360686
[2020-04-21 15:32:50] 纬度:29.606266 经度:106.360756
[2020-04-21 15:32:51] 纬度:29.60645 经度:106.360791
[2020-04-21 15:32:52] 纬度:29.608673 经度:106.361096
[2020-04-21 15:32:53] 纬度:29.611228 经度:106.361216
[2020-04-21 15:32:54] 纬度:29.611825 经度:106.36123
[2020-04-21 15:32:55] 纬度:29.611825 经度:106.36123
[2020-04-21 15:32:56] 纬度:29.612025 经度:106.361245
[2020-04-21 15:32:57] 纬度:29.612065 经度:106.361295
[2020-04-21 15:32:58] 纬度:29.612091 经度:106.36137
[2020-04-21 15:32:59] 纬度:29.612105 经度:106.361458
[2020-04-21 15:33:01] 纬度:29.612145 经度:106.362618
[2020-04-21 15:33:02] 纬度:29.61203 经度:106.36646
[2020-04-21 15:33:03] 纬度:29.612051 经度:106.366696
[2020-04-21 15:33:04] 纬度:29.612156 经度:106.37035
[2020-04-21 15:33:05] 纬度:29.61214 经度:106.374651
[2020-04-21 15:33:06] 纬度:29.612096 经度:106.378093
[2020-04-21 15:33:07] 纬度:29.612078 经度:106.378153
[2020-04-21 15:33:08] 纬度:29.612083 经度:106.378198
[2020-04-21 15:33:09] 纬度:29.612105 经度:106.37833
[2020-04-21 15:33:11] 纬度:29.61212 经度:106.37846
[2020-04-21 15:33:12] 纬度:29.612105 经度:106.379693
[2020-04-21 15:33:13] 纬度:29.61197 经度:106.380753
[2020-04-21 15:33:14] 纬度:29.611756 经度:106.381605
[2020-04-21 15:33:15] 纬度:29.611061 经度:106.383603
[2020-04-21 15:33:16] 纬度:29.610913 经度:106.384098
[2020-04-21 15:33:17] 纬度:29.610855 经度:106.384285
[2020-04-21 15:33:18] 纬度:29.610528 经度:106.385345
[2020-04-21 15:33:19] 纬度:29.610451 经度:106.38565
[2020-04-21 15:33:21] 纬度:29.610451 经度:106.38565
[2020-04-21 15:33:22] 纬度:29.610401 经度:106.385915
[2020-04-21 15:33:23] 纬度:29.610345 经度:106.386206
[2020-04-21 15:33:24] 纬度:29.610335 经度:106.386226
[2020-04-21 15:33:25] 纬度:29.6103 经度:106.386403
[2020-04-21 15:33:26] 纬度:29.61027 经度:106.38658
[2020-04-21 15:33:27] 纬度:29.610255 经度:106.386611
[2020-04-21 15:33:28] 纬度:29.610243 经度:106.386675
[2020-04-21 15:33:29] 纬度:29.610236 经度:106.386825
[2020-04-21 15:33:31] 纬度:29.610215 经度:106.386991
[2020-04-21 15:33:32] 纬度:29.610166 经度:106.387395
[2020-04-21 15:33:33] 纬度:29.610156 经度:106.387485
[2020-04-21 15:33:34] 纬度:29.610146 经度:106.387591
[2020-04-21 15:33:35] 纬度:29.610146 经度:106.387591
[2020-04-21 15:33:36] 纬度:29.610136 经度:106.387638
[2020-04-21 15:33:37] 纬度:29.610118 经度:106.38778
[2020-04-21 15:33:38] 纬度:29.610113 经度:106.387863
[2020-04-21 15:33:39] 纬度:29.610101 经度:106.388031
[2020-04-21 15:33:40] 纬度:29.610085 经度:106.388351
[2020-04-21 15:33:42] 纬度:29.610033 经度:106.389061
[2020-04-21 15:33:43] 纬度:29.609993 经度:106.389386
[2020-04-21 15:33:44] 纬度:29.609978 经度:106.389428
[2020-04-21 15:33:45] 纬度:29.609993 经度:106.389523
[2020-04-21 15:33:46] 纬度:29.61 经度:106.389571
[2020-04-21 15:33:47] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:48] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:49] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:50] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:52] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:53] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:54] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:55] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:56] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:57] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:58] 纬度:29.610195 经度:106.389993
[2020-04-21 15:33:59] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:00] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:02] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:03] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:04] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:05] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:06] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:07] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:08] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:09] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:10] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:12] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:13] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:14] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:15] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:16] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:17] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:18] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:19] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:20] 纬度:29.610195 经度:106.389993
[2020-04-21 15:34:22] 纬度:29.605548 经度:106.435588
[2020-04-21 15:34:23] 纬度:29.605048 经度:106.438256
[2020-04-21 15:34:24] 纬度:29.604535 经度:106.439735
[2020-04-21 15:34:25] 纬度:29.603025 经度:106.443626
[2020-04-21 15:34:26] 纬度:29.601625 经度:106.4472
[2020-04-21 15:34:27] 纬度:29.600068 经度:106.451066
[2020-04-21 15:34:28] 纬度:29.598905 经度:106.454213
[2020-04-21 15:34:29] 纬度:29.59888 经度:106.45434
[2020-04-21 15:34:30] 纬度:29.598818 经度:106.454888
[2020-04-21 15:34:32] 纬度:29.59885 经度:106.456268
[2020-04-21 15:34:33] 纬度:29.598828 经度:106.457346
[2020-04-21 15:34:34] 纬度:29.5988 经度:106.457583
[2020-04-21 15:34:35] 纬度:29.598606 经度:106.458478
[2020-04-21 15:34:36] 纬度:29.598228 经度:106.459485
[2020-04-21 15:34:37] 纬度:29.596961 经度:106.461946
[2020-04-21 15:34:38] 纬度:29.595875 经度:106.463806
[2020-04-21 15:34:39] 纬度:29.595176 经度:106.46479
[2020-04-21 15:34:40] 纬度:29.595086 经度:106.465008
[2020-04-21 15:34:41] 纬度:29.59501 经度:106.465338
[2020-04-21 15:34:43] 纬度:29.594993 经度:106.465613
[2020-04-21 15:34:44] 纬度:29.59499 经度:106.466701
[2020-04-21 15:34:45] 纬度:29.59493 经度:106.467031
[2020-04-21 15:34:46] 纬度:29.594861 经度:106.4674
[2020-04-21 15:34:47] 纬度:29.594811 经度:106.467635
[2020-04-21 15:34:48] 纬度:29.594733 经度:106.468015
[2020-04-21 15:34:49] 纬度:29.594663 经度:106.468356
[2020-04-21 15:34:50] 纬度:29.594606 经度:106.468688
[2020-04-21 15:34:51] 纬度:29.594496 经度:106.469243
[2020-04-21 15:34:53] 纬度:29.594405 经度:106.4697
[2020-04-21 15:34:54] 纬度:29.594256 经度:106.470393
[2020-04-21 15:34:55] 纬度:29.594128 经度:106.470938
[2020-04-21 15:34:56] 纬度:29.594086 经度:106.471188
[2020-04-21 15:34:57] 纬度:29.59407 经度:106.471315
[2020-04-21 15:34:58] 纬度:29.59407 经度:106.471315
[2020-04-21 15:34:59] 纬度:29.593996 经度:106.471381
[2020-04-21 15:35:00] 纬度:29.593996 经度:106.471381
[2020-04-21 15:35:01] 纬度:29.593996 经度:106.471381
[2020-04-21 15:35:03] 纬度:29.593996 经度:106.471381
[2020-04-21 15:35:04] 纬度:29.593996 经度:106.471381
[2020-04-21 15:35:05] 纬度:29.59573 经度:106.471016
[2020-04-21 15:35:06] 纬度:29.59598 经度:106.471043
[2020-04-21 15:35:07] 纬度:29.596046 经度:106.471066
[2020-04-21 15:35:08] 纬度:29.596221 经度:106.471141
[2020-04-21 15:35:09] 纬度:29.596728 经度:106.47149
[2020-04-21 15:35:10] 纬度:29.597083 经度:106.471711
[2020-04-21 15:35:11] 纬度:29.597168 经度:106.471793
[2020-04-21 15:35:13] 纬度:29.597321 经度:106.471921
[2020-04-21 15:35:14] 纬度:29.59745 经度:106.472008
[2020-04-21 15:35:15] 纬度:29.599268 经度:106.473231
[2020-04-21 15:35:16] 纬度:29.600981 经度:106.474456
[2020-04-21 15:35:17] 纬度:29.603555 经度:106.476253
[2020-04-21 15:35:18] 纬度:29.605808 经度:106.478031
[2020-04-21 15:35:19] 纬度:29.606413 经度:106.478705
[2020-04-21 15:35:20] 纬度:29.606973 经度:106.479531
[2020-04-21 15:35:22] 发送了熄火事件:
[2020-04-21 15:35:22] 执行了停止行驶服务
[2020-04-21 15:35:22] 本次车机模拟程序跑完........
[2020-04-26 16:45:24] 建立了连接
[2020-04-26 16:45:24] 进行了登录操作
[2020-04-26 16:45:24] 发送了版本信息
[2020-04-26 16:45:25] 当前设置了GPS轨迹:gpsLine5.txt
[2020-04-26 16:45:25] 发送了点火事件
[2020-04-26 16:45:27] 纬度:29.571413 经度:106.489936
[2020-04-26 16:45:28] 纬度:29.571413 经度:106.489936
[2020-04-26 16:45:29] 纬度:29.571413 经度:106.489936
[2020-04-26 16:45:30] 纬度:29.571413 经度:106.489936
[2020-04-26 16:45:31] 纬度:29.572476 经度:106.489228
[2020-04-26 16:45:32] 纬度:29.57247 经度:106.489278
[2020-04-26 16:45:33] 纬度:29.572478 经度:106.48928
[2020-04-26 16:45:35] 纬度:29.572493 经度:106.489308
[2020-04-26 16:45:36] 纬度:29.572491 经度:106.489336
[2020-04-26 16:45:37] 纬度:29.572516 经度:106.489401
[2020-04-26 16:45:38] 纬度:29.572516 经度:106.489463
[2020-04-26 16:45:39] 纬度:29.572513 经度:106.489526
[2020-04-26 16:45:40] 纬度:29.572516 经度:106.489551
[2020-04-26 16:45:41] 纬度:29.572516 经度:106.48958
[2020-04-26 16:45:42] 纬度:29.572513 经度:106.489673
[2020-04-26 16:45:43] 纬度:29.572528 经度:106.489723
[2020-04-26 16:45:44] 纬度:29.57255 经度:106.48976
[2020-04-26 16:45:46] 纬度:29.572548 经度:106.489806
[2020-04-26 16:45:47] 纬度:29.572588 经度:106.489945
[2020-04-26 16:45:48] 纬度:29.573006 经度:106.490688
[2020-04-26 16:45:49] 纬度:29.574358 经度:106.493176
[2020-04-26 16:45:50] 纬度:29.575038 经度:106.494316
[2020-04-26 16:45:51] 纬度:29.575311 经度:106.494641
[2020-04-26 16:45:52] 纬度:29.575978 经度:106.495465
[2020-04-26 16:45:53] 纬度:29.576051 经度:106.49554
[2020-04-26 16:45:54] 纬度:29.576178 经度:106.495676
[2020-04-26 16:45:56] 纬度:29.576178 经度:106.495676
[2020-04-26 16:45:57] 纬度:29.576513 经度:106.49603
[2020-04-26 16:45:58] 纬度:29.578031 经度:106.497765
[2020-04-26 16:45:59] 纬度:29.57854 经度:106.498773
[2020-04-26 16:46:00] 纬度:29.578868 经度:106.499798
[2020-04-26 16:46:01] 纬度:29.579578 经度:106.501658
[2020-04-26 16:46:02] 纬度:29.580096 经度:106.50237
[2020-04-26 16:46:03] 纬度:29.580836 经度:106.503121
[2020-04-26 16:46:04] 纬度:29.581896 经度:106.50395
[2020-04-26 16:46:06] 纬度:29.582433 经度:106.504175
[2020-04-26 16:46:07] 纬度:29.584653 经度:106.505063
[2020-04-26 16:46:08] 纬度:29.585078 经度:106.50554
[2020-04-26 16:46:09] 纬度:29.585436 经度:106.50609
[2020-04-26 16:46:10] 纬度:29.585701 经度:106.506691
[2020-04-26 16:46:11] 纬度:29.585848 经度:106.507366
[2020-04-26 16:46:12] 纬度:29.585931 经度:106.50825
[2020-04-26 16:46:13] 纬度:29.586 经度:106.51094
[2020-04-26 16:46:15] 纬度:29.586065 经度:106.513358
[2020-04-26 16:46:16] 纬度:29.586071 经度:106.516028
[2020-04-26 16:46:17] 纬度:29.586091 经度:106.519216
[2020-04-26 16:46:18] 纬度:29.586266 经度:106.522845
[2020-04-26 16:46:19] 纬度:29.586368 经度:106.523246
[2020-04-26 16:46:20] 纬度:29.586976 经度:106.525301
[2020-04-26 16:46:21] 纬度:29.587878 经度:106.527695
[2020-04-26 16:46:22] 纬度:29.588231 经度:106.528158
[2020-04-26 16:46:24] 纬度:29.58837 经度:106.52835
[2020-04-26 16:46:25] 纬度:29.588898 经度:106.528901
[2020-04-26 16:46:26] 纬度:29.590686 经度:106.530315
[2020-04-26 16:46:27] 纬度:29.590921 经度:106.530693
[2020-04-26 16:46:28] 纬度:29.591176 经度:106.531298
[2020-04-26 16:46:29] 纬度:29.591223 经度:106.531461
[2020-04-26 16:46:30] 纬度:29.591311 经度:106.531958
[2020-04-26 16:46:31] 纬度:29.591331 经度:106.532708
[2020-04-26 16:46:32] 纬度:29.59121 经度:106.53456
[2020-04-26 16:46:34] 纬度:29.591001 经度:106.536136
[2020-04-26 16:46:35] 纬度:29.590758 经度:106.536763
[2020-04-26 16:46:36] 纬度:29.590386 经度:106.537365
[2020-04-26 16:46:37] 纬度:29.590071 经度:106.537816
[2020-04-26 16:46:38] 纬度:29.588791 经度:106.53997
[2020-04-26 16:46:39] 纬度:29.58838 经度:106.54105
[2020-04-26 16:46:40] 纬度:29.58736 经度:106.544393
[2020-04-26 16:46:41] 纬度:29.586875 经度:106.546295
[2020-04-26 16:46:42] 纬度:29.586838 经度:106.54707
[2020-04-26 16:46:44] 纬度:29.586898 经度:106.547906
[2020-04-26 16:46:45] 纬度:29.58728 经度:106.550141
[2020-04-26 16:46:46] 纬度:29.587341 经度:106.550928
[2020-04-26 16:46:47] 纬度:29.587185 经度:106.554313
[2020-04-26 16:46:48] 纬度:29.587231 经度:106.558706
[2020-04-26 16:46:49] 纬度:29.587476 经度:106.564148
[2020-04-26 16:46:50] 纬度:29.587811 经度:106.568888
[2020-04-26 16:46:51] 纬度:29.588195 经度:106.57465
[2020-04-26 16:46:52] 纬度:29.58863 经度:106.581358
[2020-04-26 16:46:53] 纬度:29.588625 经度:106.58715
[2020-04-26 16:46:55] 纬度:29.588548 经度:106.587683
[2020-04-26 16:46:56] 纬度:29.588351 经度:106.588408
[2020-04-26 16:46:57] 纬度:29.587905 经度:106.589363
[2020-04-26 16:46:58] 纬度:29.587518 经度:106.58993
[2020-04-26 16:46:59] 纬度:29.587135 经度:106.590306
[2020-04-26 16:47:00] 纬度:29.587008 经度:106.590373
[2020-04-26 16:47:01] 纬度:29.58687 经度:106.590413
[2020-04-26 16:47:02] 纬度:29.586643 经度:106.59044
[2020-04-26 16:47:04] 纬度:29.586578 经度:106.590418
[2020-04-26 16:47:05] 纬度:29.586528 经度:106.590366
[2020-04-26 16:47:06] 纬度:29.586491 经度:106.590295
[2020-04-26 16:47:07] 纬度:29.586416 经度:106.590121
[2020-04-26 16:47:08] 纬度:29.586376 经度:106.58978
[2020-04-26 16:47:09] 纬度:29.586303 经度:106.589298
[2020-04-26 16:47:10] 纬度:29.586151 经度:106.58896
[2020-04-26 16:47:11] 纬度:29.585425 经度:106.587671
[2020-04-26 16:47:12] 纬度:29.585178 经度:106.587248
[2020-04-26 16:47:14] 纬度:29.585103 经度:106.587193
[2020-04-26 16:47:15] 纬度:29.584518 经度:106.586845
[2020-04-26 16:47:16] 纬度:29.584393 经度:106.586873
[2020-04-26 16:47:17] 纬度:29.584336 经度:106.586908
[2020-04-26 16:47:18] 纬度:29.584295 经度:106.586978
[2020-04-26 16:47:19] 纬度:29.584245 经度:106.587063
[2020-04-26 16:47:20] 纬度:29.583933 经度:106.587728
[2020-04-26 16:47:21] 纬度:29.583666 经度:106.58852
[2020-04-26 16:47:22] 纬度:29.583636 经度:106.588616
[2020-04-26 16:47:24] 纬度:29.583203 经度:106.59062
[2020-04-26 16:47:25] 纬度:29.583028 经度:106.5909
[2020-04-26 16:47:26] 纬度:29.583026 经度:106.590946
[2020-04-26 16:47:27] 纬度:29.583023 经度:106.591038
[2020-04-26 16:47:28] 纬度:29.582983 经度:106.591191
[2020-04-26 16:47:29] 纬度:29.582805 经度:106.591945
[2020-04-26 16:47:30] 纬度:29.5825 经度:106.593713
[2020-04-26 16:47:31] 纬度:29.582348 经度:106.594765
[2020-04-26 16:47:32] 纬度:29.582066 经度:106.595623
[2020-04-26 16:47:33] 纬度:29.58191 经度:106.59581
[2020-04-26 16:47:35] 纬度:29.581818 经度:106.59589
[2020-04-26 16:47:36] 纬度:29.58164 经度:106.596008
[2020-04-26 16:47:37] 纬度:29.581355 经度:106.596105
[2020-04-26 16:47:38] 纬度:29.5805 经度:106.596305
[2020-04-26 16:47:39] 纬度:29.579981 经度:106.596385
[2020-04-26 16:47:40] 纬度:29.579921 经度:106.596376
[2020-04-26 16:47:41] 纬度:29.57966 经度:106.5964
[2020-04-26 16:47:42] 纬度:29.579361 经度:106.596518
[2020-04-26 16:47:44] 纬度:29.579113 经度:106.596688
[2020-04-26 16:47:45] 纬度:29.577621 经度:106.597758
[2020-04-26 16:47:46] 纬度:29.577493 经度:106.597786
[2020-04-26 16:47:47] 纬度:29.577223 经度:106.597826
[2020-04-26 16:47:48] 纬度:29.577126 经度:106.597873
[2020-04-26 16:47:49] 纬度:29.576851 经度:106.597888
[2020-04-26 16:47:50] 纬度:29.576398 经度:106.597788
[2020-04-26 16:47:51] 纬度:29.57626 经度:106.597645
[2020-04-26 16:47:52] 纬度:29.576173 经度:106.59744
[2020-04-26 16:47:54] 纬度:29.576155 经度:106.597366
[2020-04-26 16:47:55] 纬度:29.576161 经度:106.597295
[2020-04-26 16:47:56] 纬度:29.576156 经度:106.597103
[2020-04-26 16:47:57] 纬度:29.576163 经度:106.597018
[2020-04-26 16:47:58] 纬度:29.576183 经度:106.596796
[2020-04-26 16:47:59] 纬度:29.57617 经度:106.596551
[2020-04-26 16:48:00] 纬度:29.576128 经度:106.59605
[2020-04-26 16:48:01] 纬度:29.576055 经度:106.595771
[2020-04-26 16:48:02] 纬度:29.575778 经度:106.595018
[2020-04-26 16:48:04] 纬度:29.57571 经度:106.594866
[2020-04-26 16:48:05] 纬度:29.575561 经度:106.594543
[2020-04-26 16:48:06] 纬度:29.575486 经度:106.594506
[2020-04-26 16:48:07] 纬度:29.575436 经度:106.594505
[2020-04-26 16:48:08] 纬度:29.575385 经度:106.594511
[2020-04-26 16:48:09] 纬度:29.575216 经度:106.594491
[2020-04-26 16:48:10] 纬度:29.575196 经度:106.594468
[2020-04-26 16:48:11] 纬度:29.575178 经度:106.594391
[2020-04-26 16:48:12] 纬度:29.575181 经度:106.594345
[2020-04-26 16:48:14] 纬度:29.575205 经度:106.594196
[2020-04-26 16:48:15] 纬度:29.575305 经度:106.593868
[2020-04-26 16:48:16] 纬度:29.57537 经度:106.59372
[2020-04-26 16:48:17] 纬度:29.575435 经度:106.59363
[2020-04-26 16:48:18] 纬度:29.575543 经度:106.593523
[2020-04-26 16:48:19] 纬度:29.575731 经度:106.5933
[2020-04-26 16:48:20] 纬度:29.575753 经度:106.593236
[2020-04-26 16:48:21] 纬度:29.575788 经度:106.593095
[2020-04-26 16:48:22] 纬度:29.575965 经度:106.59263
[2020-04-26 16:48:23] 纬度:29.576035 经度:106.59258
[2020-04-26 16:48:25] 纬度:29.576106 经度:106.592545
[2020-04-26 16:48:26] 纬度:29.576258 经度:106.592495
[2020-04-26 16:48:27] 纬度:29.576691 经度:106.592303
[2020-04-26 16:48:28] 纬度:29.576761 经度:106.592215
[2020-04-26 16:48:29] 纬度:29.57682 经度:106.592118
start.py
View file @
d3c9a7c6
...
...
@@ -11,7 +11,7 @@ def startSimulaterService():
autoCarObj
.
setSendDur
(
1
)
# 设置发送消息的间隔时间
autoCarObj
.
setTimeout
(
30
)
# 设置socket超时时间
autoCarObj
.
setChangeGPSLineTime
(
1
*
2
*
60
)
# 设置跑完一条轨迹后,进入下一条轨迹的时间(请设置至少大于4分钟的时间)
autoCarObj
.
setServiceTime
(
1
*
4
*
60
)
# 设置整个服务的持续时间
autoCarObj
.
setServiceTime
(
1
*
5
*
60
)
# 设置整个服务的持续时间
autoCarObj
.
setOilExpend
(
10
)
# 设置1L 油跑多少公里
autoCarObj
.
setSpeed
(
80
)
#设置车速,每小时多少公里
...
...
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