ScruffR / PS2Communication

Interrupt driven PS/2 communication library (with PS/2 mouse example)
Other
7 stars 4 forks source link

Version without particle #5

Open eugene-uk opened 7 years ago

eugene-uk commented 7 years ago

Hi, I have modified the example code but have not been able to get it working without Particle connector. Do you have version that just connects with a mouse and passes over the data? (to Serial Print for example)

eugene-uk commented 7 years ago

PS2Mouse-interrupt.zip The output I am getting:

`----- FC


F8


FC


FC


F8


FC

FFFFFFFF - not a valid mouse type`

I have connected CLK to Pin3 of Arduino and Data to Pin2. Of course I have tested the wiring and mouse with the simple PS2 Remote code from another source and it worked.

ScruffR commented 7 years ago

This library is formost meant for Particle devices, but was built ontop of an old project of mine which was targeted at a Teensy 1.0. https://www.pjrc.com/teensy/projects.html (search for vKeyboardMouse_BT)

You can have a look at that code (although I don't know in what state this was when I left it) https://www.dropbox.com/s/6rol0ucezldahuv/PS2Communication.zip?dl=0

I'd have to investigate how to "backport" to Arduino, but can't promise when I'd find time for that.

eugene-uk commented 6 years ago

Hi,

Thanks for sharing. Couple of months went past but I still haven't figured what the issue is even after using your "Arduino" version. Here's the device I am trying to use it on: https://www.youtube.com/watch?v=42_Zoz9P3ks and of course I tried it on a regular mouse too...

ScruffR commented 6 years ago

Sorry, I didn't quite get the meaning of your initial post. What do you mean with "without Particle connector"?

eugene-uk commented 6 years ago

Sorry, I didn't quite get the meaning of your initial post. What do you mean with "without Particle connector"? I meant Particle.io

ScruffR commented 6 years ago

What device are you using? Have you adapted the interrupt management to fit your platform? It might be differernt to the Teensy I used for my project. You may need to watch the signals with an oscilloscope and add some debugging to the library to get a better symptom description.

eugene-uk commented 6 years ago

Hi. I am using a regular PS/2 mouse with a scroll wheel. I did not modify interrupt management but judging by the code it should be no different. But maybe it's my skills that limit my understanding. Of course I read the PS2 description many times to understand how the protocol works and the code seems to match the protocol. But it did not work for me.

ScruffR commented 6 years ago

I still don't know what controller you are using.

eugene-uk commented 6 years ago

I am using standard Arduino Nano - simplest and cheapest. If it helps, I am happy to send you the kit with the nano - that's how keen I am to complete this little project :-) so that I can finally move on

ScruffR commented 6 years ago

That would definetly help.

You could send me PM via https://community.particle.io for my snail mail address ;-)

eugene-uk commented 6 years ago

looks like I will have to register on particle.io? do you mind sending me an email please? my address: contact at lenka.design I am in Prague so most likely the package will be very fast

ScruffR commented 6 years ago

After messing about with the Arduino Nano I must admit that I can't get it running either. I have tried with the Particle Photon and t Teensy 2.0 I dug up and both work as expected just the Nano seems to be a bit stubborn. However I'll keep on trying - meanwhile when you say the Nano would be the cheapest the Particle Photon isn't that much more expensiv (if at all) and has the ability to act as USB Mouse & Keyboard as well as having WiFi on-board.

Since you are in Prague you should be able to order here for €20,50 https://www.exp-tech.de/plattformen/sonstige/6733/particle-photon-mit-header.