started adding rigol scope stuff

This commit is contained in:
Eljakim 2024-07-16 18:49:39 +02:00
parent 172224cfdb
commit d209a6b4a4
5 changed files with 46 additions and 2 deletions

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
venv/

24
.vscode/launch.json vendored Normal file
View File

@ -0,0 +1,24 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Attempt license upgrade",
"type": "debugpy",
"request": "launch",
"program": "license_upgrade.py",
"console": "integratedTerminal",
"args": ["192.168.1.142"]
},
{
"name": "Remote scope tests",
"type": "debugpy",
"request": "launch",
"program": "remote_scope.py",
"console": "integratedTerminal",
"args": ["172.17.99.12"]
}
]
}

View File

@ -1,9 +1,9 @@
# Rigol
# Rigol
Script from the EEVBlog, that will activate all options on a rigol scope.
## Usage:
```
python3 rigol_kg.py 192.168.1.142
python3 license_upgrade.py 192.168.1.142
```
I had to force enable overwriting the key:

19
remote_scope.py Normal file
View File

@ -0,0 +1,19 @@
import sys, matplotlib
from pymso5000.mso5000 import MSO5000
with MSO5000(address = "172.17.99.12") as mso:
print(f"Identify: {mso.identify()}")
mso.set_channel_enable(0, True)
mso.set_channel_enable(1, True)
data = mso.query_waveform((0, 1))
print(data)
import matplotlib.pyplot as plt
plt.plot(data['x'], data['y0'], label = "Ch1")
plt.plot(data['x'], data['y1'], label = "Ch2")
plt.show()
if __name__ == "__main__":
pass