Zapit-Optostim / zapit

General purpose optostimulation system
GNU Lesser General Public License v2.1
6 stars 1 forks source link

setting laser power in mW seems not accurate at the low values #23

Closed raacampbell closed 1 year ago

raacampbell commented 1 year ago

Curve not linear with cheapo laser. Although I have fits that should convert from mW to control values based on sensor valuyes, These are failing near zero. I ask for 0 mW but still get quite a bit of power. I therefore for now hard-code an if statement to set power to zero if user asks for this 9d85c53fc7a95ae88ccc8daa0022364ab8989175

I think the fits should be constrained to go through zero. Maybe I need to re-do the fit with the control values re-scaled according to the max/min of a power meter. Then run one conversion instead of the two conversion weirdness I now do.

We are close, though, regarding the commands themselves.

raacampbell commented 1 year ago

It works with Obis laser