Jump to content
Thomot512

Linux drivers

Recommended Posts

Whatever you write into the internal memory of the mouse should work on Linux. I have tested this on a couple of Linux computers.

Unfortunately the configuration software (confusingly named "driver) is not available so you have to do all the configuration on another computer.

Share this post


Link to post
Share on other sites

Are there any specifications available for communication protocol between a computer and Swiftpoint Z mouse? I'm going to FOSDEM next weekend and can meet with guys who develop libratbag, a framework for configuring a mouse in Linux. These guys will have a presentation at FOSDEM and they are open to adding support for new devices. All is needed for that is specification.

Share this post


Link to post
Share on other sites

I just use software to capture the data transfer between driver and Z , it seem that The driver trans whole config file as some sort of codec every time, and only change the active profile index if it was changed  in the driver .

Share this post


Link to post
Share on other sites

I've met with libratbag developer after his presentation at FOSEM (video of this presentation will be available in a few days at that link), and we decided to start reverse engineering protocol of Z mouse configuration.

 

@PureLIN: Could you please share your capture files (along with description what you were doing during the capture)? Feel free to join reverse engineering efforts.

@Bryce: Could you please publish protocol description? Looks like configuration protocol is not very difficult to reverse engineer, but by publishing its specification, you can save us significant amount of work and earn good reputation for your company as opensource-friendly (think about more sales).

But it would be even better is you publish source code of mouse's firmware: it will allow our community to develop new features (like mouse lift detection) that you have no resources to work on and earn even better reputation among developer community (and this will translate to much more sales).

Share this post


Link to post
Share on other sites

@Oleg Girko Sorry for not getting back to you sooner. Unfortunately I can't help with this directly, but I have brought your requests to the rest of the team to see how we can assist with this effort.

I can't say for sure yet what this will entail; releasing the USB protocol info is a possibility. However I think it's unlikely that we will open source the firmware itself at this time.

Share this post


Link to post
Share on other sites

I'd love to at least see the protocol released. I could think of a lot of things that could be done with that alone, such as Node-RED support.

Share this post


Link to post
Share on other sites

@Oleg Girko If you (or anyone else) are still interested in creating Linux software for the Z,  please find the specification for the Z's raw sensor events below.

This should give you all the info you need to enable the raw outputs for all of the Z's inputs (they are disabled by default), and show you how to interpret that output. 

If you have any questions on the specifics they're likely to go over my head. But I can try to pass a few on to our devs if necessary. 

Z Raw Sensor Events Specification.pdf

  • Like 2

Share this post


Link to post
Share on other sites
Posted (edited)

I would be interested by switching profiles automatically depending on the active window (it would be for gnome, X11 only). Would it be possible to disclose information on how to alter the current profile of the Z over USB HID?

Edited by Aurélien

Share this post


Link to post
Share on other sites

Having no Windows but only Linux, I'd be very interested in a configuration program runnable on linux. If it would work, I am finally able to buy the Swiftpoint Z.

Share this post


Link to post
Share on other sites

@Bryce Hi Bryce!

I took a look at the document that you posted and it was useful for reading from the mouses outputs, but unfortunately the core functionality of the mouse is the configuration of the button and mapping/macros such.  Would it be possible to get more details about the communication protocol the mouse uses? It'd be nice to be able to at least be able to reconfigure the keybindings from Linux. Though I'd eventually also like to look at implementing something similar to the application based profile switching too. 

Share this post


Link to post
Share on other sites

@Aurélien @jvreeland

Unfortunately in order to allow you to tap into this functionality of the Z we would need to expose a lot more of the internal workings of its firmware. Which is something we want to avoid, as the firmware represents a significant portion of our IP, and investment in R&D for the Z.

So publishing the HID spec was our compromise to enable the Linux community to make software for the Z (or integrate it with existing software), independent of the firmware.

The HID spec should allow you to achieve most of the functionality we have in our software (and of course add new features). The software would just need to be setup in a "dumb" mouse "smart" driver type scenario. As apposed the the "smart" mouse, (mostly) "dumb" driver we use.

I'm sorry I couldn't provide more help, but hope you are still able to get something useful from the info we have provided. 

Share this post


Link to post
Share on other sites
Posted (edited)

Hi @Bryce!

 

Thanks for the response and I'm sorry for taking so long to respond myself, and dragging this out further but I would like to take the chance to make the argument in favor of Open Sourcing the firmware which seems to be where the IP issues would come in.  It seems it's been requested but not a lot of people have explained what it would be or why they want it.

I think to start with I'll explain my understanding.  It seem that it'd be fine to give us the protocol if it didn't expose information about the firmware, which would expose sensitive IP.

I'm biased towards Free Software so maybe this is me assuming what I'd like but seems to me it would be a big deal to open source the Driver if it didn't have information about the USB protocol.  Even though it took a lot of time and resources to make no one paid for the driver, it's unlikely to move to a subscription model, more people having the driver than bought the mouse isn't a problem and assuming you open sourced it with the GPL License (my preference were I choosing) anyone who forks it would be required to provide the source, including modifications to customers when requested so you'd be able to get the modifications and improvements other companies or the community make to the driver. So it doesn't cost anything and there might even be room for gains.

I'd argue the same is true for open sourcing the firmware.  To start with I think that anyone who could gain enough information to cause IP issues from the USB protocol could probably dump the firmware or monitor the USB hub and reverse the protocol.  Even if they did get info about the protocol, or the firmware itself and ripped a mouse open to reproduce the hardware too, I imagine it'd take quite a long time and resources to design, fabricate, assemble market and ship a product even after all that something with a feature set identical or substantially similar to the Swiftpoint Z seems like it would stand out.  I don't know too much about hardware IP but I also imagine there's a number of patent and economic protections to stop people directly or too closely ripping off existing products.   That being said if you GPL License the firmware it may seem like you're practically asking people to rip off your design.  That could be a worry but the firmware is probably fairly specific to the hardware, and they still need to design, build, market and ship that hardware.  Chances are that they'll have to abstract away the hardware or modify it to use their specific hardware. So they saved some time and resources in the development but they're required in the terms of the GPL to release the changes to customers on request. So you can take advantage of those changes (hopefully improvements) and reduce your development burden in the future. That being said the majority of the time when stuff like this is opened it just make a bunch of enthusiasts on the internet happy because they can change their mouse firmware and know it'll still work even if swiftpoint drops support at some point.

All that being said to argue there's probably no downside and potentially an upside, I'd personally like the firmware open sourced so that I can write my own linux client and program my own macros or make my own image to display on the screen or my own color patterns, maybe use the color to tell me if I have waiting email who knows.  All things that I would release back were it open sourced and also might not be a priority for swiftpoint devs.

I'm definitely on the side of open sourcing all the things but it seemed people asked for open drivers but didn't really make the case for it.  There's a bunch of different licenses with different rules about copying, integration and special commercial clauses too. It might seem weird to give away something a lot of time and resources were spent on but I think it's worth pointing out that you're already giving it away for free, anyone can download the driver and the firmware, it just doesn't benefit them without the mouse. Throwing the source up on github doesn't benefit anyone who doesn't have a compatible mouse, and if they did have one, you give the software away on your website anyway.

 

Anywho thanks for reading I appreciate it and I really like the Z and the improvements to the driver have been great.

Edited by jvreeland
  • Like 1

Share this post


Link to post
Share on other sites

I've come a bit late to this party but I have a an issue that means I have to remove the Z to play some games which kind of goes against the whole idea.

 

I run Linux and have Steam installed.  In Metro 2033 and Last Light (and maybe others) the Z gets detected a controller (even with joystick off) and you just spin around and look at the ceiling. I have to switch back to the old Logitech G to play these.

 

At least the option to disable this in the firmware would be nice or better still a full driver to take advantage of all the goodies.

Share this post


Link to post
Share on other sites

@Nick

I'm not sure how you do this on Linux but in Windows you can go into device Manager and disable the Z's controller interface.

If there is no equivalent to this in Linux, there is another way you can temporarily disable the controller interface.

As you plug in your Z just hold down the "Top Thumb Button" and the "Left Trigger (Push)". This will disable the Z Controller interface until the Z looses power.

  • Like 1

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...