From: Marek Czerski <ma.czerski@gmail.com>
To: linux-bluetooth@vger.kernel.org
Cc: Marek Czerski <ma.czerski@gmail.com>
Subject: [PATCH BlueZ] sixaxis: DS4: use 0x12 cmd to get device bdaddr
Date: Sat, 4 Apr 2026 14:30:42 +0200 [thread overview]
Message-ID: <20260404123042.3049158-1-ma.czerski@gmail.com> (raw)
This change is required for Esperanza EGG109k ps controller clone.
EGG109k looks like PS3 controller but presents itself to the system
as PS4 controller. It does not respond to 0x81 command.
Command 0x12 contains both the device mac address as well as
configured host mac address, so it can be used to query
both. Kernel driver also uses 0x12 command for that.
---
plugins/sixaxis.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/plugins/sixaxis.c b/plugins/sixaxis.c
index 27bc09815..8e212ee71 100644
--- a/plugins/sixaxis.c
+++ b/plugins/sixaxis.c
@@ -111,12 +111,12 @@ static int sixaxis_get_device_bdaddr(int fd, bdaddr_t *bdaddr)
static int ds4_get_device_bdaddr(int fd, bdaddr_t *bdaddr)
{
- uint8_t buf[7];
+ uint8_t buf[16];
int ret;
memset(buf, 0, sizeof(buf));
- buf[0] = 0x81;
+ buf[0] = 0x12;
ret = ioctl(fd, HIDIOCGFEATURE(sizeof(buf)), buf);
if (ret < 0) {
--
2.43.0
next reply other threads:[~2026-04-04 12:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-04 12:30 Marek Czerski [this message]
2026-04-04 13:25 ` [BlueZ] sixaxis: DS4: use 0x12 cmd to get device bdaddr bluez.test.bot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260404123042.3049158-1-ma.czerski@gmail.com \
--to=ma.czerski@gmail.com \
--cc=linux-bluetooth@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox