Skip to content

Commit 43ea8b3

Browse files
committed
AtomSwing対応
1 parent 41e9c04 commit 43ea8b3

File tree

1 file changed

+33
-8
lines changed

1 file changed

+33
-8
lines changed

atomcam_configs/overlay_rootfs/scripts/atom_init.sh

+33-8
Original file line numberDiff line numberDiff line change
@@ -2,46 +2,71 @@
22

33
export PATH=/tmp/system/bin:/system/bin:/bin:/sbin:/usr/bin:/usr/sbin
44
export LD_LIBRARY_PATH=/thirdlib:/system/lib:/tmp
5+
PRODUCT_CONFIG=/configs/.product_config
6+
PRODUCT_MODEL=$(awk -F "=" '/PRODUCT_MODEL *=/ {print $2}' $PRODUCT_CONFIG)
57

68
sleep 1
9+
710
insmod /system/driver/tx-isp-t31.ko isp_clk=100000000
811
insmod /system/driver/exfat.ko
9-
insmod /system/driver/audio.ko spk_gpio=-1
12+
if [ "ATOM_CAKP1JZJP" = "$PRODUCT_MODEL" ] ; then
13+
insmod /system/driver/audio.ko spk_gpio=-1 alc_mode=0 mic_gain=0
14+
else
15+
insmod /system/driver/audio.ko spk_gpio=-1
16+
fi
1017
insmod /system/driver/avpu.ko
1118
insmod /system/driver/sinfo.ko
1219
insmod /system/driver/sample_pwm_core.ko
1320
insmod /system/driver/sample_pwm_hal.ko
1421
insmod /system/driver/speaker_ctl.ko
1522

23+
devmem 0x10011110 32 0x6e094800
24+
devmem 0x10011138 32 0x300
25+
devmem 0x10011134 32 0x300
26+
1627
VENDERID="0x024c"
1728
if [ -f /system/driver/mmc_detect_test.ko ]; then
1829
insmod /system/driver/mmc_detect_test.ko
1930
while [ ! -f /sys/bus/mmc/devices/mmc1\:0001/mmc1\:0001\:1/vendor ]; do
20-
sleep 0.1
31+
sleep 0.1
2132
done
2233
VENDERID=`cat /sys/bus/mmc/devices/mmc1\:0001/mmc1\:0001\:1/vendor`
2334
fi
2435
if [ "0x024c" = "$VENDERID" ]; then
25-
insmod /system/driver/rtl8189ftv.ko
36+
insmod /system/driver/rtl8189ftv.ko
2637
elif [ "0x007a" = "$VENDERID" ]; then
27-
insmod /thirdlib/atbm603x_wifi_sdio.ko
38+
[ -f /usr/share/atbm603x_conf/atbm_txpwer_dcxo_cfg.txt ] && cp /usr/share/atbm603x_conf/atbm_txpwer_dcxo_cfg.txt /tmp
39+
[ -f /usr/share/atbm603x_conf/set_rate_power.txt ] && cp /usr/share/atbm603x_conf/set_rate_power.txt /tmp
40+
[ -f /thirdlib/atbm603x_wifi_sdio.ko ] && insmod /thirdlib/atbm603x_wifi_sdio.ko
41+
[ -f /system/driver/atbm603x_wifi_sdio.ko ] && insmod /system/driver/atbm603x_wifi_sdio.ko
42+
sleep 1
43+
if [ ! -f /sys/module/atbm603x_wifi_sdio/parameters/fw_ver ]; then
44+
sync
45+
echo 3 > /proc/sys/vm/drop_caches
46+
[ -f /thirdlib/atbm603x_wifi_sdio.ko ] && insmod /thirdlib/atbm603x_wifi_sdio.ko
47+
[ -f /system/driver/atbm603x_wifi_sdio.ko ] && insmod /system/driver/atbm603x_wifi_sdio.ko
48+
fi
49+
elif [ "0x5653" = "$VENDERID" ]; then
50+
insmod /system/driver/ssv6x5x.ko stacfgpath=/system/driver/ssv6x5x-wifi.cfg
51+
elif [ "0x424c" = "$VENDERID" ]; then
52+
insmod /system/driver/bl_fdrv.ko
2853
fi
2954

30-
devmem 0x10011110 32 0x6e094800
31-
devmem 0x10011138 32 0x300
32-
devmem 0x10011134 32 0x300
55+
mkdir -p /tmp/app
3356
touch /tmp/resolv.conf
3457
mkdir -p /tmp/log
3558
chmod 777 /tmp/log
3659

3760
/system/bin/ver-comp
3861
/system/bin/assis >> /tmp/log/assis.log 2>&1 &
3962

63+
[ "ATOM_CAKP1JZJP" = "$PRODUCT_MODEL" ] && insmod /system/driver/sample_motor.ko
64+
4065
/system/bin/hl_client >> /tmp/log/hl_client.log 2>&1 &
4166

4267
LD_PRELOAD=/tmp/system/modules/libcallback.so /system/bin/iCamera_app >> /tmp/log/atom.log 2>&1 &
4368

44-
/system/bin/dongle_app >> /tmp/log/dongle.log &
69+
[ "AC1" = "$PRODUCT_MODEL" ] && /system/bin/dongle_app >> /tmp/log/dongle.log &
4570

4671
(
4772
while sleep 3600

0 commit comments

Comments
 (0)