Using Visual Studio C++ to read IP addresses and comport number (Serial number) on Windows platform

C++-reads-IP-addresses

Using Visual Studio C++ to read IP addresses on Windows platform

HOW TO USE:

#include"GetIp.h"

int main() {
	cout << getip() << endl;//Print IP Address
}

Possible errors: Use getaddrinfo() or GetAddrInfoW() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings XXX

Solution: Open the project properties, edit the preprocessor definition, and add: _WINSOCK_DEPRECATED_NO_WARNINGS

C++ reads the serial number of the computer

Using Visual Studio C++ to read the serial number of the computer on Windows platform

HOW TO USE:

comport = getComPort(); for (int i = 0; i < comport.size(); i++) { cout << comport[i] << endl;//Print the serial port number } } ">
#include"GetComport.h"

int main() {
    vector comport = getComPort();
    for (int i = 0; i < comport.size(); i++) {
        cout << comport[i] << endl;//Print the serial port number
    }
}
Owner
zhuhuijin
may is fine/ Xi'an Jiaotong University
zhuhuijin
Similar Resources

Cross-platform, single .h file HTTP server (Windows, Linux, Mac OS X)

EWS - Single .h File C Embeddable Web Server Latest Version: 1.1.4 released September 9, 2021 Supported platforms: Linux, Mac OS X, Windows License: B

Oct 17, 2022

This repo contains Direct3D 9, Direct3D 10, a few Direct3D 11, and DirectSound C++ samples from the legacy DirectX SDK updated to build using the Windows 10 SDK and the Microsoft.DXSDK.D3DX NuGet package

DirectX SDK Legacy Samples This repo contains Direct3D 9, Direct3D 10, a few Direct3D 11, and DirectSound samples that originally shipped in the legac

Nov 21, 2022

Brynet - Header Only Cross platform high performance TCP network library using C++ 11.

Brynet - Header Only Cross platform high performance TCP network library using C++ 11.

Brynet Header Only Cross platform high performance TCP network library using C++ 11. Build status Windows : Linux/MacOS : Features Header only Cross p

Nov 26, 2022

Cross-platform, efficient, customizable, and robust asynchronous HTTP/WebSocket server C++14 library with the right balance between performance and ease of use

What Is RESTinio? RESTinio is a header-only C++14 library that gives you an embedded HTTP/Websocket server. It is based on standalone version of ASIO

Nov 25, 2022

Small and fast cross-platform networking library, with support for messaging, IPv6, HTTP, SSL and WebSocket.

frnetlib Frnetlib, is a cross-platform, small and fast networking library written in C++. There are no library dependencies (unless you want to use SS

May 16, 2022

Dolphin is an emulator for running GameCube and Wii games on Windows, Linux, macOS, and recent Android devices.

Dolphin is a GameCube / Wii emulator, allowing you to play games for these two platforms on PC with improvements.

Nov 19, 2022

WAFer is a C language-based software platform for scalable server-side and networking applications. Think node.js for C programmers.

WAFer WAFer is a C language-based ultra-light scalable server-side web applications framework. Think node.js for C programmers. Because it's written i

Nov 19, 2022

LANDrop is a cross-platform tool that you can use to conveniently transfer photos, videos, and other types of files to other devices on the same local network.

LANDrop is a cross-platform tool that you can use to conveniently transfer photos, videos, and other types of files to other devices on the same local network.

LANDrop is a cross-platform tool that you can use to conveniently transfer photos, videos, and other types of files to other devices on the same local network.

Nov 27, 2022

A cross-platform HTTP client library with a focus on usability and speed

EasyHttp A cross-platform HTTP client library with a focus on usability and speed. Under its hood, EasyHttp uses POCO C++ Libraries and derives many o

Nov 9, 2022
Netif - Header-only C++14 library for getting network addresses associated with network interface without name lookups on Windows, macOS, Linux, and FreeBSD

NetIF Get addresses associated with network interfaces on a system without using name lookups. Header-only, requires C++14. Usage Add the header file

Oct 17, 2022
This tool will check a list of IP addresses of RouterOS-based routers to validate if they were infected with Meris.

Meris RouterOS Checker This tool will check a list of ip addresses of RouterOS-based routers to validate if they were infected with Meris. The tool wi

May 2, 2022
Stream server (serial-to-wifi bridge) for ESPHome

Stream server for ESPHome Custom component for ESPHome to expose a UART stream over WiFi or Ethernet. Can be used as a serial-to-wifi bridge as known

Nov 14, 2022
Encapsulates the two protocols of OpenVpn and Ikev2, you only need to enter the server IP and port number to realize the connection and status display, and the specific situation of the connection can be displayed at the same time。

NewVpnCore 封装了OpenVpn和Ikev2两种协议,只需要输入服务器IP和端口号即可实现连接和状态显示,同时可以显示连接的具体情况。 UniteVpn Core(第一版) 1. 模块说明 unitevpn:封装了vpn的操作和统一不同协议信息的模块 ikev2:IKEV2协议的源码 op

Jun 8, 2022
Socket server for DAZ Studio meant for use with Streamdeck plug-in

StreamDeckSocket This listens on port 8080 of localhost. If the port is inconvenient, change it in "qhttpserver.h" as LISTEN_PORT do not change the LI

Nov 9, 2022
Common files for Packet Batch. Read this for configuration guidance and more!

Packet Batch (Common) Description This is a repository for Packet Batch that includes common files for all versions of Packet Batch to use (standard,

Oct 1, 2022
Nov 2, 2022
A very simple, fast, multithreaded, platform independent HTTP and HTTPS server and client library implemented using C++11 and Boost.Asio.

A very simple, fast, multithreaded, platform independent HTTP and HTTPS server and client library implemented using C++11 and Boost.Asio. Created to be an easy way to make REST resources available from C++ applications.

Nov 22, 2022
WiFi scanner with visual persistence, intended to find the idlest channel e.g. to assign to a ZigBee device
WiFi scanner with visual persistence, intended to find the idlest channel e.g. to assign to a ZigBee device

WiFiChanViz Motivation This tool was initially coded to help find the idlest 2.4GHz channel in order to connect a ZigBee device to HomeAssistant in id

Oct 27, 2022
To have platform independent network interfaces over usb which is working with Linux, Windows, Mac OS ect.
To have platform independent network interfaces over usb which is working with Linux, Windows, Mac OS ect.

To have platform independent network interfaces over usb which is working with Linux, Windows, Mac OS ect. called RNDIS. This project is a RNDIS demo, which addtionally implements a http server. It runs out of the box on a stm32f411 BlackPill board. My RNDIS library with an empty template for the second interface (which can ba UART, CAN, ETH or like in this demo a tcp/ip stack) can be found under following link: https://github.com/RDMsmartnetworks/STM32_HAL_RNDIS

Sep 27, 2022