Commit df8d1418 authored by Joanne Hugé's avatar Joanne Hugé

Update Release Candidate

parents f5a00747 41f21555
...@@ -4,7 +4,6 @@ ...@@ -4,7 +4,6 @@
[buildout] [buildout]
extends = extends =
../openssl/buildout.cfg ../openssl/buildout.cfg
../patch/buildout.cfg
../perl/buildout.cfg ../perl/buildout.cfg
../pkgconfig/buildout.cfg ../pkgconfig/buildout.cfg
../xz-utils/buildout.cfg ../xz-utils/buildout.cfg
...@@ -21,8 +20,8 @@ parts = ...@@ -21,8 +20,8 @@ parts =
[curl] [curl]
recipe = slapos.recipe.cmmi recipe = slapos.recipe.cmmi
shared = true shared = true
url = https://curl.se/download/curl-8.11.0.tar.xz url = https://curl.se/download/curl-8.12.0.tar.xz
md5sum = 49dd886ac84ed3de693464f78f1ee926 md5sum = 3005f775ce65b301a27f8d43a8c85511
configure-options = configure-options =
--disable-static --disable-static
--disable-ech --disable-ech
...@@ -78,10 +77,6 @@ environment = ...@@ -78,10 +77,6 @@ environment =
PATH=${perl:location}/bin:${pkgconfig:location}/bin:${xz-utils:location}/bin:%(PATH)s PATH=${perl:location}/bin:${pkgconfig:location}/bin:${xz-utils:location}/bin:%(PATH)s
PKG_CONFIG_PATH=${:pkgconfig} PKG_CONFIG_PATH=${:pkgconfig}
LDFLAGS=-Wl,-rpath=${libidn2:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${:OPENSSL}/lib -Wl,-rpath=${nghttp2:location}/lib -Wl,-rpath=${zstd:location}/lib ${:LDFLAGS} LDFLAGS=-Wl,-rpath=${libidn2:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${:OPENSSL}/lib -Wl,-rpath=${nghttp2:location}/lib -Wl,-rpath=${zstd:location}/lib ${:LDFLAGS}
patch-options = -p1
patch-binary = ${patch:location}/bin/patch
patches =
https://github.com/curl/curl/commit/f5c616930b5cf148b1b2632da4f5963ff48bdf88.patch?full_index=1#e6ebcd491dd9d105c26287fe830fd557
[curl-http3] [curl-http3]
<= curl <= curl
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
parts = parts =
gettext gettext
extends = extends =
../libiconv/buildout.cfg
../libxml2/buildout.cfg ../libxml2/buildout.cfg
../lunzip/buildout.cfg ../lunzip/buildout.cfg
../ncurses/buildout.cfg ../ncurses/buildout.cfg
...@@ -22,6 +23,7 @@ configure-options = ...@@ -22,6 +23,7 @@ configure-options =
--disable-more-warnings --disable-more-warnings
--with-libncurses-prefix=${ncurses:location} --with-libncurses-prefix=${ncurses:location}
--with-libxml2-prefix=${libxml2:location} --with-libxml2-prefix=${libxml2:location}
--with-libiconv-prefix=${libiconv:location}
--with-included-gettext --with-included-gettext
--without-emacs --without-emacs
--disable-acl --disable-acl
......
...@@ -53,19 +53,16 @@ environment = ...@@ -53,19 +53,16 @@ environment =
[harfbuzz] [harfbuzz]
recipe = slapos.recipe.cmmi recipe = slapos.recipe.cmmi
shared = true shared = true
url = https://www.freedesktop.org/software/harfbuzz/release/harfbuzz-2.6.4.tar.xz url = https://github.com/harfbuzz/harfbuzz/releases/download/10.2.0/harfbuzz-10.2.0.tar.xz
md5sum = 2b3a4dfdb3e5e50055f941978944da9f md5sum = f68c05409f18b4a044d71628548aacd9
pkg_config_depends = ${cairo:location}/lib/pkgconfig:${cairo:pkg_config_depends}:${icu4c:location}/lib/pkgconfig pkg_config_depends = ${cairo:location}/lib/pkgconfig:${cairo:pkg_config_depends}:${icu4c:location}/lib/pkgconfig
configure-options = configure-command =
--disable-static meson builddir --libdir=lib -Dprefix="@@LOCATION@@" -Dintrospection=disabled
--disable-gtk-doc-html make-binary = ninja -C builddir
--with-cairo
--with-freetype
--with-icu
environment = environment =
PATH=${xz-utils:location}/bin:${glib:location}/bin:${freetype:location}/bin:${pkgconfig:location}/bin:%(PATH)s PATH=${glib:location}/bin:${python3:location}/bin:${freetype:location}/bin:${meson:location}/bin:${ninja:location}/bin:${pkgconfig:location}/bin:${xz-utils:location}/bin:%(PATH)s
PKG_CONFIG_PATH=${:pkg_config_depends} PKG_CONFIG_PATH=${:pkg_config_depends}
LDFLAGS=-Wl,-rpath=${gettext:location}/lib -Wl,-rpath=${bzip2:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${icu4c:location}/lib -Wl,-rpath=${glib:location}/lib LDFLAGS=-Wl,-rpath=${gettext:location}/lib -Wl,-rpath=${bzip2:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${icu4c:location}/lib -Wl,-rpath=${glib:location}/lib -Wl,-rpath=${cairo:location}/lib -Wl,-rpath=${freetype:location}/lib -Wl,-rpath=@@LOCATION@@/lib
[fribidi] [fribidi]
recipe = slapos.recipe.cmmi recipe = slapos.recipe.cmmi
......
...@@ -13,8 +13,8 @@ parts = haproxy ...@@ -13,8 +13,8 @@ parts = haproxy
[haproxy] [haproxy]
recipe = slapos.recipe.cmmi recipe = slapos.recipe.cmmi
shared = true shared = true
url = https://www.haproxy.org/download/2.6/src/haproxy-2.6.20.tar.gz url = https://www.haproxy.org/download/2.6/src/haproxy-2.6.21.tar.gz
md5sum = b25c95f231c0c36eeb2957321849d87d md5sum = 3e52dca0e052f758a7e4519251e92128
configure-command = true configure-command = true
# for Linux kernel 2.6.28 and above, we use "linux-glibc" as the TARGET, # for Linux kernel 2.6.28 and above, we use "linux-glibc" as the TARGET,
# otherwise use "generic". # otherwise use "generic".
......
...@@ -8,9 +8,9 @@ parts = ...@@ -8,9 +8,9 @@ parts =
[openjpeg] [openjpeg]
recipe = slapos.recipe.cmmi recipe = slapos.recipe.cmmi
shared = true shared = true
version = 2.5.2 version = 2.5.3
url = https://github.com/uclouvain/openjpeg/archive/refs/tags/v${:version}.tar.gz url = https://github.com/uclouvain/openjpeg/archive/refs/tags/v${:version}.tar.gz
md5sum = f9ee64845881a15109ed0aa73a12202f md5sum = 12ae257cb21738c41b5f6ca977d01081
location = @@LOCATION@@ location = @@LOCATION@@
configure-command = ${cmake:location}/bin/cmake configure-command = ${cmake:location}/bin/cmake
configure-options = configure-options =
......
[buildout] [buildout]
extends = extends =
../ncurses/buildout.cfg ../ncurses/buildout.cfg
../perl/buildout.cfg
[texinfo] [texinfo]
# Most other components are not happy with texinfo 5, because it treats some # Most other components are not happy with texinfo 5, because it treats some
...@@ -28,3 +29,4 @@ configure-options = ...@@ -28,3 +29,4 @@ configure-options =
environment = environment =
CFLAGS=-I${ncurses:location}/include CFLAGS=-I${ncurses:location}/include
LDFLAGS=-L${ncurses:location}/lib -Wl,-rpath=${ncurses:location}/lib LDFLAGS=-L${ncurses:location}/lib -Wl,-rpath=${ncurses:location}/lib
PATH=${perl:location}/bin/:%(PATH)s
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
[template] [template]
filename = instance.cfg.in filename = instance.cfg.in
md5sum = bf0a70140e4775efaacdd5fe03ac3b62 md5sum = 2ef12d7fc16d74e0887a8cb16a848445
[template-kvm] [template-kvm]
filename = instance-kvm.cfg.jinja2 filename = instance-kvm.cfg.jinja2
...@@ -43,7 +43,7 @@ md5sum = a02f0694dcb944c18d99f7f79afa2384 ...@@ -43,7 +43,7 @@ md5sum = a02f0694dcb944c18d99f7f79afa2384
[template-kvm-export-script] [template-kvm-export-script]
filename = template/kvm-export.sh.jinja2 filename = template/kvm-export.sh.jinja2
md5sum = ba1e0359178925788792a1c6cc29ba59 md5sum = 667e4668cfdf396d18785d8cfa096396
[template-nginx] [template-nginx]
filename = template/nginx_conf.in filename = template/nginx_conf.in
......
...@@ -126,6 +126,7 @@ import-list = file parts :template-parts-destination ...@@ -126,6 +126,7 @@ import-list = file parts :template-parts-destination
recipe = slapos.cookbook:wrapper recipe = slapos.cookbook:wrapper
environment = environment =
PATH=${qemu:location}/bin PATH=${qemu:location}/bin
NO_COLOR=true
wrapper-path = wrapper-path =
$${buildout:bin-directory}/qmpbackup $${buildout:bin-directory}/qmpbackup
command-line = command-line =
...@@ -150,6 +151,7 @@ context = ...@@ -150,6 +151,7 @@ context =
recipe = slapos.cookbook:wrapper recipe = slapos.cookbook:wrapper
environment = environment =
PATH=${qemu:location}/bin PATH=${qemu:location}/bin
NO_COLOR=true
wrapper-path = wrapper-path =
$${buildout:bin-directory}/qmprestore $${buildout:bin-directory}/qmprestore
command-line = command-line =
......
...@@ -39,12 +39,12 @@ eggs = ...@@ -39,12 +39,12 @@ eggs =
colorlog colorlog
qmpbackup qmpbackup
find-links += find-links +=
https://github.com/abbbi/qmpbackup/releases/download/v0.43/qmpbackup-0.43.tar.gz https://github.com/abbbi/qmpbackup/releases/download/v0.44/qmpbackup-0.44.tar.gz
[versions] [versions]
qemu.qmp = 0.0.3:whl qemu.qmp = 0.0.3:whl
colorlog = 6.9.0:whl colorlog = 6.9.0:whl
qmpbackup = 0.43 qmpbackup = 0.44
[python-with-eggs] [python-with-eggs]
recipe = zc.recipe.egg recipe = zc.recipe.egg
......
...@@ -6,9 +6,6 @@ set -e ...@@ -6,9 +6,6 @@ set -e
LC_ALL=C LC_ALL=C
export LC_ALL export LC_ALL
BACKUP_DIR={{ directory['backup'] }} BACKUP_DIR={{ directory['backup'] }}
# decolorize colorlog in qmpbackup
NO_COLOR=true
export NO_COLOR
log=$(mktemp --tmpdir={{ directory['tmp'] }}) log=$(mktemp --tmpdir={{ directory['tmp'] }})
trap "rm -f $log" EXIT TERM INT trap "rm -f $log" EXIT TERM INT
......
...@@ -885,6 +885,18 @@ class TestInstanceResilientBackupMixin(CronMixin, KvmMixin): ...@@ -885,6 +885,18 @@ class TestInstanceResilientBackupMixin(CronMixin, KvmMixin):
return result[0].stdout.decode('utf-8') return result[0].stdout.decode('utf-8')
def awaitBackup(equeue_file):
for f in range(30):
with open(equeue_file, 'r') as fh:
equeue_log = fh.read()
if 'finished successfully' in equeue_log:
break
time.sleep(1)
else:
raise ValueError('Backup not finished: %s' % (equeue_log))
return equeue_log
@skipUnlessKvm @skipUnlessKvm
class TestInstanceResilientBackupImporter( class TestInstanceResilientBackupImporter(
TestInstanceResilientBackupMixin, KVMTestCase): TestInstanceResilientBackupMixin, KVMTestCase):
...@@ -900,16 +912,6 @@ class TestInstanceResilientBackupImporter( ...@@ -900,16 +912,6 @@ class TestInstanceResilientBackupImporter(
self.assertFalse(os.path.exists(self.getBackupPartitionPath())) self.assertFalse(os.path.exists(self.getBackupPartitionPath()))
self.call_exporter() self.call_exporter()
def awaitBackup(equeue_file):
for f in range(30):
with open(equeue_file, 'r') as fh:
equeue_log = fh.read()
if 'finished successfully' in equeue_log:
break
time.sleep(1)
else:
self.fail('Backup not finished: %s' % (equeue_log))
return equeue_log
equeue_log = awaitBackup(equeue_file) equeue_log = awaitBackup(equeue_file)
self.assertNotIn('qemu-img rebase', equeue_log) self.assertNotIn('qemu-img rebase', equeue_log)
self.assertEqual( self.assertEqual(
...@@ -957,8 +959,22 @@ class TestInstanceResilientBackupImporterIde( ...@@ -957,8 +959,22 @@ class TestInstanceResilientBackupImporterIde(
class TestInstanceResilientBackupExporterMixin( class TestInstanceResilientBackupExporterMixin(
TestInstanceResilientBackupMixin): TestInstanceResilientBackupMixin):
def assertImported(self):
self.assertEqual(
set(sorted(os.listdir(self.getPartitionPath('kvm-import', 'srv')))),
set([
'backup', 'proof.signature', 'virtual.qcow2', 'sshkeys', 'backup.diff'
,'monitor', 'cgi-bin', 'passwd', 'ssl', 'equeue.db'])
)
def initialBackup(self): def initialBackup(self):
status_text = self.call_exporter() status_text = self.call_exporter()
equeue_file = self.getPartitionPath(
'kvm-import', 'var', 'log', 'equeue.log')
# clean up equeue file for precise assertion
with open(equeue_file, 'w') as fh:
fh.write('')
awaitBackup(equeue_file)
self.assertEqual( self.assertEqual(
len(glob.glob(self.getBackupPartitionPath('FULL-*.qcow2'))), len(glob.glob(self.getBackupPartitionPath('FULL-*.qcow2'))),
1) 1)
...@@ -977,6 +993,7 @@ class TestInstanceResilientBackupExporterMixin( ...@@ -977,6 +993,7 @@ class TestInstanceResilientBackupExporterMixin(
'Post take-over cleanup', 'Post take-over cleanup',
status_text status_text
) )
self.assertImported()
@skipUnlessKvm @skipUnlessKvm
...@@ -984,6 +1001,15 @@ class TestInstanceResilientBackupExporter( ...@@ -984,6 +1001,15 @@ class TestInstanceResilientBackupExporter(
TestInstanceResilientBackupExporterMixin, KVMTestCase): TestInstanceResilientBackupExporterMixin, KVMTestCase):
def test(self): def test(self):
self.initialBackup() self.initialBackup()
# assure that additional backup run does not leave temporary files
equeue_file = self.getPartitionPath(
'kvm-import', 'var', 'log', 'equeue.log')
# clean up equeue file for precise assertion
with open(equeue_file, 'w') as fh:
fh.write('')
self.call_exporter()
awaitBackup(equeue_file)
self.assertImported()
@skipUnlessKvm @skipUnlessKvm
......
...@@ -20,7 +20,7 @@ md5sum = 109828c2a97c09b0976d266aaba00328 ...@@ -20,7 +20,7 @@ md5sum = 109828c2a97c09b0976d266aaba00328
[template-ors] [template-ors]
filename = instance-ors.cfg filename = instance-ors.cfg
md5sum = 307e38207945a9adcfea0263cba9d3a6 md5sum = dae4865ef39ad8fe07ed17b2e170d155
[slaplte.jinja2] [slaplte.jinja2]
_update_hash_filename_ = slaplte.jinja2 _update_hash_filename_ = slaplte.jinja2
...@@ -60,11 +60,11 @@ md5sum = 52da9fe3a569199e35ad89ae1a44c30e ...@@ -60,11 +60,11 @@ md5sum = 52da9fe3a569199e35ad89ae1a44c30e
[template-enb] [template-enb]
_update_hash_filename_ = instance-enb.jinja2.cfg _update_hash_filename_ = instance-enb.jinja2.cfg
md5sum = de757719d6cf4bd731394f50dbce8d99 md5sum = 22c399fc3a84aeec0f6545fe72fbf2f3
[template-ors-enb] [template-ors-enb]
_update_hash_filename_ = instance-ors-enb.jinja2.cfg _update_hash_filename_ = instance-ors-enb.jinja2.cfg
md5sum = bdc8ca95cad8374f24af7ab6a276b61c md5sum = 4f0e65d831889a7d0932f106c11856eb
[template-ors-ue] [template-ors-ue]
_update_hash_filename_ = instance-ors-ue.jinja2.cfg _update_hash_filename_ = instance-ors-ue.jinja2.cfg
......
Changelog Changelog
========= =========
Version 1.0.396 (2025-02-12)
-------------
* Publish SSB NR ARFCN
* Fix SSB NR ARFCN computation, affects band N79
Version 1.0.390 (2025-01-21) Version 1.0.390 (2025-01-21)
------------- -------------
......
...@@ -204,19 +204,6 @@ wrapper-path = ${directory:service}/${:_buildout_section_name_} ...@@ -204,19 +204,6 @@ wrapper-path = ${directory:service}/${:_buildout_section_name_}
command-line = ${xamari-xlog-script:output} command-line = ${xamari-xlog-script:output}
hash-files = ${:command-line} hash-files = ${:command-line}
[request-parameters]
<= slap-connection
recipe = slapos.cookbook:requestoptional
name = Wendelin Telecom Registration
software-url = {{ slapparameter_dict.wendelin_telecom_software_release_url }}
shared = true
{%- if not slapparameter_dict.xlog_forwarding_enabled or slapparameter_dict.get("xlog_fluentbit_forward_host") %}
state = destroyed
{%- else %}
config-fluentbit-tag = ${xlog-fluentbit-tag:xlog-fluentbit-tag}
return = gateway-host
{%- endif %}
[request-wendelin-telecom-shared] [request-wendelin-telecom-shared]
<= slap-connection <= slap-connection
recipe = slapos.cookbook:requestoptional recipe = slapos.cookbook:requestoptional
......
...@@ -230,7 +230,6 @@ eutra-cell-id = {{ ors_id['eutra_cell_id'] }} ...@@ -230,7 +230,6 @@ eutra-cell-id = {{ ors_id['eutra_cell_id'] }}
gnb-id = {{ slapparameter_dict['gnb_id'] }} gnb-id = {{ slapparameter_dict['gnb_id'] }}
nr-cell-id = {{ ors_id['nr_cell_id'] }} nr-cell-id = {{ ors_id['nr_cell_id'] }}
{%- endif %} {%- endif %}
{%- if enb_mode == 'enb' %} {%- if enb_mode == 'enb' %}
current-frequency = {{ xearfcn_module.frequency(ors_version['current-earfcn']) }} MHz current-frequency = {{ xearfcn_module.frequency(ors_version['current-earfcn']) }} MHz
current-band = {{ xearfcn_module.band(ors_version['current-earfcn'])[0]["band"] }} current-band = {{ xearfcn_module.band(ors_version['current-earfcn'])[0]["band"] }}
...@@ -239,6 +238,12 @@ current-earfcn = {{ ors_version['current-earfcn'] }} ...@@ -239,6 +238,12 @@ current-earfcn = {{ ors_version['current-earfcn'] }}
current-frequency = {{ xnrarfcn_module.frequency(ors_version['current-nr-arfcn']) }} MHz current-frequency = {{ xnrarfcn_module.frequency(ors_version['current-nr-arfcn']) }} MHz
current-nr-band = {{ ors_version['current-nr-band'] }} current-nr-band = {{ ors_version['current-nr-band'] }}
current-nr-arfcn = {{ ors_version['current-nr-arfcn'] }} current-nr-arfcn = {{ ors_version['current-nr-arfcn'] }}
{%- if slapparameter_dict.get('ssb_nr_arfcn', False) %}
current-ssb-nr-arfcn = {{ slapparameter_dict['ssb_nr_arfcn'] }}
{%- else %}
{%- set ssb_nr_arfcn, max_ssb_scs_khz = xnrarfcn_module.dl2ssb(ors_version['current-nr-arfcn'], ors_version['current-nr-band']) %}
current-ssb-nr-arfcn = {{ ssb_nr_arfcn | tojson }}
{%- endif %}
{%- endif %} {%- endif %}
......
...@@ -22,6 +22,9 @@ ...@@ -22,6 +22,9 @@
"dl_nr_arfcn": { "dl_nr_arfcn": {
"$ref": "cell/nr/input-schema.json#/properties/dl_nr_arfcn" "$ref": "cell/nr/input-schema.json#/properties/dl_nr_arfcn"
}, },
"ssb_nr_arfcn": {
"$ref": "cell/nr/input-schema.json#/properties/ssb_nr_arfcn"
},
"nr_band": { "nr_band": {
"$ref": "cell/nr/input-schema.json#/properties/nr_band" "$ref": "cell/nr/input-schema.json#/properties/nr_band"
}, },
......
...@@ -51,119 +51,137 @@ configuration = $${slap-configuration:configuration} ...@@ -51,119 +51,137 @@ configuration = $${slap-configuration:configuration}
sdr-dir = $${sdr:dir} sdr-dir = $${sdr:dir}
init = init =
import subprocess import subprocess
range_map = { default_map = {
"B28": "758MHz - 803MHz", "B28": {
"B38": "2570MHz - 2620MHz", "range": "758MHz - 803MHz",
"B39": "1880MHz - 1920MHz", "dl_earfcn": 9550,
"B40": "2300MHz - 2400MHz", "dl_nr_arfcn": 158400,
"B41": "2496MHz - 2690MHz", "nr_band": 28,
"B42": "3400MHz - 3600MHz", "tx_gain": [60, 62],
"B43": "3600MHz - 3800MHz", "rx_gain": [25, 25],
"N77": "3800MHz - 4000MHz", "rf_mode": "fdd",
"N79": "4600MHz - 5000MHz", "power_estimation": (
"UNKNOWN": "Information not available for this band", lambda x: "UNKNOWN",
} lambda x: (-0.004711416231164319) * x**2 + (1.5976906979683085) * x + (-67.71316951508676),
default_tx_gain_map = { ),
"B28": (60, 62), },
"B38": (59, 65), "B38": {
"B39": (59, 64), "range": "2570MHz - 2620MHz",
"B40": (59, 64), "dl_earfcn": 38050,
"B41": (59, 64), "dl_nr_arfcn": 519000,
"B42": (63, 62), "nr_band": 41,
"B43": (63, 62), "tx_gain": [59, 65],
"N77": (60, 62), "rx_gain": [25, 25],
"N79": (60, 62), "rf_mode": "tdd",
"UNKNOWN": (60, 62), "power_estimation": (
} lambda x: (-0.008712931375092506) * x**2 + (2.1973585140044642) * x + (-94.29420762479742),
default_rx_gain_map = { lambda x: (-0.004472751640641793) * x**2 + (1.6308290630103919) * x + (-81.84549245154561),
"B28": (25, 25), ),
"B38": (25, 25), },
"B39": (25, 25), "B39": {
"B40": (25, 25), "range": "1880MHz - 1920MHz",
"B41": (25, 25), "dl_earfcn": 38350,
"B42": (25, 25), "dl_nr_arfcn": 378000,
"B43": (25, 25), "nr_band": 39,
"N77": (25, 25), "tx_gain": [59, 64],
"N79": (25, 25), "rx_gain": [25, 25],
"UNKNOWN": (25, 25), "rf_mode": "tdd",
} "power_estimation": (
default_earfcn_map = { lambda x: (-0.008712931375092506) * x**2 + (2.1973585140044642) * x + (-94.29420762479742),
"B28": 9550, lambda x: (-0.0022523817802900985) * x**2 + (1.2674016231310092) * x + (-66.57165215468584),
"B38": 38050, ),
"B39": 38350, },
"B40": 39150, "B40": {
"B41": 40620, "range": "2300MHz - 2400MHz",
"B42": 42590, "dl_earfcn": 39150,
"B43": 44590, "dl_nr_arfcn": 470000,
"N77": 0, "nr_band": 40,
"N79": 0, "tx_gain": [59, 64],
"UNKNOWN": 0, "rx_gain": [25, 25],
} "rf_mode": "tdd",
default_nr_arfcn_map = { "power_estimation": (
"B28": 0, lambda x: "UNKNOWN",
"B38": 519000, lambda x: (-0.0016475305254340404) * x**2 + (1.1580162105112186) * x + (-62.10679297527826),
"B39": 378000, ),
"B40": 470000, },
"B41": 518600, "B41": {
"B42": 632628, "range": "2496MHz - 2690MHz",
"B43": 646666, "dl_earfcn": 40620,
"N77": 660000, "dl_nr_arfcn": 518600,
"N79": 720000, "nr_band": 41,
"UNKNOWN": 0, "tx_gain": [59, 64],
} "rx_gain": [25, 25],
default_nr_band_map = { "rf_mode": "tdd",
"B28": 0, "power_estimation": (
"B38": 41, lambda x: "UNKNOWN",
"B39": 39, lambda x: "UNKNOWN",
"B40": 40, ),
"B41": 41, },
"B42": 78, "B42": {
"B43": 78, "range": "3400MHz - 3600MHz",
"N77": 77, "dl_earfcn": 42590,
"N79": 79, "dl_nr_arfcn": 632628,
"UNKNOWN": 0, "nr_band": 78,
} "tx_gain": [63, 62],
power_map = { "rx_gain": [25, 25],
"B28": ( "rf_mode": "tdd",
lambda x: "UNKNOWN", "power_estimation": (
lambda x: "UNKNOWN", lambda x: (-0.014198126839751619) * x**2 + (2.980758813262773) * x + (-125.25800492285738),
), lambda x: (0.003977721774394756) * x**2 + (0.527208191717173) * x + (-42.761142655285376),
"B38": ( ),
lambda x: (-0.008712931375092506) * x**2 + (2.1973585140044642) * x + (-94.29420762479742), },
lambda x: (-0.004472751640641793) * x**2 + (1.6308290630103919) * x + (-81.84549245154561), "B43": {
), "range": "3600MHz - 3800MHz",
"B39": ( "dl_earfcn": 44590,
lambda x: (-0.008712931375092506) * x**2 + (2.1973585140044642) * x + (-94.29420762479742), "dl_nr_arfcn": 646666,
lambda x: (-0.0022523817802900985) * x**2 + (1.2674016231310092) * x + (-66.57165215468584), "nr_band": 78,
), "tx_gain": [63, 62],
"B40": ( "rx_gain": [25, 25],
lambda x: "UNKNOWN", "rf_mode": "tdd",
lambda x: "UNKNOWN", "power_estimation": (
), lambda x: (-0.014198126839751619) * x**2 + (2.980758813262773) * x + (-125.25800492285738),
"B41": ( lambda x: (-0.0036530114002551943) * x**2 + (1.510856844601873) * x + (-74.58790185136355),
lambda x: "UNKNOWN", ),
lambda x: "UNKNOWN", },
), "N77": {
"B42": ( "range": "3800MHz - 4000MHz",
lambda x: (-0.014198126839751619) * x**2 + (2.980758813262773) * x + (-125.25800492285738), "dl_earfcn": 0,
lambda x: (0.003977721774394756) * x**2 + (0.527208191717173) * x + (-42.761142655285376), "dl_nr_arfcn": 660000,
), "nr_band": 77,
"B43": ( "tx_gain": [60, 62],
lambda x: (-0.014198126839751619) * x**2 + (2.980758813262773) * x + (-125.25800492285738), "rx_gain": [25, 25],
lambda x: (-0.0036530114002551943) * x**2 + (1.510856844601873) * x + (-74.58790185136355), "rf_mode": "tdd",
), "power_estimation": (
"N77": ( lambda x: "UNKNOWN",
lambda x: "UNKNOWN", lambda x: lambda x: (-0.003358281211508112) * x**2 + (1.4533760798172672) * x + (-70.18774498873421),
lambda x: "UNKNOWN", ),
), },
"N79": ( "N79": {
lambda x: "UNKNOWN", "range": "4600MHz - 5000MHz",
lambda x: "UNKNOWN", "dl_earfcn": 0,
), "dl_nr_arfcn": 720000,
"UNKNOWN": ( "nr_band": 79,
lambda x: "UNKNOWN", "tx_gain": [60, 62],
lambda x: "UNKNOWN", "rx_gain": [25, 25],
), "rf_mode": "tdd",
"power_estimation": (
lambda x: "UNKNOWN",
lambda x: (-0.004745509248998074) * x**2 + (1.659474968728413) * x + (-76.46937551110834),
),
},
"UNKNOWN": {
"range": "Information not available for this band",
"dl_earfcn": 0,
"dl_nr_arfcn": 0,
"nr_band": 0,
"tx_gain": [60, 62],
"rx_gain": [25, 25],
"rf_mode": "tdd",
"power_estimation": (
lambda x: "UNKNOWN",
lambda x: "UNKNOWN",
),
},
} }
def get_sdr_info(cmd): def get_sdr_info(cmd):
if options['configuration'].get('testing', False): if options['configuration'].get('testing', False):
...@@ -181,18 +199,20 @@ init = ...@@ -181,18 +199,20 @@ init =
options['band'], options['band'],
"2x1W" if options['one-watt'] else "2x0.5W", "2x1W" if options['one-watt'] else "2x0.5W",
) )
default_tx_gain = default_tx_gain_map [options['band']][int(options['one-watt'])] default_tx_gain = default_map[options['band']]['tx_gain' ][int(options['one-watt'])]
default_rx_gain = default_rx_gain_map [options['band']][int(options['one-watt'])] default_rx_gain = default_map[options['band']]['rx_gain' ][int(options['one-watt'])]
default_earfcn = default_earfcn_map [options['band']] default_earfcn = default_map[options['band']]['dl_earfcn' ]
default_nr_arfcn = default_nr_arfcn_map[options['band']] default_nr_arfcn = default_map[options['band']]['dl_nr_arfcn']
default_nr_band = default_nr_band_map [options['band']] default_nr_band = default_map[options['band']]['nr_band' ]
options['range'] = range_map [options['band']] default_rf_mode = default_map[options['band']]['rf_mode' ]
options['range'] = default_map[options['band']]['range']
options['current-tx-gain'] = options['configuration'].get('tx_gain' , default_tx_gain ) options['current-tx-gain'] = options['configuration'].get('tx_gain' , default_tx_gain )
options['current-rx-gain'] = options['configuration'].get('rx_gain' , default_rx_gain ) options['current-rx-gain'] = options['configuration'].get('rx_gain' , default_rx_gain )
options['current-earfcn'] = options['configuration'].get('dl_earfcn' , default_earfcn ) options['current-earfcn'] = options['configuration'].get('dl_earfcn' , default_earfcn )
options['current-nr-arfcn'] = options['configuration'].get('dl_nr_arfcn', default_nr_arfcn) options['current-nr-arfcn'] = options['configuration'].get('dl_nr_arfcn', default_nr_arfcn)
options['current-nr-band'] = options['configuration'].get('nr_band' , default_nr_band ) options['current-nr-band'] = options['configuration'].get('nr_band' , default_nr_band )
power_estimate_dbm = power_map[options['band']][int(options['one-watt'])](float(options['current-tx-gain'])) options['current-rf-mode'] = options['configuration'].get('rf_mode' , default_rf_mode )
power_estimate_dbm = default_map[options['band']]['power_estimation'][int(options['one-watt'])](float(options['current-tx-gain']))
if power_estimate_dbm == "UNKNOWN": if power_estimate_dbm == "UNKNOWN":
power_estimate = "Information not available for this band" power_estimate = "Information not available for this band"
else: else:
......
...@@ -197,7 +197,7 @@ scripts = ...@@ -197,7 +197,7 @@ scripts =
[xlte-repository] [xlte-repository]
recipe = slapos.recipe.build:gitclone recipe = slapos.recipe.build:gitclone
repository = https://lab.nexedi.com/kirr/xlte.git repository = https://lab.nexedi.com/kirr/xlte.git
revision = 598588a3 revision = ee1e4652
git-executable = ${git:location}/bin/git git-executable = ${git:location}/bin/git
[xlte] [xlte]
......
...@@ -82,9 +82,9 @@ param_dict = { ...@@ -82,9 +82,9 @@ param_dict = {
'cell_type': 'nr', 'cell_type': 'nr',
'cell_kind': 'enb_peer', 'cell_kind': 'enb_peer',
'rat': 'nr', 'rat': 'nr',
'dl_nr_arfcn': 520000, 'dl_nr_arfcn': 519000,
'ssb_nr_arfcn': 520000, 'ssb_nr_arfcn': 518910,
'ul_nr_arfcn': 520000, 'ul_nr_arfcn': 519000,
'pci': 1, 'pci': 1,
'n_id_cell': 1, 'n_id_cell': 1,
'nr_cell_id': '0x0000001', 'nr_cell_id': '0x0000001',
...@@ -97,9 +97,9 @@ param_dict = { ...@@ -97,9 +97,9 @@ param_dict = {
'cell_type': 'nr', 'cell_type': 'nr',
'cell_kind': 'enb_peer', 'cell_kind': 'enb_peer',
'rat': 'nr', 'rat': 'nr',
'dl_nr_arfcn': 380000, 'dl_nr_arfcn': 378000,
'ssb_nr_arfcn': 380000, 'ssb_nr_arfcn': 378030,
'ul_nr_arfcn': 380000, 'ul_nr_arfcn': 378000,
'pci': 2, 'pci': 2,
'n_id_cell': 2, 'n_id_cell': 2,
'nr_cell_id': '0x0000002', 'nr_cell_id': '0x0000002',
...@@ -128,10 +128,10 @@ enb_param_dict = { ...@@ -128,10 +128,10 @@ enb_param_dict = {
} }
gnb_param_dict = { gnb_param_dict = {
# ors_version for tests is B39, so dl_nr_arfcn needs to be within N39 # ors_version for tests is B39, so dl_nr_arfcn needs to be within N39
'dl_nr_arfcn': 380000, 'dl_nr_arfcn': 378000,
'nr_band': 39, 'nr_band': 39,
'nr_bandwidth': 40, 'nr_bandwidth': 40,
'ssb_nr_arfcn': 380020, 'ssb_nr_arfcn': 378030,
'gnb_id': '0x17', 'gnb_id': '0x17',
'gnb_id_bits': 30, 'gnb_id_bits': 30,
'ssb_pos_bitmap': '10', 'ssb_pos_bitmap': '10',
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment