I have no idea of the difference and as assemly language was mentioned I thought I'd try and pick the brains of the more informed among the forum.
Believe me, as far as I can see, the picaxe is fine for what I need at the moment but I was just interested in other options, not knowing too much about them.
Sorry for asking.
Angie
Never a need to be sorry for asking a question.
Neither am I likely to be the
most informed with respect to Assembler but have done quite a bit in aeons gone by.
Assembler (or machine code) is in simple terms the native language of the microcontrollers (or microprocessors as used in PC's etc).
Each instruction does just one task, be that to fetch a value form memory, load an immediate value, increment a value, etc.
The work is done in a special register called the accumulator and from there is saved back to memory.
If you want to do something like go around in a loop (such as a For...Next loop) and perform some math on a value each time then you must set up the code to do each step:
1. pre-load the register to be used for the math with a starting value,
2. save the starting value in a memory register,
3. set up an index register for the (For...Next) loop
4. fetch the value saved in step 2
5. perform the math on the assigned register
6. save the modified value in the original memory register
7. fetch the loop index value
8. increment the loop index value
9. save the loop register back to its register/memory location
10. test if looping has completed and if yes leave the loop
11. if not completed, then branch back to step 4.
some chips may for example let you in effect merge steps 8 and 9
Dependant upon the microcontroller/microprocessor, the native math functions may be very limited. Some only to add subtract, others have multiplication and maybe division of sorts.
But often you need to call in a routine from a predefined math library if you want anything more than basic integer +, -, / or *
There are no defined bit, byte or word variables. You (or if writing in high level code, the compiler) must assign register/memory locations for each value to be kept and remember which is which or use definitions akin to the PICAXE SYMBOL statement.
Now the equivalent for the PICAXE is:
1. pre define the starting value and assign to a variable
2. use the FOR variable = start TO end {step x} command
3. perform the math function on the assigned variable
4. call/use the Next command.
Now this is simplified but as you can see, the PICAXE BASIC has less steps.
But underlying the variable assignments and setting up the FOR...NEXT loop are typically many
assembler/machine code commands for each BASIC program command.