Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
PyPCC
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
LOFAR2.0
PyPCC
Commits
0bbd543c
Commit
0bbd543c
authored
4 years ago
by
Paulus Kruger
Browse files
Options
Downloads
Patches
Plain Diff
debugging...
parent
a61118f8
No related branches found
No related tags found
1 merge request
!11
Pypcc2
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
config/CLK.yaml
+9
-7
9 additions, 7 deletions
config/CLK.yaml
config/RCU.yaml
+14
-14
14 additions, 14 deletions
config/RCU.yaml
config/UNB2.yaml
+19
-1
19 additions, 1 deletion
config/UNB2.yaml
opcuaserv/yamlreader.py
+4
-2
4 additions, 2 deletions
opcuaserv/yamlreader.py
with
46 additions
and
24 deletions
config/CLK.yaml
+
9
−
7
View file @
0bbd543c
...
...
@@ -105,9 +105,9 @@ variables:
debug
:
True
methods
:
-
name
:
Init
#Called after startup to load. Should have all stored registers
-
name
:
CLK_
Init
#Called after startup to load. Should have all stored registers
driver
:
I2C_CLK
hidden
:
True
debug
:
True
instructions
:
-
CLK_I2C_OK
:
1
-
RCU_IO1_GPIO1
:
Update
...
...
@@ -119,24 +119,26 @@ methods:
-
name
:
CLK_on
driver
:
I2C_CLK
instructions
:
-
CLK_I2C_OK
:
1
-
IO1.CONF1
:
0x2C
#0010 1100 PPS/PWR output, SCLK,CS,SDI
-
IO1.GPIO1
:
0x42
#0100 0010 high:PWR enable, CS
-
CLK_Enable_PWR
:
Update
-
WAIT
:
200
#ms to wait before checking lock
-
CLK_PLL_setup
:
0
-
WAIT
:
100
#ms to wait before checking lock
-
CLK_PLL_locked
:
Update
-
name
:
CLK_off
driver
:
I2C_CLK
instructions
:
-
CLK_I2C_OK
:
1
-
IO1.CONF1
:
0x2C
#0010 1100 PPS/PWR output, SCLK,CS,SDI
-
IO1.GPIO1
:
0x00
#all low
-
CLK_Enable_PWR
:
Update
# - WAIT: 100 #ms to wait before checking lock
# - CLK_PLL_setup: 0
# - WAIT: 100 #ms to wait before checking lock
# - CLK_PLL_locked: Update
-
name
:
CLK_PLL_setup
driver
:
I2C_CLK
debug
:
true
instructions
:
# - PLL.0x03: 0x08 #Set power, this is default
-
PLL.0x05
:
0x17
#was 97, set lock time
...
...
This diff is collapsed.
Click to expand it.
config/RCU.yaml
+
14
−
14
View file @
0bbd543c
...
...
@@ -252,22 +252,22 @@ variables:
description
:
LED on RCU
devreg
:
IO2.GPIO2
bitoffset
:
6
width
:
2
width
:
1
rw
:
rw
dtype
:
uint8
dtype
:
boolean
dim
:
32
mask
:
RCU_mask
#
- name: RCU_LED1
#
driver: I2C_RCU
#
description: LED on RCU
#
devreg: IO2.GPIO2
#
bitoffset: 7
#
width: 1
#
rw: rw
#
dtype: boolean
#
dim: 32
#
mask: RCU_mask
-
name
:
RCU_LED1
driver
:
I2C_RCU
description
:
LED on RCU
devreg
:
IO2.GPIO2
bitoffset
:
7
width
:
1
rw
:
rw
dtype
:
boolean
dim
:
32
mask
:
RCU_mask
-
name
:
RCU_temperature
description
:
Temperature sensor on RCU
...
...
@@ -357,9 +357,9 @@ variables:
mask
:
Ant_mask
methods
:
-
name
:
Init
#Called after startup to load. Should have all stored registers
-
name
:
RCU_
Init
#Called after startup to load. Should have all stored registers
driver
:
I2C_RCU
hidden
:
True
debug
:
True
instructions
:
-
RCU_state
:
2
-
RCU_IO1_GPIO1
:
Update
...
...
This diff is collapsed.
Click to expand it.
config/UNB2.yaml
+
19
−
1
View file @
0bbd543c
...
...
@@ -5,31 +5,44 @@ drivers:
-
name
:
I2C1
type
:
i2c_switch2
devreg
:
[
APSCT_SWITCH.MASK
,
UB2_SWITCH1.MASK
,
UB2_SWITCH2.MASK
]
parameters
:
[
1
,
0
,
0
,
0
]
#I2C port number, 3x switch reset pins
parameters
:
[
3
,
0
,
0
,
0
]
#I2C port number, 3x switch reset pins
-
name
:
switch_UNB2
type
:
i2c_array
parent
:
I2C1
parameters
:
[
0
,
1
]
mask
:
UNB2_I2C_bus_OK
-
name
:
switch_PS
type
:
i2c_array2
parent
:
I2C1
parameters
:
[
0
,
1
,
4
,
4
]
mask
:
UNB2_I2C_bus_PS_OK
-
name
:
switch_FP
type
:
i2c_array2
parent
:
I2C1
parameters
:
[
0
,
1
,
5
,
5
]
mask
:
UNB2_I2C_bus_FP_OK
-
name
:
switch_QSFP
type
:
i2c_array2
#An array of similar devices connected to an I2C switch
parent
:
I2C1
parameters
:
[
0
,
1
,
0
,
3
,
0
,
3
,
6
,
7
]
#Parameters: APSCT_Switch, main switch, 2nd switch, 2nd switch
mask
:
UNB2_I2C_bus_QSFP_OK
-
name
:
switch_DDR4
type
:
i2c_array2
parent
:
I2C1
parameters
:
[
0
,
1
,
0
,
3
,
4
,
4
]
mask
:
UNB2_I2C_bus_DDR4_OK
-
name
:
switch_FPGA_PS
type
:
i2c_array2
parent
:
I2C1
parameters
:
[
0
,
1
,
0
,
3
,
5
,
5
]
mask
:
UNB2_I2C_bus_FPGA_PS_OK
-
name
:
GPIO
type
:
gpio
...
...
@@ -80,6 +93,11 @@ variables:
rw
:
variable
dtype
:
boolean
dim
:
2
-
name
:
UNB2_I2C_bus_FP_OK
driver
:
switch_UNB2
rw
:
hidden
dtype
:
boolean
dim
:
2
-
name
:
UNB2_I2C_bus_QSFP_OK
driver
:
switch_QSFP
rw
:
variable
...
...
This diff is collapsed.
Click to expand it.
opcuaserv/yamlreader.py
+
4
−
2
View file @
0bbd543c
...
...
@@ -87,8 +87,10 @@ class yamlreader(yamlconfig):
self
.
server
.
callmethod
(
id1
,
mask
)
def
CallInit
(
self
):
v
=
Find
(
self
.
conf
[
'
methods
'
],
'
name
'
,
'
Init
'
);
if
not
(
v
):
return
;
v
=
Find
(
self
.
conf
[
'
methods
'
],
'
name
'
,
self
.
yamlfile
+
'
_Init
'
);
if
not
(
v
):
logging
.
warn
(
self
.
yamlfile
+
"
_Init method not found for initialisation!
"
)
return
;
self
.
server
.
callmethod
(
v
[
'
id
'
],[])
def
setvar
(
self
,
id1
,
data
=
[]):
...
...
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