Hello, everyone!
I am back at it again with another FTDI-related question, but this time with the Aligent VSpin centrifuge that I recently got and trying to integrate it.
So I followed the guide and installation process, verified that VSpin FTDI is there, built the script, and tried running it, but ran into an error that I am not sure how else to troubleshoot it. After some troubleshooting, something happened that I can’t fully explain, but it seems like the calibration was set wrong…?
I say this because the first error I ran into was this, even though my script had `set_bucket_1_position_to_current` method after setup:
UserWarning: No calibration found for VSpin with device id BG028CTI. Please set the bucket 1 position using `set_bucket_1_position_to_current` method after setup.
warnings.warn(
This is my Python script to configure the VSpin:
import pylibftdi
print(pylibftdi.Driver().list_devices())
import asyncio
from pylabrobot.centrifuge import Centrifuge, VSpinBackend
async def run_vspin():
cf = Centrifuge(name = "centrifuge", backend = VSpinBackend(device_id="BG028CTI"), size_x= 1, size_y=1, size_z=1)
print("Will set up")
await cf.setup()
print("vspin was set up")
await cf.open_door()
input("Press Enter to continue...")
await cf.backend.set_bucket_1_position_to_current()
await cf.close_door()
if __name__ == "__main__":
asyncio.run(run_vspin())
Halfway through modifying my script, I accidentally ran it, and something happened that I don’t recall, or saved it
But when I ran the script to try again, it froze at the setup function, not finishing the setup at all. So I switched PLR to a different branch on my computer to start “fresh”, but ran into this error, which I am inclined to believe that whatever error I ran previously is propagated here, and that I would need to “reset” that calibration if I understand properly…?
cf = Centrifuge(name = "centrifuge", backend = VSpinBackend(device_id="BG028CTI"), size_x= 1, size_y=1, size_z=1)
~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^
TypeError: VSpinBackend.__init__() missing 1 required positional argument: 'calibration_offset'
Yes, I know this is a hot mess, and you may put me on the wall of shame ![]()