G80-18xx controller replacement

imp

06 Dec 2012, 14:48

Heyho,
I've got some G80-18xx with PS/2 waiting for modification (USB and custom controller, like
Spoiler:
Image
).
The previous design, it works fine, but it's really time-consuming to wire the shift registers by hand on protoboard and I was far to lazy to and the USB hub I wanted (and it would have been another hot-glue job ;))...

Let's talk about the future - the layout for new controller board is done \o/.
Image

Compared with an original controller board for the case:
Image

The "imptech-tasta-v3" features are:
* Atmega32u4.
* 2.0 USB hub onboard (if you like, it's also possible to make a bare board without the hub and only the controller).
* SMP - there's a second controller on the board if you like, with all pins on headers (besides the USB lines). It's connected via I2c, but you can use the UART too). If the controller is connected to USB, the second external USB port has to hand over it's data lines.
* Gameport / external analog/digital-in - so you can connect your old hardware or add some fancy pointing device.
* Internal USB port - place your boot USB stick in there (for "boot&root" action ;)).
* Fits in the original case without great modifications (ranging from one hole for the minimal version up to 4).
* Plenty leds for the USB hub and 5 more connected to the shift registers.
* Will fit in TKL mods.

imp

User avatar
CeeSA

06 Dec 2012, 14:55

very nice, are you gonna offer some controllers?

User avatar
damorgue

06 Dec 2012, 15:00

That is one impressive set of features you managed to cram into that thing.

User avatar
inlikeflynn

06 Dec 2012, 15:11

wow, great job! this is a really awesome replacement controller with some great features. hopefully you plan to sell a couple, as i'm totally interested in a few

imp

06 Dec 2012, 15:35

First I want to test the thing before we can talk about selling :).

MissMurd3r84

06 Dec 2012, 15:50

Looks great, not to mention nice features ^_^

imp

15 Dec 2012, 23:44

Short update - parts and pcbs ordered, half of the parts is already there.
Couldn't resist to play with the laser-cutter of my friends :D
self-dyed keycaps with test laser engraving \o/
self-dyed keycaps with test laser engraving \o/
DSCI0500-small.JPG (880.46 KiB) Viewed 10969 times

IvanIvanovich

16 Dec 2012, 00:40

Will be keeping an eye out for your progress. Also hoping it can turn into a groupbuy or something once testing is a success. I also have few 1800 I wouldn't mind updating.

imp

17 Dec 2012, 09:28

Last parts arrived, only the pcbs are missing - hope they'll be here this week.

imp

18 Dec 2012, 13:53

Tuesday, December 18, 2012 Location Time
1 Shipment picked up SHENZHEN - CHINA, PEOPLES REPUBLIC 19:47
Gogogogogo DHL!

SmallFry

18 Dec 2012, 15:40

Looks cool!

User avatar
mbodrov

18 Dec 2012, 16:15

imp wrote:* 2.0 USB hub onboard (if you like, it's also possible to make a bare board without the hub and only the controller).
Why USB 2.0, not 3.0?

imp

18 Dec 2012, 17:16

mbodrov wrote: Why USB 2.0, not 3.0?
Because kicad doesn't make it easy at the moment to make impedance controlled tracks :/. So it would cost lots of time to make it right, or to screw it up in the end - that's why I went with 2.0 for this iteration. Oh, and I don't have any 3.0 devices around, so it doesn't bother me right now :).

SmallFry

18 Dec 2012, 17:27

I'm sure that is take at least one also. Could we get the PCB files?

imp

18 Dec 2012, 17:44

Wait until the testing has been done :).

SmallFry

18 Dec 2012, 17:56

Very cool! Thanks!

User avatar
tlt

19 Dec 2012, 07:17

Nice looking PCB and flexible design!

imp

20 Dec 2012, 18:04

Finally - boards!!1!elf Had to wait all the day for my "express" shipment from DHL and they took twice the amount of taxes if've expected... But here we go:
stack of boards
stack of boards
100_8111.JPG (967.97 KiB) Viewed 10715 times
hub and controller close-up (note the e-check marks :)
hub and controller close-up (note the e-check marks :)
100_8115.JPG (953.89 KiB) Viewed 10715 times
it fits in the case \o/
it fits in the case \o/
100_8117.JPG (968.85 KiB) Viewed 10715 times
Time to get some food (was too busy lurking all day) and warm up the soldering iron \o/.

