Make

Guest #1171787
Rate this post
• ▲ useful
▼ not useful
Randall Swaving wrote:
> How can I start lpc21isp from make?
> Thnak you.

Examples how this can be configured are available in most (all) of the
Makefiles from the WinARM-Examples collection for LPC2xxx available in
examples-directory of the WinARM distribution-package or at
http://www.siwawi.arubi.uni-kl.de/avr_projects/arm_projects/index.html

(1)
Somewhere in a Makefile you can add some configuration-options as
"variables":

#
------------------------------------------------------------------------ 
---
# Flash-Programming support using lpc21isp by Martin Maurer
# only for Philips LPC and Analog ADuC ARMs
#
# Settings and variables:
LPC21ISP = lpc21isp
LPC21ISP_PORT = com1
LPC21ISP_BAUD = 38400
LPC21ISP_XTAL = 12000
LPC21ISP_FLASHFILE = $(TARGET).hex
# other options:
# * verbose output: -debug
# * enter bootloader via RS232 DTR/RTS (only if hardware supports this
#   feature - see Philips AppNote): -control
LPC21ISP_OPTIONS = -control
#LPC21ISP_OPTIONS += -debug
#
------------------------------------------------------------------------ 
---

(2)
Than add a program target to your makefile:

program: $(TARGET).$(IMGEXT)
--->$(LPC21ISP) $(LPC21ISP_OPTIONS) $(LPC21ISP_FLASHFILE)
$(LPC21ISP_PORT) $(LPC21ISP_BAUD) $(LPC21ISP_XTAL)

"--->" to be replaced by a tabulator. All $(LPC21ISP_*) in one line.

(3)
With this entries a make program will start lpc21isp with the given
parameters

Hope this helps,
Martin Thomas

Reply

Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.

Formatting
  • [c]C-Code[/c]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]
  • [[Title]] – link to an article
  • Link to another post: right-click its post ID (#8078628), copy the address, paste it into the text

More about formatting

Post long source code as an attachment, not in the text.

Already registered? Log in

Not shown to anyone. We send you a link; your post appears once you confirm it there.

By submitting you create a free account and accept the terms of use.