A DIY-GIMX Help - adapter not enumerating?

Need help? Ask here and someone will help
Forbidden Era
Posts: 44
Joined: Thu Dec 27, 2018 6:21 am

A DIY-GIMX Help - adapter not enumerating?

Post by Forbidden Era »

Hey guys,

New to GIMX..but not new to software development (20+ yrs experience) or micro stuff..

scroll down for tl;dr: - but some history and background first:

I got a atmega32u4-based breakout board (feather) and an extra UART (already had a bunch, but, they're all cheap and half didn't work for another project, and as they're all "cables" basically, I don't even know which might be 3v3 of 5v) ..

The FTDI I got is indeed 3v3 and so was the 'feather' but I then read the whole thing is that GIMX runs the atmega at 16mhz which then drives 5v - okay - fine, I got it all mounted on a breadboard anyway - toss in a quick v/div on the atmega out->ftdi in, solves, right? done. probably better ways but, this should work for this app, no? I -> 2k2 / O / 3k3 -> G IIRC

Anyway... I finally just got around to downloading the stuff to flash the atmega (avrdude, well, arduino dev package or whatever that comes with avrdude).. and was able to hit the button on the feather to init the bootloader and flash the firmware.

I've tried both emug29ps4 and emups4, my goal being to add a handbrake (half a mic stand taped/zip tied to an old Thursmaster Ferrari GT Experience Pedal box, (works great on my Mac Pro for Grid Autosport and Dirt Rally especially, need to get bootcamp going but don't have an EFI card so that's a b*..) so I can have a handbrake in some games on the PS4 (ones that allow assigning multiple controllers likely, as it seems there is limitations in full g29 support?)

I do have a G29/pedals/h-shifter, my plan is to connect that directly to the PS4. I have two DS4 controllers available, so auth stuff shouldn't be too tricky for me.

Essentially, I want to emulate a second G29 or even a DS4 simply to map the T FGT wheel's brake to handbrake in games. On games that don't allow dual control maps, it would be nice to pipe my g29 thru this too, but ..

*goes back and reads pages*

