Connect with us

Programing

Discussion in 'Microcontrollers, Programming and IoT' started by CarterJ10, Aug 10, 2021.

Scroll to continue with content
  1. CarterJ10

    CarterJ10

    2
    0
    Aug 10, 2021
    Could someone please give me suggestions on where to begin learning to code. Understanding how it works would help me, I believe. Have took a few lessons in online free courses. I want to begin contributing to the world in a way that will be helpful for generations younger than my own. The world has went the way of internet programming. Any suggestions would be great.
     
  2. Bluejets

    Bluejets

    5,001
    1,050
    Oct 5, 2014
    Jeremy Blum has many videos for the Arduino microcontroller system which is fairly simple and easy to get in to.

    He also has books on the subject and I believe updated tutorials and such.

    The start was at this video below and it has a group of 15 videos.

     
  3. DBingaman

    DBingaman

    108
    28
    Jun 27, 2021
    If you are targeting microcontrollers, I would recommend you learn C first. Most other languages are similar to it. If you are interested the following book on programming the PIC32MX microcontrollers is a good start:

    https://www.amazon.com/Mastering-PI...dennis+bingaman&qid=1628643262&s=books&sr=1-1

    If you are targeting a PC. Recommend you start with a free C compiler. Write a lot of console based applications will get you familiar with the language. After you master C you could move on to C++, JavaScript, C# and other high end programming languages depending what your overall goals are.

    Another avenue is FPGA's programming them in VHDL and or Verilog. There is a high need for people with this skill.
    There is plenty of tutoring on the internet for VHDL. There is another book for getting started with FPGA's if you are interested in that route:

    https://www.amazon.com/Using-FPGA-M...dennis+bingaman&qid=1628643680&s=books&sr=1-2

    Much success.
     
  4. E-ten

    E-ten

    15
    1
    Aug 16, 2021
    Having recently joined I was familiarising with site content when I cam across this thread. A lot on the site is about micros and single-board programming but little on the PC side.

    So here is my tuppence-worth.

    Observing people learning a language, I notice that after the 'Hello world!" introduction, what follows is a load of terminology that in itself forms a language. In other words the learning of the language-speak and coding becomes the focus of attention rather than programming.

    I would thus choose a language that is easy to get started with and do a variety of tasks - I hate pointless exercises because they kill motivation. Of the three types of programs - script - pseudo code - compiled, there is a certain simplicity to compiled programs that is difficult to match, because a simple compiled language will run on any machine (with the right OS) without installation or special resources.

    In this day Object Oriented Programming (OOP) is the standard to follow. What this means is that rather than writing code say, "2 + 3 =", you have a series of objects and what the program does is in response to clicking on an object. In OOP the example given will have, say, two boxes into which you put the 2 and the 3. A button will say "Add" and clicking on that (object) will supply the result. You could change the object-code so that when you click on it, it subtracts. Or why not have four buttons for the four basic maths functions?

    So you may agree that to gain a feel for programming rather than a code-run-around is more beneficial. Given a simple language, you can learn the syntax as you go along, ideally doing useful exercises. I would suggest three main areas of development.

    I would start with numbers. Perhaps a currency convert - three boxes, a button and not much else. Maybe then move to a mortgage/loan/interest calculator. Then whatever takes your fancy. Maybe you are into stocks and shares. Or perhaps your needs are in odds and probability. The point is you will familiarise yourself with handling calculations - about the easiest type of operations to program.

    Next get a feel for processing and structuring text. Perhaps you can write some lists but with some element of processing. Thus a shopping list could include a structure to rearrange the list in terms of the natural navigation within your favourite supermarket. You could write a program that will count words in a text. Too many 'perhaps', or 'maybe' etc., may indicate the level of credibility one can attach to the text. Why stop there? Why not create a cypher? And the ultimate is probably a data scrape. You get a page from the internet of changing information such as, say stock prices, and you 'scrape' out the data for use somewhere else. Be careful though, this technique is considered naughty by many web sites.

    Lastly develop a feel for whole item manipulations. If we are talking images, to develop some presentation ideas would be akin to a database thus more like the previous paragraph. Instead play with over-writing an image with text or another image. You might then want to try cutting, stretching, mapping, changing colour depth and so on.

    So you have developed a feel for programming! You are now in a position to understand the limitations of what you are using and make a reasoned choice on more appropriate languages. For example if database work is important to you, you may wish to consider SQL more appropriate.

    It comes down to what language to use. I notice C is mentioned quite often. C is THE language of computers. Soon after its launch it took over from ASM as the language of choice for low level (fundamental) programming. But for general PC use it is a pig of a language to learn. The core program requires a series of libraries (which have pre-set code) in order to do anything. If you suffer from 'punctuation dyslexia' it is a nightmare language. And the compilers usually have an array of switches to be set in order to attach your program to a particular OS.

    Thus if you agree with the above that 'think programming' is more important in the early stages than 'code run-around' I would suggest that what you need is a very simple language that does not require a lot of effort to start getting useful work done. I would strongly recommend that you look at a BASIC language as a starter. There are quite a number about.

    When, about five years ago, I was looking for a programming language that, now well in retirement, I would not need to think too deeply about, I looked at a few and settled for Purebasic. Appreciate that what follows might sound like a plug for Purebasic but it is just a description of the key elements. Try a few because you might feel more comfortable with something else. I cannot suggest anything since I have not looked at other BASICs since then.

    Purebasic is free for a few hundred lines of code and if you need more, the subscription is a one-off fee. The install includes many examples to illustrate code usage and there is also an active forum. It will compile your code into a file that does not normally require installation - I have never been stuck with the in-built functions for keyboard - mouse - monitor- disc space - internet usage.

    Whatever you choose, have fun. If it is a chore, maybe programming is not for you.

    Take care.
     
    Last edited: Aug 19, 2021
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-