Hey guys. Sorry to bug everyone on the weekend/holiday (my international/US friends respectfully), but I'm having a real problem with MPLAB and I can't figure out what I'm doing wrong.
First off, is this really the best program to use for programming? I know you guys recommend to start off with assembler language as a beginning programming language, but MPLAB is giving me a hard time. I just read the MPLAB quickstart quide and after loading the sample/template asm file for my PIC and the corresponding link file, I can't get a successful build. I keep getting the following feedback in the output window:
Clean: Deleting intermediary and output files.
Clean: Deleted file "D:\Projects\ABE\ABE v1.mcs".
Clean: Done.
Executing: "C:\Program Files\Microchip\MPASM Suite\MPAsmWin.exe" /q /p16F877A "f877atemp.asm" /l"f877atemp.lst" /e"f877atemp.err" /o"f877atemp.o"
Error[129] D:\PROJECTS\ABE\F877ATEMP.ASM 1 : Expected (END)
Halting build on first failure as requested.
BUILD FAILED: Sun Sep 04 18:07:50 2005
Anyone know what I'm doing wrong? I'm using v7.21 and the quick start is for version 6.61.02.
Is there a good tutorial that will break down code sequences? In other words, a tutorial that will explain in detail how program code is accessing and assigning instructions? When I look at asm code, I feel like the biggest idiot. PLEASE HELP!
It seems like you are trying to compile blank file?
The error tells us that on line (1) should be located END dirrective (that's the last line of the file).
You might try just using MPASM?, the MicroChip assembler, MPLAB presumably calls this to actually assemble code, but you can use it on it's own - it's installed as part of MPLAB.
It's FAR easier to do this than to use MPLAB, which seems very over complicated?.
Simply write your code in a text editor (Notepad is fine) and save it with a .ASM filename. Then simply run MPASM, select that filename, and press assemble! - job done!.
thanks guys. i thought my asm had code in it as i was using an asm template that was in the program....ah well...idiot move of the week.
I keep seeing sample code all over and I'm not sure what ever little part of it means. I need a good tutorial that shows the code structure in detail from start to finish. I think I have a good algorithm figured out, I just need a good code lesson.
If you can use a text editor and a command line shell, you can use MPLAB! The IDE is there to make it easier, not harder...
By not using MPLAB, you are missing on a good free text editor and a great simulator. Build a cheap ICD2 clone and you get a complete development environment that can program *any* PIC, and debug a lot of them.
I can't believe Nigel Goodwin suggested a beginner not to tuse MPLAB...
May I recommend the Elmer 160 tutorial at https://www.amqrp.org/elmer160/index.html? It's by a programmer / radio amateur and takes you pretty much right from the beginning with MPLab...
Don't worry about stumbling... It took me nearly two weeks to get my first program running because I messed up on the configuration fuses... Also didn't realize there were all these wonderful Forums around...
Then I guess you are doing a BIG mistake! It will save you lot's of time and problems If you know how to use it. Just give it a try and don't give up too soon.
Nigel, don't take this the wrong way, but... how old are you?
Seriously, I can understand someone with a lot of experience with other software tools not wanting to use MPLAB. To each his own.
There are fine alternatives. VIDE comes to mind. Eclipse could also be configured to integrate MPASM functionality. Something like UltraEdit which is halfway between a text editor and an IDE could make a fine development environment. But you still lose the simulator and the debugging functionnality.
Suggesting Notepad to a beginner as a fine text editor? Come on... You're not really using Notepad, are you?
There's your secret! I love UltraEdit, consistantly great software at a great price. The author was nice enough to offer me a good rebate on a license when I was a student, and just for that I make a point of renewing my license every few years, even though the first version I bought back then (6 or 7, can't remember) would still do the trick today.
I use UltraEdit too. Mine is version 5.10a which I got free from the cover CD of a computer magazine. Great software, gets even better with syntax highlighting turned on.
Yep. You first have to create a Tool (Advanced->Tool Configuration...). Put the command there.
You can then assign a key in the Key Mapping section (Advanced->Configuration...->Key Mapping). In my version of UltraEdit, each "AdvancedUserTool" has a default key mapping of Ctrl-Shift-[tool number]. you can change that to whatever you want.
You can also have a button on the toolbar if you prefer that. You set that in the Toolbar section of the Configuration panel...
Hell yeah! I found this out about 2 weeks ago. Somehow, when I started playing with PIC programming, I had assumed that no one would have bothered to come up with a PIC wordlist for UEdit. Was I wrong... There are actually a few hundred wordlists to choose from, some for languages I have never even heard of!...