User avatar
damorgue

20 Dec 2012, 18:19

Looking nice there imp. I see you bought several. Might I inquire as to what they cost? It doesn't seem to be the same manufacturer as many of the other PCBs which are bought around here.

imp

20 Dec 2012, 23:01

damorgue wrote:Looking nice there imp. I see you bought several. Might I inquire as to what they cost? It doesn't seem to be the same manufacturer as many of the other PCBs which are bought around here.
About 11$ each (PCB+shipping+tax). What gave you the impersion of a different manufacturer? Solderstopmask color? I've asked the guy who managed my order, if he's ready to handle the impact of you guys ;) (no answer yet, I don't want to destroy his christmas :)).

First board is working, populated the minimal version (no ESD protection, nor external power or USB-hub - but shiny LEDs :D ):
First working board, minimal version.
First working board, minimal version.
100_8128.JPG (986.24 KiB) Viewed 10673 times
The 3 0 Ohm resistors: 1 to skip the power switch (which would normally between host-power and external power) and 2 to go directly from the USB-port onto 32u4s datalines, bypassing the missing hub.
Guess I'm going to use sockets for now (so I can detach the matrix) - don't want to end up with 3 additional keyboards on my desk only because I've soldered the matrix directly to the controller.

One minor bug from the footprint's I've used for the USB connectors: all the pads are covered on the bottom with solderstopmask, don't know why...

SmallFry

21 Dec 2012, 01:25

Very cool! I'm looking forward to more progress!

imp

21 Dec 2012, 13:55

Here we go, finished debugging the hub (looked like some bad solder joints or flux residue).
hub soldered and running
hub soldered and running
100_8136.JPG (951.86 KiB) Viewed 10625 times
The small red wire is only for changing the "gang" mode of the hub to individual power and overcurrent protection (doesn't really matter, since it got the currentlimit on the incoming power line and not existant on the downstream ports).
Would have used the board with my SD cardreader, but "rejected 1 configuration due to insufficient available bus power".... still have to find a fitting plug for the external power input :) (so I can test the selfpowered configuration too).
lsusb output with a connected usbstick:
Spoiler:

Code: Select all

# lsusb -vvvvvv -d 04b4:6570

Bus 002 Device 068: ID 04b4:6570 Cypress Semiconductor Corp. 
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            9 Hub
  bDeviceSubClass         0 Unused
  bDeviceProtocol         1 Single TT
  bMaxPacketSize0        64
  idVendor           0x04b4 Cypress Semiconductor Corp.
  idProduct          0x6570 
  bcdDevice           32.99
  iManufacturer           0 
  iProduct                1 USB2.0 Hub
  iSerial                 0 
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           25
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          0 
    bmAttributes         0xe0
      Self Powered
      Remote Wakeup
    MaxPower              100mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           1
      bInterfaceClass         9 Hub
      bInterfaceSubClass      0 Unused
      bInterfaceProtocol      0 Full speed (or root) hub
      iInterface              0 
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0001  1x 1 bytes
        bInterval              12
Hub Descriptor:
  bLength               9
  bDescriptorType      41
  nNbrPorts             4
  wHubCharacteristic 0x00e9
    Per-port power switching
    Per-port overcurrent protection
    TT think time 32 FS bits
    Port indicators
  bPwrOn2PwrGood       50 * 2 milli seconds
  bHubContrCurrent    100 milli Ampere
  DeviceRemovable    0x00
  PortPwrCtrlMask    0xff
 Hub Port Status:
   Port 1: 0000.0100 power
   Port 2: 0000.0100 power
   Port 3: 0000.0100 power
   Port 4: 0000.0503 highspeed power enable connect
Device Qualifier (for other device speed):
  bLength                10
  bDescriptorType         6
  bcdUSB               2.00
  bDeviceClass            9 Hub
  bDeviceSubClass         0 Unused
  bDeviceProtocol         0 Full speed (or root) hub
  bMaxPacketSize0        64
  bNumConfigurations      1
Device Status:     0x0000
  (Bus Powered)

imp

21 Dec 2012, 14:03

Oh, and my PCBs are bought through hackvana, his website is http://www.hackvana.com/store/ or you can catch him in freenode in #hackvana (hackvana is his nick there too).

SmallFry

21 Dec 2012, 17:36

Can we buy PCB's or are you waiting till you have all the bugs ironed out?

imp

22 Dec 2012, 14:57

Guess you must wait, a bunch of friends are also waiting to be beta testers :).
Device Status: 0x0001
Self Powered

