Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
labcode
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Model registry
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
CST
labcode
Commits
be507a57
Commit
be507a57
authored
Jul 2, 2024
by
Alexandros Asonitis
Browse files
Options
Downloads
Patches
Plain Diff
double gate devices part 2
parent
c4fa1c42
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
hp4155/ADU for double gate devices/lib/interface.py
+26
-12
26 additions, 12 deletions
hp4155/ADU for double gate devices/lib/interface.py
hp4155/ADU for double gate devices/test_interface.ipynb
+165
-0
165 additions, 0 deletions
hp4155/ADU for double gate devices/test_interface.ipynb
with
191 additions
and
12 deletions
hp4155/ADU for double gate devices/lib/interface.py
+
26
−
12
View file @
be507a57
...
...
@@ -18,9 +18,10 @@ def header(name):
return
check
,
integration
def
primary
(
name
,
start
,
step
,
stop
,
comp
):
def
primary
(
name
,
start
,
step
,
stop
,
comp
,
sync
=
False
):
primary_grid
=
GridspecLayout
(
4
,
4
)
primary_grid
[:,
3
]
=
widgets
.
Label
(
name
,
layout
=
Layout
(
height
=
'
auto
'
,
width
=
'
auto
'
))
primary_grid
[:,
3
].
style
.
font_weight
=
'
bold
'
#first line
...
...
@@ -43,6 +44,7 @@ def primary(name,start,step,stop,comp):
primary_grid
[
3
,
1
]
=
widgets
.
BoundedFloatText
(
value
=
0
,
min
=
0
,
max
=
2
,
step
=
0.1
,
layout
=
Layout
(
height
=
'
auto
'
,
width
=
floatbox_width
))
#mind the gap
primary_grid
[
3
,
2
]
=
widgets
.
Dropdown
(
options
=
[
'
SINGle
'
,
'
DOUBle
'
],
value
=
'
SINGle
'
,
layout
=
Layout
(
height
=
'
auto
'
,
width
=
floatbox_width
))
#mind the gap
if
sync
==
False
:
parameters
=
{
'
start
'
:
primary_grid
[
1
,
0
],
'
step
'
:
primary_grid
[
1
,
1
],
...
...
@@ -51,14 +53,24 @@ def primary(name,start,step,stop,comp):
'
hyst
'
:
primary_grid
[
3
,
2
],
'
pcomp
'
:
primary_grid
[
3
,
1
]
}
else
:
# for syncronus smu the step is disabled
primary_grid
[
3
,
2
].
disabled
=
True
primary_grid
[
1
,
1
].
disabled
=
True
parameters
=
{
'
start
'
:
primary_grid
[
1
,
0
],
'
stop
'
:
primary_grid
[
1
,
2
],
'
comp
'
:
primary_grid
[
3
,
0
],
'
pcomp
'
:
primary_grid
[
3
,
1
]
}
return
primary_grid
,
parameters
def
secondary
(
name
,
start
,
step
,
stop
,
comp
):
secondary_grid
=
GridspecLayout
(
4
,
4
)
secondary_grid
[:,
3
]
=
widgets
.
Label
(
name
,
layout
=
Layout
(
height
=
'
auto
'
,
width
=
'
auto
'
))
secondary_grid
[:,
3
].
style
.
font_weight
=
'
bold
'
#first line
secondary_grid
[
0
,
0
]
=
widgets
.
Label
(
"
Start(V)
"
,
layout
=
Layout
(
height
=
'
auto
'
,
width
=
'
auto
'
))
...
...
@@ -136,3 +148,5 @@ def information_box_new():
return
information
# Primary widgets
\ No newline at end of file
This diff is collapsed.
Click to expand it.
hp4155/ADU for double gate devices/test_interface.ipynb
0 → 100644
+
165
−
0
View file @
be507a57
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"id": "81f37cac-ea14-4540-8bc9-78bee248dfbb",
"metadata": {},
"outputs": [],
"source": [
"import sys\n",
"sys.path.insert(0, './lib')\n",
"sys.path.insert(0, '..') #append parent directory\n",
"\n",
"\n",
"from interface import *"
]
},
{
"cell_type": "code",
"execution_count": 2,
"id": "731635ba-6f97-4a65-ad78-ae90b277544b",
"metadata": {},
"outputs": [
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "6a1c46ce094f4cedba334f1421fe41ce",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"VBox(children=(Label(value='Sample Information', layout=Layout(height='auto', width='50%'), style=LabelStyle(f…"
]
},
"metadata": {},
"output_type": "display_data"
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"\n"
]
},
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "51abc969eab146d491ecab2854a4ab39",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"HBox(children=(Checkbox(value=True, description='Transfer Curve', indent=False), Checkbox(value=True, descript…"
]
},
"metadata": {},
"output_type": "display_data"
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"\n"
]
},
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "2ca3777bd9e442c885fbd1cda49d71e3",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"Tab(children=(VBox(children=(Dropdown(description='Integration Time', index=1, layout=Layout(height='auto', wi…"
]
},
"metadata": {},
"output_type": "display_data"
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"\n"
]
}
],
"source": [
"# Create the grids\n",
"#create the information grid\n",
"style = {'description_width': 'initial'}\n",
"sample = information_box_new()\n",
"\n",
"###end of sampling information#######################################\n",
"\n",
"# move checkboxes outside of the tabs\n",
"transfer_check,integration_transfer = header('Transfer Curve')\n",
"output_check,integration_output = header('Output Curve')\n",
"gatediode_check,integration_gatediode=header('Gatediode')\n",
"\n",
"checkboxes = widgets.HBox([transfer_check,output_check,gatediode_check])\n",
"display(checkboxes)\n",
"print()\n",
"\n",
"\n",
"#transfer\n",
"Vds_transfer_widgets,Vds_transfer = secondary('Vds',1,0,1,0.1)\n",
"Vtg_transfer_widgets,Vtg_transfer = primary('Vtg',-7,0.1,7,0.01)\n",
"Vbg_transfer_widgets,Vbg_transfer = primary('Vbg',-50,50/7*0.1,50,0.01,True)\n",
"transfer_box = widgets.VBox([integration_transfer,Vds_transfer_widgets,Vtg_transfer_widgets,Vbg_transfer_widgets])\n",
"\n",
"\n",
"#output\n",
"Vds_output_widgets,Vds_output = primary('Vds',0,0.01,5,0.1)\n",
"Vtg_output_widgets,Vtg_output = secondary('Vtg',2,-1,-8,0.01)\n",
"\n",
"\n",
"output_box = widgets.VBox([integration_output,Vds_output_widgets,Vtg_output_widgets])\n",
"\n",
"#GateDiodde\n",
"Vgs_gatediode_widgets,Vgs_gatediode=primary('Vgs',-8,0.05,2,0.02)\n",
"gatediode_box = widgets.VBox([integration_gatediode,Vgs_gatediode_widgets])\n",
"\n",
"#the tab widget\n",
"children = [transfer_box,output_box,gatediode_box]\n",
"titles = [\"Transfer\",\"Output\",\"Gatediode\"]\n",
"tab = widgets.Tab()\n",
"tab.children = children\n",
"tab.titles = titles\n",
"\n",
"display(tab)\n",
"print()\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "df6835fd-e02c-49cb-aa4e-42fddef69b86",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.12.0"
}
},
"nbformat": 4,
"nbformat_minor": 5
}
%% Cell type:code id:81f37cac-ea14-4540-8bc9-78bee248dfbb tags:
```
python
import
sys
sys
.
path
.
insert
(
0
,
'
./lib
'
)
sys
.
path
.
insert
(
0
,
'
..
'
)
#append parent directory
from
interface
import
*
```
%% Cell type:code id:731635ba-6f97-4a65-ad78-ae90b277544b tags:
```
python
# Create the grids
#create the information grid
style
=
{
'
description_width
'
:
'
initial
'
}
sample
=
information_box_new
()
###end of sampling information#######################################
# move checkboxes outside of the tabs
transfer_check
,
integration_transfer
=
header
(
'
Transfer Curve
'
)
output_check
,
integration_output
=
header
(
'
Output Curve
'
)
gatediode_check
,
integration_gatediode
=
header
(
'
Gatediode
'
)
checkboxes
=
widgets
.
HBox
([
transfer_check
,
output_check
,
gatediode_check
])
display
(
checkboxes
)
print
()
#transfer
Vds_transfer_widgets
,
Vds_transfer
=
secondary
(
'
Vds
'
,
1
,
0
,
1
,
0.1
)
Vtg_transfer_widgets
,
Vtg_transfer
=
primary
(
'
Vtg
'
,
-
7
,
0.1
,
7
,
0.01
)
Vbg_transfer_widgets
,
Vbg_transfer
=
primary
(
'
Vbg
'
,
-
50
,
50
/
7
*
0.1
,
50
,
0.01
,
True
)
transfer_box
=
widgets
.
VBox
([
integration_transfer
,
Vds_transfer_widgets
,
Vtg_transfer_widgets
,
Vbg_transfer_widgets
])
#output
Vds_output_widgets
,
Vds_output
=
primary
(
'
Vds
'
,
0
,
0.01
,
5
,
0.1
)
Vtg_output_widgets
,
Vtg_output
=
secondary
(
'
Vtg
'
,
2
,
-
1
,
-
8
,
0.01
)
output_box
=
widgets
.
VBox
([
integration_output
,
Vds_output_widgets
,
Vtg_output_widgets
])
#GateDiodde
Vgs_gatediode_widgets
,
Vgs_gatediode
=
primary
(
'
Vgs
'
,
-
8
,
0.05
,
2
,
0.02
)
gatediode_box
=
widgets
.
VBox
([
integration_gatediode
,
Vgs_gatediode_widgets
])
#the tab widget
children
=
[
transfer_box
,
output_box
,
gatediode_box
]
titles
=
[
"
Transfer
"
,
"
Output
"
,
"
Gatediode
"
]
tab
=
widgets
.
Tab
()
tab
.
children
=
children
tab
.
titles
=
titles
display
(
tab
)
print
()
```
%% Output
%% Cell type:code id:df6835fd-e02c-49cb-aa4e-42fddef69b86 tags:
```
python
```
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment