Closed RoboDoig closed 6 months ago
From Ede:
Reading the docs made me realise that the optical sensor movement unit per 360-degree ball rotation is also an important parameter, which I measured, it is higher than with the original sensor we used, which is good, but it is also weird. I did full (slow) rotations with the ball and added an accumulated node to the X value in FlowSensor1. The weird thing is that it gives different values if rotating the ball clockwise or anticlockwise. One is consistent ~30500, the other ~24000 for 360 degrees.
I also checked the range of the PAA5100-JE just by hand-rotating the ball fast and looking at the sensor data. Bad news, at reasonably fast ball rotation speeds, the readout drops to low values. Brightness (SQUAL) values are good (90+).
@RoboDoig, here is some more data.
The PMW3360 sensor I have is working as it should on a Teensy. The Arduino library is here: https://github.com/SunjunKim/PMW3360
Here is the readout from bonsai (both the csv file where you can see the readout ocassionally flipping between 2 values and the raw dump). https://drive.google.com/drive/folders/1R2CSanaWHLYM_wqbq9KUOYUN11Zdd0CX?usp=sharing
From Andrew: A few things to check:
You had mentioned the PMW3389 sensor as well, my suggestion is to focus on the 3360 since you have already had good results with it but if you want to send the 3389 as well they may be able to test it also. I agree. Here is the datasheet: https://www.codico.com/de/mpattachment/file/download/id/395/ The Arduino library we used with a teensy is here https://github.com/SunjunKim/PMW3360 and a repo from the developer with some Arduino code examples: https://github.com/mrjohnk/PMW3360DM-T2QU
We’ll base the 3360 integration on the existing Teensy library (https://github.com/SunjunKim/PMW3360) mentioned in the docs. Were there any modifications to this codebase made by you that are necessary for your use of the sensor? Xavi at Crick uses this code (AFAIK without having modified anything in the driver) https://github.com/FrancisCrickInstitute/Spherical_treadmill/tree/main
The 3360 has a very small working distance of a few mm compared to the current flow sensor. Does that still work for your current rig? After the initial setup, it wasn't an issue for us. One may get smaller SQUAL values as the animal moves the ball, but it was working fine.
A PMW3360 and 3389 sensor was sent to OEPS on Monday 05 June. I can confirm that the current sensor is unable to keep up with our mice, so this issue is critical to our ability to start experiments.
@filcarv can you confirm receipt of the sensors?
We are aiming to have the new sensor (PMW3360) integrated by end of June.
Not yet. Do you have a tracking number?
Damn! I checked with our postal service and they sent it as a simple letter, no tracking. I have 1 of each sensors left, will send them priority tomorrow morning, tracked this time...
Regarding practical usability, I just figured out that I used these in the very first prototype from a Logitech G502 mouse. Here's a video of how well it was working. https://drive.google.com/file/d/1sNaRegpXFsNwe5WQE0s7vkA3zGnt20T8/view?usp=sharing
Let me tracking it down. To which address did you ship it?
OEPS Att: Filipe CarvalhoEd. Neopark, Av Tomas Ribeiro 43Bloco 2, Piso 1, Sala 1J2790-464 CarnaxidePortugalCheers-----------Sent from my phone, please excuse typos and brevity.On 15 Jun 2023, at 19:41, Filipe Carvalho @.***> wrote: Let me tracking it down. To which address did you ship it?
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: @.***>
That's the right address. I will check tomorrow again.
Hi @filcarv, I am about to post the sensors, did you have a chance to check if the first package arrived? Cheers!
Didn't arrive. I will check tomorrow again.
Sorry for the bad news, but there's nothing in the mail yet :(
Sorry for the bad news, but there's nothing in the mail yet :(
OK, let's assume lost in action. 2 more were sent this morning, the tracking doesn't show yet, but it should be 2 days max. https://www.laposte.fr/outils/track-a-parcel?code=LJ002917055FR
Hi @filcarv, according to the tracking info, it was delivered yesterday. Cheers!
Hi @ederancz , good news! I've received the parts yesterday. And the initial shipping arrived today 😅
Hah, great, thank you @filcarv! Long live La Poste! Let me know if you had time to look at these, the sensor speed is one of the critical bottlenecks for us now. Also, I am out of sensors now, so I would appreciate it if you could send 2 back close to the time when we need to test a new firmware.
From Goncalo 11 Aug: The new PMW3360 integration will be developed by Filipe, he will be away for a couple of weeks but latest by sometime mid-September they should be ready to ship.
Flow sensors have arrived and new firmware is ready for testing.
Firmware for H1 was updated for the PMW3360 sensor (version 1.1).
Something to note that lost us a bit of time, the connector for the flow sensor must be in the correct orientation when the board is powered on, otherwise the H1 device will not be recognised.
@EleonoraAmbrad have you tried out the sensor? Can I close this issue?
Closing this issue as the sensor is tested and working. Still need to integrate into the proportional control workflow but this is a separate issue.
true, sensor works fine! However the motor control seems to be a bit "jumpy" and changing the gain does not help a lot. We were wondering if one could introduce a smoothing function (that can be externalised) on the flow sensor output, to smooth the command sent to the motor.
Opened a new issue #35
Want to utilise faster PMW3360 sensor for optic flow detection. Interface and addresses are in theory the same but when this sensor is used in place of PAA5100-JE the reported values do not appear to be linked to movement. Need to investigate firmware to see how we can have general solution for interchanging these sensors and also potentially PMW3389.