Apache HttpClient: The Java Network Request Courier

Apache HttpClient: The Java Network Request Courier

Apache HttpClient – The Java Network Request Courier Hello everyone, I am Niu Ge, transitioning from testing to Java! Today, we are going to talk about the “courier” in Java – Apache HttpClient. I still remember the first project I took on after transitioning, which required calling several external APIs. At that time, I was … Read more

The TCP/IP Three-Way Handshake and Four-Way Teardown Process

The TCP/IP Three-Way Handshake and Four-Way Teardown Process

Hello everyone, I amAms, Today I will talk about theTCP/IPThree-Way Handshake and Four-Way Teardown Process Analysis A virtual connection is established through a three-way handshake. 1. (Client) > [SYN] > (Server)IfClientandServerare communicating. WhenClientwants to communicate withServer,Clientfirst sends aSYN (Synchronize)marked packet toServerto request a connection.Note: A SYNpacket is a TCP packet with only the SYN flag … Read more

Modbus TCP Programming and Experimentation

Modbus TCP Programming and Experimentation

11.7 Modbus TCP Programming and Experimentation This course does not support sensors that use the Modbus TCP protocol, so we will write two programs: ① modbus_server_tcp.c: Simulate a Modbus TCP sensor ② modbus_client_tcp.c: Operate the sensor The program structure is shown in the figure below: No special connections are required on the hardware. The source … Read more

MODBUS Function Library: A Practical PLC Library

MODBUS Function Library: A Practical PLC Library

To communicate with other devices in a PLC, the MODBUS function library is definitely the most commonly used. Let me share my experiences and some tips from my work~ As the “universal solution” in the field of industrial automation, the MODBUS library allows our PLC to communicate with other devices that support the MODBUS protocol. … Read more

Practical Skills: SPI Flash Programming Algorithm for Any MCU with SWD Interface

Practical Skills: SPI Flash Programming Algorithm for Any MCU with SWD Interface

Previously, I shared a document-based tutorial on creating an SPI Flash programming algorithm. However, feedback from users indicated that it was not very convenient to port to other microcontrollers. This post is created to facilitate the migration to various platforms. Application scenarios for the SPI Flash programming algorithm: 1. In an IDE environment, such as … Read more

GDB Tool for RISC-V Platform: A Practical Guide

GDB Tool for RISC-V Platform: A Practical Guide

Considering the limited debugging tools for the RISC-V platform, I compiled a version of GDB and GDB server suitable for RISC-V based on the source code from the GDB official website: gdb-12.1. I have verified its functionality on RISC-V terminal devices. The tools have been uploaded to my personal GitHub: https://github.com/season727/gdb_12.1_risc-v Compilation Toolchain: Xuantie-900-gcc-linux-6.6.0-musl64-x86_64-V2.10.2-20240904 Due … Read more

Mastering Makefile: A Comprehensive Guide

Mastering Makefile: A Comprehensive Guide

1What is Makefile In the previous study of compiling C programs, we learned that compiling a program is relatively simple. However, if we need to compile multiple files or files in different folders, we need to generate different library files and determine the compilation order of these files, which often requires many complex command lines … Read more

From 0 to 1: Easily Master Makefile

From 0 to 1: Easily Master Makefile

Click on the above “IT Circle“, select “Top Public Account” Critical moments, delivered first! This article is published by reader Liang Xu from the public account, please do not reprint without authorization! 1. What is Makefile A typical enterprise-level project usually has many source files, sometimes categorized by function, type, or module in different directories, … Read more

How to Write an Impressive Makefile from Version 1 to Version 5

How to Write an Impressive Makefile from Version 1 to Version 5

1. The Three Essential Elements of Makefile 2. Working Principle 3. Start Writing First, let’s write our program, taking C language as an example. 1) func.h Define two functions: addition and subtraction: 2) Implementation of the Addition Function 3) Implementation of the Subtraction Function 4) main function 3.1 Version 1 The most basic version: just … Read more