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

	<title>Objective Development Forums</title>
	
	<link href="https://forums.obdev.at/index.php" />
	<updated>2009-05-25T11:45:16+02:00</updated>

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

		<entry>
		<author><name><![CDATA[vputz]]></name></author>
		<updated>2009-05-25T11:45:16+02:00</updated>

		<published>2009-05-25T11:45:16+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=2797&amp;p=9458#p9458</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=2797&amp;p=9458#p9458"/>
		<title type="html"><![CDATA[hid: joystick reports kill device, mouse/keyboard OK]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=2797&amp;p=9458#p9458"><![CDATA[
I'm working on a fun little device which converts the old serial SpaceOrb 360, SpaceBall 2000/4000, and Magellan devices to USB joystick/mouse/keyboard devices.  Works like a charm--sort of.  It used to work beautifully as a joystick, but now that I've added keyboard and mouse, the keyboard/mouse bindings work well but enabling joystick reports kills the device.<br /><br />In short, we have three reports: an 80-bit joystick report (report ID 4), a 48-bit keyboard report (report ID 2), and a 32-bit mouse report (report ID 3).  To send the joystick report, I do the trick of sending the first 8 bytes (1 byte for the ID, 7 bytes of the message), waiting for usbInterruptIsReady(), then sending the last three bytes of the message; the mouse and keyboard reports can be sent in one go.<br /><br />Watching the USB subsystem with USBHound, I can actually send &quot;joystick is centered&quot; messages and the device will not crash.  But if I send a message that it's off-center, I get a &quot;stall&quot; situation and the device is dropped.  My suspicion is that this has to do with the second part of the joystick message--that maybe the USB subsystem is trying to look at that first byte and make it a report id (?).  Is that likely?  Should I try and break up the joystick report into two separate reports or some such?<br /><br />Sorry for the confusion.  I can post as much info as would be helpful (device descriptors etc) but wasn't sure if someone would see the description and think &quot;ah, here is the problem&quot; and didn't want to clutter the boards with excess info.<br /><br />--&gt;VPutz<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=2308">vputz</a> — Mon May 25, 2009 11:45 am</p><hr />
]]></content>
	</entry>
	</feed>
