Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
elphel-init
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Elphel
elphel-init
Commits
8aaefcf5
Commit
8aaefcf5
authored
Sep 16, 2016
by
Mikhail Karpenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move init script to /etc/elphel393
parent
1d073f8d
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
10 deletions
+18
-10
Makefile
src/Makefile
+9
-2
init_elphel393
src/init_elphel393
+2
-1
init_elphel393.sh
src/init_elphel393.sh
+7
-7
No files found.
src/Makefile
View file @
8aaefcf5
SYSCONFDIR
=
$(DESTDIR)
/etc
SYSCONFDIR
=
$(DESTDIR)
/etc
INITDIR
=
$(DESTDIR)
/etc/init.d
INITDIR
=
$(DESTDIR)
/etc/init.d
MODPROBEDIR
=
$(SYSCONFDIR)
/modprobe.d
DRIVER_NAME
=
ahci_elphel
CONFDIR
=
$(SYSCONFDIR)
/elphel393
OWN
=
-o
root
-g
root
OWN
=
-o
root
-g
root
...
@@ -17,8 +20,8 @@ install:
...
@@ -17,8 +20,8 @@ install:
# below depends on Yocto and the corresponding recipe
(
meta-core/init/init.bb
)
# below depends on Yocto and the corresponding recipe
(
meta-core/init/init.bb
)
sed
-e
's/192.168.0.9/$(REMOTE_IP)/'
$(SCRIPT1)
>
$(SCRIPT1).tmp
sed
-e
's/192.168.0.9/$(REMOTE_IP)/'
$(SCRIPT1)
>
$(SCRIPT1).tmp
$(INSTALL)
$(OWN)
-d
$(
SYS
CONFDIR)
$(INSTALL)
$(OWN)
-d
$(CONFDIR)
$(INSTALL)
$(OWN)
-m
$(INSTMODE)
$(SCRIPT1).tmp
$(
SYS
CONFDIR)/$(SCRIPT1)
$(INSTALL)
$(OWN)
-m
$(INSTMODE)
$(SCRIPT1).tmp
$(CONFDIR)/$(SCRIPT1)
rm
$(SCRIPT1).tmp
rm
$(SCRIPT1).tmp
#INITSTRING default is defined in local.conf, weak default - meta-core/init/init.bb
#INITSTRING default is defined in local.conf, weak default - meta-core/init/init.bb
...
@@ -27,5 +30,9 @@ install:
...
@@ -27,5 +30,9 @@ install:
$(INSTALL)
$(OWN)
-m
$(INSTMODE)
$(SCRIPT2).tmp
$(INITDIR)/$(SCRIPT2)
$(INSTALL)
$(OWN)
-m
$(INSTMODE)
$(SCRIPT2).tmp
$(INITDIR)/$(SCRIPT2)
rm
$(SCRIPT2).tmp
rm
$(SCRIPT2).tmp
# blacklist AHCI driver to prevent it from loading before FPGA is configured
$(INSTALL)
$(OWN)
-d
$(MODPROBEDIR)
echo
"blacklist $(DRIVER_NAME)"
>>
$(MODPROBEDIR)/blacklist.conf
clean
:
clean
:
@
echo
"make clean in src"
@
echo
"make clean in src"
src/init_elphel393
View file @
8aaefcf5
...
@@ -8,6 +8,7 @@ DESC="extra init scripts"
...
@@ -8,6 +8,7 @@ DESC="extra init scripts"
MNTPOINT
=
/mnt/mmc
MNTPOINT
=
/mnt/mmc
MMCDEV
=
/dev/mmcblk0p1
MMCDEV
=
/dev/mmcblk0p1
SOME_SCRIPT
=
init_elphel393.sh
SOME_SCRIPT
=
init_elphel393.sh
CONFDIR
=
/etc/elphel393
case
"
$1
"
in
case
"
$1
"
in
start
)
start
)
...
@@ -23,7 +24,7 @@ case "$1" in
...
@@ -23,7 +24,7 @@ case "$1" in
fi
fi
mount
$MMCDEV
$MNTPOINT
mount
$MMCDEV
$MNTPOINT
/etc
/
$SOME_SCRIPT
$CONFDIR
/
$SOME_SCRIPT
;;
;;
stop
)
stop
)
echo
-n
"Stopping
$DESC
: "
echo
-n
"Stopping
$DESC
: "
...
...
src/init_elphel393.sh
View file @
8aaefcf5
...
@@ -40,6 +40,13 @@ echo "start white balance daemon"
...
@@ -40,6 +40,13 @@ echo "start white balance daemon"
wget
-O
-
"localhost/parsedit.php?immediate&COMPRESSOR_RUN=2&DAEMON_EN=1&WB_EN=0x1&WB_MASK=0xd&WB_PERIOD=16&WB_WHITELEV=0xfae1&WB_WHITEFRAC=0x028f&WB_SCALE_R=0x10000&WB_SCALE_GB=0x10000&WB_SCALE_B=0x10000&WB_THRESH=500&GAIN_MIN=0x18000&GAIN_MAX=0xfc000&ANA_GAIN_ENABLE=1&GAINR=0x10000&GAING=0x10000&GAINGB=0x10000&GAINB=0x10000"
wget
-O
-
"localhost/parsedit.php?immediate&COMPRESSOR_RUN=2&DAEMON_EN=1&WB_EN=0x1&WB_MASK=0xd&WB_PERIOD=16&WB_WHITELEV=0xfae1&WB_WHITEFRAC=0x028f&WB_SCALE_R=0x10000&WB_SCALE_GB=0x10000&WB_SCALE_B=0x10000&WB_THRESH=500&GAIN_MIN=0x18000&GAIN_MAX=0xfc000&ANA_GAIN_ENABLE=1&GAINR=0x10000&GAING=0x10000&GAINGB=0x10000&GAINB=0x10000"
if
[
$SATA_EN
-eq
1
]
;
then
$PYDIR
/x393sata.py
modprobe ahci_elphel &
sleep
2
echo
1
>
/sys/devices/soc0/amba@0/80000000.elphel-ahci/load_module
fi
echo
"/etc/init_elphel393.sh done"
echo
"/etc/init_elphel393.sh done"
exit
0
exit
0
...
@@ -153,11 +160,4 @@ if [ -f /usr/bin/camogm ]; then
...
@@ -153,11 +160,4 @@ if [ -f /usr/bin/camogm ]; then
camogm
-n
$CAMOGM_PIPE
-p
$CAMOGM_PORT
&
camogm
-n
$CAMOGM_PIPE
-p
$CAMOGM_PORT
&
fi
fi
if
[
$SATA_EN
-eq
1
]
;
then
$PYDIR
/x393sata.py
modprobe ahci_elphel &
sleep
2
echo
1
>
/sys/devices/soc0/amba@0/80000000.elphel-ahci/load_module
fi
sync
sync
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