atrn0 / microps Goto Github PK
View Code? Open in Web Editor NEWThis project forked from pandax381/microps
An implementation of a small TCP/IP protocol stack for learning.
License: MIT License
This project forked from pandax381/microps
An implementation of a small TCP/IP protocol stack for learning.
License: MIT License
user@513e1cfd56c5:/microps$ ping 192.0.2.2
PING 192.0.2.2 (192.0.2.2) 56(84) bytes of data.
64 bytes from 192.0.2.2: icmp_seq=2 ttl=255 time=0.566 ms
64 bytes from 192.0.2.2: icmp_seq=3 ttl=255 time=0.665 ms
64 bytes from 192.0.2.2: icmp_seq=4 ttl=255 time=0.893 ms
64 bytes from 192.0.2.2: icmp_seq=5 ttl=255 time=1.20 ms
64 bytes from 192.0.2.2: icmp_seq=6 ttl=255 time=0.715 ms
64 bytes from 192.0.2.2: icmp_seq=7 ttl=255 time=0.250 ms
64 bytes from 192.0.2.2: icmp_seq=8 ttl=255 time=0.522 ms
64 bytes from 192.0.2.2: icmp_seq=9 ttl=255 time=1.12 ms
64 bytes from 192.0.2.2: icmp_seq=10 ttl=255 time=1.15 ms
64 bytes from 192.0.2.2: icmp_seq=11 ttl=255 time=0.638 ms
64 bytes from 192.0.2.2: icmp_seq=12 ttl=255 time=0.473 ms
64 bytes from 192.0.2.2: icmp_seq=13 ttl=255 time=0.464 ms
64 bytes from 192.0.2.2: icmp_seq=14 ttl=255 time=0.735 ms
^C
--- 192.0.2.2 ping statistics ---
14 packets transmitted, 13 received, 7.14286% packet loss, time 13157ms
rtt min/avg/max/mdev = 0.250/0.722/1.204/0.280 ms
IPデータグラムを送信するときにarpのキャッシュがヒットしない場合、キューにデータグラムを保存しておいて、キャッシュがアップデートされたタイミングで再送するようにすると良さそう
08:54:03.122 [I] ip_iface_register: registered: dev=net0, unicast=127.0.0.1, netmask=255.0.0.0, broadcast=1.0.0.0 (ip.c:242)
08:54:03.122 [I] ip_iface_register: registered: dev=net1, unicast=192.0.2.2, netmask=255.255.255.0, broadcast=1.0.0.0 (ip.c:242)
正しいログ
08:51:52.610 [I] ip_iface_register: registerd: dev=net0, unicast=127.0.0.1, netmask=255.0.0.0, broadcast=127.255.255.255 (ip.c:226)
08:51:52.610 [I] ip_iface_register: registerd: dev=net1, unicast=192.0.2.2, netmask=255.255.255.0, broadcast=192.0.2.255 (ip.c:226)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.