NEW: Learning electronics? Ask your questions on the new Electronics Questions & Answers site hosted by CircuitLab.
Microcontroller Programming » Anybody using Programmer's Notepad?
January 14, 2011 by Ralphxyz ![]() |
I am looking at using Programmer's Notepad. How does one reference the libnerkits .o (Object) files? When/which do you use Make All, Make Clean or Program? Anything else I should know? Ralph |
---|---|
January 14, 2011 by Rick_S ![]() |
I Use it all the time, Ralph. If you leave the makefile the way it is, and keep it in the same folder as the file you are editing, just select [WinAVR]Make All and it will complie just as if you did it from the command line... On a PC... Not sure about Linux or MAC. With the make files simple as the included one's are, [WinAVR]Make Clean, and [WinAVR]Program, will error out because there are no entries for them in the makefile. I will occasionally add the line
where progname is the name of the file I'm working with then I can select [WinAVR]Program and just compile without uploading to the chip. This comes in handy when I'm just wanting to do a quick complie to check for my typo's in the program. :) |
January 14, 2011 by Ralphxyz ![]() |
Ah that's great thanks Rick. I'll keep playing with it. I thought I had a Makefile in the project folder probable not. I will probable use program: progname.hex as my current project uses PB0 which conflicts with the bootloader so I am flashing the mcu with my Dragon programmer. Thanks again, Ralph |
January 14, 2011 by Ralphxyz ![]() |
Rick, when I try to do "Make All" it is looking for a device on the com port. How do I tell it to just make the .hex file? Where does program: progname.hex go? I assume the AVRDUDE line has to be modified also? Ralph |
January 14, 2011 by mongo ![]() |
I use it! I just have to teach myself how each time as I go long spells between them. |
January 15, 2011 by Rick_S ![]() |
This is a sample makefile for a project I was working on. As you can see, it's just like the NK files only with the program: line added. If I select [WinAVR]Program, it just compiles. If I select [WinAVR]Make All, it compiles then uploads using the bootloader. If I wanted it to upload via ISP, I'd just change my AVRDUDEFLAGS to reflect that.
|
January 15, 2011 by Ralphxyz ![]() |
Thanks Rick, works great. Just to note I have to remove any existing .hex and .o files from the program folder before [WinAvr] Program works. Without deleting the .hex an .o I get:
This is just noted for future reference in case any comes behind me. Thanks again, Ralph |
January 15, 2011 by Rick_S ![]() |
You shouldn't have to do that if you change something in your program, then save it. Make should note the change in the source file and re-compile. If you try to re-compile without making any changes you will get that response because... there isn't really anything for make to do, the hex is current. |
January 16, 2011 by Ralphxyz ![]() |
Damm I hate applications that are smarter than I am. That makes sense. I was testing the same code. Ralph |
Please log in to post a reply.
Did you know that a motor's no-load current at a given voltage is much less than it's resistance would suggest? Learn more...
|