[![DOI](https://zenodo.org/badge/475187257.svg)](https://zenodo.org/badge/latestdoi/475187257)
# nanonisTCP
Python module for communicating to nanonis via TCP. I am actively developing this so if you have any requests or find any bugs, feel free to raise an issue.
### Installing
Install with pip:
```pip install nanonisTCP```
Installing from source:
Clone the repository, navigate to the root directory and run ```pip install .```
### Using
The following code demonstrates how to change tip bias.
```python
from nanonisTCP import nanonisTCP
from nanonisTCP.Bias import Bias
TCP_IP = '127.0.0.1' # Local host
TCP_PORT= 6501 # Check available ports in NANONIS > File > Settings Options > TCP Programming Interface
NTCP = nanonisTCP(TCP_IP, TCP_PORT, version=13520) # This is how you establish a TCP connection. NTCP is the connection handle.
# Check your nanonis version in Nanonis > help > info and enter the RT Engine number
bias = Bias(NTCP) # Nanonis Bias Module - Pass in the connection handle
bias.Set(1.1) # Set bias to 1.1 V
v = bias.Get() # Get the current bias
print("Bias: " + str(v) + " V") # Confirm bias has been set
NTCP.close_connection() # Close the connection.
```
See any of the xxxTest.py scripts to see how each module can be implemented in more detail.
### Testing
After installing, you can test any of the modules using the sctipts in the test folder.
To test all of the modules, run test.py
<strong>Note that Nanonis must be open for the tests to pass.</strong>
### Citing
If you use nanonisTCP, please consider citing it: [10.5281/zenodo.7402664](https://doi.org/10.5281/zenodo.7402664)
Raw data
{
"_id": null,
"home_page": "https://github.com/New-Horizons-SPM/nanonisTCP",
"name": "nanonisTCP",
"maintainer": null,
"docs_url": null,
"requires_python": null,
"maintainer_email": null,
"keywords": null,
"author": "Julian Ceddia",
"author_email": "jdceddia@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/c8/46/1eab35e31e771af087422c9b97074b2c6d3ab594e03686e51710bcaeec8f/nanonistcp-1.1.2.tar.gz",
"platform": null,
"description": "[![DOI](https://zenodo.org/badge/475187257.svg)](https://zenodo.org/badge/latestdoi/475187257)\r\n# nanonisTCP\r\nPython module for communicating to nanonis via TCP. I am actively developing this so if you have any requests or find any bugs, feel free to raise an issue.\r\n\r\n### Installing\r\n\r\nInstall with pip:\r\n```pip install nanonisTCP```\r\n\r\nInstalling from source:\r\nClone the repository, navigate to the root directory and run ```pip install .```\r\n\r\n### Using\r\n\r\nThe following code demonstrates how to change tip bias.\r\n\r\n```python\r\nfrom nanonisTCP import nanonisTCP\r\nfrom nanonisTCP.Bias import Bias\r\n\r\nTCP_IP = '127.0.0.1' # Local host\r\nTCP_PORT= 6501 # Check available ports in NANONIS > File > Settings Options > TCP Programming Interface\r\n\r\nNTCP = nanonisTCP(TCP_IP, TCP_PORT, version=13520) # This is how you establish a TCP connection. NTCP is the connection handle.\r\n # Check your nanonis version in Nanonis > help > info and enter the RT Engine number\r\n\r\nbias = Bias(NTCP) # Nanonis Bias Module - Pass in the connection handle\r\n\r\nbias.Set(1.1) # Set bias to 1.1 V\r\nv = bias.Get() # Get the current bias\r\nprint(\"Bias: \" + str(v) + \" V\") # Confirm bias has been set\r\n\r\nNTCP.close_connection() # Close the connection.\r\n```\r\n\r\nSee any of the xxxTest.py scripts to see how each module can be implemented in more detail.\r\n\r\n### Testing\r\nAfter installing, you can test any of the modules using the sctipts in the test folder.\r\nTo test all of the modules, run test.py\r\n<strong>Note that Nanonis must be open for the tests to pass.</strong>\r\n\r\n### Citing\r\nIf you use nanonisTCP, please consider citing it: [10.5281/zenodo.7402664](https://doi.org/10.5281/zenodo.7402664)\r\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "python module for communicating via nanonis TCP protocal",
"version": "1.1.2",
"project_urls": {
"Bug Tracker": "https://github.com/New-Horizons-SPM/nanonisTCP/issues",
"Homepage": "https://github.com/New-Horizons-SPM/nanonisTCP"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "080001259fc8cabb0b6861e5f4b7cc77319239fdbd25821224bcd82f287cbfa4",
"md5": "6acdc315a99d327c978554e43766cdcf",
"sha256": "3fd77ea4bad61010a997d2496bdcb8a6b0631e9809c694b9c06a55cc1ce2a723"
},
"downloads": -1,
"filename": "nanonisTCP-1.1.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "6acdc315a99d327c978554e43766cdcf",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 62369,
"upload_time": "2024-05-09T10:00:43",
"upload_time_iso_8601": "2024-05-09T10:00:43.735197Z",
"url": "https://files.pythonhosted.org/packages/08/00/01259fc8cabb0b6861e5f4b7cc77319239fdbd25821224bcd82f287cbfa4/nanonisTCP-1.1.2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "c8461eab35e31e771af087422c9b97074b2c6d3ab594e03686e51710bcaeec8f",
"md5": "9c1fd94537506c65f274421c5f70842a",
"sha256": "89e468253040d53d051348ae0ab5828b7afeb74c19098e9392512cfa37e7ae16"
},
"downloads": -1,
"filename": "nanonistcp-1.1.2.tar.gz",
"has_sig": false,
"md5_digest": "9c1fd94537506c65f274421c5f70842a",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 46129,
"upload_time": "2024-05-09T10:00:46",
"upload_time_iso_8601": "2024-05-09T10:00:46.446637Z",
"url": "https://files.pythonhosted.org/packages/c8/46/1eab35e31e771af087422c9b97074b2c6d3ab594e03686e51710bcaeec8f/nanonistcp-1.1.2.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-05-09 10:00:46",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "New-Horizons-SPM",
"github_project": "nanonisTCP",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "nanonistcp"
}