Geschrieben November 26, 2017 at 08:0226. Nov 2017 I'm in the process of creating a Python script that allows any sensor bricklet to be connected. To achieve this, I need a list of bircklet IDs, UIDs, name and the functions to register the device and the one to acquire sensor data, something like this: brickletDevices = [ [259, "Ambient Light Bricklet 2.0",BrickletAmbientLight(uid, ipcon), BrickletAmbientLight.get_illuminance()] ... ] At the moment I have to copy and paste the API functions manually from each bricklet's page which is tedious and time consuming. Is there a list of Python API methods and functions somewhere? The code would enumerate the connected bricklets, compare their ID against the list and print out the name, ID, and the acquired data.
Geschrieben November 26, 2017 at 23:2426. Nov 2017 The source code of the logger of the Brick Viewer has something like this in it: https://github.com/Tinkerforge/brickv/blob/master/src/brickv/data_logger/loggable_devices.py
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.