Page 1 of 2
[PS4] Raspberry Pi + Teensy 2.0 cant get it to work.
Posted: Fri Sep 30, 2016 8:05 pm
by dmp
Hi all,
I followed
this great tutorial on for a RPI build. However I cant seem to get it to work.
When I try to active gimx with
Code: Select all
gimx -p /dev/ttyUSB0 -c LogitechDrivingForcePro_G29.xml --status
(I use this instead of the autostart for troubleshooting)
The output is as followed:
controller #1: option -p with value `/dev/ttyUSB0'
now reading arguments for controller #2
global option -c with value `LogitechDrivingForcePro_G29.xml'
status flag is set
native mode is already enabled for HID device 01:01:03 (PID=c298)
src/linux/async.c:94 open failed with error: No such file or directory
Check the wiring (maybe you swapped Rx and Tx?).
No controller detected.
adapter_detect failed
On the RPI usb ports I have connected a Logitech Driving Force Pro (with a profile I made in ubuntu) and the DS4 controller.
The RPI is powered by a dedicated power source (not the PS4).
I checked and measured the wires between the Pi and the Teensy and all those connections are all good. And here are two pictures of the wiring:
I have 'atmega32u4.hex' (EMUG29PS4) loaded on the Teensy. On the Raspberry I am running RASPBIAN JESSIE LITE and used
Code: Select all
sudo apt-get update && sudo apt-get upgrade
sudo rpi-update 771a503cfc2a1130e2df2a4ddfc45ffa0f592b3f
to ensure I got the latest updates and a working kernel.
I am running out of idea's (other than buying a T300). So any advice would be most welcome.
Re: [PS4] Raspberry Pi + Teensy 2.0 cant get it to work.
Posted: Fri Sep 30, 2016 8:36 pm
by Matlo
Hi,
Replace ttyUSB0 with ttyACM0.
Re: [PS4] Raspberry Pi + Teensy 2.0 cant get it to work.
Posted: Sat Oct 01, 2016 3:01 pm
by dmp
Still no luck
Code: Select all
pi@raspberrypi:~ $ gimx -p /dev/ttyACM0 -c LogitechDrivingForcePro_G29.xml --status
controller #1: option -p with value `/dev/ttyACM0'
now reading arguments for controller #2
global option -c with value `LogitechDrivingForcePro_G29.xml'
status flag is set
native mode command sent to HID device 01:01:02 (PID=c294)
native mode enabled for HID device 01:01:02 (PID=c298)
src/linux/async.c:94 open failed with error: No such file or directory
Check the wiring (maybe you swapped Rx and Tx?).
No controller detected.
adapter_detect failed
So now I removed all the wiring and connected the teensy to my laptop (through a CP2102) and started GIMX on my laptop. And all worked, so the teensy is working fine.
After this i re-soldered everything using new wires and resistors (to eliminate any cable damage or faulty resistors) but it is still not working
Now I am going to try fresh install of raspbian...
Re: [PS4] Raspberry Pi + Teensy 2.0 cant get it to work.
Posted: Sun Oct 02, 2016 9:28 am
by Matlo
Sorry, it's ttyAMA0, not ttyACM0.
Re: [PS4] Raspberry Pi + Teensy 2.0 cant get it to work.
Posted: Mon Oct 03, 2016 11:19 pm
by dmp
Still not working. I tried reinstalling without any success.
Here is the log file:
Code: Select all
global option -l with value `log.txt'
controller #1: option -p with value `/dev/ttyAMA0'
now reading arguments for controller #2
global option -c with value `LogitechDrivingForcePro_G29.xml'
status flag is set
GIMX 5.9 ARMv6
Raspbian GNU/Linux 8.0 (jessie)
Linux 4.1.21+ #873 Mon Apr 11 18:00:37 BST 2016 unknown
Bus 001 Device 005: ID 054c:05c4 Sony Corp.
Bus 001 Device 006: ID 046d:c298 Logitech, Inc. Driving Force Pro
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. SMSC9512/9514 Fast$
Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp. LAN9500 Ethernet 1$
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
/: Bus 01.Port 1: Dev 1, Class=root_hub, Driver=dwc_otg/1p, 480M
|__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/3p, 480M
|__ Port 1: Dev 3, If 0, Class=Vendor Specific Class, Driver=smsc95xx, $
|__ Port 2: Dev 6, If 0, Class=Human Interface Device, Driver=usbhid, 1$
|__ Port 3: Dev 5, If 0, Class=Human Interface Device, Driver=usbhid, 1$
native mode is already enabled for HID device 01:01:02 (PID=c298)
can't read packet header
No controller detected.
adapter_detect failed
Also here is my config file (so you can add it to the db for linux)
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<root>
<controller id="1" dpi="0" type="G29 PS4">
<configuration id="1">
<trigger type="" id="" name="" button_id="" switch_back="no" delay="0"/>
<mouse_options_list/>
<intensity_list/>
<button_map>
<button id="abs_axis_3" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="14"/>
</button>
<button id="abs_axis_6" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="17"/>
</button>
<button id="abs_axis_4" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="15"/>
</button>
<button id="abs_axis_5" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="16"/>
</button>
<button id="abs_axis_2" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="9"/>
</button>
<button id="abs_axis_1" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="8"/>
</button>
<button id="abs_axis_13" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="7"/>
</button>
<button id="abs_axis_14" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="6"/>
</button>
<button id="abs_axis_11" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="5"/>
</button>
<button id="abs_axis_12" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="4"/>
</button>
<button id="abs_axis_7" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="3"/>
</button>
<button id="abs_axis_8" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="2"/>
</button>
<button id="abs_axis_9" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="0"/>
</button>
<button id="abs_axis_10" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="1"/>
</button>
<button id="abs_axis_15" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="11"/>
</button>
<button id="abs_axis_16" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="10"/>
</button>
<button id="abs_axis_12" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="12"/>
</button>
<button id="abs_axis_11" label="">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="button" id="13"/>
</button>
<button id="abs_axis_10" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="0"/>
</button>
<button id="abs_axis_9" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="1"/>
</button>
<button id="abs_axis_8" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="2"/>
</button>
<button id="abs_axis_7" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="3"/>
</button>
<button id="abs_axis_11" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="4"/>
</button>
<button id="abs_axis_12" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="5"/>
</button>
<button id="abs_axis_0" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="8"/>
</button>
<button id="abs_axis_1" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="9"/>
</button>
<button id="abs_axis_15" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="10"/>
</button>
<button id="abs_axis_16" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="11"/>
</button>
<button id="abs_axis_2" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="12"/>
</button>
<button id="abs_axis_3" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="14"/>
</button>
<button id="abs_axis_4" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="15"/>
</button>
<button id="abs_axis_5" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="16"/>
</button>
<button id="abs_axis_6" label="">
<device type="joystick" id="0" name="Sony Computer Entertainment Wireless Controller"/>
<event type="button" id="17"/>
</button>
</button_map>
<axis_map>
<axis id="rel_axis_0" label="wheel">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="axis" id="0" dead_zone="0" multiplier="0.0039" exponent="1.00" shape=""/>
</axis>
<axis id="abs_axis_17" label="gas">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="axis" id="1" dead_zone="0" multiplier="0.008" exponent="1.00" shape=""/>
</axis>
<axis id="abs_axis_18" label="brake">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="axis" id="2" dead_zone="0" multiplier="0.008" exponent="1.00" shape=""/>
</axis>
</axis_map>
<joystick_corrections_list>
<correction low_value="32767" low_coef="-8192" high_value="0" high_coef="0">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="axis" id="1"/>
</correction>
<correction low_value="32767" low_coef="-8192" high_value="0" high_coef="0">
<device type="joystick" id="0" name="Logitech Logitech Driving Force Pro"/>
<event type="axis" id="2"/>
</correction>
</joystick_corrections_list>
</configuration>
</controller>
</root>
Re: [PS4] Raspberry Pi + Teensy 2.0 cant get it to work.
Posted: Tue Oct 04, 2016 7:55 am
by Matlo
Did you power up the PS4 before starting GIMX?
Re: [PS4] Raspberry Pi + Teensy 2.0 cant get it to work.
Posted: Tue Oct 04, 2016 10:59 am
by dmp
Affirm. I first power up the RPI. Than the PS4 and then try to start gimx.
Re: [PS4] Raspberry Pi + Teensy 2.0 cant get it to work.
Posted: Wed Oct 05, 2016 2:37 pm
by Matlo
Do you have a multimeter? If yes, check the voltage on RPI/RXD. It should be about 3V.
Re: [PS4] Raspberry Pi + Teensy 2.0 cant get it to work.
Posted: Wed Oct 05, 2016 3:55 pm
by dmp
Here are the measurements:
Pi | Teensy | Voltage
+----+--------+--------
| 10 | D3 | ~2V
| 10 | GND | ~3V
Re: [PS4] Raspberry Pi + Teensy 2.0 cant get it to work.
Posted: Thu Oct 06, 2016 8:40 am
by Matlo
The voltages look good.
Maybe there is too much distortion due to the voltage divider.
An alternative is to use a logic level converter.