I've started designing a mouse 2-3 times and every time I've given up after realizing there's no good source of mouse sensors. The world of DIY keyboards is so well trodden, but the first step to building your own mouse is always to buy a mouse and take it apart. I hope if we keep making our own, someone will catch on and start making sensors available to order, so we can finally have highly repairable, easily accessible, open source mice.
A modern mouse sensor is essentially just a low resolution camera. You can build your own sensor, but you'll need more advanced hardware to process the image like a rasberry pi zero.
There are cheap optical mice that have decent sensors though. Microsoft basic optical, for example. Or cm storm alcor, but that one isn’t made anymore.
I don't know that starting with a mouse is a bad notion. All the parts are there, all stiffly pre-mounted and working in harmony. That's not a bad kicking off point for a project. The issue is the driver, but I imagine there are open source templates that get you a long way.
I design pcb schematics and layouts for a job. We do have fab houses in the US, they just cost 10x more, not 2x more :) Also, you may want to consider doing the assembly yourself next time with a stencil if you don't want to wait the extra few days for each prototype board. I didn't have a reflow oven when I started out so I just used an NTC heating thermistor sandwiched into an aluminum plate that I bought for like 4 bucks. Nice job though, good for you for being brave enough to dive into pcb design starting with an entire custom microcontroller- that is some intimidating stuff!
My main worry with the local fab houses is turnaround time, and how many of them operate on a quote-only basis, or only on orders of several dozen or hundred boards or more. All very fair problems for a fab house to have, of course, but these chinese companies are offering such a faster and more accessible service for prototyping that it feels like they're eating the lunch, dinner, and midnight snacks, too, of the local ones. The PCBA JLCPCB orders cost more than it might sound from the general knowledge of them being cheap; being cheap is mostly just for the PCB itself, and assembly has a decent upcharge. It's still nowhere near as expensive as local fabs, but instead of being like, 10~15 dollars (after tax+shipping) for five boards, it was like 45~50. Thanks! I probably wouldn't have been able to do it if they didn't document the Pico's hardware design so well.
Oh yeah, that custom PCB stuff impressed me too; I'm a software dev working on similar things, but I'm just going to bodge together existing hardware. Huge props to @wareya on learning that PCB design stuff!
Same with Brazil, we do got some pretty high quality PCB manufacturers and assembly services, they just cost an arm and a leg. It's the same price to order from China with express shipping and pay the horrid Brazil taxes (think paying once for the service, and again the same amount OR MORE to the government), compared to buying here.
@@wareya It's impressive how the Chinese decided to cater to a market that looked like nobody else cared about. You shouldn't need to wait a few days for a specialist to tell you "Costs more than you would ever dare paying", if the pricing system is an objective evaluation to begin with for low quantities. The quick site quotes of these services are really handy, of course for weirder stuff you'll only get it through personal quote but they do provide what few care about trying.
@@Kalvinjj I totally agree, and on top of that, those companies have been pretty quickly expanding their capabilities into everything from sheet metal to CNC to even designing board housings, metal 3d printing, and crimping+wiring cable assemblies for you. It's like a dream come true for people who love electronics projects Also those import taxes suck! I'm glad the US government subsidizes all the shipping from China for me even though I know it's bad for our economy lol
@@Kalvinjj my favorite motherboard is the IBM Alaris Cougar, the world's fastest 386 motherboard (probably). It comes factory-standard with a big ugly yellow bodge wire on the top, proudly displayed next to the IBM sticker.
Here's an idea: Add features NO OTHER MOUSE HAS! Frame capture is a feature the mouse sensor designers thought was useful but all mouse manufacturers have said "meh" about. What it does allow is dust detection! Having a look at sensor image now and then and determining if some pixels are obscured and do not change with movement would allow driver to notify user to clean sensor! I'd love for my G602 to do that...
@@rasz I know. That is a silly use-case. Now with camera phones it is even worse. But, the image-array readout of sensors can be used by drivers to do much clever stuff. For example I designed a filament tracker for 3d printers that uses the readout function to determine the diameter of the filament for automatic calibration of volumetric flow instead of just linear feed. This was possible with a single sensor thanks to this readout function.
I have the most cursed keyboard which led me to make some debounce algorithms of my own. The reason I didn't do zero-latency is because it wouldn't be resistant to noise. Instead I chose to have a stabilization period (2ms) and a following lockout period where additional state changes would be ignored, but the first one still registered if it didn't already happen. A different algorithm was to count the states during the debounce time and choose that which occurred more frequently. Then.. only changing the state if a different state was present for at least 75% of the debounce time What felt like overkill was measuring the raw data of key presses over a time to know how long each one takes specifically to stabilize in value and doing a statistics-based approach based on the individual keys variance. I can't express enough how cursed this keyboard is for me to even consider having to go that far.. and it's still not working :( Anyhow, this is an awesome project. The future of anything is open source.
In theory you can do zero-latency for keyboard switches while still resisting noise, but only for the down-click. The up-click will always have added latency. Sounds like you're trying to get a dynamic debouncing algorithm working. I hope you can figure it out!
There is a similar sort of project I came up with right after this video. Taking a G305 and turning it into a Bluetooth mouse with better firmware and custom PCB to get rid of the AA Battery and replace it for a Li-Po battery and USB c recharge circuit.
When you did the "the sponsor of this.. haha joking" I was impressed to find out you're a small creator, this editing/quality is insane! Hope *the algorithm* (dun dun duuun) blesses you again! I'm gonna try to stick!
OMG YES! I was waiting for someone to do this. I could also have done it myself, but you know, getting up, pulling through even when road blocks occur... I applaude your engineering!
I watched this + the video you linked, I had never thought about mice before since I haven't had them fail, but now I feel an immense amount of respect for you for all the work you did, congrats!!!
I have a G305 and recently replaced it because the mouse wheel kept experiencing "bounce back" where it would actually scroll in reverse of the direction I was operating the wheel.
I wish I had a fix for that one, but AFAIK, for how scroll wheels work, it's kind of inevitable that it'll start to happen after long enough. There isn't anything you can do like the smart debouncing I do here. Just gotta hope the company didn't cheap out, and that you've got one that'll last.
All mice I’ve had get this issue sooner or later. My 5yo G305 still works perfectly but I did have to disassemble and clean it at one point, because LMB had stopped working properly and the scroll wheel was acting up too
@@deamooz9810 Yea. It might have been able to work again if I cleaned it but I did that once and it only helped for so long. I never had any other mice do that but I think this is the first one I stuck to for a really long time.
@@rasz They eventually fill up with gunk and start having one or two of their notches fail to scroll properly, because the part the light passes through is fully open to the air, unfortunately. Cleaning them and keeping them working for a long time is simpler than the mechanical/electrical ones, but they're not without their downsides.
Hi, amazing video! I love how you explain the bouncing and chatter problems. Extremely clear, on point and no bullcrap. About desoldering with an hot air station, that sure is optimal, but you can get away with a soldering iron, using flux and a larger tip that has more thermal inertia. That redesign of the pico layout to fit your project is amazing. It's truly the genius kind of mad stuff. You earned a new sub, and hope you get many, many more !
you are actually making me get into this stuff... i might try my hand at making PCBs as i always wanted to try making one. hell when this mouse breaks i might just attempt this project.
Based. An SPDT switch with NC and NO tied to V+ and GND respectively, with COM tied to a voltage divider feeding a Schmitt trigger, is a really reliable way to get debouncing done with no latency. A capacitor also works, but is probably worse for the switch. Instead of hot air, you could use a desoldering iron, they’re generally better for THTs. I just got a cheap one that’s a hollow soldering iron with a manual solder sucker built in, it works great but may struggle at ground planes. Surely with all those dead Logitech mice you’ve got some to salvage the sensors out of, no? Also the G Pro (replacement for the G303 IIRC) is meant to have long lasting switches.
The ground plane is the main problem, yeah. Depending on the mouse it can dissipate heat faster than the soldering iron is capable of safely supplying it (without melting the plastic of the IC package). My g203s use a Mercury sensor, which is poorly documented and a lot less common than the 3360. I would've preferred using it if it wasn't for that.
If all you want is that sensor off the board you can just use snips and chop it out. You can cut right through PCB. The best board salvage method is the wet dip though. You just hold the board over a pool of molten solder and pluck out whatever you want. I have a 5 pound solder pot I use for parts salvage.
Because of the curves on top you should print the final version with 0.1mm layer height and maybe even think about a 0.25mm nozzle. That will drastically reduce the stair stepping effect you get at the top. Also you can use a pi pico to run the printer with klipper instead of the default firmware and add an accelerometer to increase print speed and quality.
@@carlc.4714 would give you a better finish but it is still not that easy to do. It is way easier to just print with 0.05mm layer and a 0.25mm nozzle and wait for an eternity if you really need the quality.
Yeah, if they break, you can print new ones and slide them on, or print a bunch of spares ahead of time and use them. Just gotta unscrew the PCB and pull the broken ones off.
Very cool. I thought about doing the same thing and dropped the project when finding out they don't sell the sensor and I didn't want to buy a mouse just the destroy the sensor while resoldering. Also I like how you can see you improvement from basic self soldered board to custom PCB. Great progress in personal skills
Man, I was actually thinking of making mouse with pmw3360 myself last weeks and this video just popped out, great job! As for PCB prototyping, making own PCB's is definetly fastest and cheapest way if you'd want to make more projects, the only downside is that it requires more time. When you have all the stuff needed to make PCBs then making them basically costs nothing and you can get your PCB done the same day you finished the design. With photo-positive method 0.4mm trace is easily achievable and 0.2mm is also possible with some practice. I think you could get everything needed for 50-100$ depending on where you live (not including laser printer). Looking forward for next projects!
That's what the timed state latch is for! Even if they double click for like, a hundred milliseconds, you can still filter it out without adding any latency, as long as you've got a solution for chatter.
after searching the market 3-4 few years back, I found out that only steelseries that uses its own switches while all the others use types of the omrons. it still works, never failed yet, while omrons die after 2 to 6 months for me, or could be really electrical or static fault on my part. you might want to give a shot, if you want a mouse with brand :) btw you killed it.
Glad to have stumbled upon this. Have had a number of Logitech mice over the years, most recently having a G703's scroll wheel break on me. Been working on my own shell but needed to figure out the internals
I considered it, but it would basically just be the closed caption breakout. You can open it up with the "show transcript" button, I think. It's not divided into paragraphs like it should be, though.
@@wareya I read this blog or watched a video a while back where the youtuber uploaded the transcript to GPT or whatever and had it create timestamp + chapters titles for the video. Brilliant! Probably could restructure the transcript to a written version too? ¯\_(ツ)_/¯ anyway, great stuff as always
Dude, great work, great video and amazingly documented, insta-sub on my side. The neat thing about it is that it can easily be upgraded to add a mini fan to cool the hand, LEDs...
absolutly awesome video! i really liked the editing and the explenation. it was very clear, while i still have no idea whats going on (like a nile red video) keep up the good work!
Found your video on my feed today right after yesterday my G102 got this bounce problem 0:58 on one of the keys. Bought it in 2019, after 6 year it decided to only had that problem yesterday. The fact that this is open source tempted me to do this project but it'd be much, much, more expensive than buying new one here in my country, especially making the custom PCB and 3D printing. (damn cool video btw)
I had a G502 that worked extremely well for years after buying it used from a friend. When it finally died, I went to go replace it with a new G502. Every single part of it just felt so much cheaper. I'm still using that one, so it's lasted quite a while at least. But every so often it's just like "man this thing feels so cheap".
I believe the breakout boards probably have a bit of a chicken and egg problem, once demand is high enough they will likely be available much cheaper on aliexpress, ebay etc.
I also use a G203 and I also had to send it back for.repairs like, twice in the first year!! They make mouses with twigs and putty now apparently!! I am NOT capable of doing this, but it's good to know the tech is out there, great job!!
this video rocked!!! wish it was a little longer though, i had to rewatch some parts because of how fast you were talking, and i would love to hear some more specific details on the process of actually making it
I don't know about Asus' patent, but I know about switches in new mices on the market which are a) hotswappable, b) they are optical, so the bouncing on the contacts is no problem anymore... Almost all new Razer mices have them (and some other brands).
Absolutely amazing. Going to try and replicate this and drop some improvements in the mix. Thanks for all the upfront work and for making it open source, and I'll try to help push it along...
Then there's me, who learned soldering just to solder new switches for M1 and M2 for my G502 Hero. I used Japanese-made Omron switches specifically. Avoid the Chinese ones (regardless of brand), because the copper gets tarnished way too fast, usually within a year. You can clean/polish them if you are dextrous enough, though. That's what I did a couple times until I realised it would be far better to pick up a new skill and just solve the issue for good in one try. Needless to say, it worked flawlessly. The connectors are gigantic, anyway, so even a newbie can desolder them and replace them easily. I even bought a new and original outer shell for the mouse on Aliexpress (since no local sellers regardless of where I looked) and I basically own a brand-new mouse now. PS: Funny enough, I wonder why the M4, M5 and so on never had issues. Maybe it's less usage. Maybe it's different switch structure (or material?). Makes me curious, though. I only ever had issues with M1 and M2 switches.
If your solder beads up, like where you soldered your replacement resistors, it means the components to be soldered aren't hot enough. You need to continue heating the place with your iron and wait until the solder nicely flows over everything.
I'm bodging through-hole components onto tiny (0603) surface-mount pads and intentionally applying way too much solder so that thermal expansion/contraction is less likely to make them crack off. Having a round shape is normal in that case.
Yo, for unsoldering components from donor hardware: I found that you can mix in some fresh lead-containing solder to get the existing solder to flow. Then you can use some desoldering mesh to get rid of the excess. Really great presentation on that video btw. :)
This was a super interesting video, great job! I'm currently putting together a very custom hand wired split ergo keyboard I designed for my hands specifically, and recently my mouse got slightly damaged, so I'm very tempted to try my hand at something like this lol.
I am fairly certain you can desolder that sensor with a soldering iron and a wick pretty easily? Anyway glad to hear I am not the one disappointed with Logitech mice! With these mice replacing the switches becomes a yearly tradition
It depends on how much the ground plane dissipates heat from the soldering iron; for the mouse I was desoldering from, there was too much dissipation, and the solder on the ground pin refused to melt at temperatures low enough to not damage the sensor's IC.
@@wareya Next time try with a larger tip, chisel or beveled. Smear solder paste over the wick, it should soak all the tin and leave you with a clean pad 😊
@@Willow1w I've got a proper temperature-controlled weller soldering iron with chisel tips, multiple desoldering pumps, desoldering wick, rosin-core leaded solder, and separate flux just in case! I know how to desolder things. The clip in the video is just a dramatic reenactment. The sides edges of needle-point soldering tips work just as well at heat transfer as the points of chisel tips. If you look closely at the clip in the video, you'll see that that's the part I'm using.
@@wareya Impressive setup! Over the years I removed lots of much larger components with this basic technique, IGBTs, power mosfets, transformers, heatsinks, all without trouble... But if it caused you issues I hope you can find an alternate solution!
@@Willow1w Yeah, for most components I haven't had any real issues with the iron + desoldering pump and/or wick + leaded solder and extra flux just in case setup. It's just for some reason removing the 3360 from the mouse I chose to desolder it from ended up being super hard! Shelling out a couple dozen dollars for a hot air rework station was the first alternative that worked safely.
I can attest to logitechs lack of quality control; I have 2 g203's - in one the middle mouse button barely works, on the other the buttons all stopped working. - Update: It turns out the buttons hadn't stopped working, the thumb buttons were now left and right click; the PC I was using the mouse on had somehow corruped the Logitech G Hub software and reinstalling it fixed the problem. But, if I try and use the mouse on a PC without the G Hub installed, it's the thumb buttons again.
Super impressive! Shitty buttons has been a huge problem for a long time now. I wonder if soldering a capacitor across the traces would cause a current spike when you close the switch, and if that would wet the contacts. I've been using the Razer RC30 with optical switches and that part of the mouse has been great.
Mice and most trackballs have enough room for full size microswitches of the type you find in an US Happ style arcade machine (cherry dx-44's) that would not fail for decades. Yet most if not all mice use the tiny mini-switches that have a much higher failure rate on purpose so you'll end up getting a new mouse faster and making them more money.
Oh, that's phenomenal. I've been doing a lot of RP2040 work lately, and my second G300s mouse is just about dead in the same way as usual. Suppose I better start working on this while I can still click most of the time.
i would make a joke about mouse eating cheese and cheese in your spaghetti code but nothing has clicked yet awesome vid tho, its awesome that u made it open sauce >:3
Like more and more as companies just keep cutting costs it seems like the only way to get quality products is to just make them yourself, or find someone who's equally as fed up as you are who's already done it
4 หลายเดือนก่อน +1
I had to test the desoldering on an old mouse just out of curiosity. I had no issues with my soldering iron set to 480°C, then adding a tiny bit of new solder and removing it all with solder wick.
It depends a lot on the specific mouse you're desoldering from! If the ground plane dissipates heat too easily, then the ground pin will have a really hard time coming unsoldered, and might deform the IC casing around itself. 480C is definitely hot enough for this to happen if you leave the iron on the ground pin for too long.
I feel your pain. After churning through a few different mice I ended up turning back to my old-ass Logitech G700, and keep a stash of Omron and Kailh switches. Thankfully, in my case the switches tend to last a few years, so I don't have to replace them very often
Yeah, I noticed every mouse likes to advertise "Omron switches that can survive 50 million clicks!" but I've gone through a lot of mice that start double clicking or failing to click after 2 or 3 years. I liked my current mouse enough that when it started having this issue, I took it apart and just bent the little piece of metal on the switch back into shape. That worked out pretty well. Your solution is uh, a lot more involved lol
2 or 3 years is pretty good service. Double clicking is usually due to pitted contacts. The contact where it makes contact develops a dent. Then as that dent interacts with the other contact it does a double open close. The dent is really tiny so you need a microscope to see it. It's very tiny. The contacts themselves are tiny.
Ive been looking to make my own ergo mouse, so I'll probably use your code and such when i get to that. Its not happening anytime soon though lol, ive got a much bigger project to do before i get back to it. I did buy those pmw3360 breakout boards for some trackball builds im working on though (which is the project coming up first)
I changed the microswitches in my venerable Logitech MX400 with the Japanese made Omrons and it made a huge difference. I think they're about 6 years old now and only in the last month has the LMB started to double-click on me. I'm not as much of a gamer as I used to be, but I do use it every day. I would change them again, but I think the sensor is starting to die.. the tracking occasionally gets hung up on nothing. (no hairs or anything stuck inside that I can tell) Sucks because it's the most comfortable mouse I've ever used.
Really impressive, that was a lot of work. I have a similar mouse (just black). In even quite expensive gaming mouses from other manufacturers as well they just put those trash 10M cycles switches... They really do break quite fast. I actually broke mine trying to make the mouse silent but I ordered much more durable switches. I think they are 50M blue stuff? They hold for 5 years of abuse without a problem. The only downside is the noise, cuz they aren't quiet at all. I got them from china for like 1$ a piece so it was really cheap.
I've been using the WaveShare RP2040 Zero for a lot of my projects. It's nice because it has a rear facing USB C and is really small. The power of the Pico but a much smaller footprint.
I’ve had my Logitech g903 for around 4 years, and I absolutely refuse to let it die because it was so expensive (for a mouse). I’ve had to replace the switches 5 times, and I also had it RMA’d by Logitech themselves for faulty switches about a month after I bought it. However, after my most recent switch change to Kailh GM4.0 switches, I’ve really found some that last long. These most recent switches have lasted me a whole year and are still going strong. I really wish Logitech would fix their switches, it’s such a widespread issue and their mice can be so expensive yet still vulnerable to this idiotic design flaw…
I've started designing a mouse 2-3 times and every time I've given up after realizing there's no good source of mouse sensors. The world of DIY keyboards is so well trodden, but the first step to building your own mouse is always to buy a mouse and take it apart. I hope if we keep making our own, someone will catch on and start making sensors available to order, so we can finally have highly repairable, easily accessible, open source mice.
A modern mouse sensor is essentially just a low resolution camera. You can build your own sensor, but you'll need more advanced hardware to process the image like a rasberry pi zero.
LCSC says they carry the sensor in this video, but it's a "preorder" and stock is at zero.
There are cheap optical mice that have decent sensors though. Microsoft basic optical, for example. Or cm storm alcor, but that one isn’t made anymore.
I don't know that starting with a mouse is a bad notion. All the parts are there, all stiffly pre-mounted and working in harmony. That's not a bad kicking off point for a project. The issue is the driver, but I imagine there are open source templates that get you a long way.
Maybe the Raspberry Pi Foundation could start making their own mice sensors. Or Pine64.
Now this is youtubing
really impressed at how well this turned out
I design pcb schematics and layouts for a job. We do have fab houses in the US, they just cost 10x more, not 2x more :)
Also, you may want to consider doing the assembly yourself next time with a stencil if you don't want to wait the extra few days for each prototype board. I didn't have a reflow oven when I started out so I just used an NTC heating thermistor sandwiched into an aluminum plate that I bought for like 4 bucks.
Nice job though, good for you for being brave enough to dive into pcb design starting with an entire custom microcontroller- that is some intimidating stuff!
My main worry with the local fab houses is turnaround time, and how many of them operate on a quote-only basis, or only on orders of several dozen or hundred boards or more. All very fair problems for a fab house to have, of course, but these chinese companies are offering such a faster and more accessible service for prototyping that it feels like they're eating the lunch, dinner, and midnight snacks, too, of the local ones.
The PCBA JLCPCB orders cost more than it might sound from the general knowledge of them being cheap; being cheap is mostly just for the PCB itself, and assembly has a decent upcharge. It's still nowhere near as expensive as local fabs, but instead of being like, 10~15 dollars (after tax+shipping) for five boards, it was like 45~50.
Thanks! I probably wouldn't have been able to do it if they didn't document the Pico's hardware design so well.
Oh yeah, that custom PCB stuff impressed me too; I'm a software dev working on similar things, but I'm just going to bodge together existing hardware. Huge props to @wareya on learning that PCB design stuff!
Same with Brazil, we do got some pretty high quality PCB manufacturers and assembly services, they just cost an arm and a leg. It's the same price to order from China with express shipping and pay the horrid Brazil taxes (think paying once for the service, and again the same amount OR MORE to the government), compared to buying here.
@@wareya It's impressive how the Chinese decided to cater to a market that looked like nobody else cared about. You shouldn't need to wait a few days for a specialist to tell you "Costs more than you would ever dare paying", if the pricing system is an objective evaluation to begin with for low quantities. The quick site quotes of these services are really handy, of course for weirder stuff you'll only get it through personal quote but they do provide what few care about trying.
@@Kalvinjj I totally agree, and on top of that, those companies have been pretty quickly expanding their capabilities into everything from sheet metal to CNC to even designing board housings, metal 3d printing, and crimping+wiring cable assemblies for you. It's like a dream come true for people who love electronics projects
Also those import taxes suck! I'm glad the US government subsidizes all the shipping from China for me even though I know it's bad for our economy lol
Nothing says "relatable content" like those bodge resistors.
We all been through that eh?
The funniest is seeing obvious bodges like that in commercially released products. It happens to anyone!
@@Kalvinjj my favorite motherboard is the IBM Alaris Cougar, the world's fastest 386 motherboard (probably).
It comes factory-standard with a big ugly yellow bodge wire on the top, proudly displayed next to the IBM sticker.
Here's an idea: Add features NO OTHER MOUSE HAS!
Frame capture is a feature the mouse sensor designers thought was useful but all mouse manufacturers have said "meh" about.
What it does allow is dust detection! Having a look at sensor image now and then and determining if some pixels are obscured and do not change with movement would allow driver to notify user to clean sensor! I'd love for my G602 to do that...
There was a mouse with integrated scanner. Cathode Ray Dude [CRD] covered it in [Why would you scan things with a... mouse?], it was a total flop
@@rasz I know. That is a silly use-case. Now with camera phones it is even worse.
But, the image-array readout of sensors can be used by drivers to do much clever stuff.
For example I designed a filament tracker for 3d printers that uses the readout function to determine the diameter of the filament for automatic calibration of volumetric flow instead of just linear feed. This was possible with a single sensor thanks to this readout function.
Decoupling capacitors are like seasonings
Just gotta sprinkle them on every circuits u make
Nothing is more delicious than low noise voltage source.
this is seriously so impressive, woah! awesome job!!! (great job with the editing in the video too)
Thanks! I learned davinci resolve just to edit this!
I have the most cursed keyboard which led me to make some debounce algorithms of my own. The reason I didn't do zero-latency is because it wouldn't be resistant to noise. Instead I chose to have a stabilization period (2ms) and a following lockout period where additional state changes would be ignored, but the first one still registered if it didn't already happen.
A different algorithm was to count the states during the debounce time and choose that which occurred more frequently.
Then.. only changing the state if a different state was present for at least 75% of the debounce time
What felt like overkill was measuring the raw data of key presses over a time to know how long each one takes specifically to stabilize in value and doing a statistics-based approach based on the individual keys variance.
I can't express enough how cursed this keyboard is for me to even consider having to go that far.. and it's still not working :(
Anyhow, this is an awesome project. The future of anything is open source.
In theory you can do zero-latency for keyboard switches while still resisting noise, but only for the down-click. The up-click will always have added latency.
Sounds like you're trying to get a dynamic debouncing algorithm working. I hope you can figure it out!
surprised at the quality of the video and project, good work
thank,
youtubes hidden gems
Impressive project, it's such a shame an open source an ready available mouse optical sensor doesn't exist.
Currently there wouldn't be much point I'm afraid, they're integrated circuits so no one would be able to manufacture them outside of chip fabs.
There is a similar sort of project I came up with right after this video. Taking a G305 and turning it into a Bluetooth mouse with better firmware and custom PCB to get rid of the AA Battery and replace it for a Li-Po battery and USB c recharge circuit.
Great work man! I had OSHPark make me a custom PCB for an RCA Volume Knob build I was doing and they're so rad.
When you did the "the sponsor of this.. haha joking" I was impressed to find out you're a small creator, this editing/quality is insane! Hope *the algorithm* (dun dun duuun) blesses you again! I'm gonna try to stick!
This is a sick project! I would love to see more content like this.
Subscribed.
Thanks for the sub!
impressive work! Also, I really like the rhythm and speed of narration.
I dont know how but these few days youtube has been serving me with videos from small creators and i am supper happy
why don't youtube recommend this kind of video more often
Because most people are dumb and won't watch it🥸
Because most people aren't watching nerdy stuff like this.
Thank you for taking the time to make this video and sharing the project.
OMG YES! I was waiting for someone to do this. I could also have done it myself, but you know, getting up, pulling through even when road blocks occur... I applaude your engineering!
4:15 Great intuition actually. That's how a lot of bumper buttons in controllers work or even triggers in light guns are similar.
I watched this + the video you linked, I had never thought about mice before since I haven't had them fail, but now I feel an immense amount of respect for you for all the work you did, congrats!!!
I have a G305 and recently replaced it because the mouse wheel kept experiencing "bounce back" where it would actually scroll in reverse of the direction I was operating the wheel.
I wish I had a fix for that one, but AFAIK, for how scroll wheels work, it's kind of inevitable that it'll start to happen after long enough. There isn't anything you can do like the smart debouncing I do here. Just gotta hope the company didn't cheap out, and that you've got one that'll last.
All mice I’ve had get this issue sooner or later. My 5yo G305 still works perfectly but I did have to disassemble and clean it at one point, because LMB had stopped working properly and the scroll wheel was acting up too
@@deamooz9810 Yea. It might have been able to work again if I cleaned it but I did that once and it only helped for so long. I never had any other mice do that but I think this is the first one I stuck to for a really long time.
@@wareya you can use optical scroll sensor like in the good old days, those Never bounce and never die.
@@rasz They eventually fill up with gunk and start having one or two of their notches fail to scroll properly, because the part the light passes through is fully open to the air, unfortunately. Cleaning them and keeping them working for a long time is simpler than the mechanical/electrical ones, but they're not without their downsides.
Hope you make more stuff like this. I made my own headphones, and now I'm starting to wonder if I ought to make a mouse too.
Hi, amazing video! I love how you explain the bouncing and chatter problems. Extremely clear, on point and no bullcrap.
About desoldering with an hot air station, that sure is optimal, but you can get away with a soldering iron, using flux and a larger tip that has more thermal inertia.
That redesign of the pico layout to fit your project is amazing. It's truly the genius kind of mad stuff.
You earned a new sub, and hope you get many, many more !
My favourite kind of channel
Old touhou tf2 oot clips speaks to my soul
you are actually making me get into this stuff... i might try my hand at making PCBs as i always wanted to try making one. hell when this mouse breaks i might just attempt this project.
Based. An SPDT switch with NC and NO tied to V+ and GND respectively, with COM tied to a voltage divider feeding a Schmitt trigger, is a really reliable way to get debouncing done with no latency. A capacitor also works, but is probably worse for the switch.
Instead of hot air, you could use a desoldering iron, they’re generally better for THTs. I just got a cheap one that’s a hollow soldering iron with a manual solder sucker built in, it works great but may struggle at ground planes.
Surely with all those dead Logitech mice you’ve got some to salvage the sensors out of, no? Also the G Pro (replacement for the G303 IIRC) is meant to have long lasting switches.
The ground plane is the main problem, yeah. Depending on the mouse it can dissipate heat faster than the soldering iron is capable of safely supplying it (without melting the plastic of the IC package).
My g203s use a Mercury sensor, which is poorly documented and a lot less common than the 3360. I would've preferred using it if it wasn't for that.
If all you want is that sensor off the board you can just use snips and chop it out. You can cut right through PCB. The best board salvage method is the wet dip though. You just hold the board over a pool of molten solder and pluck out whatever you want. I have a 5 pound solder pot I use for parts salvage.
Amazing project, sharing this far and wide.
Because of the curves on top you should print the final version with 0.1mm layer height and maybe even think about a 0.25mm nozzle. That will drastically reduce the stair stepping effect you get at the top. Also you can use a pi pico to run the printer with klipper instead of the default firmware and add an accelerometer to increase print speed and quality.
How about non planar printing? 🤔
@@carlc.4714 would give you a better finish but it is still not that easy to do. It is way easier to just print with 0.05mm layer and a 0.25mm nozzle and wait for an eternity if you really need the quality.
This is an awesome project! Ive watched a few videos of people custom designing mouses and i would love to do this if or when i get a printer!
Very sick. The side buttons seem like an obvious point of potential failure. I assume they're easy to replace?
Yeah, if they break, you can print new ones and slide them on, or print a bunch of spares ahead of time and use them. Just gotta unscrew the PCB and pull the broken ones off.
Very cool. I thought about doing the same thing and dropped the project when finding out they don't sell the sensor and I didn't want to buy a mouse just the destroy the sensor while resoldering.
Also I like how you can see you improvement from basic self soldered board to custom PCB. Great progress in personal skills
Ive been looking for a pcb for years thank you so much for this video
This looks like an amazing project. Thank you for sharing it!
Man, I was actually thinking of making mouse with pmw3360 myself last weeks and this video just popped out, great job!
As for PCB prototyping, making own PCB's is definetly fastest and cheapest way if you'd want to make more projects, the only downside is that it requires more time. When you have all the stuff needed to make PCBs then making them basically costs nothing and you can get your PCB done the same day you finished the design. With photo-positive method 0.4mm trace is easily achievable and 0.2mm is also possible with some practice. I think you could get everything needed for 50-100$ depending on where you live (not including laser printer).
Looking forward for next projects!
dont tell him that all mechanical switches eventually double click no matter if they are under volted like on the logi boards :3
That's what the timed state latch is for! Even if they double click for like, a hundred milliseconds, you can still filter it out without adding any latency, as long as you've got a solution for chatter.
after searching the market 3-4 few years back, I found out that only steelseries that uses its own switches while all the others use types of the omrons. it still works, never failed yet, while omrons die after 2 to 6 months for me, or could be really electrical or static fault on my part. you might want to give a shot, if you want a mouse with brand :)
btw you killed it.
Glad to have stumbled upon this. Have had a number of Logitech mice over the years, most recently having a G703's scroll wheel break on me. Been working on my own shell but needed to figure out the internals
nice work , ive been looking for a mouse based project !
Thanks for the info about ESP 32 usb support issue!
This is chaotic and delightful. But seriously, can you compliment this with a blog? I’m too dum to keep up with this video lol
I considered it, but it would basically just be the closed caption breakout. You can open it up with the "show transcript" button, I think. It's not divided into paragraphs like it should be, though.
@@wareya I read this blog or watched a video a while back where the youtuber uploaded the transcript to GPT or whatever and had it create timestamp + chapters titles for the video. Brilliant! Probably could restructure the transcript to a written version too? ¯\_(ツ)_/¯ anyway, great stuff as always
Nice to se you got the pinecill too
Hey, congrats! You discovered compliant mechanism!🎉
Dude, great work, great video and amazingly documented, insta-sub on my side.
The neat thing about it is that it can easily be upgraded to add a mini fan to cool the hand, LEDs...
absolutly awesome video!
i really liked the editing and the explenation.
it was very clear, while i still have no idea whats going on (like a nile red video)
keep up the good work!
damn this should have more views, interesting project. Good luck
Found your video on my feed today right after yesterday my G102 got this bounce problem 0:58 on one of the keys. Bought it in 2019, after 6 year it decided to only had that problem yesterday. The fact that this is open source tempted me to do this project but it'd be much, much, more expensive than buying new one here in my country, especially making the custom PCB and 3D printing. (damn cool video btw)
I had a G502 that worked extremely well for years after buying it used from a friend. When it finally died, I went to go replace it with a new G502. Every single part of it just felt so much cheaper. I'm still using that one, so it's lasted quite a while at least. But every so often it's just like "man this thing feels so cheap".
most people just solder new switch but you ball out with this one damn.
I believe the breakout boards probably have a bit of a chicken and egg problem, once demand is high enough they will likely be available much cheaper on aliexpress, ebay etc.
So awesome, keep the good work
High quality video! Great work
Thanks!
I WAS WAITING FOR THIS, I love you man. especially that its open source unlike some other projects.
I also use a G203 and I also had to send it back for.repairs like, twice in the first year!! They make mouses with twigs and putty now apparently!!
I am NOT capable of doing this, but it's good to know the tech is out there, great job!!
Woah, buddy! Well done and medium rare all the way, bro!
Congrats!!
this video rocked!!! wish it was a little longer though, i had to rewatch some parts because of how fast you were talking, and i would love to hear some more specific details on the process of actually making it
the problem isn't the logitech, but Asus holding the patent for hotswappable mouse switches
The problem is that you can patent obvious things like make a part changeable. It's not an invention.
The problem is logitech because they're using garbage switches that go bad stupidly fast
I don't know about Asus' patent, but I know about switches in new mices on the market which are a) hotswappable, b) they are optical, so the bouncing on the contacts is no problem anymore... Almost all new Razer mices have them (and some other brands).
ayo, you're the dude that made that 'don't use machine translation tools' video all those years ago
Seriously hope this project leads to a DIY mouse industry!
Absolutely amazing. Going to try and replicate this and drop some improvements in the mix. Thanks for all the upfront work and for making it open source, and I'll try to help push it along...
Then there's me, who learned soldering just to solder new switches for M1 and M2 for my G502 Hero.
I used Japanese-made Omron switches specifically. Avoid the Chinese ones (regardless of brand), because the copper gets tarnished way too fast, usually within a year. You can clean/polish them if you are dextrous enough, though. That's what I did a couple times until I realised it would be far better to pick up a new skill and just solve the issue for good in one try.
Needless to say, it worked flawlessly. The connectors are gigantic, anyway, so even a newbie can desolder them and replace them easily. I even bought a new and original outer shell for the mouse on Aliexpress (since no local sellers regardless of where I looked) and I basically own a brand-new mouse now.
PS: Funny enough, I wonder why the M4, M5 and so on never had issues. Maybe it's less usage. Maybe it's different switch structure (or material?). Makes me curious, though. I only ever had issues with M1 and M2 switches.
If your solder beads up, like where you soldered your replacement resistors, it means the components to be soldered aren't hot enough. You need to continue heating the place with your iron and wait until the solder nicely flows over everything.
I'm bodging through-hole components onto tiny (0603) surface-mount pads and intentionally applying way too much solder so that thermal expansion/contraction is less likely to make them crack off. Having a round shape is normal in that case.
Yo, for unsoldering components from donor hardware:
I found that you can mix in some fresh lead-containing solder to get the existing solder to flow.
Then you can use some desoldering mesh to get rid of the excess.
Really great presentation on that video btw. :)
Nice video. Your DIY can be handy for people that needs a custom mouse for disability or RSI.
This was a super interesting video, great job! I'm currently putting together a very custom hand wired split ergo keyboard I designed for my hands specifically, and recently my mouse got slightly damaged, so I'm very tempted to try my hand at something like this lol.
I am fairly certain you can desolder that sensor with a soldering iron and a wick pretty easily? Anyway glad to hear I am not the one disappointed with Logitech mice! With these mice replacing the switches becomes a yearly tradition
It depends on how much the ground plane dissipates heat from the soldering iron; for the mouse I was desoldering from, there was too much dissipation, and the solder on the ground pin refused to melt at temperatures low enough to not damage the sensor's IC.
@@wareya Next time try with a larger tip, chisel or beveled. Smear solder paste over the wick, it should soak all the tin and leave you with a clean pad 😊
@@Willow1w I've got a proper temperature-controlled weller soldering iron with chisel tips, multiple desoldering pumps, desoldering wick, rosin-core leaded solder, and separate flux just in case! I know how to desolder things. The clip in the video is just a dramatic reenactment.
The sides edges of needle-point soldering tips work just as well at heat transfer as the points of chisel tips. If you look closely at the clip in the video, you'll see that that's the part I'm using.
@@wareya Impressive setup! Over the years I removed lots of much larger components with this basic technique, IGBTs, power mosfets, transformers, heatsinks, all without trouble... But if it caused you issues I hope you can find an alternate solution!
@@Willow1w Yeah, for most components I haven't had any real issues with the iron + desoldering pump and/or wick + leaded solder and extra flux just in case setup. It's just for some reason removing the 3360 from the mouse I chose to desolder it from ended up being super hard! Shelling out a couple dozen dollars for a hot air rework station was the first alternative that worked safely.
This are the type of Videos I wanna see. Im impressed at the outcome. Definetly something I have to do sooner or later
this frame is intentionally left blank is very cool
I can attest to logitechs lack of quality control; I have 2 g203's - in one the middle mouse button barely works, on the other the buttons all stopped working.
-
Update:
It turns out the buttons hadn't stopped working, the thumb buttons were now left and right click; the PC I was using the mouse on had somehow corruped the Logitech G Hub software and reinstalling it fixed the problem. But, if I try and use the mouse on a PC without the G Hub installed, it's the thumb buttons again.
Super impressive! Shitty buttons has been a huge problem for a long time now. I wonder if soldering a capacitor across the traces would cause a current spike when you close the switch, and if that would wet the contacts. I've been using the Razer RC30 with optical switches and that part of the mouse has been great.
I think that's one of the ways people generally work around this, yeah!
Calling the Basilisk an "RC30" is crazy
Salvaging the sensor sucks but I love the rest of this. Good job!
Mice and most trackballs have enough room for full size microswitches of the type you find in an US Happ style arcade machine (cherry dx-44's) that would not fail for decades. Yet most if not all mice use the tiny mini-switches that have a much higher failure rate on purpose so you'll end up getting a new mouse faster and making them more money.
Well deserved like, quality video my dude 👍
Every day is a day that I regret not learning how to do something like this, and somehow still remaining too lazy to learn
Oh, that's phenomenal. I've been doing a lot of RP2040 work lately, and my second G300s mouse is just about dead in the same way as usual. Suppose I better start working on this while I can still click most of the time.
Me with a g203 that I've had for years, my first and only one: uhhhhh ouch
i would make a joke about mouse eating cheese and cheese in your spaghetti code but nothing has clicked yet
awesome vid tho, its awesome that u made it open sauce >:3
Like more and more as companies just keep cutting costs it seems like the only way to get quality products is to just make them yourself, or find someone who's equally as fed up as you are who's already done it
I had to test the desoldering on an old mouse just out of curiosity. I had no issues with my soldering iron set to 480°C, then adding a tiny bit of new solder and removing it all with solder wick.
It depends a lot on the specific mouse you're desoldering from! If the ground plane dissipates heat too easily, then the ground pin will have a really hard time coming unsoldered, and might deform the IC casing around itself. 480C is definitely hot enough for this to happen if you leave the iron on the ground pin for too long.
3:37 this feels personal
4:34 you could use the "bare" ESP32 S2 module instead of devkit which is large
this is the pinnacle of TH-cam
cool stuff! i use cad in school and this is really interesting
omg thank you for the work, I'll definitely use this when I build my own mouse
I really wish it was possible to just buy the sensor somewhere
there are listings for it on aliexpress and alibaba for like $1
Make sure you don't get scammed: some of them don't include the lens!
Very cool oomfie! Great video too.
I only understood around 40% of what he talked about, but i recognize how awesome it is what he has done.
I feel your pain. After churning through a few different mice I ended up turning back to my old-ass Logitech G700, and keep a stash of Omron and Kailh switches. Thankfully, in my case the switches tend to last a few years, so I don't have to replace them very often
Mouser not carrying mouse sensors gotta be the peak of irony
Yeah, I noticed every mouse likes to advertise "Omron switches that can survive 50 million clicks!" but I've gone through a lot of mice that start double clicking or failing to click after 2 or 3 years. I liked my current mouse enough that when it started having this issue, I took it apart and just bent the little piece of metal on the switch back into shape. That worked out pretty well. Your solution is uh, a lot more involved lol
2 or 3 years is pretty good service. Double clicking is usually due to pitted contacts. The contact where it makes contact develops a dent. Then as that dent interacts with the other contact it does a double open close. The dent is really tiny so you need a microscope to see it. It's very tiny. The contacts themselves are tiny.
I wanna see a mouse with a proper clicky keyboard switch, like Kailh Box Jade, heavy-asf but would feel very nice on tactility.
Ive been looking to make my own ergo mouse, so I'll probably use your code and such when i get to that. Its not happening anytime soon though lol, ive got a much bigger project to do before i get back to it. I did buy those pmw3360 breakout boards for some trackball builds im working on though (which is the project coming up first)
I changed the microswitches in my venerable Logitech MX400 with the Japanese made Omrons and it made a huge difference. I think they're about 6 years old now and only in the last month has the LMB started to double-click on me. I'm not as much of a gamer as I used to be, but I do use it every day. I would change them again, but I think the sensor is starting to die.. the tracking occasionally gets hung up on nothing. (no hairs or anything stuck inside that I can tell) Sucks because it's the most comfortable mouse I've ever used.
Really impressive, that was a lot of work.
I have a similar mouse (just black). In even quite expensive gaming mouses from other manufacturers as well they just put those trash 10M cycles switches... They really do break quite fast. I actually broke mine trying to make the mouse silent but I ordered much more durable switches. I think they are 50M blue stuff? They hold for 5 years of abuse without a problem. The only downside is the noise, cuz they aren't quiet at all. I got them from china for like 1$ a piece so it was really cheap.
The g502 hero I’ve had for a while now. Never had any problems with any of my buttons. But I love diy tech.
3:30 gotta protect those corporate copyrights
Gaming mouse manufacturers do care that their switches keep failing. It’s what keeps mice sales up
my graphic designer ass is still absolutely *limping* through TinkerCad so i totally understand the dodgy 3D design
I've been using the WaveShare RP2040 Zero for a lot of my projects. It's nice because it has a rear facing USB C and is really small. The power of the Pico but a much smaller footprint.
I’ve had my Logitech g903 for around 4 years, and I absolutely refuse to let it die because it was so expensive (for a mouse). I’ve had to replace the switches 5 times, and I also had it RMA’d by Logitech themselves for faulty switches about a month after I bought it. However, after my most recent switch change to Kailh GM4.0 switches, I’ve really found some that last long. These most recent switches have lasted me a whole year and are still going strong. I really wish Logitech would fix their switches, it’s such a widespread issue and their mice can be so expensive yet still vulnerable to this idiotic design flaw…