wasatch 2.3.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- wasatch/AbstractUSBDevice.py +29 -0
- wasatch/AndorDevice.py +910 -0
- wasatch/AreaScanImage.py +19 -0
- wasatch/AutoRaman.py +457 -0
- wasatch/AutoRamanRequest.py +96 -0
- wasatch/BLEDevice.py +1032 -0
- wasatch/BalanceAcquisition.py +136 -0
- wasatch/CSVLoader.py +188 -0
- wasatch/CommandSettings.py +95 -0
- wasatch/ControlObject.py +17 -0
- wasatch/DetectorROI.py +36 -0
- wasatch/DetectorRegions.py +158 -0
- wasatch/DeviceFinderBLE.py +107 -0
- wasatch/DeviceFinderTCP.py +20 -0
- wasatch/DeviceFinderUSB.py +236 -0
- wasatch/DeviceID.py +344 -0
- wasatch/EEPROM.py +1450 -0
- wasatch/EEPROM_multical.sav +48 -0
- wasatch/FPGAOptions.py +125 -0
- wasatch/FeatureIdentificationDevice.py +3961 -0
- wasatch/FirmwareRequirements.py +76 -0
- wasatch/HardwareInfo.py +36 -0
- wasatch/IDSCamera.py +916 -0
- wasatch/IDSDevice.py +329 -0
- wasatch/IMX385.py +179 -0
- wasatch/InterfaceDevice.py +40 -0
- wasatch/MockUSBDevice.py +353 -0
- wasatch/OceanDevice.py +215 -0
- wasatch/PollStatus.py +15 -0
- wasatch/ProcessedReading.py +352 -0
- wasatch/ROI.py +33 -0
- wasatch/Reading.py +80 -0
- wasatch/RealUSBDevice.py +64 -0
- wasatch/SPIDevice.py +628 -0
- wasatch/SpectrometerRequest.py +15 -0
- wasatch/SpectrometerResponse.py +38 -0
- wasatch/SpectrometerSettings.py +446 -0
- wasatch/SpectrometerState.py +255 -0
- wasatch/StatusMessage.py +14 -0
- wasatch/TCPDevice.py +409 -0
- wasatch/TakeOneRequest.py +43 -0
- wasatch/WasatchBus.py +87 -0
- wasatch/WasatchDevice.py +1060 -0
- wasatch/WasatchDeviceWrapper.py +452 -0
- wasatch/WrapperWorker.py +304 -0
- wasatch/__init__.py +4 -0
- wasatch/applog.py +177 -0
- wasatch/simulation_protocol.py +227 -0
- wasatch/utils.py +731 -0
- wasatch-2.3.2.dist-info/LICENSE +21 -0
- wasatch-2.3.2.dist-info/METADATA +347 -0
- wasatch-2.3.2.dist-info/RECORD +53 -0
- wasatch-2.3.2.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2018 Wasatch Photonics
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,347 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: wasatch
|
|
3
|
+
Version: 2.3.2
|
|
4
|
+
Summary: Application-level driver for Wasatch Photonics spectrometers
|
|
5
|
+
Requires-Python: >=3.9
|
|
6
|
+
Description-Content-Type: text/markdown
|
|
7
|
+
Requires-Dist: numpy
|
|
8
|
+
Requires-Dist: six
|
|
9
|
+
Requires-Dist: psutil
|
|
10
|
+
Requires-Dist: future
|
|
11
|
+
Requires-Dist: pygtail
|
|
12
|
+
Requires-Dist: pyusb
|
|
13
|
+
Requires-Dist: requests
|
|
14
|
+
Requires-Dist: pexpect
|
|
15
|
+
Requires-Dist: seabreeze
|
|
16
|
+
Requires-Dist: pyudev
|
|
17
|
+
Requires-Dist: pywin32; platform_system=='Windows'
|
|
18
|
+
Requires-Dist: pyftdi
|
|
19
|
+
Requires-Dist: crcmod
|
|
20
|
+
Requires-Dist: bleak
|
|
21
|
+
Requires-Dist: ids_peak; platform_system=='Windows'
|
|
22
|
+
Project-URL: Homepage, https://github.com/WasatchPhotonics/wasatch.py
|
|
23
|
+
|
|
24
|
+