Okay, so it seems like the issue is on Linux (and I had planned on using my spare Pi to host this diy-gimx):
Force feedback only works for Logitech wheels older than the G29/G920, and for the G29/G920 starting from Linux kernel 4.6. Auto-adjustment of the wheel range is only supported for Logitech wheels older than the G29/G920, and rpm led control is only supported for the G27.
So, this should only affect me in games where I would have to have everything running thru the gimx (games that don't support mapping multiple controllers) but otherwise the g29 will be directly connected to the ps4 so doesn't matter..

And that's also only if I'm using the PI to host it, I could use my laptop instead (I have an mbp with an xp vm, was good for flashing but doesn't seem to want to run gimx {msvc dll err} even with msvc redist, should try a win7 vm at least prob, also have a win10 laptop otherwise if needed) but wanted to use my Pi.

Most games I want to use likely allow dual controllers. Unfortunately, one big one doesn't at this time, from what I can tell - Assetto Corsa.. (though, really, I should get bootcamp working on my Mac Pro and probably have better luck with a lot of these games on PC)

BUT I got the PS4 to not have to F* around to play a game..and here I am trying to build a gimx for it ;)

At least the games/races where I don't need a handbrake are great..! but yeah...the g29 should have come with a h/b..imho..but..I should prob also have a fanatec..but f* $$$

tl;dr:

anyway.. once I've flashed this feather (with either the emups4 or emug29ps4 firmrwares) with avrdude, the USB is not enumerating on my laptop at all - I can't even pipe it to my VM letalone see it recognized on the mac - is this normal? (I've never plugged a DS4 or g29 in ps4 mode to my computers) I wouldn't think so - a usb device should always enumerate, no?

haven't bothered trying to plug it in the ps4 yet, the gimx software won't run on my xp vm either so.. but I mean, it should still show up after flashing, right? as either a ds4 or g29? dep on fw?

sorry if I'm missing something ( like does it need GIMX to turn it on over the UART adapter first? ) but ya the docs could use work, I suppose if I just bought a pre-made one I'd already be up and running but.. what's the fun in that?

thanks for info ! cheers
User avatar
GoDlike
Posts: 1318
Joined: Thu Apr 28, 2016 12:47 pm
Location: Poland

Re: A DIY-GIMX Help - adapter not enumerating?

Post by GoDlike »

GIMX won't work on Windows XP, it's too old.
GIMX in any VM also won't work correctly, it may work but the lag added will make it useless.
Unless you have drivers installed, UART connected to PC will show as "Unknown Device" in device manager.

After flashing firmware the adapter is masking itself as emulated device after some time, maybe that's why you can't enumerate it. Use gimx-loader to flash the firmware, it has support for already flashed firmwe by asking you to replug the cable and detects chip before it masks itself.

Chip has to be Atmega32U4, no other chips are supported.
By FTDI you mean FT232R?
My hardware: PS3 Slim CFW 4.80 | PS4 Pro 500 Million LE | PS5 | Xbox Series X
Steam: Godlike_RU | PSN: GoDlike_RU | XBL: GoDlike
Forbidden Era
Posts: 44
Joined: Thu Dec 27, 2018 6:21 am

Re: A DIY-GIMX Help - adapter not enumerating?

Post by Forbidden Era »

Pretty sure its an r, yeah

I see nothing enumerate in osx host or in windows guest once it flashed. I can still push the button on the breakout board for the micro to init bootloader and flash it np.

Specs of the board I got:
Measures 2.0" x 0.9" x 0.28" (51mm x 23mm x 8mm) without headers soldered in
Light as a (large?) feather - 4.8 grams
ATmega32u4 @ 8MHz with 3.3V logic/power
3.3V regulator with 500mA peak current output
USB native support, comes with USB bootloader and serial port debugging
You also get tons of pins - 20 GPIO pins
Hardware Serial, hardware I2C, hardware SPI support
7 x PWM pins
10 x analog inputs (one is used to measure the battery voltage)
Built in 100mA lipoly charger with charging status indicator LED
Pin #13 red LED for general purpose blinking
Power/enable pin
4 mounting holes
Reset button

..

The only concern I really had was 3.3v but I assume the firmware would run it at 5v/16mhz as I have read? My ttl is 3v too but I have a voltage divider wired in as I said, shouldnt be an issue..

I do a fair bit of other toying with arduinos/micros/pi/programmers etc and have a fair bit of stuff kicking around

Does the micro need to be initialized by gimx at all before it'll work? I havent yet bothered trying to hook it to the ps4.

Was the only micro with that chip at the shop that day but it is def the right chip so..it programs fine..

Any info on debugging? Does it output anything over the serial pins I could watch? I suppose gimx talks to it thru the uart anyway, maybe I should pop gimx up and see if it can see the adapter on that side?

I have a win10 laptop i can use for now..eventually when its all working I think I will want to use the pi unless there is a game where I need to connect my g29 to the gimx instead of directly.

I just got a psvr today - definitely need gimx working now..dirt rally with g29 and custom handbrake and psvr..yes please.

Any/all help appreciated. I can grab different hw if needed but id like to get what I have working as it should work
User avatar
Matlo
Posts: 5768
Joined: Wed Jul 06, 2011 7:01 am
Location: France
Contact:

Re: A DIY-GIMX Help - adapter not enumerating?

Post by Matlo »

Firmware will not work at 3.3V.
GIMX creator
Forbidden Era
Posts: 44
Joined: Thu Dec 27, 2018 6:21 am

Re: A DIY-GIMX Help - adapter not enumerating?

Post by Forbidden Era »

But I'm not asking it to run at 3.3v..?

Does the firmware not decide whether the chip runs at 8mhz/3.3 or 16mhz/5v? or is it something on the breakout board? I thought I read that it depends on fw but perhaps I misread?

The FTDI board I got is indeed a R. I have another 5v-capable (at least, it works with my car's ECU just fine which is 5v) FTDI that I tried tonight and it was unable to communicate either. Both will talk loopback just fine as well.

I am able to reset the board into bootloader and reflash it with any of the firmwares via avrdude no problem.

After that, I am not sure if the USB side is supposed to enumerate/have anything be visible immediately or not or whether the GIMX software has to perform some init or something first? Either way, the GIMX software is not able to get any IO from the board over it's IO.

I did notice, stupidly, until now, I was actually using the wrong pins on my 32u4 board for IO, I soldered on some pins near where it said rx/tx/gnd and was using those, looked closer tonight and realized that those are actually just pins on the ground plane and the next row is where I should've been connecting to..

Moved the connection over, but still don't get a connection at all thru the GIMX app..tried swapping rx/tx of course..latency at 1ms..tried 2 diff FTDI adapters.

I am running on a Windows laptop now, FTDI drivers are installed and functional, GIMX times out trying to talk to the chip..

tried a few different firmwares including emups4, emups3, emug27pc..

I eventually have a Pi that I will run the software on once it is functional, but I figured I'd start on the PC..

Any suggestions now? There has to be a way I can make this board work for this..after all, it's basically a 32u4 breakout board. Not much else there except a battery input, 3v3 voltage regulator (which I believe can be disabled), debug LED and a bootloader reset button..and a few resistors/caps/diodes/etc
Forbidden Era
Posts: 44
Joined: Thu Dec 27, 2018 6:21 am

Re: A DIY-GIMX Help - adapter not enumerating?

Post by Forbidden Era »

if it's a matter of modding my board to run at 5v/16mhz or something, I can definitely look into that...

perhaps i should scan the datasheet for this chippy
User avatar
Matlo
Posts: 5768
Joined: Wed Jul 06, 2011 7:01 am
Location: France
Contact:

Re: A DIY-GIMX Help - adapter not enumerating?

Post by Matlo »

The firmware sets the clock to 16MHz. From datasheet this requires power supply to be 5V. From the specs you provided your board has a 3.3V power supply. This is not going to work and there is no way to change power supply voltage without hardware modification.
GIMX creator
Forbidden Era
Posts: 44
Joined: Thu Dec 27, 2018 6:21 am

Re: A DIY-GIMX Help - adapter not enumerating?

Post by Forbidden Era »

Matlo wrote: Fri Feb 01, 2019 12:46 pm The firmware sets the clock to 16MHz. From datasheet this requires power supply to be 5V. From the specs you provided your board has a 3.3V power supply. This is not going to work and there is no way to change power supply voltage without hardware modification.
Marlo, thank you - that was the exact answer I was looking for. Hardware modification is no issue, while I understand most may not want to go down that route, I am a developer/engineer/tinkerer..I could have just ordered a pre-made one, but I saw it was just a micro and UART and some software so why not try and build it? I have no other current use for this micro, got it just for this. If I can't get it working, I'll have to find a use..but I'd bet even for anything else I'd want 5v..too bad this board was designed for 3v3..

Most info I can find is more about using a 3v3 USB UART with a 5v micro...not really my issue..

I'll go take a look at the boards schematic and see what needs done.
Last edited by Forbidden Era on Sat Feb 02, 2019 11:13 pm, edited 2 times in total.
Forbidden Era
Posts: 44
Joined: Thu Dec 27, 2018 6:21 am

Re: A DIY-GIMX Help - adapter not enumerating?

Post by Forbidden Era »

There is an enable pin for the 3v3 regulator. Whether this bypasses it to the micro or just disables the 3ve pin, I don't know yet but would be nice if I could just pull down a pin and go..

Otherwise, I was thinking to just bypass the regulator. Power comes from 5v usb anyway. Couple of nicks and a bodge around the reg and I should be gaming in no time.

I really want my handbrake on ps4, lol..
Forbidden Era
Posts: 44
Joined: Thu Dec 27, 2018 6:21 am

Re: A DIY-GIMX Help - adapter not enumerating?

Post by Forbidden Era »

Looks like the onboard reg is 3v3 only. Was hoping it might have been configurable :)

Just a bit apprehensive about using usb 5v direct.
Post Reply