PIC use Microchip assembler, nothing really like Z80, 8080 or else. Every datasheet state the available assembler mnemonics in.
Free online book
http://www.mikroe.com/en/books/picbook/picbook.htm
PIC use Microchip assembler, nothing really like Z80, 8080 or else. Every datasheet state the available assembler mnemonics in.
Free online book
http://www.mikroe.com/en/books/picbook/picbook.htm
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
.
Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
.
There simply is no "Happy Spam" If you do it you will disappear from this forum.
Originally Posted by Joe S.
- The datasheets. The "Instruction Set" section lists each opcode and what it does.
- The .ASM file generated by PBP
- The .LST file generated by the assembler.
- PBPPIC14.LIB / PBPPIC14.MAC
-or- PBPPIC18.LIB /PBPPIC18.MAC files. (depending on the PIC you are using)
I've looked at other PIC assembler books, and the one thing they all lack, is how to use assembly language with PicBasic Pro.
It's not the same.
I don't think I could even write a working program in straight assembly language. Mostly because I used the same list of items shown above myself, to learn ASM with PBP.
PBP, doesn't really write any ASM. Instead it converts your Basic program into a series of macros that are at a level in-between Basic and assembly language.
If you want to use ASM with PicBasic Pro, then this is the area you need to learn the most.
You can actually work at the macro level, without knowing any of the 35 opcodes that the PIC uses (a few more for 18F's).
Since you already know a lot about PBP, the easiest way will be to just create small programs. (blinky lights, or simple A/D conversions)
Compile the program with PBP then open up the .ASM file that has the same name as your program. There you can see how it converted the Basic language statements into the "Macro" language. Then make small changes to the program, and see how the macro's change.
Once you know what macros are used, you can look them up in the PBP1xPIC.LIB and .MAC files to see the actual Assembly language Opcodes used. When you come up on an opcode that you aren't familiar with, look it up in the datasheet. Since you already know what it's supposed to do (you wrote the PBP program) it makes it much easier to understand how the opcode works. Reading a book doesn't give you that "Edge".
It's also a little like an interactive book.
Instead of getting stuck because the author left something out.
You can just make another test program in PBP to see how it ends up in ASM.
I never did use anything out of those other books.
It just didn't apply to PicBasic Pro.
HTH,
DT
I think in years to come the only people using ASM will be Kernel programmers.
Hi Darrel,
Hmmmmmmmn, Good to know, save my money too, Very good thing! That is pretty much how I have learned everything else I know, keep taking it apart to see what makes it tick. I just sort of thought there might be a <font color=red>college boy</font color> way that was more expedient. At least I am familiar with this path. ThankYou for the heads up!<br> I just want to understand what programs do at the machine's level when you or Mr_e or others post assy code examples and helpers. Probably I need to get sharper with PBP before wandering into the woods . . .
Thanks again,
JS
If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
.
Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
.
There simply is no "Happy Spam" If you do it you will disappear from this forum.
Bookmarks