|
|
25
|
+
|
|
26
|
+
# Overview
|
|
27
|
+
|
|
28
|
+
Wasatch.PY is a Python application-level driver for Wasatch Photonics spectrometers.
|
|
29
|
+
It has been tested on Windows, Linux and MacOS platforms, and is directly used by
|
|
30
|
+
Wasatch's own [ENLIGHTEN™](https://wasatchphotonics.com/product-category/software/)
|
|
31
|
+
spectroscopy desktop GUI.
|
|
32
|
+
|
|
33
|
+
If you'd like simpler, smaller examples of how to perform individual operations
|
|
34
|
+
against Wasatch spectrometers from Python, please also see our
|
|
35
|
+
[Python Example Scripts](https://github.com/WasatchPhotonics/Python-USB-WP-Raman-Examples)
|
|
36
|
+
repository.
|
|
37
|
+
|
|
38
|
+
## History
|
|
39
|
+
|
|
40
|
+
This project started as a successor to the earlier
|
|
41
|
+
[WasatchUSB](https://github.com/WasatchPhotonics/WasatchUSB). The main
|
|
42
|
+
difference is that while WasatchUSB was a one-time copy-pasta of legacy ENLIGHTEN
|
|
43
|
+
classes, Wasatch.PY is an actively maintained and supported HAL (hardware abstraction layer)
|
|
44
|
+
dependency of the current [ENLIGHTEN](https://wasatchphotonics.com/product-category/software/)
|
|
45
|
+
application. As a result, when we add or update ENLIGHTEN features, Wasatch.PY is
|
|
46
|
+
updated by necessity; making the same foundational interface available to all our users.
|
|
47
|
+
|
|
48
|
+
This shared library exemplifies one of our core values: we're all about
|
|
49
|
+
[dogfooding](https://en.wikipedia.org/wiki/Eating_your_own_dog_food)!
|
|
50
|
+
|
|
51
|
+
Finally, the updated project name reflects the fact that this is specifically a
|
|
52
|
+
Python binding and implementation; for other USB-capable interfaces, see
|
|
53
|
+
[Wasatch.NET](https://github.com/WasatchPhotonics/Wasatch.NET),
|
|
54
|
+
[Wasatch.VCPP](https://github.com/WasatchPhotonics/Wasatch.VCPP)
|
|
55
|
+
and other [software drivers](https://wasatchphotonics.com/software-support/software-drivers/)!
|
|
56
|
+
|
|
57
|
+
# API
|
|
58
|
+
|
|
59
|
+
Rendered API documentation for classes and methods is available here:
|
|
60
|
+
|
|
61
|
+
- https://wasatchphotonics.com/api/Wasatch.PY/annotated.html
|
|
62
|
+
|
|
63
|
+
A significant portion of Wasatch.PY's command interface is exposed through key-value
|
|
64
|
+
settings, originally provided to simplify multi-process applications and summarized here:
|
|
65
|
+
|
|
66
|
+
- [Key-Value Settings](https://github.com/WasatchPhotonics/Wasatch.PY/blob/master/README_SETTINGS.md)
|
|
67
|
+
|
|
68
|
+
# PyPi
|
|
69
|
+
|
|
70
|
+
Looking for Wasatch.PY from `pip` ([PyPi](https://pypi.org/))? Look no further! The
|
|
71
|
+
latest released version of Wasatch.PY can be loaded into your environment with a simple
|
|
72
|
+
pip command:
|
|
73
|
+
|
|
74
|
+
$ pip install wasatch
|
|
75
|
+
|
|
76
|
+
Package info:
|
|
77
|
+
|
|
78
|
+
- https://pypi.org/project/wasatch/
|
|
79
|
+
|
|
80
|
+
For more information about PyPi package management, see [README_PYPI](https://github.com/WasatchPhotonics/Wasatch.PY/blob/master/README_PYPI.md).
|
|
81
|
+
|
|
82
|
+
# Dependencies
|
|
83
|
+
|
|
84
|
+
Wasatch.PY used to use the Python 3.x build of [Miniconda](https://conda.io/miniconda.html)
|
|
85
|
+
for dependencies and package management. Increasingly however, we just use pip:
|
|
86
|
+
|
|
87
|
+
$ pip install -r requirements.txt
|
|
88
|
+
|
|
89
|
+
# Running the Demo
|
|
90
|
+
|
|
91
|
+
Following are the general usage instructions for the included command-line demo
|
|
92
|
+
scripts. After find specific Anaconda setup instructions for Windows, Linux, MacOS
|
|
93
|
+
and other tested platforms.
|
|
94
|
+
|
|
95
|
+
mzieg-macbook.local [~/work/code/Wasatch.PY] mzieg 9:48PM $ conda activate wasatch3
|
|
96
|
+
(wasatch3) mzieg-macbook.local [~/work/code/Wasatch.PY] mzieg 9:49PM $ python -u demo.py --help
|
|
97
|
+
|
|
98
|
+
usage: demo.py [-h] [--log-level LOG_LEVEL]
|
|
99
|
+
[--integration-time-ms INTEGRATION_TIME_MS]
|
|
100
|
+
[--scans-to-average SCANS_TO_AVERAGE]
|
|
101
|
+
[--boxcar-half-width BOXCAR_HALF_WIDTH] [--delay-ms DELAY_MS]
|
|
102
|
+
[--outfile OUTFILE] [--max MAX] [--non-blocking] [--ascii-art]
|
|
103
|
+
|
|
104
|
+
Simple demo to acquire spectra from command-line interface
|
|
105
|
+
|
|
106
|
+
optional arguments:
|
|
107
|
+
-h, --help show this help message and exit
|
|
108
|
+
--log-level LOG_LEVEL
|
|
109
|
+
logging level [DEBUG,INFO,WARNING,ERROR,CRITICAL]
|
|
110
|
+
--integration-time-ms INTEGRATION_TIME_MS
|
|
111
|
+
integration time (ms, default 10)
|
|
112
|
+
--scans-to-average SCANS_TO_AVERAGE
|
|
113
|
+
scans to average (default 1)
|
|
114
|
+
--boxcar-half-width BOXCAR_HALF_WIDTH
|
|
115
|
+
boxcar half-width (default 0)
|
|
116
|
+
--delay-ms DELAY_MS delay between integrations (ms, default 1000)
|
|
117
|
+
--outfile OUTFILE output filename (e.g. path/to/spectra.csv)
|
|
118
|
+
--max MAX max spectra to acquire (default 0, unlimited)
|
|
119
|
+
--non-blocking non-blocking USB interface (WasatchDeviceWrapper
|
|
120
|
+
instead of WasatchDevice)
|
|
121
|
+
--ascii-art graph spectra in ASCII
|
|
122
|
+
|
|
123
|
+
## Microsoft Windows
|
|
124
|
+
|
|
125
|
+
The following session was run on Windows 10 using the Cmd shell of [Git for Windows](https://git-scm.com/)
|
|
126
|
+
and [Miniconda](https://conda.io/miniconda.html) (Python 3.x):
|
|
127
|
+
|
|
128
|
+
C:\Users\mzieg>set PATH=%HOME%\miniconda3;%HOME%\miniconda3\scripts;%PATH%
|
|
129
|
+
C:\Users\mzieg>cd work\code\Wasatch.PY
|
|
130
|
+
C:\Users\mzieg\work\code\Wasatch.PY>conda update conda
|
|
131
|
+
C:\Users\mzieg\work\code\Wasatch.PY>cp environments\conda-win10.yml environment.yml
|
|
132
|
+
C:\Users\mzieg\work\code\Wasatch.PY>conda env create -n wasatch3
|
|
133
|
+
Solving environment: done
|
|
134
|
+
Preparing transaction: done
|
|
135
|
+
Verifying transaction: done
|
|
136
|
+
Executing transaction: done
|
|
137
|
+
Requirement already satisfied: future==0.16.0 in c:\users\mzieg\miniconda3\envs\conda_enlighten\lib\site-packages (from -r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 1))
|
|
138
|
+
Collecting pefile==2016.3.28 (from -r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 2))
|
|
139
|
+
Requirement already satisfied: pygtail==0.7.0 in c:\users\mzieg\miniconda3\envs\conda_enlighten\lib\site-packages (from -r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 3))
|
|
140
|
+
Requirement already satisfied: pyside==1.2.4 in c:\users\mzieg\miniconda3\envs\conda_enlighten\lib\site-packages (from -r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 4))
|
|
141
|
+
Requirement already satisfied: pytest-capturelog==0.7 in c:\users\mzieg\miniconda3\envs\conda_enlighten\lib\site-packages (from -r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 5))
|
|
142
|
+
Requirement already satisfied: pytest-qt==2.1.0 in c:\users\mzieg\miniconda3\envs\conda_enlighten\lib\site-packages (from -r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 6))
|
|
143
|
+
Requirement already satisfied: pyusb==1.0.0 in c:\users\mzieg\miniconda3\envs\conda_enlighten\lib\site-packages (from -r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 7))
|
|
144
|
+
Requirement already satisfied: requests==2.13.0 in c:\users\mzieg\miniconda3\envs\conda_enlighten\lib\site-packages (from -r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 8))
|
|
145
|
+
Requirement already satisfied: py>=1.1.1 in c:\users\mzieg\miniconda3\envs\wasatch3\lib\site-packages (from pytest-capturelog==0.7->-r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 5))
|
|
146
|
+
Requirement already satisfied: pytest>=2.7.0 in c:\users\mzieg\miniconda3\envs\wasatch3\lib\site-packages (from pytest-qt==2.1.0->-r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 6))
|
|
147
|
+
Requirement already satisfied: colorama in c:\users\mzieg\miniconda3\envs\wasatch3\lib\site-packages (from pytest>=2.7.0->pytest-qt==2.1.0->-r C:\Users\mzieg\work\code\Wasatch.PY\condaenv.xq_jth.requirements.txt (line 6))
|
|
148
|
+
Installing collected packages: pefile
|
|
149
|
+
Found existing installation: pefile 2017.11.5
|
|
150
|
+
Uninstalling pefile-2017.11.5:
|
|
151
|
+
Successfully uninstalled pefile-2017.11.5
|
|
152
|
+
Successfully installed pefile-2016.3.28
|
|
153
|
+
|
|
154
|
+
C:\Users\mzieg\work\code\Wasatch.PY>activate wasatch3
|
|
155
|
+
|
|
156
|
+
C:\Users\mzieg\work\code\Wasatch.PY>python demo.py --outfile data.csv --integration-time-ms 100 --delay-ms 500
|
|
157
|
+
2018-01-22 15:20:12,457 MainProcess wasatch.fid_hardware INFO reading EEPROM page 1
|
|
158
|
+
2018-01-22 15:20:12,473 MainProcess wasatch.fid_hardware INFO reading EEPROM page 0
|
|
159
|
+
2018-01-22 15:20:12,473 MainProcess wasatch.fid_hardware INFO reading EEPROM page 2
|
|
160
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO reading EEPROM page 5
|
|
161
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO EEPROM settings:
|
|
162
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO Wavecal coeff0: 399.24130249
|
|
163
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO Wavecal coeff1: 0.43601000309
|
|
164
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO Wavecal coeff2: -7.33139968361e-05
|
|
165
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO Wavecal coeff3: 2.80489995674e-08
|
|
166
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO Calibration date: 6/2
|
|
167
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO Calibrated by: NH
|
|
168
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO Excitation (nm): 0
|
|
169
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO Slit size (um): 50
|
|
170
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO degCToDAC coeff0: 6.30511975963e-10
|
|
171
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO degCToDAC coeff1: 1.68748300666e-07
|
|
172
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO degCToDAC coeff2: 0.10000000149
|
|
173
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO adcToDegC coeff0: 66.0
|
|
174
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO adcToDegC coeff1: -0.00999999977648
|
|
175
|
+
2018-01-22 15:20:12,490 MainProcess wasatch.fid_hardware INFO adcToDegC coeff2: -9.99999974738e-05
|
|
176
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.fid_hardware INFO Det temp min: 20
|
|
177
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.fid_hardware INFO Det temp max: 10
|
|
178
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.fid_hardware INFO TEC R298: 0
|
|
179
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.fid_hardware INFO TEC beta: 0
|
|
180
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.fid_hardware INFO Detector name: S10141
|
|
181
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.fid_hardware INFO Pixels: 1024
|
|
182
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.fid_hardware INFO Pixel height: 1
|
|
183
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.fid_hardware INFO Min integration: 1
|
|
184
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.fid_hardware INFO Max integration: 60000
|
|
185
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.fid_hardware INFO Bad Pixels: []
|
|
186
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.devices INFO Connected to 0x24aa:0x1000
|
|
187
|
+
2018-01-22 15:20:12,505 MainProcess wasatch.devices INFO Connected to feature identification device
|
|
188
|
+
2018-01-22 15:20:12,520 MainProcess wasatch.devices INFO Serial: WP-00154
|
|
189
|
+
2018-01-22 15:20:12,520 MainProcess wasatch.devices INFO Firmware: 10.0.0.6
|
|
190
|
+
2018-01-22 15:20:12,520 MainProcess wasatch.devices INFO Int Time: 100
|
|
191
|
+
2018-01-22 15:20:12,520 MainProcess wasatch.devices INFO FPGA: 026-007
|
|
192
|
+
2018-01-22 15:20:12,520 MainProcess wasatch.devices INFO Gain: 1.90234375
|
|
193
|
+
2018-01-22 15:20:12,520 MainProcess wasatch.devices INFO Model: VIS
|
|
194
|
+
2018-01-22 15:20:12,520 MainProcess __main__ INFO connect: device connected
|
|
195
|
+
2018-01-22 15:20:12,520 MainProcess __main__ INFO Press Control-Break to interrupt...
|
|
196
|
+
2018-01-22 15:20:12,630 MainProcess __main__ INFO Reading: 1 Detector: 66.00 degC Min: 909.00 Max: 31491.00 Avg: 2097.14
|
|
197
|
+
2018-01-22 15:20:13,115 MainProcess __main__ INFO Reading: 2 Detector: 66.00 degC Min: 911.00 Max: 31394.00 Avg: 2097.02
|
|
198
|
+
2018-01-22 15:20:13,630 MainProcess __main__ INFO Reading: 3 Detector: 66.00 degC Min: 916.00 Max: 31253.00 Avg: 2097.88
|
|
199
|
+
2018-01-22 15:20:14,145 MainProcess __main__ INFO Reading: 4 Detector: 66.00 degC Min: 916.00 Max: 31432.00 Avg: 2098.49
|
|
200
|
+
2018-01-22 15:20:14,661 MainProcess __main__ INFO Reading: 5 Detector: 66.00 degC Min: 913.00 Max: 31460.00 Avg: 2097.57
|
|
201
|
+
^C
|
|
202
|
+
|
|
203
|
+
Z:\work\code\Wasatch.PY>head data.csv | cut -c1-50
|
|
204
|
+
time,temp,399.24,399.68,400.11,400.55,400.98,401.4 # header row + wavelengths
|
|
205
|
+
2018-01-22 15:20:12.630000,66.00,909.00,945.00,953
|
|
206
|
+
2018-01-22 15:20:13.115000,66.00,918.00,920.00,932
|
|
207
|
+
2018-01-22 15:20:13.630000,66.00,916.00,937.00,945
|
|
208
|
+
2018-01-22 15:20:14.146000,66.00,916.00,924.00,956
|
|
209
|
+
2018-01-22 15:20:14.661000,66.00,913.00,941.00,951
|
|
210
|
+
|
|
211
|
+
## Raspberry Pi
|
|
212
|
+
|
|
213
|
+
A standalone Raspberry Pi "Quick Start" tutorial is available here:
|
|
214
|
+
|
|
215
|
+
- [README RPI](https://github.com/WasatchPhotonics/Wasatch.PY/blob/master/README_RPI.md)
|
|
216
|
+
|
|
217
|
+
## Linux
|
|
218
|
+
|
|
219
|
+
**IMPORTANT:** For Linux, you must copy the file udev/10-wasatch.rules from the
|
|
220
|
+
Wasatch.PY distribution to /etc/udev/rules.d, then HUP udev or reboot. This will
|
|
221
|
+
require root (sudo) privs, and is required to give userland applications access
|
|
222
|
+
to USB devices matching Wasatch VID/PID.
|
|
223
|
+
|
|
224
|
+
The following was tested under Ubuntu 16.04 LTS:
|
|
225
|
+
|
|
226
|
+
$ uname -a
|
|
227
|
+
Linux ubuntu 4.4.0-59-generic #80-Ubuntu SMP Fri Jan 6 17:47:47 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
|
|
228
|
+
|
|
229
|
+
$ conda update -q conda
|
|
230
|
+
$ ln -s environments/conda-linux.yml environment.yml
|
|
231
|
+
$ conda env create -n wasatch3
|
|
232
|
+
$ source activate wasatch3
|
|
233
|
+
|
|
234
|
+
(wasatch) ubuntu [~/work/code/Wasatch.PY] parallels 07:17 PM $ python demo.py
|
|
235
|
+
2018-01-22 19:17:12,041 MainProcess wasatch.fid_hardware INFO reading EEPROM page 1
|
|
236
|
+
2018-01-22 19:17:12,052 MainProcess wasatch.fid_hardware INFO reading EEPROM page 0
|
|
237
|
+
2018-01-22 19:17:12,061 MainProcess wasatch.fid_hardware INFO reading EEPROM page 2
|
|
238
|
+
2018-01-22 19:17:12,071 MainProcess wasatch.fid_hardware INFO reading EEPROM page 5
|
|
239
|
+
2018-01-22 19:17:12,081 MainProcess wasatch.fid_hardware INFO EEPROM settings:
|
|
240
|
+
2018-01-22 19:17:12,081 MainProcess wasatch.fid_hardware INFO Wavecal coeff0: 399.24130249
|
|
241
|
+
2018-01-22 19:17:12,082 MainProcess wasatch.fid_hardware INFO Wavecal coeff1: 0.43601000309
|
|
242
|
+
2018-01-22 19:17:12,082 MainProcess wasatch.fid_hardware INFO Wavecal coeff2: -7.33139968361e-05
|
|
243
|
+
2018-01-22 19:17:12,082 MainProcess wasatch.fid_hardware INFO Wavecal coeff3: 2.80489995674e-08
|
|
244
|
+
2018-01-22 19:17:12,082 MainProcess wasatch.fid_hardware INFO Calibration date: 6/2
|
|
245
|
+
2018-01-22 19:17:12,083 MainProcess wasatch.fid_hardware INFO Calibrated by: NH
|
|
246
|
+
2018-01-22 19:17:12,083 MainProcess wasatch.fid_hardware INFO Excitation (nm): 0
|
|
247
|
+
2018-01-22 19:17:12,083 MainProcess wasatch.fid_hardware INFO Slit size (um): 50
|
|
248
|
+
2018-01-22 19:17:12,083 MainProcess wasatch.fid_hardware INFO degCToDAC coeff0: 6.30511975963e-10
|
|
249
|
+
2018-01-22 19:17:12,083 MainProcess wasatch.fid_hardware INFO degCToDAC coeff1: 1.68748300666e-07
|
|
250
|
+
2018-01-22 19:17:12,083 MainProcess wasatch.fid_hardware INFO degCToDAC coeff2: 0.10000000149
|
|
251
|
+
2018-01-22 19:17:12,083 MainProcess wasatch.fid_hardware INFO adcToDegC coeff0: 66.0
|
|
252
|
+
2018-01-22 19:17:12,084 MainProcess wasatch.fid_hardware INFO adcToDegC coeff1: -0.00999999977648
|
|
253
|
+
2018-01-22 19:17:12,084 MainProcess wasatch.fid_hardware INFO adcToDegC coeff2: -9.99999974738e-05
|
|
254
|
+
2018-01-22 19:17:12,084 MainProcess wasatch.fid_hardware INFO Det temp min: 20
|
|
255
|
+
2018-01-22 19:17:12,084 MainProcess wasatch.fid_hardware INFO Det temp max: 10
|
|
256
|
+
2018-01-22 19:17:12,084 MainProcess wasatch.fid_hardware INFO TEC R298: 0
|
|
257
|
+
2018-01-22 19:17:12,084 MainProcess wasatch.fid_hardware INFO TEC beta: 0
|
|
258
|
+
2018-01-22 19:17:12,084 MainProcess wasatch.fid_hardware INFO Detector name: S10141
|
|
259
|
+
2018-01-22 19:17:12,084 MainProcess wasatch.fid_hardware INFO Pixels: 1024
|
|
260
|
+
2018-01-22 19:17:12,085 MainProcess wasatch.fid_hardware INFO Pixel height: 1
|
|
261
|
+
2018-01-22 19:17:12,085 MainProcess wasatch.fid_hardware INFO Min integration: 1
|
|
262
|
+
2018-01-22 19:17:12,085 MainProcess wasatch.fid_hardware INFO Max integration: 60000
|
|
263
|
+
2018-01-22 19:17:12,085 MainProcess wasatch.fid_hardware INFO Bad Pixels: []
|
|
264
|
+
2018-01-22 19:17:12,085 MainProcess wasatch.devices INFO Connected to 0x24aa:0x1000
|
|
265
|
+
2018-01-22 19:17:12,085 MainProcess wasatch.devices INFO Connected to feature identification device
|
|
266
|
+
2018-01-22 19:17:12,112 MainProcess wasatch.devices INFO Serial: WP-00154
|
|
267
|
+
2018-01-22 19:17:12,112 MainProcess wasatch.devices INFO Firmware: 10.0.0.6
|
|
268
|
+
2018-01-22 19:17:12,112 MainProcess wasatch.devices INFO Int Time: 0
|
|
269
|
+
2018-01-22 19:17:12,112 MainProcess wasatch.devices INFO FPGA: 026-007
|
|
270
|
+
2018-01-22 19:17:12,113 MainProcess wasatch.devices INFO Gain: 1.90234375
|
|
271
|
+
2018-01-22 19:17:12,113 MainProcess wasatch.devices INFO Model: VIS
|
|
272
|
+
2018-01-22 19:17:12,113 MainProcess __main__ INFO connect: device connected
|
|
273
|
+
2018-01-22 19:17:12,113 MainProcess __main__ INFO Press Control-Break to interrupt...
|
|
274
|
+
2018-01-22 19:17:12,129 MainProcess __main__ INFO Reading: 1 Detector: 66.00 degC Min: 812.00 Max: 1333.00 Avg: 846.03
|
|
275
|
+
2018-01-22 19:17:13,136 MainProcess __main__ INFO Reading: 2 Detector: 66.00 degC Min: 819.00 Max: 3068.00 Avg: 900.29
|
|
276
|
+
2018-01-22 19:17:14,136 MainProcess __main__ INFO Reading: 3 Detector: 66.00 degC Min: 825.00 Max: 3043.00 Avg: 900.32
|
|
277
|
+
2018-01-22 19:17:15,138 MainProcess __main__ INFO Reading: 4 Detector: 66.00 degC Min: 821.00 Max: 3119.00 Avg: 901.80
|
|
278
|
+
2018-01-22 19:17:16,140 MainProcess __main__ INFO Reading: 5 Detector: 66.00 degC Min: 819.00 Max: 981.00 Avg: 844.84
|
|
279
|
+
^C
|
|
280
|
+
|
|
281
|
+
## MacOS
|
|
282
|
+
|
|
283
|
+
The following was tested under MacOS 10.13.2 ("High Sierra"):
|
|
284
|
+
|
|
285
|
+
$ conda update -q conda
|
|
286
|
+
$ ln -s environments/conda-macos.yml environment.yml
|
|
287
|
+
$ conda env create -n wasatch3
|
|
288
|
+
Solving environment: done
|
|
289
|
+
Preparing transaction: done
|
|
290
|
+
Verifying transaction: done
|
|
291
|
+
Executing transaction: done
|
|
292
|
+
Collecting future==0.16.0 (from -r /Users/mzieg/work/code/Wasatch.PY/condaenv.LqSNvr.requirements.txt (line 1))
|
|
293
|
+
Collecting pygtail==0.7.0 (from -r /Users/mzieg/work/code/Wasatch.PY/condaenv.LqSNvr.requirements.txt (line 2))
|
|
294
|
+
Collecting pyusb==1.0.0 (from -r /Users/mzieg/work/code/Wasatch.PY/condaenv.LqSNvr.requirements.txt (line 3))
|
|
295
|
+
Collecting requests==2.13.0 (from -r /Users/mzieg/work/code/Wasatch.PY/condaenv.LqSNvr.requirements.txt (line 4))
|
|
296
|
+
Using cached requests-2.13.0-py2.py3-none-any.whl
|
|
297
|
+
Installing collected packages: future, pygtail, pyusb, requests
|
|
298
|
+
Successfully installed future-0.16.0 pygtail-0.7.0 pyusb-1.0.0 requests-2.13.0
|
|
299
|
+
$ source activate wasatch
|
|
300
|
+
$ python demo.py --outfile spectra.csv
|
|
301
|
+
2018-01-22 16:45:10,611 MainProcess __main__ INFO connect: device connected
|
|
302
|
+
2018-01-22 16:45:10,611 MainProcess __main__ INFO Press Control-Break to interrupt...
|
|
303
|
+
2018-01-22 16:45:10,628 MainProcess __main__ INFO Reading: 1 Detector: 66.00 degC Min: 833.00 Max: 3888.00 Avg: 940.95
|
|
304
|
+
2018-01-22 16:45:11,631 MainProcess __main__ INFO Reading: 2 Detector: 66.00 degC Min: 829.00 Max: 3897.00 Avg: 940.13
|
|
305
|
+
2018-01-22 16:45:12,635 MainProcess __main__ INFO Reading: 3 Detector: 66.00 degC Min: 829.00 Max: 3909.00 Avg: 941.80
|
|
306
|
+
2018-01-22 16:45:13,637 MainProcess __main__ INFO Reading: 4 Detector: 66.00 degC Min: 829.00 Max: 3878.00 Avg: 940.21
|
|
307
|
+
|
|
308
|
+
# Environment Variables
|
|
309
|
+
|
|
310
|
+
The following environment variables affect the operation of Wasatch.PY:
|
|
311
|
+
|
|
312
|
+
- DISABLE_GEN15
|
|
313
|
+
- if defined, SpectrometerSettings.is_gen15() always returns False
|
|
314
|
+
- SPI_PIN_READY
|
|
315
|
+
- if defined, remaps the FT232H pin for the SPI "DATA_READY" signal (default "D5")
|
|
316
|
+
- SPI_PIN_TRIGGER
|
|
317
|
+
- if defined, remaps the FT232H pin for the SPI "TRIGGER" signal (default "D6")
|
|
318
|
+
- SPI_BLOCK_SIZE
|
|
319
|
+
- if defined, set the number of bytes read in a block over USB during SPI acquisitions (default 256)
|
|
320
|
+
- SPI_BAUD_MHZ
|
|
321
|
+
- if defined, set the SPI baud rate in MHz (default 10 MHz)
|
|
322
|
+
|
|
323
|
+
# Common Errors
|
|
324
|
+
|
|
325
|
+
## PyUSB usb.core error: No backend available (Windows)
|
|
326
|
+
|
|
327
|
+
I have seen this occur when the default device driver for 0x24aa:0x1000 had been
|
|
328
|
+
switched for FX2 firmware updates. Solution was:
|
|
329
|
+
|
|
330
|
+
- Device Manager -> Universal Serial Bus controllers -> Wasatch Photonics device -> Update Driver -> Browse My Computer -> Let Me Pick -> Wasatch Photonics Spectrometer
|
|
331
|
+
|
|
332
|
+
Spectrometer should then appear in Device Manager under "libusb-win32 devices"
|
|
333
|
+
|
|
334
|
+
## LIBUSB error: No backend available (MacOS)
|
|
335
|
+
|
|
336
|
+
Using [Homebrew](https://brew.sh/), type:
|
|
337
|
+
|
|
338
|
+
$ brew install libusb
|
|
339
|
+
|
|
340
|
+
# Backlog
|
|
341
|
+
|
|
342
|
+
- update .inf files to deprecate "Stroker"
|
|
343
|
+
|
|
344
|
+
# Version History
|
|
345
|
+
|
|
346
|
+
See [Changelog](CHANGELOG.md)
|
|
347
|
+
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
wasatch/AbstractUSBDevice.py,sha256=7RMtaM9cGERgVgz-1hN17kYnjtTNQGq76Yyve3Gmhq8,387
|
|
2
|
+
wasatch/AndorDevice.py,sha256=_2AyN94kKMB6-BKB5CyjjMHSjqkY8-N0FqKgIfMU4NY,40481
|
|
3
|
+
wasatch/AreaScanImage.py,sha256=0_2DR0IcBGQe0KcyFp3IZiKVd3pmjW-qynar-z-is5E,826
|
|
4
|
+
wasatch/AutoRaman.py,sha256=-DT6oGDG8uxoM3uoCwvZTDthyxCBY_FQ1NkJeFfjosc,19557
|
|
5
|
+
wasatch/AutoRamanRequest.py,sha256=loHDsl6Swz4kyzhJPnmzp80xPt9on669xo5u5LVIKic,5984
|
|
6
|
+
wasatch/BLEDevice.py,sha256=wcEsszjXaERqgVETmBuI6CiyoUETITKRY2bh0ggp1Sg,43455
|
|
7
|
+
wasatch/BalanceAcquisition.py,sha256=8Sat6e1R2UH1uXaYYaAh991QUeNYHLJKSeOt6jwP0TE,4779
|
|
8
|
+
wasatch/CSVLoader.py,sha256=NHpCLDaMzVWTIBZrM7ZkDyg2bcSox_OM9fDuZvNyuX4,8614
|
|
9
|
+
wasatch/CommandSettings.py,sha256=EF4ygU77x2M59-YhwJp6kKjPA2VaRUpxU7DUoR2JRlM,3482
|
|
10
|
+
wasatch/ControlObject.py,sha256=-vZGTWKmOkRQwpCLNy7b0af1a0fYQSDXqUq-a498yjU,661
|
|
11
|
+
wasatch/DetectorROI.py,sha256=oBO--nkTHGJggckPLSvVpb1rtN4egDWXdufeeknbXAs,1062
|
|
12
|
+
wasatch/DetectorRegions.py,sha256=xlC92ep0-ULyV61zKS1gziC_pi1Emb7ZbbMxHHrtojo,6241
|
|
13
|
+
wasatch/DeviceFinderBLE.py,sha256=P8F2BH9Be-QX3mHgW-Th6iwN9ZtNyk8_6SmY6_MjsR4,4206
|
|
14
|
+
wasatch/DeviceFinderTCP.py,sha256=Gpm3zjKJXA__RzvTwHlNT7xf6Khnwx-ocjdrzKCZJcU,401
|
|
15
|
+
wasatch/DeviceFinderUSB.py,sha256=NJpnRoLenWf7f_lcfkJ-vuO67FXyYhYX9SjAli93x-4,11724
|
|
16
|
+
wasatch/DeviceID.py,sha256=pCI34Wnmg_YdhiBmOISc1jdUmanmRooYty60ILquvMA,14255
|
|
17
|
+
wasatch/EEPROM.py,sha256=y1DWgHtNcXlwonAGH3M8c6JDrqRWFIFqhL2VzBQqGBQ,68325
|
|
18
|
+
wasatch/EEPROM_multical.sav,sha256=jHZ8pX9O_a0Vdblwy7uWnzICOe-9CVP6Bod1nx8_yag,1712
|
|
19
|
+
wasatch/FPGAOptions.py,sha256=J0s3ofEWMaaLi5Zpm96UIGZnv5MOuFjao5DWMMGZmPM,4387
|
|
20
|
+
wasatch/FeatureIdentificationDevice.py,sha256=pIQbGVMkvp6KIs9evhHvW0N-cGtjPPKZblz4kyzanxk,177861
|
|
21
|
+
wasatch/FirmwareRequirements.py,sha256=qTBe2rV4WG2rzHERs4JCYoQW6RLNaor1ziw98nqjf0k,3263
|
|
22
|
+
wasatch/HardwareInfo.py,sha256=kkCu--AiY5WT8ceYTe3DS7u4sq73IjV4HCC-cDFtnD8,1095
|
|
23
|
+
wasatch/IDSCamera.py,sha256=VCcAdTHnhs39vi3B-vPRLseTc4ffiW3uL68FKcEiHDg,42025
|
|
24
|
+
wasatch/IDSDevice.py,sha256=0ejlxxETD3BlwILPG5MhlLwJhP20S6FQhkv8tTnAhuQ,13227
|
|
25
|
+
wasatch/IMX385.py,sha256=qb86xneWY3pO1nI3McnAdmHUC3pPfa4peGV4kvwaTWY,40038
|
|
26
|
+
wasatch/InterfaceDevice.py,sha256=MKGmolvkywgl27f1NbJ6G3DDNRbZU7w1Vq5hjNT8lQY,1903
|
|
27
|
+
wasatch/MockUSBDevice.py,sha256=YhNAbE6qIWNJHjzdvjHT6zhikH8AtX6j9g2DuWPAg9E,13398
|
|
28
|
+
wasatch/OceanDevice.py,sha256=2VjXEXT-JQOtk_qu6lVx6AUuCA4MHuIrQzDFTzygnIg,9794
|
|
29
|
+
wasatch/PollStatus.py,sha256=fPwHaVkwchn-Gm6-WTtk46JH7FRu6PM7-eEc38wm-zg,373
|
|
30
|
+
wasatch/ProcessedReading.py,sha256=lIQdp9Lk5vtGrYNCTXUza4E-biTB3RvH_i7QuVSgjJM,15072
|
|
31
|
+
wasatch/ROI.py,sha256=NM5IwFwCXlrimH4pmIbV_fk6NErnCqrtuVFfjhxsyiw,914
|
|
32
|
+
wasatch/Reading.py,sha256=pDpIUx6y_hwiBLZfmp-MHdEXzdz0Xxe2Ascu0SZUWR0,3384
|
|
33
|
+
wasatch/RealUSBDevice.py,sha256=R637KtgL7_lPtCvNG8_0l1-Ho0HZMfrh7cmHLlTsK_A,1679
|
|
34
|
+
wasatch/SPIDevice.py,sha256=DgAFXoftmjRTpwhdqRJ4IFZD_HG801dFA4BAViX9J1E,28638
|
|
35
|
+
wasatch/SpectrometerRequest.py,sha256=PLWSPWEETH5QcxvS3DAylU2VGhgEtrFh4CniZpl5h1E,415
|
|
36
|
+
wasatch/SpectrometerResponse.py,sha256=-LiV6h3RxT41BEiLRRu6IkqVJwVAErlKpIuC8_OiaSo,1233
|
|
37
|
+
wasatch/SpectrometerSettings.py,sha256=Y5KdIiI8YuJqUCTyl5gAeW49Tbv0AgJuPMJJhTa-eaw,17122
|
|
38
|
+
wasatch/SpectrometerState.py,sha256=NknNJP7AgvAmaj1DVawE5hD44SkwEFNqNIAgQHkXV2s,11144
|
|
39
|
+
wasatch/StatusMessage.py,sha256=2IpeCAwDfRvtrHoXDAtfsyC1ygWl4m8n1_wF41_2_3E,571
|
|
40
|
+
wasatch/TCPDevice.py,sha256=QhWCJcqIiV9_LubDkaFdbHJYt0_cDEBO9bJ99dTd4sw,14870
|
|
41
|
+
wasatch/TakeOneRequest.py,sha256=fkypNvPUEI-KkzZ_QlLzZefumHDEEUZPCmqNPtRSjZg,2110
|
|
42
|
+
wasatch/WasatchBus.py,sha256=qlOfJgBmchpEjucY3FeTtNe2T0mHDwSvH_aaG7VF_OA,2778
|
|
43
|
+
wasatch/WasatchDevice.py,sha256=HhwiXXFAHfNrQVKhNmro3AUeh3OQUjMi2F1DXWUTIPM,51723
|
|
44
|
+
wasatch/WasatchDeviceWrapper.py,sha256=GDit8N8T86cJsgOSUqI8wMKpPCaY1R4gY8ehgV6wzZE,21596
|
|
45
|
+
wasatch/WrapperWorker.py,sha256=c-V0nTCn3Ar1pLIE6x1mbygUaI6-ix-yJWaHGH7S2c0,13717
|
|
46
|
+
wasatch/__init__.py,sha256=CMcnT73I4elRhp5H4BiZ4mpj6ynVYZbDEtyuE6s5xy0,172
|
|
47
|
+
wasatch/applog.py,sha256=tv73qZqA64dF33xnKu3nOu8cduKShAkl898k1wYaUGw,6646
|
|
48
|
+
wasatch/simulation_protocol.py,sha256=N8tVgXL7obGptUDgnFLymhdKPcTjN3MlFlCjnUFd_vE,8545
|
|
49
|
+
wasatch/utils.py,sha256=otSth8QnYMRyH6LckYDoiHfXGWPO3Z8dnf5gXmSrNZU,23977
|
|
50
|
+
wasatch-2.3.2.dist-info/LICENSE,sha256=6zhlhB0AYuYkzBwmT7QaUTWJWecvusd6P-V4WFNcSNQ,1074
|
|
51
|
+
wasatch-2.3.2.dist-info/WHEEL,sha256=EZbGkh7Ie4PoZfRQ8I0ZuP9VklN_TvcZ6DSE5Uar4z4,81
|
|
52
|
+
wasatch-2.3.2.dist-info/METADATA,sha256=c31EniR0Ic6oK2BVCdomJeIQ6pGAQ5j-A_v8RTlpuoo,21467
|
|
53
|
+
wasatch-2.3.2.dist-info/RECORD,,
|