Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Applied modern C/C++ in calculus, discrete mathematics, robotics and machine learning with CMake.

License

NotificationsYou must be signed in to change notification settings

XuhuaHuang/EmbeddedProgramming

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

$$\int_b^d study ,dt= life$$

https://g.dev/xuhua-huang-io

https://github.com/XuhuaHuang/EmbeddedProgramming

#include<>

wakatime

This repositoryhopefully can lead you through themodern C++ world, with some of its popular tool chains.
Each topic is placed in individual folder. Projects are placed under each descriptively-named folders.
Most of the directories are provided with aCMakeLists.txt.
UsingCMake will be significantly easier than manually compiling all the files with your favorite compiler.
For your comfort, some of the files have required compilation command documented in the source file itself.

Table of Contents

Special Thanks

Prof. Charmaine Jirgens
My mentor to the programming world
Professor, Electronics Engineering and Information Technology
Heritage College, Gatineau, Quebec, Canada

Software does not run in a magic fairy aether powered by the fevered dreams of CS PhDs.

Languages

C/C++, Objective-C/C++

An image for C LanguageAn image for C++An image for MinGW

classperson{public:explicitperson() = default;explicitperson(const std::string& fn,const std::string& ln)        : first(fn)        , last(ln)    {    }explicitperson(std::string&& fn, std::string&& ln)        : first(std::move(fn))        , last(std::move(ln))    {    }person(const person& rhs)                =default;    person&operator=(const person&)         =default;person(person&& rhs)noexcept            =default;    person&operator=(person&& rhs)noexcept =default;virtual~person()noexcept               =default;    [[nodiscard]]inline std::string&first_name() {return first; }inlineconst std::string&first_name()const {return first; }    [[nodiscard]]inline std::string&last_name() {return last; }inlineconst std::string&last_name()const {return last; }private:    std::string first;    std::string last;};template<typename T>conceptprintable =requires(T t) {    { std::cout << t } -> std::convertible_to<std::ostream&>;}structprint{constexprprint() = default;template<typename T>requires printable<T>inlineconstexprvoidoperator()(Tconst& t)const    {        std::cout << t <<"\n";    }};

Getting Started

Obtainvcpkg and Dependencies

cdgit clone https://github.com/microsoft/vcpkgcd vcpkgbash ./bootstrap-vcpkg.sh./vcpkg integrate install./vcpkg install gtest./vcpkg install qt6

Example to Compile a File Namedget_tie.cpp

g++ --versioncd ./StandardTemplateLibrary/Tupleg++ -g -Wall -Wextra -Wpedantic -c get_tie.cpp -o get_tie.exe -std=gnu++2b./get_tie

To UpdateMinGW on Windows
Run aPowerShell session with administrator privilege and run:

# Get the latest version of mingwmingw-get updatemingw-get upgrade# Verify the version of installed gcc and g++gcc --versiong++ --version

Repository Directories

If you already have a configuredCMake for your operating system, simple change to the directory with suchCMakeLists.txt and run:

cmake.

or

cmake ./CMakeLists.txt

For example, change to directory./DesignPatterns:

cd ./DesignPatternscmake ./CMakeLists.txt

The convention is to create a folder dedicated toCMake files, for example,build orbin:

cd ./DesignPatternsmkdir buildcd buildcmake ../CMakeLists.txt -G"Visual Studio 17 2022"

To build with popularNinja orMinGW generator:

# With Ninja generatorcmake ../CMakeLists.txt -G"Ninja"# With MinGW generatorcmake ../CMakeLists.txt -G"MinGW Makefiles"

To build the repository and run tests:

cmake. -Bbuildcd buildcmake --build.ctest --verbose

Functionality provided by separate module. A namespaceutil is created to better manage the functions.
Tests andGoogleTest are located within theUtil/tests folder.

namespaceutil {namespacedata_structure {}namespaceiife {}namespacelist {}namespacemath {namespacecartesian_plane {}namespaceeuclidean_space {}    }namespaceparse {}namespacephysics {}namespacepointer {}namespacerange {}namespacetype {}namespacetype_safety {}namespacevector {}}

HackerRank

Contains solutions to some of the basic problem solving coding questions. Provided file name most likely describes the content.TheREADME.md has more handy notes when encountering those problems.
Click to see my HackerRank profile

LeetCodePlayground

Contains solutions to some of the basic problem solving coding questions.
Click to see my LeetCode profile

ObjectiveC

Popular concepts in Objective-C.Compiled in Windows usingGNUstep Core and providedGNUstep developer tools.

Projects

Contains projects carried along the coursework and includes some personal project as well.For example, building a terminal progress bar for visual effects and working withOpenGL library inC++.

References

Commonly Used Command inCMake


[8]ページ先頭

©2009-2025 Movatter.jp