Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
Simple PCIe FMC carrier SPEC
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
50
Issues
50
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Simple PCIe FMC carrier SPEC
Commits
bc0b9676
Commit
bc0b9676
authored
Jun 29, 2020
by
Federico Vaga
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sw:py: dma_write returns the number of transfered bytes
Signed-off-by:
Federico Vaga
<
federico.vaga@cern.ch
>
parent
c6b97be4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
0 deletions
+2
-0
test_dma.py
pytest/test_dma.py
+1
-0
PySPEC.py
software/PySPEC/PySPEC/PySPEC.py
+1
-0
No files found.
pytest/test_dma.py
View file @
bc0b9676
...
...
@@ -65,6 +65,7 @@ class TestDma(object):
"""
spec
.
dma_start
()
spec
.
dma_write
(
0
,
b
"
\x00
"
*
dma_size
)
assert
count
==
dma_size
spec
.
dma_stop
()
...
...
software/PySPEC/PySPEC/PySPEC.py
View file @
bc0b9676
...
...
@@ -46,6 +46,7 @@ class PySPEC:
start
=
0
while
len
(
data
)
-
start
>
0
:
start
+=
self
.
dma_file
.
write
(
bytes
(
data
[
start
:]))
return
start
def
__dma_seek
(
self
,
offset
):
self
.
dma_file
.
seek
(
offset
)
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