4 # Dual Channel Wi-Fi Startup Script
6 # This script creates the proper network bridge configuration
7 # necessary for Dual Channel Wi-Fi, and starts the dcwapd daemon
10 # Note - shellcheck cannot deal with the dynamic sourcing
11 # shellcheck disable=SC1090
12 # which also messes with variables defined in the sourced file
13 # shellcheck disable=SC2154
14 scriptdir
=$
(dirname -- "$(readlink -f -- "$0")")
15 .
"$scriptdir"/dcwapd.inc
18 # get the list of channel sets
21 for channelset
in $channelsets; do
22 if [ -n "$channelset" ]; then
23 get_channelset_enabled
"$channelset"
25 if [ "$enabled" = "1" ]; then
26 # the channel set is enabled
28 # get the list of data channels used by the channel set
29 get_datachannels
"$channelset"
31 for datachannel
in $datachannels; do
32 datachannel_up
"$datachannel"
38 # start dcwapd, sending stdout and stderr to the system log
39 dcwapd
2>&1 | logger
&