Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Lu Xu
slapos
Commits
6bca7aa8
Commit
6bca7aa8
authored
Jan 09, 2024
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
09f73362
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
32 additions
and
15 deletions
+32
-15
software/ors-amarisoft/config/enb.jinja2.cfg
software/ors-amarisoft/config/enb.jinja2.cfg
+1
-1
software/ors-amarisoft/config/out/CELL__a-drb.cfg
software/ors-amarisoft/config/out/CELL__a-drb.cfg
+0
-0
software/ors-amarisoft/config/out/CELL__a-sib23.asn
software/ors-amarisoft/config/out/CELL__a-sib23.asn
+0
-0
software/ors-amarisoft/config/out/CELL__b-drb.cfg
software/ors-amarisoft/config/out/CELL__b-drb.cfg
+0
-0
software/ors-amarisoft/config/out/CELL__b-sib23.asn
software/ors-amarisoft/config/out/CELL__b-sib23.asn
+0
-0
software/ors-amarisoft/config/out/enb.cfg
software/ors-amarisoft/config/out/enb.cfg
+8
-8
software/ors-amarisoft/config/out/ue.cfg
software/ors-amarisoft/config/out/ue.cfg
+2
-2
software/ors-amarisoft/slaplte.jinja2
software/ors-amarisoft/slaplte.jinja2
+5
-1
software/ors-amarisoft/slapos-render-config.py
software/ors-amarisoft/slapos-render-config.py
+16
-3
No files found.
software/ors-amarisoft/config/enb.jinja2.cfg
View file @
6bca7aa8
{%- import 'slaplte.jinja2' as slaplte with context %}
{%- import 'slaplte.jinja2' as slaplte with context %}
{%- set B = slaplte.B %}
{%- set J = slaplte.J %}
{%- set J = slaplte.J %}
{%- set jcell_ru_ref = slaplte.jcell_ru_ref %}
{%- set jcell_ru_ref = slaplte.jcell_ru_ref %}
{%- set B = xbuildout.encode %}
{#- for standalone testing via slapos-render-config.py
{#- for standalone testing via slapos-render-config.py
NOTE: keep in sync with instance-enb.jinja2.cfg and ru/libinstance.jinja2.cfg #}
NOTE: keep in sync with instance-enb.jinja2.cfg and ru/libinstance.jinja2.cfg #}
...
...
software/ors-amarisoft/config/out/CELL_a-drb.cfg
→
software/ors-amarisoft/config/out/CELL_
_
a-drb.cfg
View file @
6bca7aa8
File moved
software/ors-amarisoft/config/out/CELL_a-sib23.asn
→
software/ors-amarisoft/config/out/CELL_
_
a-sib23.asn
View file @
6bca7aa8
File moved
software/ors-amarisoft/config/out/CELL_b-drb.cfg
→
software/ors-amarisoft/config/out/CELL_
_
b-drb.cfg
View file @
6bca7aa8
File moved
software/ors-amarisoft/config/out/CELL_b-sib23.asn
→
software/ors-amarisoft/config/out/CELL_
_
b-sib23.asn
View file @
6bca7aa8
File moved
software/ors-amarisoft/config/out/enb.cfg
View file @
6bca7aa8
...
@@ -48,7 +48,7 @@
...
@@ -48,7 +48,7 @@
// LTE cells
// LTE cells
cell_list: [
cell_list: [
// CELL_a (RU1)
// CELL_
_
a (RU1)
{
{
rf_port: 0,
rf_port: 0,
n_antenna_dl: 2,
n_antenna_dl: 2,
...
@@ -68,7 +68,7 @@
...
@@ -68,7 +68,7 @@
// Intra-ENB HO
// Intra-ENB HO
{
{
rat: "nr",
rat: "nr",
cell_id: 0x02, // -> CELL_b
cell_id: 0x02, // -> CELL_
_
b
},
},
// Inter-ENB HO
// Inter-ENB HO
...
@@ -102,7 +102,7 @@
...
@@ -102,7 +102,7 @@
// Dual Connectivity: LTE + NR
// Dual Connectivity: LTE + NR
en_dc_scg_cell_list: [
en_dc_scg_cell_list: [
{
{
cell_id: 0x02, // + CELL_b
cell_id: 0x02, // + CELL_
_
b
},
},
],
],
...
@@ -140,11 +140,11 @@
...
@@ -140,11 +140,11 @@
srs_hopping_bandwidth: 0,
srs_hopping_bandwidth: 0,
},
},
drb_config: "CELL_a-drb.cfg",
drb_config: "CELL_
_
a-drb.cfg",
sib_sched_list: [
sib_sched_list: [
{
{
filename: "CELL_a-sib23.asn",
filename: "CELL_
_
a-sib23.asn",
si_periodicity: 16,
si_periodicity: 16,
},
},
],
],
...
@@ -242,7 +242,7 @@
...
@@ -242,7 +242,7 @@
// NR cells
// NR cells
nr_cell_list: [
nr_cell_list: [
// CELL_b (RU2)
// CELL_
_
b (RU2)
{
{
rf_port: 1,
rf_port: 1,
n_antenna_dl: 2,
n_antenna_dl: 2,
...
@@ -267,7 +267,7 @@
...
@@ -267,7 +267,7 @@
// Intra-ENB HO
// Intra-ENB HO
{
{
rat: "eutra",
rat: "eutra",
cell_id: 0x1001201, // -> CELL_a
cell_id: 0x1001201, // -> CELL_
_
a
n_id_cell: 1,
n_id_cell: 1,
dl_earfcn: 38050,
dl_earfcn: 38050,
tac: 0x1234,
tac: 0x1234,
...
@@ -438,7 +438,7 @@
...
@@ -438,7 +438,7 @@
},
},
drb_config: "CELL_b-drb.cfg",
drb_config: "CELL_
_
b-drb.cfg",
},
},
],
],
...
...
software/ors-amarisoft/config/out/ue.cfg
View file @
6bca7aa8
...
@@ -12,8 +12,8 @@
...
@@ -12,8 +12,8 @@
// XXX vvv <- ru.txrx_active ? XXX how to handle txrx_active for SDR ?
// XXX vvv <- ru.txrx_active ? XXX how to handle txrx_active for SDR ?
// (tx_gain=-1000 does not work - it still sets tx_gain to min.possible value 14)
// (tx_gain=-1000 does not work - it still sets tx_gain to min.possible value 14)
name: "sdr",
name: "sdr",
// _
UCELL1
_ru 2T1R (sdr)
// _
_UCELL1_
_ru 2T1R (sdr)
// _
UCELL2
_ru 2T2R (sdr)
// _
_UCELL2_
_ru 2T2R (sdr)
args: "dev0=/dev/sdr0,dev1=/dev/sdr2",
args: "dev0=/dev/sdr0,dev1=/dev/sdr2",
rx_antenna:"tx_rx",
rx_antenna:"tx_rx",
tdd_tx_mod: 1,
tdd_tx_mod: 1,
...
...
software/ors-amarisoft/slaplte.jinja2
View file @
6bca7aa8
...
@@ -79,6 +79,10 @@
...
@@ -79,6 +79,10 @@
}
}
%}
%}
{#- XXX explain #}
{%- set B = xbuildout.encode %}
{#- J is used around macro calls to retrieve returned objects.
{#- J is used around macro calls to retrieve returned objects.
It is needed to workaround jinja2 limitation that macro can return only
It is needed to workaround jinja2 limitation that macro can return only
...
@@ -419,7 +423,7 @@
...
@@ -419,7 +423,7 @@
{%- set rx_gainv = [] %} {#- rx_gain by rx channel #}
{%- set rx_gainv = [] %} {#- rx_gain by rx channel #}
{%- for (ru_ref, iru) in iru_dict.items() | sort(attribute="1._._rf_port") %}
{%- for (ru_ref, iru) in iru_dict.items() | sort(attribute="1._._rf_port") %}
{%- set ru = iru['_'] %}
{%- set ru = iru['_'] %}
// {{
dumps
(ru_ref) }} {{ ru.n_antenna_dl }}T{{ ru.n_antenna_ul }}R ({{ ru.ru_type }})
// {{
B
(ru_ref) }} {{ ru.n_antenna_dl }}T{{ ru.n_antenna_ul }}R ({{ ru.ru_type }})
{%- if ru.ru_type == 'sdr' %}
{%- if ru.ru_type == 'sdr' %}
{%- do ru_sdr_dict.update({len(dev_argv): ru}) %}
{%- do ru_sdr_dict.update({len(dev_argv): ru}) %}
{%- for n in ru.sdr_dev_list %}
{%- for n in ru.sdr_dev_list %}
...
...
software/ors-amarisoft/slapos-render-config.py
View file @
6bca7aa8
...
@@ -6,7 +6,19 @@
...
@@ -6,7 +6,19 @@
import
zc.buildout.buildout
# XXX workaround for https://lab.nexedi.com/nexedi/slapos.recipe.template/merge_requests/9
import
zc.buildout.buildout
# XXX workaround for https://lab.nexedi.com/nexedi/slapos.recipe.template/merge_requests/9
from
slapos.recipe.template
import
jinja2_template
from
slapos.recipe.template
import
jinja2_template
import
json
,
copy
,
sys
,
os
,
pprint
,
glob
import
json
,
copy
,
sys
,
os
,
pprint
,
glob
,
types
# ~ import xbuildout (see instance.cfg:activate-eggs)
def
readfile
(
path
):
with
open
(
path
)
as
f
:
return
f
.
read
()
xbuildout
=
types
.
ModuleType
(
'xbuildout'
)
exec
(
readfile
(
'ru/xbuildout.py'
),
xbuildout
.
__dict__
)
assert
'xbuildout'
not
in
sys
.
modules
sys
.
modules
[
'xbuildout'
]
=
xbuildout
B
=
xbuildout
.
encode
# j2render renders config/<src> into config/out/<out> with provided json parameters.
# j2render renders config/<src> into config/out/<out> with provided json parameters.
...
@@ -19,6 +31,7 @@ def j2render(src, out, jcfg):
...
@@ -19,6 +31,7 @@ def j2render(src, out, jcfg):
textctx
=
''
textctx
=
''
for
k
,
v
in
ctx
.
items
():
for
k
,
v
in
ctx
.
items
():
textctx
+=
'json %s %s
\
n
'
%
(
k
,
json
.
dumps
(
v
))
textctx
+=
'json %s %s
\
n
'
%
(
k
,
json
.
dumps
(
v
))
textctx
+=
'import xbuildout xbuildout
\
n
'
textctx
+=
'import json_module json
\
n
'
textctx
+=
'import json_module json
\
n
'
textctx
+=
'import nrarfcn_module nrarfcn
\
n
'
textctx
+=
'import nrarfcn_module nrarfcn
\
n
'
textctx
+=
'import xearfcn_module xlte.earfcn
\
n
'
textctx
+=
'import xearfcn_module xlte.earfcn
\
n
'
...
@@ -466,11 +479,11 @@ def do_enb():
...
@@ -466,11 +479,11 @@ def do_enb():
'ru'
:
ru
,
'ru'
:
ru
,
})
})
j2render
(
'drb_%s.jinja2.cfg'
%
cell
[
'cell_type'
],
j2render
(
'drb_%s.jinja2.cfg'
%
cell
[
'cell_type'
],
'%s-drb.cfg'
%
cell_ref
,
B
(
'%s-drb.cfg'
%
cell_ref
)
,
jctx
)
jctx
)
j2render
(
'sib23.jinja2.asn'
,
j2render
(
'sib23.jinja2.asn'
,
'%s-sib23.asn'
%
cell_ref
,
B
(
'%s-sib23.asn'
%
cell_ref
)
,
jctx
)
jctx
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment