<?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/243" />

	<title>Objective Development Forums</title>
	
	<link href="https://forums.obdev.at/index.php" />
	<updated>2007-02-14T04:49:45+02:00</updated>

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

		<entry>
		<author><name><![CDATA[ksz]]></name></author>
		<updated>2007-02-14T04:49:45+02:00</updated>

		<published>2007-02-14T04:49:45+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=243&amp;p=911#p911</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=243&amp;p=911#p911"/>
		<title type="html"><![CDATA[[long] IR mouse problem]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=243&amp;p=911#p911"><![CDATA[
<blockquote><div><cite>Grendel wrote:</cite>How big is ir.data[] dimensioned ? I could see that overflowing if it's smaller than 253.</div></blockquote><br /><br />It is 64<br />Change to 256 doesn't help..<br /><br />EDIT:<br />Well, on two tinys connected via USART it just works..<br />No dmesg's errors, everything is OK..<br /><br />Thanks for help any way!<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=127">ksz</a> — Wed Feb 14, 2007 4:49 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Grendel]]></name></author>
		<updated>2007-02-13T23:54:20+02:00</updated>

		<published>2007-02-13T23:54:20+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=243&amp;p=908#p908</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=243&amp;p=908#p908"/>
		<title type="html"><![CDATA[[long] IR mouse problem]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=243&amp;p=908#p908"><![CDATA[
How big is ir.data[] dimensioned ? I could see that overflowing if it's smaller than 253.<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=101">Grendel</a> — Tue Feb 13, 2007 11:54 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[christian]]></name></author>
		<updated>2007-02-13T23:45:58+02:00</updated>

		<published>2007-02-13T23:45:58+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=243&amp;p=907#p907</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=243&amp;p=907#p907"/>
		<title type="html"><![CDATA[[long] IR mouse problem]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=243&amp;p=907#p907"><![CDATA[
I doubt that it's a problem with the rxBuffer crossing a page. If it were a page boundary problem, it would not depend on whether interrupts are actually received or not.<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=8">christian</a> — Tue Feb 13, 2007 11:45 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Grendel]]></name></author>
		<updated>2007-02-13T23:42:50+02:00</updated>

		<published>2007-02-13T23:42:50+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=243&amp;p=906#p906</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=243&amp;p=906#p906"/>
		<title type="html"><![CDATA[[long] IR mouse problem]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=243&amp;p=906#p906"><![CDATA[
.bss segment crossing a 256b page boundary maybe ?<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=101">Grendel</a> — Tue Feb 13, 2007 11:42 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[christian]]></name></author>
		<updated>2007-02-12T20:15:22+02:00</updated>

		<published>2007-02-12T20:15:22+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=243&amp;p=896#p896</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=243&amp;p=896#p896"/>
		<title type="html"><![CDATA[[long] IR mouse problem]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=243&amp;p=896#p896"><![CDATA[
The debug logs look as if you would do logging from the IR interrupt handler (one line of log is inserted into the middle of another line). You should NEVER do time consuming things like debug logging from an ISR. That causes all kinds of problems.<br /><br />You must do something in your ISR or main code which confuses the USB driver. The most likely thing is that you disable interrupts for too long, maybe implicitly by calling a library routine.<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=8">christian</a> — Mon Feb 12, 2007 8:15 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ksz]]></name></author>
		<updated>2007-02-12T14:25:24+02:00</updated>

		<published>2007-02-12T14:25:24+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=243&amp;p=892#p892</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=243&amp;p=892#p892"/>
		<title type="html"><![CDATA[[long] IR mouse problem]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=243&amp;p=892#p892"><![CDATA[
no..<br />Still after few packets from remote the device 'disapears' from usbview, here's some of debug now (as you can see, there are some strange otputs, eg.:<br />10: 00 002: 01 00 00, this 002: is my 02: prefix..)<br /><div class="codebox"><p>Code: </p><pre><code>...<br />5 27 00 04 0d 00 09 f6<br />10: 00 002: 01 00 00<br />5 27 00 04 0d 00 09 f6<br />10: 00 002: 01 00 00<br />5 27 00 04 0d 00 09 f6<br />ff:<br />10: 00 002: 01 00 00<br />5 27 00 04 0d 00 09 f6<br />10: 00 002: 01 00 00<br />5 28 00 05 0d 00 0a 76 0d<br />10: 00 002: 01 00 00<br />5 28 00 04 0d 00 09 76<br />10: 00 002: 01 00 00<br />5 28 00 04 0d 00 09 76<br />ff:<br />10: 80 06 00 00 06 0d 00 0b 6e ca fd<br />20: 4b 00 00<br />ff:<br />ff:<br />10: 00 05 2c 00 06 0d 00 0b 76 0d 00<br />20: 4b 00 00<br />ff:<br />10: 00 002: 00 00 fd<br />5 2c 00 04 0d 00 09 a0<br />10: 00 002: 00 00 fd<br />5 2c 00 04 0d 00 09 a0<br />10: 00 002: 00 00 fd<br />5 2c 00 04 0d 00 09 a0<br />10: 00 002: 00 00 fd<br />5 2c 00 04 0d 00 09 a0<br />ff:<br />10: 00 05 31 00 06 0d 00 0b f7 0d 00<br />20: 4b 00 00<br />10: 05 302: 00 00 fd<br />1 00 05 0e 00 09 a0 0e<br />10: 00 002: 00 00 fd<br />5 31 00 04 0d 00 09 a0<br />10: 00 002: 00 00 fd<br />5 31 00 04 0d 00 09 a0<br />10: 00 002: 00 00 fd<br />5 31 00 05 0d 00 0a a0 0d<br />ff:<br />10: 00 002: 00 00 fd<br />5 31 00 05 0d 00 0a a0 0d<br />10: 00 002: 00 00 fd<br />5 31 00 04 0d 00 09 a0<br />10: 00 002: 00 00 fd<br />5 31 00 04 0d 00 09 a0<br />ff:<br />10: 00 05 36 00 06 0d 00 0b 77 0d 00<br />20: 4b 00 00<br />10: 00 05 36 00 04 0d 00 09 a0<br />10: 00 002: 00 00 fd<br />5 36 00 04 0d 00 09 a0<br />10: 00 002: 00 00 fd<br />5 36 00 04 0d 00 09 a0<br />10: 05 302: 00 00 fd<br />6 00 05 0e 00 09 a0 0e<br />ff:<br />10: 00 002: 00 00 fd<br />5 36 00 04 0d 00 09 a0<br />10: 00 002: 00 00 fd<br />5 36 00 04 0d 00 09 a0<br />...</code></pre></div><br /><br />And here with no IR transmition:<br /><div class="codebox"><p>Code: </p><pre><code>...<br />ff:<br />10: 00 05 3b 00 06 0d 00 0b f7 0d 00<br />20: 4b 00 00<br />ff:<br />ff:<br />10: 00 05 40 00 06 0d 00 0b 72 0d 00<br />20: 4b 00 00<br />ff:<br />ff:<br />10: 00 05 45 00 06 0d 00 0b f2 0d 00<br />20: 4b 00 00<br />ff:<br />ff:<br />10: 00 05 4a 00 06 0d 00 0b 72 0d 00<br />20: 4b 00 00<br />ff:<br /></code></pre></div><br /><br />And again my USB HUB hangs (mouse stops:), after disconnect of my 'IRmouse' hub works normally, mouse is usable..<br />(Sometimes hub hangs for good, only disconnect of my device helps, somatimes hangs for a while, turning IRmouse off and works fine.. This debug output is for long hang of whole hub..)<br /><br />Arghhh..!<br />I think I'll make it on two attinys: one for IR, one for USB.. <br />Or, Christian, are there some other solutions..?<br /><br />Any way, thanks a lot for patience and help!<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=127">ksz</a> — Mon Feb 12, 2007 2:25 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[christian]]></name></author>
		<updated>2007-02-12T11:21:41+02:00</updated>

		<published>2007-02-12T11:21:41+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=243&amp;p=891#p891</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=243&amp;p=891#p891"/>
		<title type="html"><![CDATA[[long] IR mouse problem]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=243&amp;p=891#p891"><![CDATA[
And... does it change anything?<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=8">christian</a> — Mon Feb 12, 2007 11:21 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ksz]]></name></author>
		<updated>2007-02-12T01:41:46+02:00</updated>

		<published>2007-02-12T01:41:46+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=243&amp;p=889#p889</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=243&amp;p=889#p889"/>
		<title type="html"><![CDATA[[long] IR mouse problem]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=243&amp;p=889#p889"><![CDATA[
<blockquote><div><cite>christian wrote:</cite>I'm not sure the code for vector 5 is OK. The SEI as a first instruction is inserted manually (&quot;#APP&quot; and &quot;#NOAPP&quot; framing) and the compiler comments that the function is &quot;naked&quot;. That would indicate that no PUSH instructions have been emitted as it would be appropriate for an ISR.<br /><br />Vector 6, on the other hand, is probably OK. You did not include the PUSH instructions, but since everything was compiler-generated, the pushes should be OK.</div></blockquote><br /><br />My mistake, sorry..<br />Now no manually added sei() in ISR's and no naked interrupts..<br />Here are compiler generated vectors:<br /><div class="codebox"><p>Code: </p><pre><code>   .global   __vector_5<br />   .type   __vector_5, @function<br />__vector_5:<br />/* prologue: frame size=0 */<br />   sei<br />   push __zero_reg__<br />   push __tmp_reg__<br />   in __tmp_reg__,__SREG__<br />   push __tmp_reg__<br />   clr __zero_reg__<br />   push r18<br />   push r19<br />   ...<br />   <br />   .global   __vector_6<br />   .type   __vector_6, @function<br />__vector_6:<br />/* prologue: frame size=0 */<br />   sei<br />   push __zero_reg__<br />   push __tmp_reg__<br />   in __tmp_reg__,__SREG__<br />   push __tmp_reg__<br />   clr __zero_reg__<br />   push r18<br />   ...</code></pre></div><p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=127">ksz</a> — Mon Feb 12, 2007 1:41 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[christian]]></name></author>
		<updated>2007-02-11T23:49:51+02:00</updated>

		<published>2007-02-11T23:49:51+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=243&amp;p=886#p886</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=243&amp;p=886#p886"/>
		<title type="html"><![CDATA[[long] IR mouse problem]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=243&amp;p=886#p886"><![CDATA[
I'm not sure the code for vector 5 is OK. The SEI as a first instruction is inserted manually (&quot;#APP&quot; and &quot;#NOAPP&quot; framing) and the compiler comments that the function is &quot;naked&quot;. That would indicate that no PUSH instructions have been emitted as it would be appropriate for an ISR.<br /><br />Vector 6, on the other hand, is probably OK. You did not include the PUSH instructions, but since everything was compiler-generated, the pushes should be OK.<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=8">christian</a> — Sun Feb 11, 2007 11:49 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ksz]]></name></author>
		<updated>2007-02-11T23:07:33+02:00</updated>

		<published>2007-02-11T23:07:33+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=243&amp;p=885#p885</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=243&amp;p=885#p885"/>
		<title type="html"><![CDATA[[long] IR mouse problem]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=243&amp;p=885#p885"><![CDATA[
<blockquote><div><cite>christian wrote:</cite>If &quot;__attribute__ ((interrupt))&quot; does not change anything, I'd be suspicious. Try to compile the module with the &quot;-S&quot; option to gcc. this will print the assembler source code. Then look at the code where the sei() instruction is. If it's among the first instructions of the ISR, it's OK and the problem must be somewhere else.</div></blockquote><br /><br />sei is first <img class="smilies" src="./../../../images/smilies/icon_neutral.gif" alt=":|" title="Neutral" /><br /><div class="codebox"><p>Code: </p><pre><code>__vector_5:<br />/* prologue: frame size=0 */<br />/* prologue: naked */<br />/* prologue end &#40;size=0&#41; */<br />/* #APP */<br />   sei<br />/* #NOAPP */<br />   ...</code></pre></div><br /><div class="codebox"><p>Code: </p><pre><code>__vector_6:<br />/* prologue: frame size=0 */<br />   sei<br />   ...</code></pre></div><br /><br />So where is the problem..? My code..? What else can I do to find it?<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=127">ksz</a> — Sun Feb 11, 2007 11:07 pm</p><hr />
]]></content>
	</entry>
	</feed>