User avatar
Half-Saint

23 Dec 2012, 00:00

Great!

I wish there was an integrated SD card reader tho.. I know, you can't please everybody ;)

imp

23 Dec 2012, 01:35

Half-Saint wrote:I wish there was an integrated SD card reader tho.. I know, you can't please everybody ;)
For storing/loading layouts and macros or only connected to the pc and not the controller(s)?
You can use the internal USB port to connect it (if you got already one).
The second atmega32u4 got all pins on headers, so it should be easy to connect one :).
I still got the wish to generate statistics (not dumping complete strings like a keylogger, just something up to tri-grams and their frequency) about the keyboard usage directly inside the keyboard - this should give some real personalized input for layout optimizer. This would be my use-case for an internal SD card.

Got one complete board now, need to make some holes inside the case now :).

Things to optimize:
  • - placement for reset switches (maybe on the bottom side, just drill a hole),
    - maybe a dip switch to select layouts,
    - more constant current allowed from external input (right now it's 1A) - so you can put your raspberry pi into your keyboard instead of the numpad (shadowrun like deck :ugeek:),
    - switch to select connection of the whole hub to the pi / pc,
    - some more crazy ideas :D

imp

12 Jan 2013, 00:53

Heyho,
the USB hubs caused some trouble... The example schematic from Cypress had all the status leds I've connected too. After reporting random numbers of ports each time I called lsusb... The datasheet mentioned "pin strapping pin foo and bar might enable proprietary firmware functions" - removing all the status leds fixed the problem :).
Speed testing the hub with an usbstick ended by 32Mbyte/s on my laptop (34 while connecting the stick directly). Still want to take a look at the eye diagram.

For the USB port placement, I'm not very happy with it for laptop use (i.e. putting the board on the laptop keyboard). The upstream port is right in the middle of my screen and the two external ports face the same problem. Any suggestions on this for a second iteration?
One fix would be skipping the USB-B jack and to solder the cable direct into it's place and fixating it with a zip-tie (and then using the original exit in the case). Also the same can be done with the two external ones, placing them on the side of the keyboard using the same way. But this causes the same problem that some Das Keyboard users got, cable / usbstick over the mousepad. Vertical ports are might be an option, but then again, you'll get cables / sticks infront of your screen (if this option is possible at all due the internal connection to the matrix - guess I have to make an cutout to get a closer look at it in the assembled state)...

Got my grabbags from ne0phyte today and replaced nearly all my caps, typing on a flat profile now :D.
new keycaps \o/
new keycaps \o/
flat-caps-small.jpg (456.45 KiB) Viewed 10288 times
Sadly I've got no 1.75x keys in that profile nor 1.25x :(.

User avatar
Jmneuv

18 Feb 2013, 21:37

Since i own a freshly cleaned 1800 i'm very excited about your controller project.

About the placement of the usb-ports:
Hmm the 1800 has some very nice flat surfaces at the rear face, perfect for openings. You just shouldn't place the keyboard onto your laptop :P
How about still at the rear, but vertical and pointed away in a 45° angle?
Would make it somewhat harder to hit the ports but could be a compromise.

imp

26 Feb 2013, 22:27

Jmneuv wrote:Since i own a freshly cleaned 1800 i'm very excited about your controller project.

About the placement of the usb-ports:
Hmm the 1800 has some very nice flat surfaces at the rear face, perfect for openings. You just shouldn't place the keyboard onto your laptop :P
That's where there all the openings are right now :P.
Here is the long promised image from the openings:
USB-ports\power socket
USB-ports\power socket
100_8181.JPG (501.88 KiB) Viewed 10012 times
Jmneuv wrote:How about still at the rear, but vertical and pointed away in a 45° angle?
Would make it somewhat harder to hit the ports but could be a compromise.
Still not better for my laptop usage :D. Guess I'll have to accept this for now (anyway, the option to move the ports around and solder wires onto the pcb still exists).
For some closeups on the modded case, visit the ABS Sludge thread: http://deskthority.net/workshop-f7/abs- ... ml#p101366 (even if the case material is SB and not ABS, works the same way :)).

Post Reply

Return to “Workshop”