Skip to content

_lowLevelEnumerateUnits: ps6000EnumerateUnits NULL validity #137

@JohnDMcMaster

Description

@JohnDMcMaster

_lowLevelEnumerateUnits() calls ps6000EnumerateUnits() with parameters that seem to be causing it to fail. See my post on the picoscope forum with additional details: https://www.picotech.com/support/post134781.html?sid=2452f9c184c30325fe7ef5d20feabd2c#p134781

Sounds like this is expected behavior but maybe it worked in the past? IMHO their API broke, but I guess they don't see it that way. In any case I can give a PR with a workaround if that's of interest. Basically you need to do something like this:

-        m = self.lib.ps6000EnumerateUnits(byref(count), None, None)
+        serials = c_int8(0)
+        serialLth = c_int16(0)
+        m = self.lib.ps6000EnumerateUnits(byref(count), byref(serials), byref(serialLth))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions