Write down what you wish to accomplish. Then break it down into smaller parts. Try to find the simplest part, and implement just that part. If you can’t get that simple part to work, see if you can break it down into even simpler parts.
If you can’t break it down any further, move on to the next problem. Perhaps by the time you finish the problem you can solve, you’ll have some insight into the related problem that you couldn’t.