Python wrapper for interfacing to IntrepidCS Hardware.
Project description
Description
Python wrapper for interfacing to IntrepidCS Hardware.
Installing
pip install python_ics
Platform specific Installation notes
Windows
- Windows requires icsneo40.dll to be installed in the PATH. This can be obtained through vspy3 or our hardware installation kit found here: https://cdn.intrepidcs.net/updates/files/RP1210KitInstall.zip
Linux
- Linux builds use libicsneo and are built against manylinux using cibuildwheel.
- libicsneolegacy.so is bundled with the wheel and python_ics will automatically use it.
MacOS
- Mac builds use libicsneo and are built using cibuildwheel
- libicsneolegacy.dylib is bundled with the wheel and python_ics will automatically use it.
Basic usage
import ics
devices = ics.find_devices()
print(f"Found {len(devices)} devices...")
for device in devices:
# Print, open, load default settings, close
print(device)
device.open()
device.load_default_settings()
device.close()
Documentation
http://python-ics.readthedocs.io/
Building from source
- Building from source requires clang and clang-format to be present on the build machine.
- python_ics has submodules, please be sure to initial all submodules also.
PS > git clone git@github.com:intrepidcs/python_ics.git
PS > cd python_ics
PS > git submodule update --init
PS > clang --version
clang version 11.1.0
Target: x86_64-pc-windows-msvc
Thread model: posix
InstalledDir: C:\Program Files\LLVM\bin
PS > clang-format --version
clang-format version 11.1.0
PS > python -m pip install .
Debugging on Windows with Visual Studio Code
- Build and install python_ics for debug. When installing python choose the following:
- Customize Installation -> Advanced Options
- Check Download debugging symbols
- Check Download debug binaries
- Customize Installation -> Advanced Options
- Build python with debug:
- Install Visual Studio 2019 build tools(NOTE: As of 2/5/24, it looks like MSVC 2022 does not build correctly with setuptools and debug configurations). You should be able to build from source already.
- Create virtual environment and activate it (powershell):
python -m venv .venv
.\.venv\Scripts\Activate.ps1
- Install dependencies:
python -m pip install -r requirements.txt
- Build in debug (
-g
flag):python setup.py build -g
- Install into our virtual environment:
python setup.py install --force
- Inside visual studio code:
- Open the root python_ics directory
code C:\Path\To\python_ics
- Make sure the python extension is installed (ctrl+shift+x)
- Select the python interpreter from our virtual environment (bottom right with a python file open in the editor).
- Open and place a breakpoint in
src/icsdebug.py
- launch "Python: Debug icsdebug.py"
- Note the PID that is outputted to terminal (Can also add
os.getpid()
to watch window)
- Note the PID that is outputted to terminal (Can also add
- Place a breakpoint inside the function you'd like to debug in
methods.cpp
- launch "Debugger Attach" (
launch.json
) and enter the pid when prompted. - enjoy!
- Open the root python_ics directory
License - MIT
Copyright (c) Intrepid Control Systems, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Hashes for python_ics-917.18-cp312-cp312-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5182a7dcef89069dd6c29e26431e77deb34ecdd07ec6b6fb3da8c25453450ead |
|
MD5 | 6c8c5dae846e7229000df06dbb8a40ea |
|
BLAKE2b-256 | e92b15e84ca0da262251f7cae08ac6f928c3259550ad362817de6819acfb04de |
Hashes for python_ics-917.18-cp312-cp312-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 52a23deee7779eeb9a380ddfe16ee11de427b36c21aac56738a16faa400dfbc0 |
|
MD5 | 8a7feb44dffde0b2f4c71b5ce00419a5 |
|
BLAKE2b-256 | 50ceb466eeb3bd1c5436b3280a653297ded332a4992e988fae9498348f0a54a8 |
Hashes for python_ics-917.18-cp312-cp312-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 81d9e899e05cda99847b0e64660e6e2b7c10dd08608d4ce99acf92d5cf4bf6e3 |
|
MD5 | 0213e327dc914be5b11f0ff661c2438c |
|
BLAKE2b-256 | 76223fbd48f2ce8ac1799857338b0f1e1d9354dea4ffd75bb93c4b4ffc695e60 |
Hashes for python_ics-917.18-cp312-cp312-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | de4ef13edf895f84ccb5bf05177f3b2a4efa12b18ea9156ac2b7e6829b098adb |
|
MD5 | d03f1a7fb613737ce5cd59e77de13ea5 |
|
BLAKE2b-256 | 07c7bed3a1d827b0a16a73fb39d6bc5fa8851c2f248a153dd672b832dc248993 |
Hashes for python_ics-917.18-cp312-cp312-macosx_10_13_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e9e2d4e9b2a5035bfd8e247bfdec08163b57cd9d1a56dcb0547ad342609a920b |
|
MD5 | ece57ad9437d26ff3df18d016b531410 |
|
BLAKE2b-256 | f6c7d0ffda9e1632841a1efcf233de26634f0e29ab3cab025a70dab0f21d08e3 |
Hashes for python_ics-917.18-cp311-cp311-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | da57ae01da60204ec43ccaff69a8e2f5acec931b3cef5225cb13517f6dd88439 |
|
MD5 | 183afd862493689c4994df228cf61505 |
|
BLAKE2b-256 | fd7699655c991b15a5ad14d61fd7a1190d3c9555e096829dabc76bf8a78e1952 |
Hashes for python_ics-917.18-cp311-cp311-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 36a8c7918e191bb94e6b7186291bf4d50372ee15a7735053c76a56ab4fa6c110 |
|
MD5 | d29884f6f73c0317c190ce41bbb980b8 |
|
BLAKE2b-256 | 65b6d50e804dc2dc66757bf540b67424d8b9c0e8c3b63ada94347dd425075129 |
Hashes for python_ics-917.18-cp311-cp311-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f88c63e969de5d34efb7972556b46df146fb7d14d402118d85b763d3ae5a60ef |
|
MD5 | b594e423c311d01b2c2d89fa939f3628 |
|
BLAKE2b-256 | 1f676eff0f442419b6ac0d71ab076da97d7091de4ce0ab3aa4830803c3808347 |
Hashes for python_ics-917.18-cp311-cp311-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 94621c9ff99610cd4b25db5fcdcfdda3967f75a4c95b150f0581983cb68a828a |
|
MD5 | 755d514a064a9f844a1d6c3a79af3900 |
|
BLAKE2b-256 | d1fdf4873ebc4afad319521d3d1a41370b14af61d913c813d752af7b130b6eb7 |
Hashes for python_ics-917.18-cp311-cp311-macosx_10_13_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e4ba1a0eaf767426b3653d8d0cbee0557f3a4844efe4f14669a34f095ea029ba |
|
MD5 | 772cf836b5b0cffad7fae8d62d960369 |
|
BLAKE2b-256 | c51c0dbfe84a37451b9ca7a1ff307d45993b87a65d4ed31849ecff0d027e73de |
Hashes for python_ics-917.18-cp310-cp310-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 97a586eb3ca4d1173b5bc4ceeb97d23592ca61fe5e8e9d537c7b9f054c881606 |
|
MD5 | e1b887b36fb3e45300623d0b336890d6 |
|
BLAKE2b-256 | 6337f5933447fb923d0342ba23e93a3298a915412f72c159e2decfcd12d4e619 |
Hashes for python_ics-917.18-cp310-cp310-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 88fa11744b6c4cd09cbdf8581901503b00a1fa698e516289497eb87f93838efe |
|
MD5 | 59de929f69ef3bf0b9aafdf014f537d8 |
|
BLAKE2b-256 | 39daa25b81b9c22af7b03f90c01d6e3274e13b5303ad90de1cf5c914defcfe8d |
Hashes for python_ics-917.18-cp310-cp310-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bf3069d797beb41dd28dddd8aa2a6a516fae76921a83921a14a4a88df8b9512d |
|
MD5 | 5ccc661c49b6e928cc4a37dc380b0fa9 |
|
BLAKE2b-256 | b0760d0b26c97151a56b1c0207fe1280c6dff9830ca240097ab4bdbe9da2187b |
Hashes for python_ics-917.18-cp310-cp310-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 577c28f0de7c9569cefb9af42ae9152dded8b4c5e9e31d3ba9b00f0a2a5dc570 |
|
MD5 | 254aa9bd3c672e6a7fa0ce7529c82da2 |
|
BLAKE2b-256 | 5e2b9a1fec9c06feab47aad18431b8fdb39cc57c40921e22c57914ed40fb3675 |
Hashes for python_ics-917.18-cp310-cp310-macosx_10_13_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0c567c985acf42ac9193e821340181440b748ffc222a30434f86bbe10ba98931 |
|
MD5 | cc4935ded3c230f14081f70e04293a8b |
|
BLAKE2b-256 | 834d64b80d9b06d369141a4ae7da869cf52244fb0eae0e7f90d227ff3e86d271 |
Hashes for python_ics-917.18-cp39-cp39-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 70755fd34c0f1725e610acdc1aee3d21bdcb0fc241e153a115a2978eabf4bbd5 |
|
MD5 | 72ba90a87b184a5967faa6e235f20ea2 |
|
BLAKE2b-256 | e5a1050d7c78b1b74e756967478b9143f74fb5eeefea45e9b66380bc5e81c000 |
Hashes for python_ics-917.18-cp39-cp39-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e9e94dc4f9f3db9da847c267a3e8c50b8791f5f3852fa399d22d29ef4f4039a7 |
|
MD5 | 94caf5a3c4eeeb7d33c8c6476cbd7ba6 |
|
BLAKE2b-256 | 5a7353b0af5452f4f0461877fe5e40381230c7ab1d64e6d163f23585e6a59ffc |
Hashes for python_ics-917.18-cp39-cp39-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0ebfd4d5ebf82069f14511c2ac740d4d5ae1abde0ba847613b30e4a3af4e3911 |
|
MD5 | 3e9f4052f394c99248755ad897f872b8 |
|
BLAKE2b-256 | 66fcdcdb669fbf0a8285285af17c9e704af0f3827e973e70790aababf4f43d82 |
Hashes for python_ics-917.18-cp39-cp39-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a1ddcbf845132924f0e61002cdb393f2edf177e955906e7959cd32c7fa19c2fd |
|
MD5 | 439d0c314c38bdbce40bb5474984b3c9 |
|
BLAKE2b-256 | b7a6421a4e59af481a0c3a9f55f85b03b8274c1b227b543b5210aa72c0615b99 |
Hashes for python_ics-917.18-cp39-cp39-macosx_10_13_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e8cc74b98ac253353e665652fb34dddc5a65462b3e7624aac80b12f742404ff5 |
|
MD5 | ae7521fb3eb21188bdc4f60ed4098e5c |
|
BLAKE2b-256 | 1f24e16f596da9d3b3a1d3a08de2fedd7932a59bc0b2a7c74aee2961b9227b1b |
Hashes for python_ics-917.18-cp38-cp38-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6a98ad8292921241949d4fb4fd1ba1e952144ee337e2f543ec53a3933e0fcf3e |
|
MD5 | 2e1b5b0c53f2d2ea6958399f06edef59 |
|
BLAKE2b-256 | 48a0e2f028e5e034754a8107ddafe139b980793868de97f61ca2478a6427177d |
Hashes for python_ics-917.18-cp38-cp38-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c5ca8e3aba46e41e801a8635e4be5b8bd189c97bded68ed1bc4c9aabdfbe3043 |
|
MD5 | 561a8ae5b31d1e575919dd163e175dc9 |
|
BLAKE2b-256 | af93fe7e7061c93d58f8b7f86292656e01423d9a381c94433b30cbf5ad96792a |
Hashes for python_ics-917.18-cp38-cp38-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 790f1a3a34b00bce447b4180bb396bd050f8c684d3ccc098b3e437982eca028c |
|
MD5 | 12d270ceb4339732ca74c81fc2491334 |
|
BLAKE2b-256 | 96e1696d987a194e5937e456370b8965f038d3104f733d09dc7fdce96884363a |
Hashes for python_ics-917.18-cp38-cp38-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a0e57ae50bdbfa68b76bdad5815f69d1bf7b2ca74c0af1492a075f0799c66d2a |
|
MD5 | 8dc251329a46b5df1da363219bea0242 |
|
BLAKE2b-256 | a8807e48e20270c75fb335d7afa34eed944edc87726a2005dbfa135ec9bb87d2 |
Hashes for python_ics-917.18-cp38-cp38-macosx_10_13_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9fa085e58d1659d30348d306818a73c92689a56f36e40981022aea6c70366ef9 |
|
MD5 | 205e0cd4208df9d61e689f06595cd322 |
|
BLAKE2b-256 | 5c41d7a820f437242e418e21605e64b3820d347eab1f88b71a9f911f68039675 |