You are correct. C language is much easier. However, C language is a higher level language. In C, there isn't always an intuitive understanding of how your programming is affecting the hardware components inside the chip. For instance, in Assembly, there is setting the timers for delay routines, setting bits in the special function registers, and manipulation of data memory locations. In C language, you can use the delay instruction to create delays, whereas in Assembly, you need to develop a delay routine using counters and possibly the internal timers. In C language, you can declare variables and the assembler automatically assigns variables to a memory location so you don't have to. In Assembly you have to designate memory locations and pay attention to the memory map (although, there is the CBlock directive). Here is another example. In C, you can create a "for loop." for (i = 1; i
@@2bit661 You make a lot of good points! Once you master assembly, you can write very fast programs in the small memory space on a $1 pic chip. Back in the days of Commodore 64 and Apple //e, game programmers had to use assembly language to make a fast complex game in a small memory space.
Wouldn't writing C code be much easier, and almost as fast as assembly?
You are correct. C language is much easier. However, C language is a higher level language. In C, there isn't always an intuitive understanding of how your programming is affecting the hardware components inside the chip. For instance, in Assembly, there is setting the timers for delay routines, setting bits in the special function registers, and manipulation of data memory locations.
In C language, you can use the delay instruction to create delays, whereas in Assembly, you need to develop a delay routine using counters and possibly the internal timers.
In C language, you can declare variables and the assembler automatically assigns variables to a memory location so you don't have to. In Assembly you have to designate memory locations and pay attention to the memory map (although, there is the CBlock directive).
Here is another example. In C, you can create a "for loop."
for (i = 1; i
@@2bit661 You make a lot of good points! Once you master assembly, you can write very fast programs in the small memory space on a $1 pic chip. Back in the days of Commodore 64 and Apple //e, game programmers had to use assembly language to make a fast complex game in a small memory space.