Site Tools


Hotfix release available: 2025-05-14b "Librarian". upgrade now! [56.2] (what's this?)
Hotfix release available: 2025-05-14a "Librarian". upgrade now! [56.1] (what's this?)
New release available: 2025-05-14 "Librarian". upgrade now! [56] (what's this?)
Hotfix release available: 2024-02-06b "Kaos". upgrade now! [55.2] (what's this?)
Hotfix release available: 2024-02-06a "Kaos". upgrade now! [55.1] (what's this?)
New release available: 2024-02-06 "Kaos". upgrade now! [55] (what's this?)
Hotfix release available: 2023-04-04b "Jack Jackrum". upgrade now! [54.2] (what's this?)
Hotfix release available: 2023-04-04a "Jack Jackrum". upgrade now! [54.1] (what's this?)
New release available: 2023-04-04 "Jack Jackrum". upgrade now! [54] (what's this?)
Hotfix release available: 2022-07-31b "Igor". upgrade now! [53.1] (what's this?)
Hotfix release available: 2022-07-31a "Igor". upgrade now! [53] (what's this?)
New release available: 2022-07-31 "Igor". upgrade now! [52.2] (what's this?)
New release candidate 2 available: rc2022-06-26 "Igor". upgrade now! [52.1] (what's this?)
New release candidate available: 2022-06-26 "Igor". upgrade now! [52] (what's this?)
Hotfix release available: 2020-07-29a "Hogfather". upgrade now! [51.4] (what's this?)
New release available: 2020-07-29 "Hogfather". upgrade now! [51.3] (what's this?)
New release candidate 3 available: 2020-06-09 "Hogfather". upgrade now! [51.2] (what's this?)
New release candidate 2 available: 2020-06-01 "Hogfather". upgrade now! [51.1] (what's this?)
New release candidate available: 2020-06-01 "Hogfather". upgrade now! [51] (what's this?)
Hotfix release available: 2018-04-22c "Greebo". upgrade now! [50.3] (what's this?)
Hotfix release available: 2018-04-22b "Greebo". upgrade now! [50.2] (what's this?)
Hotfix release available: 2018-04-22a "Greebo". upgrade now! [50.1] (what's this?)
New release available: 2018-04-22 "Greebo". upgrade now! [50] (what's this?)
Hotfix release available: 2017-02-19g "Frusterick Manners". upgrade now! [49.7] (what's this?)
Hotfix release available: 2017-02-19f "Frusterick Manners". upgrade now! [49.6] (what's this?)
Hotfix release available: 2017-02-19e "Frusterick Manners". upgrade now! [49.5] (what's this?)
Hotfix release available fixing CVE-2017-12979 and CVE-2017-12980: 2017-02-19d "Frusterick Manners". upgrade now! [49.4] (what's this?)
Hotfix release available fixing CVE-2017-12583: 2017-02-19c "Frusterick Manners". upgrade now! [49.3] (what's this?)
pan:slave_operation

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
pan:slave_operation [2017/10/29 02:47]
1.241.172.144
pan:slave_operation [2017/11/08 12:29] (current)
1.241.172.144
Line 220: Line 220:
 # hciconfig -a # hciconfig -a
 hci0:   Type: Primary ​ Bus: UART hci0:   Type: Primary ​ Bus: UART
-        BD Address: 00:18:9A:07:DC:7A  ACL MTU: 620:5  SCO MTU: 64:8+        BD Address: 00:18:9A:26:93:23  ACL MTU: 620:5  SCO MTU: 64:8
         DOWN         DOWN
         RX bytes:891 acl:0 sco:0 events:23 errors:0         RX bytes:891 acl:0 sco:0 events:23 errors:0
Line 238: Line 238:
 # hciconfig -a # hciconfig -a
 hci0:   Type: Primary ​ Bus: UART hci0:   Type: Primary ​ Bus: UART
-        BD Address: 00:18:9A:07:DC:7A  ACL MTU: 620:5  SCO MTU: 64:8+        BD Address: 00:18:9A:26:93:23  ACL MTU: 620:5  SCO MTU: 64:8
         UP RUNNING         UP RUNNING
         RX bytes:1754 acl:0 sco:0 events:45 errors:0         RX bytes:1754 acl:0 sco:0 events:45 errors:0
Line 261: Line 261:
 # hciconfig -a # hciconfig -a
 hci0:   Type: Primary ​ Bus: UART hci0:   Type: Primary ​ Bus: UART
-        BD Address: 00:18:9A:07:DC:7A  ACL MTU: 620:5  SCO MTU: 64:8+        BD Address: 00:18:9A:26:93:23  ACL MTU: 620:5  SCO MTU: 64:8
         UP RUNNING PSCAN ISCAN         UP RUNNING PSCAN ISCAN
         RX bytes:2102 acl:0 sco:0 events:49 errors:0         RX bytes:2102 acl:0 sco:0 events:49 errors:0
Line 308: Line 308:
 [hci0] [hci0]
   Name: VI-0 [rw]   Name: VI-0 [rw]
-  Address: 00:18:9A:07:DC:7A+  Address: 00:18:9A:26:93:23
   Class: 0x0   Class: 0x0
   Discoverable:​ 1 [rw]   Discoverable:​ 1 [rw]
Line 327: Line 327:
 [hci0] [hci0]
   Name: VI-0 [rw]   Name: VI-0 [rw]
-  Address: 00:18:9A:07:DC:7A+  Address: 00:18:9A:26:93:23
   Class: 0x0   Class: 0x0
   Discoverable:​ 1 [rw]   Discoverable:​ 1 [rw]
Line 354: Line 354:
   Paired: 1   Paired: 1
   RSSI: -70   RSSI: -70
 +[F4:​06:​69:​56:​B1:​47]
 +  Name: (null)
 +  Alias: F4-06-69-56-B1-47
 +  Address: F4:​06:​69:​56:​B1:​47
 +  Icon: computer
 +  Class: 0x12010c
 +  LegacyPairing:​ 0
 +  Paired: 0
 +  RSSI: -83
 +
 +bluetoothd[204]:​ Unknown command complete for opcode 37
 +[00:​18:​9A:​07:​DC:​7A]
 +  Name: (null)
 +  Alias: 00-18-9A-07-DC-7A
 +  Address: 00:​18:​9A:​07:​DC:​7A
 +  Icon: computer
 +  Class: 0x420100
 +  LegacyPairing:​ 0
 +  Paired: 0
 +  RSSI: -73
 +
 +bluetoothd[204]:​ Unknown command complete for opcode 37
  
 Done Done
Line 361: Line 383:
  
 <​code>​ <​code>​
-# bt-device -c 24:DB:ED:F2:53:4F +# bt-device -c 00:18:9A:07:DC:7A 
-Connecting to: 24:DB:ED:F2:53:4F +Connecting to: 00:18:9A:07:DC:7A 
- +DeviceVI-0 (00:18:9A:07:DC:7A) 
-Attempting to pair with 24:DB:ED:F2:53:4F +Access Bluetooth Address File 
-Request confirmation +Fail to Read Bluetooth Address File 
-Confirm passkey 336667 ​(yes/no): yes+Address :00515194(0x0007dc7a) 
 +PIN code:11278784 
 +bluetoothd[204]:​ input-headset driver probe failed for device 00:​18:​9A:​07:​DC:​7A 
 +Done 
 +#
 </​code>​ </​code>​
  
Line 372: Line 398:
  
 <​code>​ <​code>​
-# bt-network -c 24:DB:ED:F2:53:4F nap & +#bt-network -c 00:18:9A:07:DC:7A nap & 
-Network service is connected +Network service is connected 
-bluetoothd[225]: bnep0 connected+bluetoothd[204]: bnep0 connected
 Interface: bnep0 Interface: bnep0
 UUID: NAP (00001116-0000-1000-8000-00805f9b34fb) UUID: NAP (00001116-0000-1000-8000-00805f9b34fb)
 +#
 </​code>​ </​code>​
  
Line 382: Line 409:
  
 <​code>​ <​code>​
-ifconfig +ifconfig 
-bnep0     Link encap:​Ethernet ​ HWaddr 00:18:9A:07:DC:7A +bnep0     Link encap:​Ethernet ​ HWaddr 00:18:9A:26:93:23 
-          inet6 addr: fe80::​218:​9aff:​fe07:dc7a/64 Scope:Link+          inet6 addr: fe80::​218:​9aff:​fe26:9323/64 Scope:Link
           UP BROADCAST RUNNING MULTICAST ​ MTU:​1500 ​ Metric:1           UP BROADCAST RUNNING MULTICAST ​ MTU:​1500 ​ Metric:1
-          RX packets:errors:0 dropped:0 overruns:0 frame:0 +          RX packets:errors:0 dropped:0 overruns:0 frame:0 
-          TX packets:10 errors:0 dropped:0 overruns:0 carrier:0 +          TX packets:13 errors:0 dropped:0 overruns:0 carrier:0
-          collisions:​0 txqueuelen:​1000 +
-          RX bytes:12 (12.0 B)  TX bytes:663 (663.0 B) +
- +
-eth0      Link encap:​Ethernet ​ HWaddr 62:​03:​47:​49:​CB:​F3 +
-          inet addr:​192.168.28.28 ​ Bcast:​192.168.28.255 ​ Mask:​255.255.255.0 +
-          inet6 addr: fe80::​6003:​47ff:​fe49:​cbf3/​64 Scope:​Link +
-          UP BROADCAST RUNNING MULTICAST ​ MTU:​1500 ​ Metric:1 +
-          RX packets:​9565 errors:0 dropped:1 overruns:0 frame:0 +
-          TX packets:​4808 ​errors:0 dropped:0 overruns:0 carrier:0+
           collisions:​0 txqueuelen:​1000           collisions:​0 txqueuelen:​1000
-          RX bytes:9858251 ​(9.4 MiB)  TX bytes:809360 ​(790.3 KiB) +          RX bytes:315 (315.0 B)  TX bytes:858 (858.0 B)
-          Interrupt:​29+
  
 lo        Link encap:Local Loopback lo        Link encap:Local Loopback
Line 422: Line 439:
  
 <​code>​ <​code>​
-# ifconfig bnep0 add 192.168.28.38+# ifconfig bnep0 add 172.16.10.
 +# ifconfig 
 +bnep0     Link encap:​Ethernet ​ HWaddr 00:​18:​9A:​26:​93:​23 
 +          inet addr:​172.16.10.2 ​ Bcast:​172.16.255.255 ​ Mask:​255.255.0.0 
 +          inet6 addr: fe80::​218:​9aff:​fe26:​9323/​64 Scope:​Link 
 +          UP BROADCAST RUNNING MULTICAST ​ MTU:​1500 ​ Metric:1 
 +          RX packets:3 errors:0 dropped:0 overruns:0 frame:0 
 +          TX packets:16 errors:0 dropped:0 overruns:0 carrier:0 
 +          collisions:​0 txqueuelen:​1000 
 +          RX bytes:319 (319.0 B)  TX bytes:1040 (1.0 KiB) 
 + 
 +lo        Link encap:Local Loopback 
 +          inet addr:​127.0.0.1 ​ Mask:​255.0.0.0 
 +          inet6 addr: ::1/128 Scope:​Host 
 +          UP LOOPBACK RUNNING ​ MTU:​65536 ​ Metric:1 
 +          RX packets:0 errors:0 dropped:0 overruns:0 frame:0 
 +          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 
 +          collisions:​0 txqueuelen:​1 
 +          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
 </​code>​ </​code>​
  
Line 429: Line 464:
 <​code>​ <​code>​
 # ifconfig # ifconfig
-bnep0     Link encap:​Ethernet ​ HWaddr 00:18:9A:07:DC:7A +bnep0     Link encap:​Ethernet ​ HWaddr 00:18:9A:26:93:23 
-          inet addr:​192.168.28.38 ​ Bcast:​192.168.28.255 ​ Mask:​255.255.255.0 +          inet6 addr: fe80::​218:​9aff:​fe26:9323/64 Scope:Link
-          inet6 addr: fe80::​218:​9aff:​fe07:dc7a/64 Scope:Link+
           UP BROADCAST RUNNING MULTICAST ​ MTU:​1500 ​ Metric:1           UP BROADCAST RUNNING MULTICAST ​ MTU:​1500 ​ Metric:1
-          RX packets:errors:0 dropped:0 overruns:0 frame:0 +          RX packets:errors:0 dropped:0 overruns:0 frame:0 
-          TX packets:14 errors:0 dropped:0 overruns:0 carrier:0+          TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
           collisions:​0 txqueuelen:​1000           collisions:​0 txqueuelen:​1000
-          RX bytes:16 (16.0 B)  TX bytes:910 (910.0 B) +          RX bytes:182 (182.0 B)  TX bytes:663 (663.0 B)
- +
-eth0      Link encap:​Ethernet ​ HWaddr 62:​03:​47:​49:​CB:​F3 +
-          inet addr:​192.168.28.28 ​ Bcast:​192.168.28.255 ​ Mask:​255.255.255.0 +
-          inet6 addr: fe80::​6003:​47ff:​fe49:​cbf3/​64 Scope:​Link +
-          UP BROADCAST RUNNING MULTICAST ​ MTU:​1500 ​ Metric:1 +
-          RX packets:​9658 errors:0 dropped:1 overruns:0 frame:0 +
-          TX packets:​4884 errors:0 dropped:0 overruns:0 carrier:0 +
-          collisions:​0 txqueuelen:​1000 +
-          RX bytes:​9869022 (9.4 MiB)  TX bytes:​824340 (805.0 KiB) +
-          Interrupt:​29+
  
 lo        Link encap:Local Loopback lo        Link encap:Local Loopback
 +          inet addr:​127.0.0.1 ​ Mask:​255.0.0.0
 +          inet6 addr: ::1/128 Scope:Host
 +          UP LOOPBACK RUNNING ​ MTU:​65536 ​ Metric:1
 +          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
 +          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
 +          collisions:​0 txqueuelen:​1
 +          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
 +</​code>​
 +
 +외부와의 Network 연결을 위한 Gateway 설정
 +
 +<​code>​
 +
 +# route
 +Kernel IP routing table
 +Destination ​    ​Gateway ​        ​Genmask ​        Flags Metric Ref    Use Iface
 +172.16.0.0 ​     *               ​255.255.0.0 ​    ​U ​    ​0 ​     0        0 bnep0
 +# route add default gw 172.16.10.1
 +# route
 +Kernel IP routing table
 +Destination ​    ​Gateway ​        ​Genmask ​        Flags Metric Ref    Use Iface
 +default ​        ​172.16.10.1 ​    ​0.0.0.0 ​        ​UG ​   0      0        0 bnep0
 +172.16.0.0 ​     *               ​255.255.0.0 ​    ​U ​    ​0 ​     0        0 bnep0
 +#
 +
 +</​code>​
 +
 +NAP(BT-AP)으로의 Local Address Ping Test
 +
 +<​code>​
 +
 +# ping 172.16.10.1
 +PING 172.16.10.1 (172.16.10.1):​ 56 data bytes
 +64 bytes from 172.16.10.1:​ seq=0 ttl=64 time=51.988 ms
 +64 bytes from 172.16.10.1:​ seq=1 ttl=64 time=69.315 ms
 +64 bytes from 172.16.10.1:​ seq=2 ttl=64 time=62.093 ms
 +64 bytes from 172.16.10.1:​ seq=3 ttl=64 time=57.377 ms
 +^C
 +--- 172.16.10.1 ping statistics ---
 +4 packets transmitted,​ 4 packets received, 0% packet loss
 +round-trip min/avg/max = 51.988/​60.193/​69.315 ms
 +#
 +</​code>​
 +
 +NAP(BT-AP)으로의 외부 Address Ping Test
 +
 +<​code>​
 +
 +# ping 192.168.28.28
 +PING 192.168.28.28 (192.168.28.28):​ 56 data bytes
 +64 bytes from 192.168.28.28:​ seq=0 ttl=64 time=97.868 ms
 +64 bytes from 192.168.28.28:​ seq=1 ttl=64 time=69.902 ms
 +64 bytes from 192.168.28.28:​ seq=2 ttl=64 time=56.526 ms
 +^C
 +--- 192.168.28.28 ping statistics ---
 +3 packets transmitted,​ 3 packets received, 0% packet loss
 +round-trip min/avg/max = 56.526/​74.765/​97.868 ms
 +#
 +
 +</​code>​
 +
 +외부 Network 으로의 Ping Test
 +
 +<​code>​
 +
 +# ping 192.168.28.100
 +PING 192.168.28.100 (192.168.28.100):​ 56 data bytes
 +64 bytes from 192.168.28.100:​ seq=0 ttl=127 time=70.940 ms
 +64 bytes from 192.168.28.100:​ seq=1 ttl=127 time=54.995 ms
 +64 bytes from 192.168.28.100:​ seq=2 ttl=127 time=61.538 ms
 +^C
 +--- 192.168.28.100 ping statistics ---
 +3 packets transmitted,​ 3 packets received, 0% packet loss
 +round-trip min/avg/max = 54.995/​62.491/​70.940 ms
 +#
 +
 +</​code>​
 +
 +외부 Internet (Google의 DNS서버)으로의 Ping Test
 +
 +<​code>​
 +
 +# ping 8.8.8.8
 +PING 8.8.8.8 (8.8.8.8): 56 data bytes
 +64 bytes from 8.8.8.8: seq=0 ttl=53 time=94.536 ms
 +64 bytes from 8.8.8.8: seq=1 ttl=53 time=117.943 ms
 +64 bytes from 8.8.8.8: seq=2 ttl=53 time=101.969 ms
 +^C
 +--- 8.8.8.8 ping statistics ---
 +3 packets transmitted,​ 3 packets received, 0% packet loss
 +round-trip min/avg/max = 94.536/​104.816/​117.943 ms
 +#
 +
 +</​code>​
 +
 +/​etc/​network/​interfaces
 +
 +<​code>​
 +auto lo
 +iface lo inet loopback
 +</​code>​
 +
 +/​etc/​init.d/​S40network
 +
 +<​code>​
 +#!/bin/sh
 +#
 +# Start the network....
 +#
 +
 +# Debian ifupdown needs the /​run/​network lock directory
 +mkdir -p /​run/​network
 +
 +case "​$1"​ in
 +  start)
 + printf "​Starting network: "
 + /​usr/​sbin/​inetd
 + [ $? = 0 ] && echo "inetd OK" || echo "inetd FAIL"
 + /sbin/ifup -a
 + [ $? = 0 ] && echo "ifup OK" || echo "ifup FAIL"
 + ;;
 +  stop)
 + printf "​Stopping network: "
 + /​sbin/​ifdown -a
 + [ $? = 0 ] && echo "​OK"​ || echo "​FAIL"​
 + ;;
 +  restart|reload)
 + "​$0"​ stop
 + "​$0"​ start
 + ;;
 +  *)
 + echo "​Usage:​ $0 {start|stop|restart}"​
 + exit 1
 +esac
 +
 +exit $?
 +
 +</​code>​
 +
 +/​etc/​init.d/​S60blueZ
 +
 +<​code>​
 +#!/bin/sh
 +#
 +# Start the BlueZ....
 +#
 +
 +# Debian ifupdown needs the /​run/​network lock directory
 +
 +BT_pskey() {
 + echo "BT Module : set PSKEY..."​
 + count=0
 + while [ ${count} -le 5 ]; do
 +#​ /​usr/​sbin/​bccmd -t bcsp -d /dev/ttyS4 -b 115200 psload -r /​root/​my.psr
 + /​root/​bccmd -t bcsp -d /dev/ttyS4 -b 115200 psload -r /​root/​my.psr
 + if [ $? = 0 ]; then
 + count=10
 + echo "BT Module : set PSKEY - OK"
 + else
 + echo "BT Module : set PSKEY - FAIL"
 + sleep 0.5
 + fi
 + count=$(( ${count}+1 ))
 + done
 +}
 +
 +BT_attach() {
 + echo "BT Module : Attach"​
 + count=0
 + while [ ${count} -le 5 ]; do
 + /​usr/​sbin/​hciattach -n -s 115200 /dev/ttyS4 bcsp 115200 &
 + if [ $? = 0 ]; then
 + count=10
 + echo "BT Module : Attach - OK"
 + else
 + echo "BT Module : Attach - FAIL"
 + sleep 0.5
 + fi
 + count=$(( ${count}+1 ))
 + done
 +}
 +
 +BT_up() {
 + echo "BT Module : Start"
 + count=0
 + while [ ${count} -le 5 ]; do
 + /​usr/​sbin/​hciconfig hci0 up
 + if [ $? = 0 ]; then
 + count=10
 + echo "BT Module : Start - OK"
 + else
 + echo "BT Module : Start - FAIL"
 + sleep 0.5
 + fi
 + count=$(( ${count}+1 ))
 + done
 +}
 +
 +BT_down() {
 + echo "BT Module : Stop"
 + count=0
 + while [ ${count} -le 5 ]; do
 + /​usr/​sbin/​hciconfig hci0 down
 + if [ $? = 0 ]; then
 + count=10
 + echo "BT Module : Stop - OK"
 + else
 + echo "BT Module : Stop - FAIL"
 + sleep 0.5
 + fi
 + count=$(( ${count}+1 ))
 + done
 +}
 +
 +BT_enable_scan() {
 + echo "BT Module : Enable Scan"
 + count=0
 + while [ ${count} -le 5 ]; do
 + /​usr/​sbin/​hciconfig hci0 piscan
 + if [ $? = 0 ]; then
 + count=10
 + echo "BT Module : Enable Scan - OK"
 + else
 + echo "BT Module : Enable Scan - FAIL"
 + sleep 0.5
 + fi
 + count=$(( ${count}+1 ))
 + done
 +}
 +
 +case "​$1"​ in
 +  start)
 + BT_pskey
 + sleep 0.3
 + BT_attach
 + sleep 0.5
 + BT_up
 + sleep 0.3
 + BT_enable_scan
 +# BT_down
 +# sleep 0.3
 + ​ /​usr/​sbin/​bluetoothd -n &
 + [ $? = 0 ] && echo "​bluetoothd OK" || echo "​bluetoothd FAIL"
 +# for Handy
 + sleep 0.5
 + ​ /​usr/​bin/​sdptool add PANU
 + [ $? = 0 ] && echo "add PANU OK" || echo "add PANU FAIL"
 + ;;
 +  stop)
 + printf "​Stopping BT: "
 + ​ killall bluetoothd
 + [ $? = 0 ] && echo "​OK"​ || echo "​FAIL"​
 + ;;
 +  restart|reload)
 + "​$0"​ stop
 + "​$0"​ start
 + ;;
 +  *)
 + echo "​Usage:​ $0 {start|stop|restart}"​
 + exit 1
 +esac
 +
 +exit $?
 +
 +</​code>​
 +
 +
 +<​code>​
 </​code>​ </​code>​
  
  
pan/slave_operation.1509212848.txt.gz · Last modified: 2017/10/29 02:47 by 1.241.172.144