Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
meta-elphel393
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
meta-elphel393
Commits
c3f1e194
Commit
c3f1e194
authored
Jun 24, 2016
by
Oleg Dzhimiev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
moved mountpoints to /tmp
parent
1160b049
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
17 additions
and
13 deletions
+17
-13
camogm.js
recipes-core/apps-web/files/camogm.js
+3
-3
setup.php
recipes-core/apps-web/files/setup.php
+1
-1
init_elphel393
recipes-core/init-elphel393/files/init_elphel393
+6
-5
init-elphel393_1.0.bb
recipes-core/init-elphel393/init-elphel393_1.0.bb
+3
-0
90-elphel-automount.rules
recipes-core/udev-rules/files/90-elphel-automount.rules
+4
-4
No files found.
recipes-core/apps-web/files/camogm.js
View file @
c3f1e194
...
@@ -59,7 +59,7 @@ function init(){
...
@@ -59,7 +59,7 @@ function init(){
ct2
=
$
(
"<div style='padding-top:20px;'>"
);
ct2
=
$
(
"<div style='padding-top:20px;'>"
);
tmpstr
=
"Absolute path: <input id='abspath' style='text' value='/mnt/sda1' class='ap' />"
;
tmpstr
=
"Absolute path: <input id='abspath' style='text' value='/
tmp/
mnt/sda1' class='ap' />"
;
ct2
.
html
(
tmpstr
);
ct2
.
html
(
tmpstr
);
$
(
"#controls"
).
append
(
ct2
);
$
(
"#controls"
).
append
(
ct2
);
...
@@ -212,14 +212,14 @@ function get_files(){
...
@@ -212,14 +212,14 @@ function get_files(){
function
init_path
(){
function
init_path
(){
$
.
ajax
({
$
.
ajax
({
url
:
"camogm.php?cmd=list&path=/mnt"
,
url
:
"camogm.php?cmd=list&path=/
tmp/
mnt"
,
complete
:
function
(
data
){
complete
:
function
(
data
){
var
xml
=
data
.
responseXML
;
var
xml
=
data
.
responseXML
;
var
dirs
=
$
(
xml
).
find
(
"d"
);
var
dirs
=
$
(
xml
).
find
(
"d"
);
var
res
=
false
;
var
res
=
false
;
for
(
var
i
=
0
;
i
<
dirs
.
length
;
i
++
){
for
(
var
i
=
0
;
i
<
dirs
.
length
;
i
++
){
var
tmp
=
$
(
dirs
[
i
]).
text
();
var
tmp
=
$
(
dirs
[
i
]).
text
();
if
(
tmp
==
"/mnt/sda1"
)
{
if
(
tmp
==
"/
tmp/
mnt/sda1"
)
{
$
(
"#abspath"
).
val
(
tmp
);
$
(
"#abspath"
).
val
(
tmp
);
res
=
true
;
res
=
true
;
}
}
...
...
recipes-core/apps-web/files/setup.php
View file @
c3f1e194
...
@@ -136,7 +136,7 @@ if ($cmd=="find_sdram_phase"){
...
@@ -136,7 +136,7 @@ if ($cmd=="find_sdram_phase"){
}
}
function
get_sensor_type
(){
function
get_sensor_type
(){
$lastline
=
exec
(
"cat /
mnt/mm
c/init_elphel393.sh | grep
\"
SENSOR_TYPE=
\"
"
);
$lastline
=
exec
(
"cat /
et
c/init_elphel393.sh | grep
\"
SENSOR_TYPE=
\"
"
);
$res
=
explode
(
"="
,
$lastline
);
$res
=
explode
(
"="
,
$lastline
);
$res
[
1
]
=
intval
(
$res
[
1
]);
$res
[
1
]
=
intval
(
$res
[
1
]);
if
((
$res
[
1
]
!=
5
)
&&
(
$res
[
1
]
!=
14
))
$res
[
1
]
=
0
;
if
((
$res
[
1
]
!=
5
)
&&
(
$res
[
1
]
!=
14
))
$res
[
1
]
=
0
;
...
...
recipes-core/init-elphel393/files/init_elphel393
View file @
c3f1e194
...
@@ -5,7 +5,7 @@ DAEMON=/usr/sbin/init_elphel393
...
@@ -5,7 +5,7 @@ DAEMON=/usr/sbin/init_elphel393
NAME
=
init_elphel393
NAME
=
init_elphel393
DESC
=
"extra init scripts"
DESC
=
"extra init scripts"
MNTPOINT
=
/mnt/mmc
MNTPOINT
=
/
tmp/
mnt/mmc
MMCDEV
=
/dev/mmcblk0p1
MMCDEV
=
/dev/mmcblk0p1
SOME_SCRIPT
=
init_elphel393.sh
SOME_SCRIPT
=
init_elphel393.sh
...
@@ -19,12 +19,13 @@ case "$1" in
...
@@ -19,12 +19,13 @@ case "$1" in
#mount here
#mount here
echo
" Mounting Memory Card to
$MNTPOINT
"
echo
" Mounting Memory Card to
$MNTPOINT
"
if
[
!
-d
$MNTPOINT
]
;
then
if
[
!
-d
$MNTPOINT
]
;
then
mkdir
$MNTPOINT
mkdir
-p
$MNTPOINT
fi
fi
mount
$MMCDEV
$MNTPOINT
mount
$MMCDEV
$MNTPOINT
if
[
-f
$MNTPOINT
/
$SOME_SCRIPT
]
;
then
echo
" Launching
$SOME_SCRIPT
"
if
[
-f
/etc/
$SOME_SCRIPT
]
;
then
$MNTPOINT
/
$SOME_SCRIPT
echo
" Launching /etc/
$SOME_SCRIPT
"
/etc/
$SOME_SCRIPT
else
else
echo
"
$SOME_SCRIPT
not found. Nothing to launch."
echo
"
$SOME_SCRIPT
not found. Nothing to launch."
fi
fi
...
...
recipes-core/init-elphel393/init-elphel393_1.0.bb
View file @
c3f1e194
...
@@ -49,6 +49,9 @@ do_install_append() {
...
@@ -49,6 +49,9 @@ do_install_append() {
install -d ${D}${sysconfdir}/init.d
install -d ${D}${sysconfdir}/init.d
install -m 0755 ${WORKDIR}/init_elphel393 ${D}${sysconfdir}/init.d
install -m 0755 ${WORKDIR}/init_elphel393 ${D}${sysconfdir}/init.d
#install init script to /etc
install -m 0755 ${WORKDIR}/init_elphel393.sh ${D}${sysconfdir}/
for RLOC in ${PRODUCTION_ROOT_LOCATION}; do
for RLOC in ${PRODUCTION_ROOT_LOCATION}; do
if [ ! -d ${DEPLOY_DIR_IMAGE}/${RLOC} ]; then
if [ ! -d ${DEPLOY_DIR_IMAGE}/${RLOC} ]; then
mkdir -p ${DEPLOY_DIR_IMAGE}/${RLOC}
mkdir -p ${DEPLOY_DIR_IMAGE}/${RLOC}
...
...
recipes-core/udev-rules/files/90-elphel-automount.rules
View file @
c3f1e194
...
@@ -13,14 +13,14 @@ ENV{ID_FS_LABEL}=="", ENV{ID_FS_USAGE}=="", GOTO="quit_automount"
...
@@ -13,14 +13,14 @@ ENV{ID_FS_LABEL}=="", ENV{ID_FS_USAGE}=="", GOTO="quit_automount"
ENV{ID_FS_LABEL}=="", ENV{ID_FS_USAGE}=="filesystem", ENV{dir_name}="%k"
ENV{ID_FS_LABEL}=="", ENV{ID_FS_USAGE}=="filesystem", ENV{dir_name}="%k"
# Mount device to /media if it is not SSD
# Mount device to /media if it is not SSD
ACTION=="add", ENV{ID_ATA_SATA}!="1", RUN+="/bin/mkdir -p /
media/%E{dir_name}", RUN+="/bin/mount /dev/%k
/media/%E{dir_name}"
ACTION=="add", ENV{ID_ATA_SATA}!="1", RUN+="/bin/mkdir -p /
tmp/media/%E{dir_name}", RUN+="/bin/mount /dev/%k /tmp
/media/%E{dir_name}"
# Mound device to /mnt if it is SSD
# Mound device to /mnt if it is SSD
ACTION=="add", ENV{ID_ATA_SATA}=="1", RUN+="/bin/mkdir -p /
mnt/%E{dir_name}", RUN+="/bin/mount /dev/%k
/mnt/%E{dir_name}"
ACTION=="add", ENV{ID_ATA_SATA}=="1", RUN+="/bin/mkdir -p /
tmp/mnt/%E{dir_name}", RUN+="/bin/mount /dev/%k /tmp
/mnt/%E{dir_name}"
# Delete directory after removal
# Delete directory after removal
ACTION=="remove", ENV{ID_ATA_SATA}!="1", ENV{dir_name}!="", RUN+="/bin/rmdir /media/%E{dir_name}"
ACTION=="remove", ENV{ID_ATA_SATA}!="1", ENV{dir_name}!="", RUN+="/bin/rmdir /
tmp/
media/%E{dir_name}"
ACTION=="remove", ENV{ID_ATA_SATA}=="1", ENV{dir_name}!="", RUN+="/bin/rmdir /mnt/%E{dir_name}"
ACTION=="remove", ENV{ID_ATA_SATA}=="1", ENV{dir_name}!="", RUN+="/bin/rmdir /
tmp/
mnt/%E{dir_name}"
# Exit point
# Exit point
LABEL="quit_automount"
LABEL="quit_automount"
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