Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
Software for White Rabbit PTP Core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
32
Issues
32
List
Board
Labels
Milestones
Merge Requests
7
Merge Requests
7
CI / CD
CI / CD
Pipelines
Schedules
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
Software for White Rabbit PTP Core
Commits
c2da691b
Commit
c2da691b
authored
Mar 30, 2021
by
Juan David González Cobas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add installation script to repository
parent
d0543eab
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
31 additions
and
0 deletions
+31
-0
ertm-setup
libertm/ertm-setup
+31
-0
No files found.
libertm/ertm-setup
0 → 100755
View file @
c2da691b
#!/bin/sh
SCRIPT_DIR
=
$(
readlink
-f
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
))
SERIAL_LINE
=
/dev/ttyUSB2
# override default serial line if need be
if
[
x
"
$1
"
!=
x
""
]
;
then
SERIAL_LINE
=
"
$1
"
fi
# ensure existence of the serial line
if
!
[
-c
"
$SERIAL_LINE
"
]
;
then
echo
"serial device
$SERIAL_LINE
not present, exiting"
>
&2
exit
1
fi
# ensure permissions on the serial line
chmod
-f
777
"
$SERIAL_LINE
"
||
[
-r
$SERIAL_LINE
-o
-w
$SERIAL_LINE
]
||
(
echo
"cannot r/w serial line
$SERIAL_LINE
, please run as root"
2>&1
exit
)
# wrc.bin embedded firmware loading
BOOTLOADER
=
$SCRIPT_DIR
/usb-bootloader.py
SPEED
=
921600
WRC_BIN
=
$SCRIPT_DIR
/../lib/wrc.bin
PYTHON
=
$SCRIPT_DIR
/../pyenv/bin/python3
# load wrc.bin firmware
$PYTHON
$BOOTLOADER
-b
default
-s
$SPEED
-p
$SERIAL_LINE
$WRC_BIN
sleep
7
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