Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
ebpfCAT
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
karaboDevices
ebpfCAT
Commits
d6861e58
Commit
d6861e58
authored
3 months ago
by
Martin Teichmann
Browse files
Options
Downloads
Patches
Plain Diff
allocate mailbox lock early
parent
74ae1989
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
ebpfcat/ethercat.py
+3
-3
3 additions, 3 deletions
ebpfcat/ethercat.py
with
3 additions
and
3 deletions
ebpfcat/ethercat.py
+
3
−
3
View file @
d6861e58
...
@@ -572,13 +572,12 @@ class Terminal:
...
@@ -572,13 +572,12 @@ class Terminal:
assert
relative
is
not
None
or
absolute
is
not
None
assert
relative
is
not
None
or
absolute
is
not
None
if
absolute
is
None
:
if
absolute
is
None
:
absolute
=
await
self
.
ec
.
find_free_address
()
absolute
=
await
self
.
ec
.
find_free_address
()
self
.
mbx_lock
=
self
.
ec
.
get_mbx_lock
(
absolute
)
if
relative
is
not
None
:
if
relative
is
not
None
:
await
self
.
ec
.
roundtrip
(
ECCmd
.
APWR
,
relative
,
0x10
,
"
H
"
,
absolute
)
await
self
.
ec
.
roundtrip
(
ECCmd
.
APWR
,
relative
,
0x10
,
"
H
"
,
absolute
)
self
.
position
=
absolute
self
.
position
=
absolute
self
.
mbx_lock
=
self
.
ec
.
get_mbx_lock
(
self
.
position
)
await
self
.
set_state
(
0x11
)
await
self
.
to_operational
(
MachineState
.
INIT
)
await
self
.
set_state
(
1
)
fmmu_no
,
=
await
self
.
read
(
4
,
"
B
"
)
fmmu_no
,
=
await
self
.
read
(
4
,
"
B
"
)
self
.
fmmu_used
=
[
None
]
*
fmmu_no
self
.
fmmu_used
=
[
None
]
*
fmmu_no
...
@@ -604,6 +603,7 @@ class Terminal:
...
@@ -604,6 +603,7 @@ class Terminal:
return
await
self
.
initialize
(
relative
=
relative
)
return
await
self
.
initialize
(
relative
=
relative
)
else
:
else
:
self
.
position
=
absolute
self
.
position
=
absolute
self
.
mbx_lock
=
self
.
ec
.
get_mbx_lock
(
self
.
position
)
state
,
*
_
=
await
self
.
get_state
()
state
,
*
_
=
await
self
.
get_state
()
if
state
is
MachineState
.
INIT
:
if
state
is
MachineState
.
INIT
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment