Small Notes on Porting PS2 Handles to STM32
1. Hardware preparation: Warship development board, PS2 handle receiver, PS2 handle, connection cable 2. Hardware connection: The PS2 handle receiver has six pins and connects to the IO port of the single-chip computer as follows:
Receiver signalSingle-chip IOGNDGNDVCC3.3VDI/DATPB12DO/CMDPB13CSPB14CLKPB15
3. Introduction to PS2 Communication ...
Added by kanetan on Sat, 13 Nov 2021 00:45:16 +0200
Sequential storage structure and chain storage structure of linear table and their simple operation (mixed use of C and C + +)
Sequential storage structure and chain storage structure of linear table and their simple operation (mixed use of C and C + +)1, Preface:In the first computer experiment when learning data structure, the teacher asked us to realize the sequential storage structure and chain storage structure of linear table and their simple operation. It was pa ...
Added by Axem on Fri, 12 Nov 2021 17:25:38 +0200
C language project practice: Zero basic project of Chinese chess, 210 lines of source code example
This article mainly introduces in detail the implementation of C language - "Chinese chess project". The example code in this article is very detailed and has certain reference value. Interested partners can refer to it!
Introduction to the game:
Chinese chess is a two person confrontational game in which two people take turns to ...
Added by niesom on Fri, 12 Nov 2021 13:27:58 +0200
Implementation of mine sweeping -- Application of two-dimensional array
Minesweeping is a classic game. Now use c language to realize minesweeping, the most important of which is the use of arrays.
File creation
Creating different modules can make the code more logical and concise, and can also hide some programs.
test.c: as a test file, it is mainly used to test the whole project; game.c: game file, which is ...
Added by jcantrell on Fri, 12 Nov 2021 12:22:40 +0200
C language implementation of minesweeping game package + optimization (recursion)
Mine sweeping game can be said to be a very classic game. Today we will try to realize this game in C language
catalogue
1. Ideas
2. Code
3. Ideas
4. Optimization (recursion)
1. ideas
Before writing code, think about how the framework can realize the game. First, it has a 9 * 9 chessboard with randomly placed mines,
Click one of ...
Added by balsdorf on Fri, 12 Nov 2021 01:44:15 +0200
Chapter V circulation structure
1 basic cycle structure
The cycle structure generally consists of two parts:
Cycle condition: determines whether to enter or exit the cycle. When satisfied, enter the next cycle, otherwise exit the cycle.Loop body: the operation performed for each round of loop, usually consisting of a sequence of statements. Three cycle structures
w ...
Added by windyweather on Thu, 11 Nov 2021 13:20:10 +0200
Who doesn't love such Python combat projects - 40 Python entry-level applets that must be learned in Station C are full of harvest
Hello everyone, here is the list of code gods (a little boastful, ha ha). It's a newcomer. I hope you can give me more advice.
Many students still find it difficult to use Python flexibly after learning it. I sorted out 37 small programs for getting started with Python. In practice, the application of Python will have twice the result with hal ...
Added by elis on Wed, 10 Nov 2021 02:19:18 +0200
Analysis and implementation of C language source code -- implementation of strtok() series functions
Source code analysis and Practice
strtok() source code implementation
Because it is a global variable storage address implemented by static, you only need to pass it once and then pass NULL to operate the previous string.
But it also causes a problem: if two threads use this function, they will share this variable because it is a gl ...
Added by gladiator83x on Mon, 08 Nov 2021 21:02:23 +0200
782-C language #if, #ifdef, #ifndef usage details
Detailed explanation of C language conditional compilation
What if we want to develop a C language program, let it output red text, and require cross platform and can run under Windows and Linux? The difficulty of this program is that the codes for controlling text color are different on different platforms. We must be able to identify differe ...
Added by klapy on Mon, 08 Nov 2021 14:58:17 +0200
Special points encountered in the early learning of C language [detailed explanation of Sanzi chess] [gospel for beginners, detailed summary, review experts]
Three character chess and its key points
When a programmer learning programming can understand conventional code, he needs to achieve shape similarity or even shape similarity through continuous imitation and summary
preface
In the process of programming, in addition to the common knowledge points in textbooks, there are many stra ...
Added by CONFUSIONUK on Mon, 08 Nov 2021 13:56:36 +0200