No packets sending through 6lowpan
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 25/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- linux, python, raspberry-pi
- Domain
- embedded-iot, networking, operating-systems
Research direction
Start by reproducing the TCP failure on the Raspberry Pi Zero W setup using the bluetooth_6lowpan module, bt0, and the provided Python client and server. Compare the working ping traffic with the missing application packets using tshark, while checking the reported Linux 5.10.17+ environment. Done means TCP data can traverse the 6lowpan interface as expected.
Written by the indexing model from the issue text.
Description
Describe the bug
Connected two Raspberry Pi W using 6lowpan and ping is working fine with global address at both devices. However, it seems that no programs can send data through the interface, I tried python scrips and mosquitto server etc.
To reproduce
Client:
Enable bluetooth_6lowpan module
modprobe bluetooth_6lowpan
echo 1 > /sys/kernel/debug/bluetooth/6lowpan_enable
Start advertising
hciconfig hci0 leadv
Server:
modprobe bluetooth_6lowpan
echo 1 > /sys/kernel/debug/bluetooth/6lowpan_enable
hcitool lescan
Connect to the client with the bluetooth mac address discovered
echo "connect <mac addr> 1" > /sys/kernel/debug/bluetooth/6lowpan_control
Ping with link local address
ping6 -I bt0 <link local address of the client>
Add gloabal address (in client)
ip addr add fd00::2/64 dev bt0
Add global address (in server)
ip addr add fd00::1/64 dev bt0
Ping the global address, server to client, works fine
ping6 fd00::2
Ping the global address, client to server, works fine
ping6 fd00::1
Try to connect client to server using a program, such as python scripts given below, No data is sending through the 6lowpan (observe with a tshark, or similar).
tcp client program
#!/usr/bin/env python3
import socket
import struct
SERVER_ADDR = 'fd00::1'
SERVER_PORT = 9001
sequence_number = 1
sock = socket.socket(socket.AF_INET6, socket.SOCK_STREAM)
print('send connect request')
sock.connect((SERVER_ADDR, SERVER_PORT))
while sequence_number < 101 :
data = struct.pack("!I", sequence_number)
data += 'Ping'
sock.sendto(data, (SERVER_ADDR, SERVER_PORT, 0, 0))
recv_data = sock.recvfrom(8)
print(recv_data)
sequence_number+= 1
sock.close()
del sock
tcp server program
#!/usr/bin/env python3
import socket
SERVER_ADDR = ''
SERVER_PORT = 9001
with socket.socket(socket.AF_INET6, socket.SOCK_STREAM) as s:
server_addr = (SERVER_ADDR, SERVER_PORT, 0, 0)
s.bind(server_addr)
s.listen(1)
conn, addr = s.accept()
with conn:
while True:
data = conn.recv(128)
if not data:
print('break')
break
conn.sendall(data)
s.close()
del s
System
-
Which model of Raspberry Pi?
PiZeroW -
Which OS and version (
cat /etc/rpi-issue)?
Raspberry Pi reference 2020-12-02
Generated using pi-gen, https://github.com/RPi-Distro/pi-gen, cce27bd6f44a3b2e83855645986b3e21f771e852, stage2 -
Which firmware version (
vcgencmd version)?
Feb 25 2021 12:12:09
Copyright (c) 2012 Broadcom
version 564e5f9b852b23a330b1764bcf0b2d022a20afd0 (clean) (release) (start) -
Which kernel version (
uname -a)?
Linux raspberrypi 5.10.17+ #1403 Mon Feb 22 11:26:13 GMT 2021 armv6l GNU/Linux
- Dominant language
- C
- Stars
- 13.2k
- Forks
- 5.5k
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 21
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from raspberrypi/linux
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
raspberrypi/linux#7415 · 2 comments · 1 reaction ·
-
rp1-cfe doesn't forward V4L2_EVENT_SOURCE_CHANGE event from csi-2 sensor driver to userspace app Open
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
raspberrypi/linux#7399 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 82/100
raspberrypi/linux#7357 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
raspberrypi/linux#7054 · 2 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 48/100
raspberrypi/linux#7634 · 8 comments · 1 reaction ·
All issues in raspberrypi/linux
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
zephyrproject-rtos/zephyr#119726 ·
-
[Bounty proposal] fix(web): memory insights count an evening memory on the next day ($25 proposed) Open
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
BasedHardware/omi#15320 ·
-
[adam] AdamNet network read doesn't cap to MAX_ADAM_PACKET_LEN, overflows client receive buffers Open
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
FujiNetWIFI/fujinet-firmware#1649 · 2 comments ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
HarbourMasters/Shipwright#7229 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
riscv-software-src/riscv-isa-sim#2435 · 1 comment ·