Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
WuhrlWuhrd authored Feb 19, 2024
1 parent aeb7351 commit eb9b47d
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,11 @@ pip install git+https://github.com/WuhrlWuhrd/PyOmniDriver.git
after which you should be able to import the `pyomnidriver` package and load the interface, after which you should be able to import the various OmniDriver classes, like so:

```python
# Import the python wrapper and start it up
import pyomnidriver; pyomnidriver.load();
# Import the package
import pyomnidriver;

# We need to call this to startup Java
pyomnidriver.load();

# Now we should be able to import the OmniDriver Java classes as if they were Python classes
from com.oceanoptics.omnidriver.spectrometer.usb650 import USB650
Expand All @@ -42,3 +45,13 @@ plt.show()
# Close the connection now we're done
spectrometer.close()
```

If you are running this with along side [JISA](https://github.com/OE-FET/JISA) by useing [PyJISA](https://github.com/OE-FET/PyJISA), then because they both use Java, import both before only calling `pyjisa.load()` like so:

```python
import pyjisa
import pyomnidriver

# This will load everything together, no need to call pyomnidriver.load()
pyjisa.load()
```

0 comments on commit eb9b47d

Please sign in to comment.