-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
thorlabs k10cr1 issues #101
Comments
Thanks for the report. What version of Instrumental and NiceLib are you using? I'd be interested to see the traceback you get when trying to open the instrument, and (maybe more usefully) your I haven't seen the issue with not-homing before. Maybe the new stage is only compatible with a newer version of the Thorlabs Kinesis API? Also, you can look at the code for the K10CR1 and search for |
So I made some progress since I posted this and figured out that in fact the stages *are* behaving the same, but I was doing this in the interpreter to test before running my experiment and I was getting confused keeping track of the offsets and positions.
I don’t have the version information or traceback on hand right now, but I can get those when I get into the lab in the morning. I can say that I installed instrumental and nicelib via pip sometime in the last month or so.
I did find a workaround by using a try/except block that just calls instrument(‘saved_instrument’) twice.
The issue with homing appears to be related to wait_for_home(); if I just tell the stages to go where I want them to go, they work fine, but if I call home() with wait=True, they seem to get locked in an endless loop. No motion, but the active light stays on.
My expectation for offset was based on the documentation saying that move_to() accounts for the offset, leading me to believe that after setting the offset the stage would report its position as zero when homed to the offset point. In practice, after an offset is set and the stage is homed the stage reports its position as the negative of the offset, and continues to report its position relative to the zero point on startup, so when I want it to go to a position relative to the offset I have to subtract the offset from the position I’m feeding to move_to(). While trying to understand this behavior I pulled up the kinesis GUI and noticed that the offset value in the preferences is greyed out and not editable; not sure whether that’s related or not but figured it might be worth mentioning.
Also, this may just be due to inexperience but the documentation says that move_to() takes its argument in degrees; my naive expectation was that I would simply pass an int as the argument and that it would interpret that as degrees, but in practice doing that makes it move in radians. Using ureg.degree works as expected, or passing a string like move_to(‘10 degree’), but I spent a solid half hour being confused by that before it occurred to me that pint might solve the issue.
On Oct 1, 2019 at 22:38, <Nate Bogdanowicz<mailto:[email protected]>> wrote:
Thanks for the report. What version of Instrumental and NiceLib are you using?
I'd be interested to see the traceback you get when trying to open the instrument, and (maybe more usefully) your instrumental.conf file.
I haven't seen the issue with not-homing before. Maybe the new stage is only compatible with a newer version of the Thorlabs Kinesis API?
Also, you can look at the code for the K10CR1 and search for offset to see how it's used internally. I haven't thought about this stuff in awhile, but how do you expect the offset should work?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmabuchilab%2FInstrumental%2Fissues%2F101%3Femail_source%3Dnotifications%26email_token%3DAI4IPQMMJVB2NWYQ3FL4CKTQMQJTDA5CNFSM4I356ANKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEADN7HQ%23issuecomment-537321374&data=02%7C01%7Crobertbivens%40my.unt.edu%7C4228321b1782416aa36e08d746e9fbcd%7C70de199207c6480fa318a1afcba03983%7C0%7C0%7C637055843113197003&sdata=wF4LKp18yb5IJep5zII%2FPpuHdYUqhkxL9fJj57uX6Lw%3D&reserved=0>, or mute the thread<https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAI4IPQKS6AUV3JFHSLKLHZLQMQJTDANCNFSM4I356ANA&data=02%7C01%7Crobertbivens%40my.unt.edu%7C4228321b1782416aa36e08d746e9fbcd%7C70de199207c6480fa318a1afcba03983%7C0%7C0%7C637055843113197003&sdata=21yi61Rs4h9ZTVx%2BB%2FqZctkowkwwayD5ZmcgSba18i4%3D&reserved=0>.
|
Here's an example including the traceback. Using NiceLib version 0.6
Here's the config file:
|
Sorry about the formatting, i'm kinda new to github and still figuring out how to get stuff to look right |
I'm having several issues with controlling k10cr1 rotation stages. The least important of these is that I have to use a try/except block to call instrument('saved_instrument') twice for each stage in order to actually load the things, the first call to instrument() raises a 'no known Paramset' error.
More importantly, I'm getting different behavior from different stages. We have 3 K10CR1 stages, one that we've had for a while and a pair that we just got in. In the case of the older one, stage.home() works as expected after an offset has been defined, but the stage always reports position relative to the zero point when it was initialized; this means that move_to() does not account for the offset.
After determining this, I started working on one of the newer stages and discovered that stage.home() doesn't appear to work at all in this case; the active light comes on, but the stage doesn't move.
The text was updated successfully, but these errors were encountered: