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

	<title>Objective Development Forums</title>
	
	<link href="https://forums.obdev.at/index.php" />
	<updated>2015-10-01T14:04:07+02:00</updated>

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

		<entry>
		<author><name><![CDATA[Sinnlosvoll]]></name></author>
		<updated>2015-10-01T14:04:07+02:00</updated>

		<published>2015-10-01T14:04:07+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=10070&amp;p=30340#p30340</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=10070&amp;p=30340#p30340"/>
		<title type="html"><![CDATA[Problems with USB HID Special keys]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=10070&amp;p=30340#p30340"><![CDATA[
Hey there,<br /><br />I tried for a while to get my old sun type 5c keyboard onto usb and now I'm at a point where the keys are registered and modifiers work, but only on linux.<br />On windows it doesn't accept the volume up/down/mute or power keys. And on linux the power key seems to act as a sleep key.<br /><br />I assume it has to do with my report descriptor and/or differences in how windows handles those few keys.<br />I checked with a tool if the keyboard does get recognised correctly in windows and sends the correct commands, and they seem okay.<br />Compared to another real keyboard, it only has 1 stream while the real one has apparently 2.<br /><br />Can anyone help me with this problem?<br /><br /><div class="codebox"><p>Code: </p><pre><code>PROGMEM const char usbHidReportDescriptor&#91;USB_CFG_HID_REPORT_DESCRIPTOR_LENGTH&#93; = {<br />    0x05, 0x01,                    // USAGE_PAGE (Generic Desktop)<br />    0x09, 0x06,                    // USAGE (Keyboard)<br />    0xa1, 0x01,                    // COLLECTION (Application)<br />    0x75, 0x01,                    //   REPORT_SIZE (1)<br />    0x95, 0x08,                    //   REPORT_COUNT (8)<br />    0x05, 0x07,                    //   USAGE_PAGE (Keyboard)(Key Codes)<br />    0x19, 0xe0,                    //   USAGE_MINIMUM (Keyboard LeftControl)(224)<br />    0x29, 0xe7,                    //   USAGE_MAXIMUM (Keyboard Right GUI)(231)<br />    0x15, 0x00,                    //   LOGICAL_MINIMUM (0)<br />    0x25, 0x01,                    //   LOGICAL_MAXIMUM (1)<br />    0x81, 0x02,                    //   INPUT (Data,Var,Abs) ; Modifier byte<br />    0x95, 0x01,                    //   REPORT_COUNT (1)<br />    0x75, 0x08,                    //   REPORT_SIZE (8)<br />    0x81, 0x03,                    //   INPUT (Cnst,Var,Abs) ; Reserved byte<br />    0x95, 0x05,                    //   REPORT_COUNT (5)<br />    0x75, 0x01,                    //   REPORT_SIZE (1)<br />    0x05, 0x08,                    //   USAGE_PAGE (LEDs)<br />    0x19, 0x01,                    //   USAGE_MINIMUM (Num Lock)<br />    0x29, 0x05,                    //   USAGE_MAXIMUM (Kana)<br />    0x91, 0x02,                    //   OUTPUT (Data,Var,Abs) ; LED report<br />    0x95, 0x01,                    //   REPORT_COUNT (1)<br />    0x75, 0x03,                    //   REPORT_SIZE (3)<br />    0x91, 0x03,                    //   OUTPUT (Cnst,Var,Abs) ; LED report padding<br />    0x95, 0x06,                    //   REPORT_COUNT (6)<br />    0x75, 0x08,                    //   REPORT_SIZE (8)<br />    0x15, 0x00,                    //   LOGICAL_MINIMUM (0)<br />    0x25, 0xFF,                    //   LOGICAL_MAXIMUM (101)<br />    0x05, 0x07,                    //   USAGE_PAGE (Keyboard)(Key Codes)<br />    0x19, 0x00,                    //   USAGE_MINIMUM (Reserved (no event indicated))(0)<br />    0x29, 0x91,                    //   USAGE_MAXIMUM (Keyboard Application)(101)<br />    0x81, 0x00,                    //   INPUT (Data,Ary,Abs)<br />    0xc0                           // END_COLLECTION<br />};</code></pre></div><p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=21604">Sinnlosvoll</a> — Thu Oct 01, 2015 2:04 pm</p><hr />
]]></content>
	</entry>
	</feed>
