Open xp1632 opened 1 year ago
If a procedure is wrong and you don't know why?
-How to find where the problem locates?
-1. image you are testing a wiring connection that is not working,
there are two mental sticks in your hands, they will tell you
if a component has electricity, when you ..|..O..|.. put them
on both sides of a component
-2. You first start with the most outside start and end of this connect
.|.....O1.....O2......O3....|.....
check its input and outcome,
3. Then you test the small component of it,
....|..O1..|...O2......O3.........
......O1..|...O2..|....O3.........
......O1.....O2..|....O3....|.....
make sure the input and outcome of each component is correct
4. If the problem still exist after component checking,
could be the connection between some components is wrong, now we
test the connection of neighboring components
....|..O1.....O2...|...O3.........
......O1...|..O2......O3...|......
....|..O1.....O2......O3...|......
How to debug? -remember to look for the root/return of the function -And trace it by the clue, -check the exact place, overlook the unimportant ones, for example, ignore the functions when it's a static problem -compare it with the correct ones and see the exact differences