Compared files  

Left
/fw/dreame.vacuum.p2041o/4.1.2_1107/xout/_root/usr/bin/do_start_ap.sh
Last modified2021-04-23 02:08:44
Size2.7 Kb (105 Lines)
EncodingLatin 1 - ANSI (CP1252) default
Right
/fw/dreame.vacuum.p2041/4.3.2_1108/xout/_root/usr/bin/do_start_ap.sh
Last modified2021-09-03 08:43:04
Size3.6 Kb (130 Lines)
EncodingLatin 1 - ANSI (CP1252) default


   Comparison Statistics  

Detailed Statistics

All Changes
 BlocksLines
Unchanged899
Inserted314
Deleted11
Ignored14
Changed218




   Comparison Details  

1 1 #!/bin/sh
2 2 #
3 # start ap (last 30 minites) 3 # start ap (keep 30 minites for release, keep 5 min for debug)
4 # version 0.0.3 4 # version 0.0.4
5 5 #
6 6 # set -x
7 7  
2 skipped lines
10 10 INTERVAL=2
11 11 MAX_TIMES=900
12 12 START_AP_FLAG=0
  13 CHANNEL=6
13 14  
14 15 LOG_FILE=/data/log/wifi.log
15 16  
15 skipped lines
31 32             sync
32 33  
33 34             START_AP_FLAG=1
  35             # wifi light flash slowly in ap mode
  36             if [ "$NEW_LIGHT_DISPLAY" == "yes" ]; then
  37                 set_wifi_light.sh flash
  38             else
  39                 set_wifi_light.sh flash_slow
  40             fi
  41             avacmd clb '{"type":"clb","cmd":"report_network_connect_mode","mode":0}' &
34             wifi_setup.sh ap 42             CHANNEL="${CHANNEL}" wifi_setup.sh ap
35 43             # we should start ble after wifi-ap
36 44             switch_ble start
37 45             # +++ We should empty IOT_FLAG before restart iot_sdk, this will make sure all iot sdk will be start.
19 skipped lines
57 65             then
58 66                 echo `date` "start station mode" >> ${LOG_FILE}
59 67                 rm -f ${AP_FLAG} && sync
  68                 # wifi flash_fastlight flash fast in ap mode
  69                 if [ "$NEW_LIGHT_DISPLAY" == "yes" ]; then
  70                     set_wifi_light.sh flash
  71                 else
  72                     set_wifi_light.sh flash_fast
  73                 fi
60 74                 wifi_setup.sh sta 20
61 75                 echo -n "INIT" > ${CONFIGNET_FLAG}
62 76             elif [[ _"${RET}" == _"AP" ]]
4 skipped lines
67 81             elif [[ _"${RET}" != _"INIT" ]]
68 82             then
69 83                 echo `date` "get ret=\"${RET}\"" >> ${LOG_FILE}
70                 echo -n "INIT" > ${CONFIGNET_FLAG}  
71 84             fi
72 85         fi
73 86  
3 skipped lines
77 90  
78 91     if [ ${cnt} -ge ${MAX_TIMES} ]
79 92     then
  93         if [ "$NEW_LIGHT_DISPLAY" == "yes" ]; then
  94             set_wifi_light.sh state_off
  95             avacmd clb '{"type":"clb","cmd":"report_network_connect_mode","mode":6}' &
  96         else
80         set_wifi_light.sh flash_slow 97             set_wifi_light.sh flash_slow
81         avacmd clb '{"type":"clb", "cmd":"report_network_connect_mode", "mode":1}' 98             avacmd clb '{"type":"clb","cmd":"report_network_connect_mode","mode":1}' &
  99         fi
82 100  
83 101         rm -f ${AP_FLAG} && sync
84 102         switch_ble stop
16 skipped lines
101 119     exit 1
102 120 }
103 121  
  122 if [ "$1" == "short_time" ]; then
  123     MAX_TIMES=150
  124     CHANNEL=$(($RANDOM % 11))
  125     let CHANNEL++
  126     log "set ap keep_time=5min, channel=$CHANNEL"
  127 fi
  128  
104 129 main
105 130  

   Text comparison Options  

Syntax colouring language used: Shell
Match character case: yes.
Match line endings: no.
Match spaces

At start of lines: yes,
In middle of lines: yes,
At end of lines: yes.
Blank lines as empty lines: no.
Activate comparison algorithm
At word level: yes,
At character level: no.


   Legend  

Unchanged lineExample of unchanged line
Modified lineExample of modified line
Added lineExample of added line
Removed lineExample of removed line
Ignored lineExample of ignored line