<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Safe Stack]]></title><description><![CDATA[Learn Linux, networking, AWS, cloud security, Docker, Kubernetes, and DevSecOps through simple explanations, practical labs, and hands-on projects.]]></description><link>https://safestack.hashnode.dev</link><image><url>https://cdn.hashnode.com/uploads/logos/6aeb065f1d43a1ea1ddbae80/deef4ff2-c14f-49ea-9e3d-4350225c87c8.png</url><title>Safe Stack</title><link>https://safestack.hashnode.dev</link></image><generator>RSS for Node</generator><lastBuildDate>Sat, 05 Dec 2026 00:46:31 GMT</lastBuildDate><atom:link href="https://safestack.hashnode.dev/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[Networking, IoT and Network Diagnostics]]></title><description><![CDATA[Learn networking, IoT, Wi-Fi, TCP/IP, DNS, MQTT and network diagnostics through simple explanations and practical examples.]]></description><link>https://safestack.hashnode.dev/networking-iot-and-network-diagnostics</link><guid isPermaLink="true">https://safestack.hashnode.dev/networking-iot-and-network-diagnostics</guid><category><![CDATA[networking]]></category><category><![CDATA[iot]]></category><category><![CDATA[computer networks]]></category><category><![CDATA[Internet of Things]]></category><category><![CDATA[cybersecurity]]></category><dc:creator><![CDATA[Mridul Pandey]]></dc:creator><pubDate>Sat, 28 Nov 2026 22:01:01 GMT</pubDate><enclosure url="https://cdn.hashnode.com/uploads/covers/6aeb065f1d43a1ea1ddbae80/0b30ef27-0a3d-4767-87dc-09a220935c88.jpg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h1>W01: <strong>Learning the Fundamentals</strong></h1>
<h2>Introduction</h2>
<p>Have you ever wondered why your Wi-Fi sometimes becomes slow, why video calls freeze, or why a website takes too long to load?</p>
<p>To understand these problems, we first need to understand how devices communicate, how networks transfer information, and how we identify network problems.</p>
<p>I explored the fundamentals of <strong>Internet of Things (IoT), computer networking, wireless communication, network diagnostics, and basic machine learning.</strong></p>
<p>Here are the concepts I learned, explained from the ground up.</p>
<hr />
<h2>1. Understanding the Hardware Behind IoT</h2>
<p>Before understanding how devices communicate, let's understand the small computers that make IoT possible.</p>
<h3>What is a Microcontroller (MCU)?</h3>
<p>A microcontroller is a tiny computer built into a single chip.</p>
<p>Unlike a laptop, which can perform many different tasks, a microcontroller is generally designed to perform specific tasks repeatedly.</p>
<p><strong>Example:</strong> A digital watch uses a small computer to track and display time.</p>
<h3>What is ESP32?</h3>
<p>ESP32 is a low-cost microcontroller with built-in Wi-Fi and Bluetooth capabilities.</p>
<p>It allows electronic devices to connect to wireless networks and exchange information.</p>
<p><strong>Example:</strong> Imagine a temperature sensor that measures room temperature and sends the reading to your phone. An ESP32 can help perform this task.</p>
<h3>What is Raspberry Pi?</h3>
<p>Raspberry Pi is a small, fully functional computer that can run an operating system such as Linux.</p>
<p>Unlike a basic microcontroller, it can run multiple programs, manage databases, and host applications.</p>
<p><strong>Example:</strong> Think of an ESP32 as a worker collecting information and a Raspberry Pi as a manager collecting, storing, and analyzing that information.</p>
<h3>What is GPIO?</h3>
<p>GPIO stands for General Purpose Input/Output.</p>
<p>These are physical pins on a development board that allow software to communicate with external electronic components.</p>
<ul>
<li>Input: Read information from a button or sensor.</li>
<li>Output: Control an LED or another electronic component.</li>
</ul>
<p><strong>Example:</strong> A light switch receives an input when pressed and changes the light's state.</p>
<h3>What is an SoC?</h3>
<p>SoC stands for System on a Chip.</p>
<p>It combines multiple computer components, such as a processor, memory controllers, and communication hardware, into a single chip.</p>
<p><strong>Example:</strong> Instead of building a computer using many separate components, imagine combining several important components into one compact package.</p>
<hr />
<h2>2. Understanding Wi-Fi and Wireless Communication</h2>
<h3>What is Radio Frequency (RF)?</h3>
<p>Radio Frequency refers to electromagnetic waves used to transmit information wirelessly.</p>
<p>Wi-Fi, Bluetooth, and cellular networks use radio waves to communicate.</p>
<p><strong>Example:</strong> When you connect your phone to Wi-Fi, information travels between your phone and router using radio waves instead of a physical cable.</p>
<h3>What is an Access Point (AP)?</h3>
<p>An Access Point is a device that allows wireless devices to connect to a network.</p>
<p>Many home routers have an Access Point built into them.</p>
<p><strong>Example:</strong> Your phone connects to your home router through its wireless Access Point.</p>
<h3>What is SSID?</h3>
<p>SSID stands for Service Set Identifier.</p>
<p>It is simply the name of a Wi-Fi network that appears when you search for available networks.</p>
<p><strong>Example:</strong> When you see <code>Home_WiFi</code> or <code>Office_WiFi</code> on your phone, those are SSIDs.</p>
<h3>What is BSSID?</h3>
<p>BSSID stands for Basic Service Set Identifier.</p>
<p>It identifies a particular wireless access point, usually through its MAC address.</p>
<p><strong>Difference:</strong></p>
<ul>
<li>SSID = Wi-Fi network name.</li>
<li>BSSID = Identifier of a particular access point.</li>
</ul>
<p>This distinction becomes useful when multiple access points share the same Wi-Fi name.</p>
<h3>What is RSSI?</h3>
<p>RSSI stands for Received Signal Strength Indicator.</p>
<p>It indicates how strong a received wireless signal is.</p>
<p>It is commonly represented using dBm values.</p>
<p>Some example readings:</p>
<ul>
<li>-30 dBm: Very strong signal.</li>
<li>-60 dBm: Generally good signal.</li>
<li>-80 dBm: Weak signal.</li>
<li>-90 dBm: Very weak signal.</li>
</ul>
<p>Remember: For negative dBm readings, a value closer to zero represents a stronger signal.</p>
<h3>What is 2.4 GHz vs 5 GHz Wi-Fi?</h3>
<p>These are two commonly used Wi-Fi frequency bands.</p>
<p><strong>2.4 GHz</strong></p>
<ul>
<li>Generally provides better coverage.</li>
<li>Travels farther.</li>
<li>Usually performs better through walls.</li>
<li>Can experience more interference.</li>
</ul>
<p><strong>5 GHz</strong></p>
<ul>
<li>Can provide higher data speeds.</li>
<li>Generally has shorter range.</li>
<li>Is more easily weakened by obstacles.</li>
</ul>
<p><strong>Real-life example:</strong> Imagine two people shouting across a building. A lower-pitched sound may travel farther through obstacles, while a higher-pitched sound may not travel as far.</p>
<h3>What is Airtime Contention?</h3>
<p>Wi-Fi devices share wireless communication channels.</p>
<p>When many devices compete to transmit information, they may have to wait for their turn.</p>
<p>This can increase network delays.</p>
<p><strong>Example:</strong> Imagine 20 students trying to speak in one classroom. Everyone cannot speak clearly at the same time.</p>
<hr />
<h2>3. Computer Networking Fundamentals</h2>
<h3>What is a Network?</h3>
<p>A computer network is a group of connected devices that communicate and share information.</p>
<p>These devices can include:</p>
<ul>
<li>Computers</li>
<li>Smartphones</li>
<li>Printers</li>
<li>Servers</li>
<li>Smart TVs</li>
</ul>
<h3>What is LAN?</h3>
<p>LAN stands for Local Area Network.</p>
<p>It connects devices within a limited geographical area, such as a home, office, or college laboratory.</p>
<p><strong>Example:</strong> Your laptop, phone, and printer connected to the same home router.</p>
<h3>What is WAN?</h3>
<p>WAN stands for Wide Area Network.</p>
<p>It connects networks across large geographical areas.</p>
<p>The Internet is the most familiar example of a WAN.</p>
<p><strong>Simple difference:</strong></p>
<ul>
<li>LAN: A local network.</li>
<li>WAN: A network connecting networks over larger distances.</li>
</ul>
<h3>What is a Default Gateway?</h3>
<p>A default gateway is the device that forwards traffic from your local network to other networks.</p>
<p>In most home networks, your router acts as the default gateway.</p>
<p><strong>Example:</strong> Imagine your house has a main exit door. Whenever you need to travel outside, you use that door. Your default gateway performs a similar role for network traffic.</p>
<h3>What is an ISP?</h3>
<p>ISP stands for Internet Service Provider.</p>
<p>It is the company that provides your Internet connection.</p>
<p>Examples include Jio, Airtel, and other broadband providers.</p>
<h3>What is Ethernet?</h3>
<p>Ethernet is a technology used to connect devices through wired network connections.</p>
<p>It commonly uses Ethernet cables to transfer data between devices.</p>
<p><strong>Example:</strong> Connecting your computer directly to a router using a network cable instead of Wi-Fi.</p>
<h3>What is Cat6?</h3>
<p>Cat6 stands for Category 6 Ethernet cable.</p>
<p>It is a type of network cable designed to support high-speed wired communication.</p>
<hr />
<h2>4. Understanding Network Performance</h2>
<p>A network can have excellent download speeds but still perform poorly during video calls or online gaming.</p>
<p>To understand why, we need to learn some important measurements.</p>
<h3>What is Bandwidth?</h3>
<p>Bandwidth represents how much data a network connection can transfer over a given amount of time.</p>
<p>It is commonly measured in Mbps or Gbps.</p>
<p><strong>Example:</strong> Imagine a highway with ten lanes. More lanes allow more vehicles to travel simultaneously.</p>
<h3>What is Latency?</h3>
<p>Latency is the time taken for data to travel from one point to another.</p>
<p>It is commonly measured in milliseconds (ms).</p>
<p>Lower latency generally means faster responses.</p>
<p><strong>Example:</strong> When you click a button in an online game, latency determines how quickly the server receives and responds to your action.</p>
<h3>Bandwidth vs Latency</h3>
<ul>
<li>Bandwidth = How much data can travel.</li>
<li>Latency = How long data takes to travel.</li>
</ul>
<p>A connection can have high bandwidth but high latency.</p>
<h3>What is RTT?</h3>
<p>RTT stands for Round-Trip Time.</p>
<p>It measures how long a packet takes to travel to a destination and return.</p>
<p>This is what we commonly observe when using the <code>ping</code> command.</p>
<p><strong>Example:</strong> Imagine shouting into a valley and measuring how long your echo takes to return.</p>
<h3>What is Jitter?</h3>
<p>Jitter describes variations in packet delay over time.</p>
<p>Consider these two examples:</p>
<ul>
<li>20 ms, 21 ms, 19 ms, 20 ms: Consistent delays.</li>
<li>20 ms, 350 ms, 18 ms, 520 ms: Highly inconsistent delays.</li>
</ul>
<p>High jitter can cause problems during video calls, online gaming, and live streaming.</p>
<h3>What is Packet Loss?</h3>
<p>Packet loss occurs when some data packets fail to reach their destination.</p>
<p><strong>Example:</strong> Imagine sending 100 letters through the postal service, but only 95 arrive.</p>
<p>The remaining five letters represent packet loss.</p>
<h3>What is Bufferbloat?</h3>
<p>Bufferbloat occurs when excessive data builds up in network queues, increasing delays.</p>
<p><strong>Example:</strong> Imagine standing in a supermarket checkout line behind someone with a trolley full of groceries when you only want to buy one chocolate bar.</p>
<p>Your request is small, but you still have to wait.</p>
<hr />
<h2>5. Important Network Protocols</h2>
<p>Protocols are rules that define how devices communicate with each other.</p>
<p>Let's understand some important networking protocols.</p>
<h3>What is an IP Address?</h3>
<p>An IP address is a numerical address assigned to a device on a network.</p>
<p>It helps devices identify where information should be sent.</p>
<p>Example:</p>
<p><code>192.168.1.10</code></p>
<p>Think of it as the postal address of a house.</p>
<h3>What is DHCP?</h3>
<p>DHCP stands for Dynamic Host Configuration Protocol.</p>
<p>It automatically assigns IP configuration to devices joining a network.</p>
<p><strong>Example:</strong> When your phone connects to Wi-Fi, your router can automatically assign it an IP address.</p>
<h3>What is ICMP?</h3>
<p>ICMP stands for Internet Control Message Protocol.</p>
<p>It is used for network diagnostics and error reporting.</p>
<p>The <code>ping</code> command commonly uses ICMP Echo Request and Echo Reply messages.</p>
<p><strong>Example:</strong> You knock on someone's door to check whether they are home. If they respond, you know they are reachable.</p>
<h3>What is TCP?</h3>
<p>TCP stands for Transmission Control Protocol.</p>
<p>It provides reliable, ordered delivery of data between communicating devices.</p>
<p>It uses acknowledgements and retransmissions to handle missing data.</p>
<p><strong>Example:</strong> Sending a registered parcel where delivery confirmation matters.</p>
<h3>What is UDP?</h3>
<p>UDP stands for User Datagram Protocol.</p>
<p>It sends data without establishing TCP-style reliable delivery.</p>
<p>It has less communication overhead and is useful when speed and low delay are important.</p>
<p><strong>Example:</strong> A live radio broadcast does not stop and repeat everything just because one listener missed a sentence.</p>
<h3>TCP vs UDP</h3>
<table>
<thead>
<tr>
<th>TCP</th>
<th>UDP</th>
</tr>
</thead>
<tbody><tr>
<td>Reliable delivery</td>
<td>No guaranteed delivery</td>
</tr>
<tr>
<td>Uses acknowledgements</td>
<td>No TCP-style acknowledgements</td>
</tr>
<tr>
<td>Retransmits lost data</td>
<td>Does not automatically retransmit</td>
</tr>
<tr>
<td>Common in file transfers</td>
<td>Common in real-time applications</td>
</tr>
</tbody></table>
<h3>What is DNS?</h3>
<p>DNS stands for Domain Name System.</p>
<p>It translates human-readable domain names into IP addresses.</p>
<p>For example:</p>
<p><code>google.com</code> → An IP address.</p>
<p><strong>Example:</strong> Your phone's contact list converts a person's name into their phone number.</p>
<p>Without DNS, remembering IP addresses for websites would be much harder.</p>
<h3>What is mDNS?</h3>
<p>mDNS stands for Multicast Domain Name System.</p>
<p>It allows devices on a local network to discover each other using names without requiring a traditional central DNS server.</p>
<p><strong>Example:</strong> Instead of remembering a device's IP address, you may be able to access it using a local hostname ending in <code>.local</code>.</p>
<h3>What is a Captive Portal?</h3>
<p>A captive portal is a web page that appears when you connect to certain Wi-Fi networks.</p>
<p>It may ask you to log in, accept terms, or enter information before accessing the Internet.</p>
<p><strong>Example:</strong> The login page you see when connecting to hotel or airport Wi-Fi.</p>
<h3>What is SoftAP?</h3>
<p>SoftAP stands for Software-enabled Access Point.</p>
<p>It allows a device to create its own Wi-Fi network.</p>
<p><strong>Example:</strong> A device can broadcast its own temporary Wi-Fi network so that another device can connect and configure it.</p>
<hr />
<h2>6. IoT Communication and Data Storage</h2>
<p>IoT devices often have limited processing power, memory, and network resources.</p>
<p>Therefore, lightweight communication methods are useful.</p>
<h3>What is MQTT?</h3>
<p>MQTT stands for Message Queuing Telemetry Transport.</p>
<p>It is a lightweight messaging protocol commonly used in IoT applications.</p>
<p>It allows small devices to send information without requiring heavy communication overhead.</p>
<p><strong>Example:</strong> A temperature sensor sends its current reading to another computer using MQTT.</p>
<h3>What is an MQTT Broker?</h3>
<p>An MQTT Broker is the central component responsible for receiving messages from publishers and delivering them to subscribers.</p>
<p><strong>Example:</strong> Imagine a post office:</p>
<ul>
<li>People send letters to the post office.</li>
<li>The post office receives them.</li>
<li>It delivers them to the correct recipients.</li>
</ul>
<h3>What is Publish/Subscribe (Pub/Sub)?</h3>
<p>Publish/Subscribe is a communication model.</p>
<p>It has two important roles:</p>
<ul>
<li>Publisher: Sends information.</li>
<li>Subscriber: Receives information.</li>
</ul>
<p>A broker manages the communication between them.</p>
<p><strong>Example:</strong> When you subscribe to a YouTube channel, you receive updates when the creator publishes new content.</p>
<h3>What is MQTT QoS?</h3>
<p>QoS stands for Quality of Service.</p>
<p>It defines the delivery guarantee for MQTT messages.</p>
<p>There are three levels:</p>
<ul>
<li>QoS 0: At most once. The message is sent without delivery confirmation.</li>
<li>QoS 1: At least once. The message is delivered with acknowledgement, but duplicates are possible.</li>
<li>QoS 2: Exactly once. The protocol uses additional steps to prevent duplicate delivery to the receiving application.</li>
</ul>
<h3>What is a Time-Series Database?</h3>
<p>A Time-Series Database stores information associated with timestamps.</p>
<p>Examples include:</p>
<ul>
<li>Temperature readings over time.</li>
<li>Network latency measurements.</li>
<li>CPU usage every second.</li>
<li>Sensor measurements throughout the day.</li>
</ul>
<p><strong>Example:</strong> Think of a fitness tracker recording your heart rate every few seconds. The timestamp helps you understand how your heart rate changes over time.</p>
<p>InfluxDB is an example of a Time-Series Database.</p>
<hr />
<h2>7. Understanding Cellular Networks</h2>
<p>Wi-Fi is not the only way devices connect to the Internet. Smartphones also communicate using cellular networks.</p>
<h3>What is LTE / 4G?</h3>
<p>LTE stands for Long-Term Evolution.</p>
<p>It is a mobile communication technology used to provide high-speed wireless Internet connectivity.</p>
<p>4G is the fourth generation of mobile network technology.</p>
<h3>What is RSRP?</h3>
<p>RSRP stands for Reference Signal Received Power.</p>
<p>It measures the strength of the reference signal received from a cellular base station.</p>
<p>It is generally measured in dBm.</p>
<p><strong>Example:</strong> It helps us understand how strong the cellular signal reaching your phone is.</p>
<h3>What is RSRQ?</h3>
<p>RSRQ stands for Reference Signal Received Quality.</p>
<p>It provides information about the quality of the received cellular signal, considering interference and noise.</p>
<p><strong>Simple difference:</strong></p>
<ul>
<li>RSRP: Signal strength.</li>
<li>RSRQ: Signal quality.</li>
</ul>
<h3>What is Cell ID?</h3>
<p>Cell ID identifies a particular cellular network cell or sector.</p>
<p>It helps determine which cell your phone is communicating with.</p>
<h3>What is Termux?</h3>
<p>Termux is a terminal emulator and Linux environment available on Android.</p>
<p>It allows users to run command-line tools, scripts, and programming environments directly on their smartphones.</p>
<p><strong>Example:</strong> You can use Python from your Android phone without needing a laptop.</p>
<hr />
<h2>8. Introduction to Machine Learning and Network Diagnosis</h2>
<p>After collecting information from a network, we need a way to understand what the measurements mean.</p>
<p>This is where logical rules and machine learning become useful.</p>
<h3>What is Baseline Calibration?</h3>
<p>Baseline calibration means measuring normal system behaviour under known conditions.</p>
<p>This gives us a reference point for identifying unusual behaviour later.</p>
<p><strong>Example:</strong> Before checking whether your body temperature is unusually high, a doctor considers the normal temperature range.</p>
<h3>What is a Heuristic Rule?</h3>
<p>A heuristic is a practical rule or shortcut used to make decisions.</p>
<p>It commonly follows an IF-THEN structure.</p>
<p>Example:</p>
<ul>
<li>IF the router cannot be reached, THEN investigate the local network connection.</li>
<li>IF an IP address is reachable but a domain name cannot be resolved, THEN investigate DNS.</li>
</ul>
<p>These rules help narrow down possible problems.</p>
<h3>What is Machine Learning?</h3>
<p>Machine Learning is a field of Artificial Intelligence in which computers learn patterns from data.</p>
<p>Instead of manually writing every possible rule, we train a model using examples.</p>
<p><strong>Example:</strong> Show a computer thousands of pictures of cats and dogs. It can learn patterns that help distinguish between them.</p>
<h3>What is Random Forest?</h3>
<p>Random Forest is a Machine Learning algorithm that combines multiple decision trees to make a prediction.</p>
<p>Each decision tree makes its own prediction, and the model combines their results.</p>
<p><strong>Example:</strong> Imagine asking 50 people to independently diagnose a problem. You choose the answer receiving the majority of votes.</p>
<h3>What is Selective Abstention?</h3>
<p>Selective abstention means allowing an AI system to avoid making a prediction when it is not sufficiently confident.</p>
<p>Instead of guessing, the system can respond that the result is inconclusive.</p>
<p><strong>Example:</strong> A doctor may say that more tests are needed before making a diagnosis.</p>
<p>This is important because an uncertain answer is sometimes better than an incorrect one.</p>
<hr />
<h2>9. A Few Important Things I Learned</h2>
<p>After exploring these concepts, some important distinctions became clearer:</p>
<ol>
<li>A strong Wi-Fi signal does not always mean a fast connection.</li>
<li>High bandwidth does not automatically mean low latency.</li>
<li>Packet loss and jitter are different network problems.</li>
<li>TCP and UDP serve different communication requirements.</li>
<li>DNS translates domain names into IP addresses.</li>
<li>MQTT makes communication between small IoT devices easier.</li>
<li>Machine Learning can identify patterns that are difficult to capture using simple rules.</li>
<li>Network troubleshooting becomes easier when problems are investigated layer by layer.</li>
</ol>
<hr />
<h2>What's Next?</h2>
<p>My next learning goals are to strengthen my understanding of:</p>
<ul>
<li>Linux networking commands.</li>
<li>IP addressing and subnetting.</li>
<li>DNS resolution and troubleshooting.</li>
<li>TCP/IP communication.</li>
<li>Network monitoring and packet analysis.</li>
<li>Practical networking experiments.</li>
</ul>
<p><strong>Final takeaway:</strong> Understanding networking is not just about connecting devices to the Internet. It is about understanding how information travels, how communication problems occur, and how we can identify and solve them.</p>
<p>Let knowledge be your Light, and Patience your Path.</p>
]]></content:encoded></item></channel></rss>