<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forums.obdev.at/app.php/feed/topic/4334" />

	<title>Objective Development Forums</title>
	
	<link href="https://forums.obdev.at/index.php" />
	<updated>2010-06-10T17:47:49+02:00</updated>

	<author><name><![CDATA[Objective Development Forums]]></name></author>
	<id>https://forums.obdev.at/app.php/feed/topic/4334</id>

		<entry>
		<author><name><![CDATA[borisdekat]]></name></author>
		<updated>2010-05-25T21:47:12+02:00</updated>

		<published>2010-05-25T21:47:12+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=4334&amp;p=14594#p14594</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=4334&amp;p=14594#p14594"/>
		<title type="html"><![CDATA[Re: Compiling with AVRStudio]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=4334&amp;p=14594#p14594"><![CDATA[
I found my Error !. Nothing to do with AVRstudio and/or linking stuff.<br /><br />I used for the hid-mouse example not the included usbconfig.h but started of with usbconfig-prototype and made the (I thought...) needed changes. Apparantly I missed one very important one:<br /><br />#define USB_CFG_HAVE_INTRIN_ENDPOINT    0<br />/* Define this to 1 if you want to compile a version with two endpoints: The<br /> * default control endpoint 0 and an interrupt-in endpoint (any other endpoint<br /> * number).<br /> */<br /><br />It should be &quot;1&quot; to enable the interrupt routines in main.c to function correct (even compile correct)....<br /><br />So a real newbee error <img class="smilies" src="./../../../images/smilies/icon_smile.gif" alt=":-)" title="Smile" /><br /><br />Thanks for the reply , gl<br /><br />Boris.<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=3949">borisdekat</a> — Tue May 25, 2010 9:47 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ciplukz]]></name></author>
		<updated>2010-05-25T16:54:04+02:00</updated>

		<published>2010-05-25T16:54:04+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=4334&amp;p=14587#p14587</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=4334&amp;p=14587#p14587"/>
		<title type="html"><![CDATA[Re: Compiling with AVRStudio]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=4334&amp;p=14587#p14587"><![CDATA[
Actually, at first i also got stuck when trying it with AVRStudio...<br />But, after seeking up some reference i got the sample which is using avr studio for IDE.<br />You can look avr-cdc example for Your reference.. I got my project compile with it makefile..<br /><br />Here i try to post my working makefile...<br /><div class="codebox"><p>Code: </p><pre><code> <br />###############################################################################<br /># Makefile for the AVRStudio Project.<br />###############################################################################<br /><br />## General Flags ---&gt; Change this project name refers to your projects name<br />PROJECT = RX<br /><br />#MCU = atmega8<br />#MCU = atmega16<br />#MCU = atmega48<br />#MCU = atmega88<br />#MCU = atmega168<br />MCU = atmega32<br />#MCU = atmega328p<br /><br />CLK = 12000000UL<br />#CLK = 15000000UL<br />#CLK = 16000000UL<br />#CLK = 18000000UL<br />#CLK = 20000000UL<br /><br />TARGET = RX.elf<br />CC = avr-gcc<br /><br />## Options common to compile, link and assembly rules<br />COMMON = -mmcu=$(MCU) -DF_CPU=$(CLK)<br /><br />## Compile options common for all C compilation units.<br />CFLAGS = $(COMMON)<br />CFLAGS += -Wall -gdwarf-2 -Os -fsigned-char<br />CFLAGS += -MD -MP -MT $(*F).o -MF dep/$(@F).d <br /><br />## Assembly specific flags<br />ASMFLAGS = $(COMMON)<br />ASMFLAGS += $(CFLAGS)<br />ASMFLAGS += -x assembler-with-cpp -Wa,-gdwarf2<br /><br />## Linker flags<br />LDFLAGS = $(COMMON)<br />LDFLAGS += <br /><br /><br />## Intel Hex file production flags<br />HEX_FLASH_FLAGS = -R .eeprom -R .fuse -R .lock -R .signature<br /><br />HEX_EEPROM_FLAGS = -j .eeprom<br />HEX_EEPROM_FLAGS += --set-section-flags=.eeprom=&quot;alloc,load&quot;<br />HEX_EEPROM_FLAGS += --change-section-lma .eeprom=0 --no-change-warnings<br /><br /><br />## Include Directories<br />INCLUDES = -I&quot;..&quot; -I&quot;../../usbdrv&quot;<br /><br />## Objects that must be built in order to link<br />OBJECTS = usbdrv.o usbdrvasm.o oddebug.o main.o <br /><br />## Objects explicitly added by the user<br />LINKONLYOBJECTS = <br /><br />## Build<br />all: $(TARGET) RX.hex RX.eep RX.lss size<br /><br />## Compile<br />usbdrvasm.o: ../../usbdrv/usbdrvasm.S<br />   $(CC) $(INCLUDES) $(ASMFLAGS) -c  $&lt;<br /><br />usbdrv.o: ../../usbdrv/usbdrv.c<br />   $(CC) $(INCLUDES) $(CFLAGS) -c  $&lt;<br /><br />oddebug.o: ../../usbdrv/oddebug.c<br />   $(CC) $(INCLUDES) $(CFLAGS) -c  $&lt;<br /><br />main.o: ../main.c<br />   $(CC) $(INCLUDES) $(CFLAGS) -c  $&lt;<br /><br />##Link<br />$(TARGET): $(OBJECTS)<br />    $(CC) $(LDFLAGS) $(OBJECTS) $(LINKONLYOBJECTS) $(LIBDIRS) $(LIBS) -o $(TARGET)<br /><br />%.hex: $(TARGET)<br />   avr-objcopy -O ihex $(HEX_FLASH_FLAGS)  $&lt; $@<br /><br />%.eep: $(TARGET)<br />   -avr-objcopy $(HEX_EEPROM_FLAGS) -O ihex $&lt; $@ || exit 0<br /><br />%.lss: $(TARGET)<br />   avr-objdump -h -S $&lt; &gt; $@<br /><br />size: ${TARGET}<br />   @echo<br />   @avr-size -C --mcu=${MCU} ${TARGET}<br /><br />## Clean target<br />.PHONY: clean<br />clean:<br />   -rm -rf $(OBJECTS) RX.elf dep/* RX.hex RX.eep RX.lss<br /><br />## Other dependencies<br />-include $(shell mkdir dep 2&gt;/dev/null) $(wildcard dep/*)<br /></code></pre></div><br /><br />I can attach the working mouse example projects here if you want, but i didnt know how to attach file in this forum..<br />If it is allowed, i'll upload the file to shared file hosting and post the link directly here...  <img class="smilies" src="./../../../images/smilies/icon_wink.gif" alt=":wink:" title="Wink" /><p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=3206">ciplukz</a> — Tue May 25, 2010 4:54 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[borisdekat]]></name></author>
		<updated>2010-06-10T17:47:49+02:00 </updated>

		<published>2010-05-24T23:26:45+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=4334&amp;p=14581#p14581</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=4334&amp;p=14581#p14581"/>
		<title type="html"><![CDATA[-resolved- Compiling with AVRStudio]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=4334&amp;p=14581#p14581"><![CDATA[
Hi, I think it is something very obvious but I can't get it to work...<br /><br />Trying to compile HID_mouse example with AVRSTUDIO.<br /><br />Did copy all the USBDRVto the project directory, changed usbconfig-protoype.h to usbconfig.h, did make some adjustments for the correct port and CPU speed.<br /><br />Added to the project the source files: main.c, oddebug.c, usbdrv.c and usbdrvasm.S<br /><br />When I build all: I get -only- the warning:<br /><br />../main.c:155: warning: implicit declaration of function 'usbInterruptIsReady'<br />../main.c:159: warning: implicit declaration of function 'usbSetInterrupt'<br /><br />and later -only- on the error:<br /><br />D:\sw_atmel\attiny44\default/../main.c:155: undefined reference to `usbInterruptIsReady'<br />D:\sw_atmel\attiny44\default/../main.c:159: undefined reference to `usbSetInterrupt'<br /><br />Seems I am missing some link ?<br /><br />Any hints ?<br /><br />Thanks,<br /><br />Boris<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=3949">borisdekat</a> — Mon May 24, 2010 11:26 pm</p><hr />
]]></content>
	</entry>
	</feed>
