Re: [Sdcc-user] Auto assign variable value through assembler directive instead of code

2007-09-30 Thread David Lucena
--- Peter Kuhar <[EMAIL PROTECTED]> escribió: > Is this a global variable??? > > On 9/30/07, David Lucena <[EMAIL PROTECTED]> wrote: > > > > I am using SDCC to program a z80 machine. When I create this code: > > > > unsigned char test = 0; > > > > It is assembled as follows: > > > > ld

Re: [Sdcc-user] Auto assign variable value through assembler directive instead of code

2007-09-30 Thread Peter Kuhar
Is this a global variable??? On 9/30/07, David Lucena <[EMAIL PROTECTED]> wrote: > > I am using SDCC to program a z80 machine. When I create this code: > > unsigned char test = 0; > > It is assembled as follows: > > ld iy,#_test > ld 0(iy),#0x00 > > But I would like that

[Sdcc-user] Auto assign variable value through assembler directive instead of code

2007-09-30 Thread David Lucena
I am using SDCC to program a z80 machine. When I create this code: unsigned char test = 0; It is assembled as follows: ld iy,#_test ld 0(iy),#0x00 But I would like that it could be initialized as its done in assembler: test: .db 0 Is there any way of forcing this beh

Re: [Sdcc-user] PIC not executing using any power supply other than the computer USB port

2007-09-30 Thread Xiaofan Chen
On 9/30/07, Stanley Lee <[EMAIL PROTECTED]> wrote: > Sorry for the additional spam, but I have a few more questions about the > Makefile as I am on the way of switching away from using piklab ide I think Piklab should work fine. If you have Piklab related problem, try ask in gnupic mailing list. T

Re: [Sdcc-user] PIC not executing using any power supply other than the computer USB port

2007-09-30 Thread Ken Jackson
I salute the switch to the Makefile, even if it's a pain. It makes a LOT of sense to keep all the details of a compilation (commands, switches, command-line variables, etc.) in one text file which can be controlled by a version control system. Most IDEs keep that information in some proprietary p

Re: [Sdcc-user] PIC not executing using any power supply other than the computer USB port

2007-09-30 Thread sdcc
Hi Sadly makefiles are hard to read. I usually write generic makefiles so i only need to do it once ;) Stanley Lee wrote: > PROG_NAME = LED_toggle.hex > OBJS = main.o > all: $(PROG_NAME) > > #for the .c.o directive below, do I need to replace it with the > .c .o instead of .c.o? i.e. how would I

Re: [Sdcc-user] PIC not executing using any power supply other than the computer USB port

2007-09-30 Thread bobrob
[EMAIL PROTECTED] wrote: >I use "$< -o $@" >where you have "$+ -o $(@)". > oops, I have confused my compile and link commands. My link command uses "$^ -o $@" $^ is like $+, but with no duplicates. Randy - This SF.net em

Re: [Sdcc-user] PIC not executing using any power supply other than the computer USB port

2007-09-30 Thread Bodo Wenzel
> Sorry for the additional spam, but I have a few more questions about the > Makefile as I am on the way of switching away from using piklab ide and > more towards using the Makefile. > [...] Please do a simple Google search with "make tutorial", and read at least two or three of them. It might he

Re: [Sdcc-user] PIC not executing using any power supply other than the computer USB port

2007-09-30 Thread bobrob
Stanley Lee wrote: > #for the .c.o directive below, do I need to replace it with the > .c .o instead of .c.o? i.e. how would I know which > source code to compile and build? > > .c.o: >$(CC) $(CFLAGS) $(INC) -c $< I'm no expert on makefiles, but perhaps you want to use %.o : %.c I thi