lists.osmocom.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

gerrit-log

Thread Start a new thread
Download
Threads by month
  • ----- 2026 -----
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2025 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
gerrit-log@lists.osmocom.org

October 2024

  • 1 participants
  • 1631 discussions
[L] Change in libosmo-abis[master]: libosmotrau: implement RAA' decoder function
by falconia 02 Oct '24

02 Oct '24
falconia has submitted this change. ( https://gerrit.osmocom.org/c/libosmo-abis/+/38293?usp=email ) Change subject: libosmotrau: implement RAA' decoder function ...................................................................... libosmotrau: implement RAA' decoder function The previous patch implements RAA' encoder function; now comes the decoder. Related: OS#6167 Change-Id: I1347a25ce97d5022502ee9112caded66315b09a4 --- M .gitignore M include/osmocom/trau/csd_raa_prime.h M src/Makefile.am A src/trau/raa_prime_decode.c M tests/Makefile.am A tests/raa_prime/test_dec.c M tests/testsuite.at 7 files changed, 280 insertions(+), 0 deletions(-) Approvals: falconia: Looks good to me, approved Jenkins Builder: Verified diff --git a/.gitignore b/.gitignore index 2f3ba99..fd0974d 100644 --- a/.gitignore +++ b/.gitignore @@ -40,6 +40,7 @@ tests/subchan_demux/.dirstamp tests/subchan_demux/subchan_demux_test tests/ipa_recv/ipa_recv_test +tests/raa_prime/test_dec tests/raa_prime/test_enc tests/trau_pcu_ericsson/trau_pcu_ericsson_test tests/trau_conv/trau16_to_rtp diff --git a/include/osmocom/trau/csd_raa_prime.h b/include/osmocom/trau/csd_raa_prime.h index 43bfe4e..7c3e817 100644 --- a/include/osmocom/trau/csd_raa_prime.h +++ b/include/osmocom/trau/csd_raa_prime.h @@ -55,3 +55,31 @@ void osmo_csd144_to_atrau_ra2(uint8_t *out_bytes, const ubit_t *m_bits, const ubit_t *d_bits, ubit_t atrau_c4, ubit_t atrau_c5); + +/*! Decode aligned A-TRAU frame into user form of 288 D-bits and + * two M-bits; the A-TRAU frame input is given in unpacked bit form. + * + * \param[out] m_bits caller-provided buffer for 2 M-bits + * \param[out] d_bits caller-provided buffer for 288 user data bits + * \param[out] atrau_c4 return of A-TRAU frame bit C4 (NULL pointer OK) + * \param[out] atrau_c5 return of A-TRAU frame bit C5 (NULL pointer OK) + * \param[in] atrau_bits A-TRAU frame as 320 unpacked bits + * \return 0 if A-TRAU frame is good; negative if it is invalid + */ +int osmo_csd144_from_atrau_bits(ubit_t *m_bits, ubit_t *d_bits, + ubit_t *atrau_c4, ubit_t *atrau_c5, + const ubit_t *atrau_bits); + +/*! Decode aligned A-TRAU frame into user form of 288 D-bits and + * two M-bits; the A-TRAU frame input is given in RA2 octet form. + * + * \param[out] m_bits caller-provided buffer for 2 M-bits + * \param[out] d_bits caller-provided buffer for 288 user data bits + * \param[out] atrau_c4 return of A-TRAU frame bit C4 (NULL pointer OK) + * \param[out] atrau_c5 return of A-TRAU frame bit C5 (NULL pointer OK) + * \param[in] atrau_bytes A-TRAU frame as 160 RA2 octets + * \return 0 if A-TRAU frame is good; negative if it is invalid + */ +int osmo_csd144_from_atrau_ra2(ubit_t *m_bits, ubit_t *d_bits, + ubit_t *atrau_c4, ubit_t *atrau_c5, + const uint8_t *atrau_bytes); diff --git a/src/Makefile.am b/src/Makefile.am index 6d8bc98..3a6b83d 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -42,6 +42,7 @@ $(NULL) libosmotrau_la_LIBADD = $(COMMONLIBS) $(LIBOSMOCODEC_LIBS) $(ORTP_LIBS) libosmotrau_la_SOURCES = trau/csd_ra2.c \ + trau/raa_prime_decode.c \ trau/raa_prime_encode.c \ trau/trau_frame.c \ trau/trau_pcu_ericsson.c \ diff --git a/src/trau/raa_prime_decode.c b/src/trau/raa_prime_decode.c new file mode 100644 index 0000000..65d916e --- /dev/null +++ b/src/trau/raa_prime_decode.c @@ -0,0 +1,121 @@ +/* + * This C module contains the implementation of RAA' (RAA-prime) function + * in the decoding direction, from an A-TRAU frame to user bits. + * The interface is defined in <osmocom/trau/csd_raa_prime.h>. + * + * Author: Mychaela N. Falconia <falcon(a)freecalypso.org>, 2024 - however, + * Mother Mychaela's contributions are NOT subject to copyright. + * No rights reserved, all rights relinquished. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#include <stdint.h> +#include <string.h> +#include <errno.h> +#include <osmocom/core/bits.h> +#include <osmocom/core/utils.h> +#include <osmocom/trau/csd_raa_prime.h> +#include <osmocom/trau/csd_ra2.h> + +static int decode_zsp(const ubit_t *atrau_bits, unsigned *pos) +{ + unsigned pos1, n; + + /* guard bits must be set */ + if (!atrau_bits[0] || !atrau_bits[7]) + return -EINVAL; + pos1 = 0; + for (n = 0; n < 5; n++) { + pos1 <<= 1; + pos1 |= atrau_bits[2 + n]; + } + if (pos1 < 1 || pos1 > 29) + return -EINVAL; + *pos = pos1 - 1; + return 0; +} + +static int decode_subframe(ubit_t *d_bits, const ubit_t *atrau_bits) +{ + ubit_t zi, cbit; + unsigned pos, z_pos, numd; + int rc; + + /* consume Zi bit and weed out the trivial case */ + zi = *atrau_bits++; + if (zi) { + memcpy(d_bits, atrau_bits, 36); + return 0; + } + pos = 0; + for (;;) { + if (pos > 28) + return -EINVAL; + rc = decode_zsp(atrau_bits + pos, &z_pos); + if (rc < 0) + return rc; + cbit = atrau_bits[pos + 1]; + if (z_pos < pos) + return -EINVAL; + numd = z_pos - pos; + memcpy(d_bits + pos, atrau_bits + 8 + pos, numd); + memset(d_bits + pos + numd, 0, 8); + pos += numd + 8; + if (cbit) + break; + } + OSMO_ASSERT(pos <= 36); + numd = 36 - pos; + memcpy(d_bits + pos, atrau_bits + pos, numd); + return 0; +} + +int osmo_csd144_from_atrau_bits(ubit_t *m_bits, ubit_t *d_bits, + ubit_t *atrau_c4, ubit_t *atrau_c5, + const ubit_t *atrau_bits) +{ + static const ubit_t header_bits[20] = {0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 1, 0, 1, 1}; + int subf, rc; + + if (memcmp(atrau_bits, header_bits, 20) != 0) + return -EINVAL; + if (atrau_c4) + *atrau_c4 = atrau_bits[20]; + if (atrau_c5) + *atrau_c5 = atrau_bits[21]; + m_bits[0] = atrau_bits[22]; + m_bits[1] = atrau_bits[23]; + + /* done with the header, do the 8 subframes */ + atrau_bits += 24; + for (subf = 0; subf < 8; subf++) { + rc = decode_subframe(d_bits, atrau_bits); + if (rc < 0) + return rc; + atrau_bits += 37; + d_bits += 36; + } + return 0; +} + +int osmo_csd144_from_atrau_ra2(ubit_t *m_bits, ubit_t *d_bits, + ubit_t *atrau_c4, ubit_t *atrau_c5, + const uint8_t *atrau_bytes) +{ + ubit_t atrau_bits[OSMO_ATRAU_FRAME_BITS]; + + osmo_csd_ra2_16k_unpack(atrau_bits, atrau_bytes, OSMO_ATRAU_RA2_OCTETS); + return osmo_csd144_from_atrau_bits(m_bits, d_bits, atrau_c4, atrau_c5, + atrau_bits); +} diff --git a/tests/Makefile.am b/tests/Makefile.am index d50b09a..fd264d0 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -7,6 +7,7 @@ ipa_proxy_test \ subchan_demux/subchan_demux_test \ ipa_recv/ipa_recv_test \ + raa_prime/test_dec \ raa_prime/test_enc \ trau_conv/trau16_to_rtp \ trau_sync/trau_sync_test \ @@ -39,6 +40,10 @@ $(LIBOSMOCORE_LIBS) $(LIBOSMOGSM_LIBS) \ $(LIBOSMOVTY_LIBS) +raa_prime_test_dec_SOURCES = raa_prime/test_dec.c +raa_prime_test_dec_LDADD = $(top_builddir)/src/libosmotrau.la \ + $(LIBOSMOCORE_LIBS) + raa_prime_test_enc_SOURCES = raa_prime/test_enc.c raa_prime_test_enc_LDADD = $(top_builddir)/src/libosmotrau.la \ $(LIBOSMOCORE_LIBS) diff --git a/tests/raa_prime/test_dec.c b/tests/raa_prime/test_dec.c new file mode 100644 index 0000000..9ca1b02 --- /dev/null +++ b/tests/raa_prime/test_dec.c @@ -0,0 +1,118 @@ +/* + * This C module is a unit test program for libosmotrau implementation + * of RAA' function in the decoding direction. + * + * Author: Mychaela N. Falconia <falcon(a)freecalypso.org>, 2024 - however, + * Mother Mychaela's contributions are NOT subject to copyright. + * No rights reserved, all rights relinquished. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#include <ctype.h> +#include <stdio.h> +#include <stdint.h> +#include <stdbool.h> +#include <stdlib.h> +#include <string.h> + +#include <osmocom/core/bits.h> +#include <osmocom/core/utils.h> +#include <osmocom/trau/csd_raa_prime.h> + +static uint8_t frame_buf[OSMO_ATRAU_RA2_OCTETS]; +static unsigned hex_chunk_count; + +static void process_frame(void) +{ + ubit_t m_bits[2], d_bits[288]; + uint8_t d_bits_packed[36]; + int rc, i; + + rc = osmo_csd144_from_atrau_ra2(m_bits, d_bits, NULL, NULL, frame_buf); + if (rc < 0) { + printf("Bad A-TRAU frame!\n"); + return; + } + osmo_ubit2pbit(d_bits_packed, d_bits, 288); + printf("%u%u ", m_bits[0], m_bits[1]); + for (i = 0; i < 36; i++) + printf("%02x", d_bits_packed[i]); + putchar('\n'); +} + +static void process_hex_input(const char *hex_str) +{ + osmo_hexparse(hex_str, frame_buf + hex_chunk_count * 40, 40); + hex_chunk_count++; + if (hex_chunk_count >= 4) { + process_frame(); + hex_chunk_count = 0; + } +} + +static void process_line(char *linebuf, const char *infname, int lineno) +{ + char *cp = linebuf, *hex_str; + int ndig; + + while (isspace(*cp)) + cp++; + if (*cp == '\0' || *cp == '#') + return; + /* expect string of 80 hex digits */ + hex_str = cp; + for (ndig = 0; ndig < 80; ndig++) { + if (!isxdigit(*cp)) + goto inv; + cp++; + } + if (*cp) { + if (!isspace(*cp)) + goto inv; + *cp++ = '\0'; + } + /* must be end of non-comment line */ + while (isspace(*cp)) + cp++; + if (*cp != '\0' && *cp != '#') + goto inv; + + process_hex_input(hex_str); + return; + +inv: fprintf(stderr, "%s line %d: invalid syntax\n", infname, lineno); + exit(1); +} + +int main(int argc, char **argv) +{ + const char *infname; + FILE *inf; + char linebuf[256]; + int lineno; + + if (argc != 2) { + fprintf(stderr, "usage: %s input-file\n", argv[0]); + exit(1); + } + infname = argv[1]; + inf = fopen(infname, "r"); + if (!inf) { + perror(infname); + exit(1); + } + + for (lineno = 1; fgets(linebuf, sizeof(linebuf), inf); lineno++) + process_line(linebuf, infname, lineno); + fclose(inf); + exit(0); +} diff --git a/tests/testsuite.at b/tests/testsuite.at index c430220..70e7f25 100644 --- a/tests/testsuite.at +++ b/tests/testsuite.at @@ -36,6 +36,12 @@ AT_CHECK([$abs_top_builddir/tests/raa_prime/test_enc $abs_srcdir/raa_prime/d144-ul-input.asc], [0], [expout], [ignore]) AT_CLEANUP +AT_SETUP([raa_prime_decode]) +AT_KEYWORDS([raa_prime_decode]) +cat $abs_srcdir/raa_prime/d144-ul-input.asc > expout +AT_CHECK([$abs_top_builddir/tests/raa_prime/test_dec $abs_srcdir/raa_prime/nokia-tcsm2-atrau.hex], [0], [expout], [ignore]) +AT_CLEANUP + AT_SETUP([trau_sync]) AT_KEYWORDS([trau_sync]) cat $abs_srcdir/trau_sync/trau_sync_test.ok > expout -- To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/38293?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: libosmo-abis Gerrit-Branch: master Gerrit-Change-Id: I1347a25ce97d5022502ee9112caded66315b09a4 Gerrit-Change-Number: 38293 Gerrit-PatchSet: 5 Gerrit-Owner: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[L] Change in libosmo-abis[master]: libosmotrau: implement RAA' encoder function
by falconia 02 Oct '24

02 Oct '24
falconia has submitted this change. ( https://gerrit.osmocom.org/c/libosmo-abis/+/38292?usp=email ) Change subject: libosmotrau: implement RAA' encoder function ...................................................................... libosmotrau: implement RAA' encoder function RAA' is the rate adaption function specific to 14.4 kbit/s CSD services. It is defined in 3GPP TS 48.020 chapter 11, and consists of transforming each user data frame of 290 bits (as it would appear at the radio channel coder interface) into a special A-TRAU frame. 64 kbit/s streams consisting of these A-TRAU frames are meant to traverse the call switching network from one mobile call leg to the other, or from a mobile call leg to an IWF. RAA' transform involves rather bewildering manipulation of payload bit content, done to prevent any possibility of false A-TRAU frame alignment in octet-oriented (no frame boundaries) 64 kbit/s transport. The complexity is such that unit tests are essential, especially unit tests that cross-check our software implementation against those made by others. Fortunately this RAA' function is included in traditional T1/E1 TRAUs, those that support CSD in 14.4 kbit/s mode and implement it according to the specs. Nokia TCSM2 in Themyscira lab includes the necessary support, and the present patch includes a unit test that verifies perfect agreement between our software implementation of RAA' encoder and the historical hw implementation in the old Nokia TRAU. Related: OS#6167 Change-Id: I11fc1529f5be88fa778c7e05cb11eef58a389d40 --- M .gitignore M include/Makefile.am A include/osmocom/trau/csd_raa_prime.h M src/Makefile.am A src/trau/raa_prime_encode.c M tests/Makefile.am A tests/raa_prime/README.test-data A tests/raa_prime/d144-ul-input.asc A tests/raa_prime/nokia-tcsm2-atrau.hex A tests/raa_prime/test_enc.c M tests/testsuite.at 11 files changed, 396 insertions(+), 0 deletions(-) Approvals: falconia: Looks good to me, approved Jenkins Builder: Verified diff --git a/.gitignore b/.gitignore index 2bed942..2f3ba99 100644 --- a/.gitignore +++ b/.gitignore @@ -40,6 +40,7 @@ tests/subchan_demux/.dirstamp tests/subchan_demux/subchan_demux_test tests/ipa_recv/ipa_recv_test +tests/raa_prime/test_enc tests/trau_pcu_ericsson/trau_pcu_ericsson_test tests/trau_conv/trau16_to_rtp tests/trau_sync/trau_sync_test diff --git a/include/Makefile.am b/include/Makefile.am index 2832541..2d22a55 100644 --- a/include/Makefile.am +++ b/include/Makefile.am @@ -5,6 +5,7 @@ osmocom/abis/subchan_demux.h osmocom/abis/e1_input.h \ osmocom/abis/lapd.h osmocom/abis/lapd_pcap.h osmocom/abis/unixsocket_proto.h \ osmocom/trau/csd_ra2.h \ + osmocom/trau/csd_raa_prime.h \ osmocom/trau/trau_frame.h \ osmocom/trau/trau_sync.h \ osmocom/trau/trau_pcu_ericsson.h \ diff --git a/include/osmocom/trau/csd_raa_prime.h b/include/osmocom/trau/csd_raa_prime.h new file mode 100644 index 0000000..43bfe4e --- /dev/null +++ b/include/osmocom/trau/csd_raa_prime.h @@ -0,0 +1,57 @@ +/* + * This header file defines the API to the RAA' (RAA-prime) function of + * 3GPP TS 48.020 chapter 11, which is a transform applicable to + * circuit-switched data calls at air interface user rate of 14.4 kbit/s. + * RAA' converts between the "user" form of 290 bits (288 payload bits + * plus two M-bits) that appears at the radio channel coder interface + * and in E-TRAU frames on one side, and external PCM interface A-TRAU + * frames on the other side. + * + * Author: Mychaela N. Falconia <falcon(a)freecalypso.org>, 2024 - however, + * Mother Mychaela's contributions are NOT subject to copyright. + * No rights reserved, all rights relinquished. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#pragma once + +#include <stdint.h> +#include <osmocom/core/bits.h> + +#define OSMO_ATRAU_FRAME_BITS 320 +#define OSMO_ATRAU_RA2_OCTETS 160 + +/*! Convert one 20 ms frame of csd144 from user form to A-TRAU frame; + * the output is in the form of unpacked bits. + * + * \param[out] out_bits caller-provided buffer of size OSMO_ATRAU_FRAME_BITS + * \param[in] m_bits 2 M-bits associated with this 20 ms CSD frame + * \param[in] d_bits 288 user data bits in this 20 ms CSD frame + * \param[in] atrau_c4 value to be put into A-TRAU frame bit C4 + * \param[in] atrau_c5 value to be put into A-TRAU frame bit C5 + */ +void osmo_csd144_to_atrau_bits(ubit_t *out_bits, const ubit_t *m_bits, + const ubit_t *d_bits, ubit_t atrau_c4, + ubit_t atrau_c5); + +/*! Convert one 20 ms frame of csd144 from user form to A-TRAU frame; + * the output is the external output form with RA2 applied. + * + * \param[out] out_bytes caller-provided buffer of size OSMO_ATRAU_RA2_OCTETS + * \param[in] m_bits 2 M-bits associated with this 20 ms CSD frame + * \param[in] d_bits 288 user data bits in this 20 ms CSD frame + * \param[in] atrau_c4 value to be put into A-TRAU frame bit C4 + * \param[in] atrau_c5 value to be put into A-TRAU frame bit C5 + */ +void osmo_csd144_to_atrau_ra2(uint8_t *out_bytes, const ubit_t *m_bits, + const ubit_t *d_bits, ubit_t atrau_c4, + ubit_t atrau_c5); diff --git a/src/Makefile.am b/src/Makefile.am index 1df7f4c..6d8bc98 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -42,6 +42,7 @@ $(NULL) libosmotrau_la_LIBADD = $(COMMONLIBS) $(LIBOSMOCODEC_LIBS) $(ORTP_LIBS) libosmotrau_la_SOURCES = trau/csd_ra2.c \ + trau/raa_prime_encode.c \ trau/trau_frame.c \ trau/trau_pcu_ericsson.c \ trau/trau_sync.c \ diff --git a/src/trau/raa_prime_encode.c b/src/trau/raa_prime_encode.c new file mode 100644 index 0000000..754125f --- /dev/null +++ b/src/trau/raa_prime_encode.c @@ -0,0 +1,139 @@ +/* + * This C module contains the implementation of RAA' (RAA-prime) function + * in the encoding direction, from user bits to A-TRAU frame. + * The interface is defined in <osmocom/trau/csd_raa_prime.h>. + * + * Author: Mychaela N. Falconia <falcon(a)freecalypso.org>, 2024 - however, + * Mother Mychaela's contributions are NOT subject to copyright. + * No rights reserved, all rights relinquished. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#include <stdint.h> +#include <stdbool.h> +#include <string.h> +#include <osmocom/core/bits.h> +#include <osmocom/core/utils.h> +#include <osmocom/trau/csd_raa_prime.h> +#include <osmocom/trau/csd_ra2.h> + +/* max possible number of Z-sequences per 36-bit subframe */ +#define MAX_ZSEQ_CNT 4 + +static bool is_z_seq(const ubit_t *d_bits) +{ + int i; + + for (i = 0; i < 8; i++) { + if (d_bits[i]) + return false; + } + return true; +} + +static unsigned find_z_seqs(const ubit_t *d_bits, uint8_t *zseq_pos) +{ + unsigned idx, count; + + count = 0; + for (idx = 0; idx <= 28; ) { + if (is_z_seq(d_bits + idx)) { + zseq_pos[count++] = idx; + idx += 8; + } else + idx++; + } + return count; +} + +static void encode_zsp(ubit_t *out_bits, uint8_t pos_0based, bool is_final) +{ + uint8_t pos_1based = pos_0based + 1; + + *out_bits++ = 1; + *out_bits++ = is_final; + *out_bits++ = (pos_1based >> 4) & 1; + *out_bits++ = (pos_1based >> 3) & 1; + *out_bits++ = (pos_1based >> 2) & 1; + *out_bits++ = (pos_1based >> 1) & 1; + *out_bits++ = (pos_1based >> 0) & 1; + *out_bits++ = 1; +} + +static void atrau_pack_subframe(ubit_t *out_bits, const ubit_t *d_bits) +{ + uint8_t zseq_pos[MAX_ZSEQ_CNT]; + unsigned zseq_count, n; + unsigned in_pos, z_pos, numd; + + zseq_count = find_z_seqs(d_bits, zseq_pos); + /* weed out the trivial case of no substitution needed */ + if (zseq_count == 0) { + out_bits[0] = 1; /* Zi bit */ + memcpy(out_bits + 1, d_bits, 36); + return; + } + /* we do need substitution: set Zi accordingly */ + *out_bits++ = 0; + in_pos = 0; + for (n = 0; n < zseq_count; n++) { + z_pos = zseq_pos[n]; + encode_zsp(out_bits, z_pos, n == zseq_count - 1); + out_bits += 8; + OSMO_ASSERT(z_pos >= in_pos); + numd = z_pos - in_pos; + memcpy(out_bits, d_bits + in_pos, numd); + out_bits += numd; + in_pos += numd + 8; + } + OSMO_ASSERT(in_pos <= 36); + numd = 36 - in_pos; + memcpy(out_bits, d_bits + in_pos, numd); +} + +void osmo_csd144_to_atrau_bits(ubit_t *out_bits, const ubit_t *m_bits, + const ubit_t *d_bits, ubit_t atrau_c4, + ubit_t atrau_c5) +{ + int subf; + + /* sync pattern: 16 zeros followed by a single one */ + memset(out_bits, 0, 16); + out_bits[16] = 1; + /* C1..C5 per TS 48.020 section 11.1 */ + out_bits[17] = 0; + out_bits[18] = 1; + out_bits[19] = 1; + out_bits[20] = atrau_c4; + out_bits[21] = atrau_c5; + /* the two M-bits are pass-through */ + out_bits[22] = m_bits[0]; + out_bits[23] = m_bits[1]; + /* done with the header, do the 8 subframes */ + out_bits += 24; + for (subf = 0; subf < 8; subf++) { + atrau_pack_subframe(out_bits, d_bits); + d_bits += 36; + out_bits += 37; + } +} + +void osmo_csd144_to_atrau_ra2(uint8_t *out_bytes, const ubit_t *m_bits, + const ubit_t *d_bits, ubit_t atrau_c4, + ubit_t atrau_c5) +{ + ubit_t atrau_bits[OSMO_ATRAU_FRAME_BITS]; + + osmo_csd144_to_atrau_bits(atrau_bits, m_bits, d_bits, atrau_c4, + atrau_c5); + osmo_csd_ra2_16k_pack(out_bytes, atrau_bits, OSMO_ATRAU_RA2_OCTETS); +} diff --git a/tests/Makefile.am b/tests/Makefile.am index e50a3b7..d50b09a 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -7,6 +7,7 @@ ipa_proxy_test \ subchan_demux/subchan_demux_test \ ipa_recv/ipa_recv_test \ + raa_prime/test_enc \ trau_conv/trau16_to_rtp \ trau_sync/trau_sync_test \ trau_pcu_ericsson/trau_pcu_ericsson_test @@ -38,6 +39,10 @@ $(LIBOSMOCORE_LIBS) $(LIBOSMOGSM_LIBS) \ $(LIBOSMOVTY_LIBS) +raa_prime_test_enc_SOURCES = raa_prime/test_enc.c +raa_prime_test_enc_LDADD = $(top_builddir)/src/libosmotrau.la \ + $(LIBOSMOCORE_LIBS) + rtp_test_rtp_test_SOURCES = rtp_test/rtp_test.c rtp_test_rtp_test_LDADD = $(top_builddir)/src/libosmotrau.la \ $(LIBOSMOCORE_LIBS) @@ -76,6 +81,7 @@ EXTRA_DIST = testsuite.at $(srcdir)/package.m4 $(TESTSUITE) \ subchan_demux/subchan_demux_test.ok \ ipa_recv/ipa_recv_test.ok \ + raa_prime/d144-ul-input.asc raa_prime/nokia-tcsm2-atrau.hex \ rtp_test/rtp_test.ok \ trau_conv/trau16_efr.in trau_conv/trau16_efr_std.ok \ trau_conv/trau16_efr_twts001.ok \ diff --git a/tests/raa_prime/README.test-data b/tests/raa_prime/README.test-data new file mode 100644 index 0000000..8f82704 --- /dev/null +++ b/tests/raa_prime/README.test-data @@ -0,0 +1,22 @@ +The two test data files presented here for unit testing of RAA' function are: + +d144-ul-input.asc + + This file is generated in Themyscira gsm-net-reveng Hg repository, + d144 subdirectory. The original hand-crafted input is a different + file in the same directory (ul-input); the present *.asc file is + the output of some helper programs maintained in the same place, + reformatted to be more directly suitable as a unit test for + libosmotrau RAA' encoding functions. + +nokia-tcsm2-atrau.hex + + This file is the A-interface output from a historical hardware TRAU + (Nokia TCSM2) whose input was the sequence of 290-bit "user" frames in + d144-ul-input.asc. It is raw E1 timeslot output that has been extracted + in perfect alignment and converted into hexadecimal representation, + with 80 hex digits per line. + +A correct RAA' encoder implementation should produce output identical to +nokia-tcsm2-atrau.hex when fed with d144-ul-input.asc, and vice-versa for +a correct RAA' decoder implementation. diff --git a/tests/raa_prime/d144-ul-input.asc b/tests/raa_prime/d144-ul-input.asc new file mode 100644 index 0000000..9f2c662 --- /dev/null +++ b/tests/raa_prime/d144-ul-input.asc @@ -0,0 +1,4 @@ +00 000000000001122345010101010080808080101010100f00f00f00f00f0000ffff807fff +01 aaaaaaaaafffffffff1abcd807ffff000ffff000f000fc0c0c0c00c0c0c0c03c0c0c0c07 +10 1007803001000000000000f0000008040201008040200008040300700a00568180222200 +11 1234567890505050503456789ab024abcdeffffff0000013670100013670101013660101 diff --git a/tests/raa_prime/nokia-tcsm2-atrau.hex b/tests/raa_prime/nokia-tcsm2-atrau.hex new file mode 100644 index 0000000..dad53a3 --- /dev/null +++ b/tests/raa_prime/nokia-tcsm2-atrau.hex @@ -0,0 +1,16 @@ +3F3F3F3F3F3F3F3FBFFFBF3F7F3F3F7FFF3FBF7FFF7F3F7FFFFFBF7FBF3F3FFF3F3FFF3F7F3F7F3F +BF3FBF3FFF7F3F7F7FBF3F3F3FBF3F3F3FBF3F3F3FBF3F3F3FBF3F7F3F3FBF3F3F3FBF3F3F3FBF3F +3F3FBF3F3F3F7FFFFF7FBF3FBF3F3F3FBF3F3F3FBF3F3F3FBFBF3FBFFFFFFFBFBF3FFFFFFFFFFFBF +FFFFFF7F3F7F7FFFFFFF7F3F7FFFFFFFFFBF7FFFFFBFFF7FFF7FFFFFFFFFFFFFFFFFFFFFFFFFFFFF +3F3F3F3F3F3F3F3FBFFFBF7FFF7F7F7F7F7F7F7F7F7F7F7F7F7F7F7F7F7F7FFFFFFFFFFFFFFFFFFF +FFFFFFFFFFFFFFFFFF7FFF7FBFBF3FFF7F7F7FFFBF7FBFFFFFFFFFBFFF7FBFFFFFFFFFFFFFFF3F3F +FFFFFFFFFFFF7F3F7F7FFFFFFFFF7F7FBF3F7FFFBF3F7FFFBFFFFF7FFFFF3F3F3FFF3F3F3FFF3F3F +3FFF3F7FFFBFFFFFBF3F3F7FBF3F3F7FBF3F3F7FFFFFFF3F3F3FFF3F3F3FFF3F3F3FFF3F3F3F7FFF +3F3F3F3F3F3F3F3FBFFFBFBF7F3F7F7FBF3FFF7F3FBFBFFFFFFFFFBFFF7FBFBF3FBFFF3F7FBF7FBF +FFBFBFBFFFFFFFBFFF7F3F3F7FFF3FBF7FFF7F7F7FFFFFFFFFFF7FBFBF3F3FFFBF7F7F7FFF7F3FFF +FFFFFFBF7FFF7F3F3F7FFF3FBFBFFFBFBF7FFFFFFFFF3FFF3FBF3F3FFFBF7F7F7FFF7F3FFFFFFFFF +BFFFFF7F3F7F7FBFFFFFFF3F3FFF7F3FBFBFFF7F3F3FBF3FFF7F3F7FFFFFFF3FBFBF3FBF3FBF3FBF +3F3F3F3F3F3F3F3FBFFFBFFFBF3FBF7F3F7FBFBF3FBFBFFF3FFFFF3F7F3FFF3F3F7F7F3F3F7F7F3F +3F7F7F3F3F7F7F3F3FBF7FBFBF3FBFBFFF3FFFFF3F7F3FFF7F7F7FFF3F3F3FBF7F3FBFBFBFFFFF3F +FF7FFFBFFFFF7F7F7F7FFFFFFFFFFFFFFFFFFFFFFFFFFF7FBFFFFFBFFF3F3F3F7F3FFF7FBF7FFF3F +3F3F7FBF3F3F3FBF7FBFFF3FFFBF3F3F3FBF3F3F3FBFFFBFBF7F3F3F3F7F3FFF7FBF7FFF3F3F3F7F diff --git a/tests/raa_prime/test_enc.c b/tests/raa_prime/test_enc.c new file mode 100644 index 0000000..8e18f3f --- /dev/null +++ b/tests/raa_prime/test_enc.c @@ -0,0 +1,143 @@ +/* + * This C module is a unit test program for libosmotrau implementation + * of RAA' function in the encoding direction. + * + * Author: Mychaela N. Falconia <falcon(a)freecalypso.org>, 2024 - however, + * Mother Mychaela's contributions are NOT subject to copyright. + * No rights reserved, all rights relinquished. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#include <ctype.h> +#include <stdio.h> +#include <stdint.h> +#include <stdbool.h> +#include <stdlib.h> +#include <string.h> + +#include <osmocom/core/bits.h> +#include <osmocom/core/utils.h> +#include <osmocom/trau/csd_raa_prime.h> + +/* + * The output A-TRAU frame in RA2 dressing is 160 binary bytes. + * But instead of emitting it as a single hex line of 320 digits + * followed by a single newline, we split it into 4 hex lines + * of 80 characters each. This approach is taken because the + * hex file against which we'll be comparing our output comes from + * Themyscira Wireless, and ThemWi (unlike Osmocom) treats the + * 80 characters line length as absolute and inviolable. + */ +static void print_hex_output(const uint8_t *bin) +{ + int i, j, n; + + n = 0; + for (i = 0; i < 4; i++) { + for (j = 0; j < 40; j++) + printf("%02X", bin[n++]); + putchar('\n'); + } +} + +static void process_record(const char *mbits_arg, const char *hex_str) +{ + uint8_t input_bytes[36]; + ubit_t m_bits[2], d_bits[288]; + uint8_t outbuf[OSMO_ATRAU_RA2_OCTETS]; + + m_bits[0] = mbits_arg[0] - '0'; + m_bits[1] = mbits_arg[1] - '0'; + osmo_hexparse(hex_str, input_bytes, sizeof(input_bytes)); + osmo_pbit2ubit(d_bits, input_bytes, sizeof(d_bits)); + /* + * We set C4=1 as will always be the case in BSS->IWF direction: + * see Table 3 in TS 48.020 section 11.1. We set C5=0 in this + * unit test to match the condition that existed in the hw test + * setup with Nokia TCSM2, which was used to produce the A-TRAU + * output we'll be comparing against. + */ + osmo_csd144_to_atrau_ra2(outbuf, m_bits, d_bits, 1, 0); + print_hex_output(outbuf); +} + +static void process_line(char *linebuf, const char *infname, int lineno) +{ + char *cp = linebuf, *mbits_arg, *hex_str; + int ndig; + + while (isspace(*cp)) + cp++; + if (*cp == '\0' || *cp == '#') + return; + /* expect M-bits argument */ + mbits_arg = cp; + for (ndig = 0; ndig < 2; ndig++) { + if (*cp != '0' && *cp != '1') + goto inv; + cp++; + } + if (!isspace(*cp)) + goto inv; + *cp++ = '\0'; + while (isspace(*cp)) + cp++; + if (*cp == '\0' || *cp == '#') + goto inv; + /* expect string of 72 hex digits */ + hex_str = cp; + for (ndig = 0; ndig < 72; ndig++) { + if (!isxdigit(*cp)) + goto inv; + cp++; + } + if (*cp) { + if (!isspace(*cp)) + goto inv; + *cp++ = '\0'; + } + /* must be end of non-comment line */ + while (isspace(*cp)) + cp++; + if (*cp != '\0' && *cp != '#') + goto inv; + + process_record(mbits_arg, hex_str); + return; + +inv: fprintf(stderr, "%s line %d: invalid syntax\n", infname, lineno); + exit(1); +} + +int main(int argc, char **argv) +{ + const char *infname; + FILE *inf; + char linebuf[256]; + int lineno; + + if (argc != 2) { + fprintf(stderr, "usage: %s input-file\n", argv[0]); + exit(1); + } + infname = argv[1]; + inf = fopen(infname, "r"); + if (!inf) { + perror(infname); + exit(1); + } + + for (lineno = 1; fgets(linebuf, sizeof(linebuf), inf); lineno++) + process_line(linebuf, infname, lineno); + fclose(inf); + exit(0); +} diff --git a/tests/testsuite.at b/tests/testsuite.at index 2528eb8..c430220 100644 --- a/tests/testsuite.at +++ b/tests/testsuite.at @@ -30,6 +30,12 @@ AT_CHECK([$abs_top_builddir/tests/rtp_test/rtp_test], [ignore], [expout]) AT_CLEANUP +AT_SETUP([raa_prime_encode]) +AT_KEYWORDS([raa_prime_encode]) +cat $abs_srcdir/raa_prime/nokia-tcsm2-atrau.hex > expout +AT_CHECK([$abs_top_builddir/tests/raa_prime/test_enc $abs_srcdir/raa_prime/d144-ul-input.asc], [0], [expout], [ignore]) +AT_CLEANUP + AT_SETUP([trau_sync]) AT_KEYWORDS([trau_sync]) cat $abs_srcdir/trau_sync/trau_sync_test.ok > expout -- To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/38292?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: libosmo-abis Gerrit-Branch: master Gerrit-Change-Id: I11fc1529f5be88fa778c7e05cb11eef58a389d40 Gerrit-Change-Number: 38292 Gerrit-PatchSet: 5 Gerrit-Owner: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[L] Change in libosmo-abis[master]: libosmotrau: implement RAA' decoder function
by falconia 02 Oct '24

02 Oct '24
Attention is currently required from: fixeria, laforge, pespin. falconia has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/libosmo-abis/+/38293?usp=email ) Change subject: libosmotrau: implement RAA' decoder function ...................................................................... Patch Set 5: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/38293?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: libosmo-abis Gerrit-Branch: master Gerrit-Change-Id: I1347a25ce97d5022502ee9112caded66315b09a4 Gerrit-Change-Number: 38293 Gerrit-PatchSet: 5 Gerrit-Owner: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Wed, 02 Oct 2024 14:25:22 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[L] Change in libosmo-abis[master]: libosmotrau: implement RAA' encoder function
by falconia 02 Oct '24

02 Oct '24
Attention is currently required from: fixeria, laforge, pespin. falconia has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/libosmo-abis/+/38292?usp=email ) Change subject: libosmotrau: implement RAA' encoder function ...................................................................... Patch Set 5: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/38292?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: libosmo-abis Gerrit-Branch: master Gerrit-Change-Id: I11fc1529f5be88fa778c7e05cb11eef58a389d40 Gerrit-Change-Number: 38292 Gerrit-PatchSet: 5 Gerrit-Owner: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Wed, 02 Oct 2024 14:25:04 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[XL] Change in pysim[master]: tests: sanitize all cards before running tests
by osmith 02 Oct '24

02 Oct '24
Attention is currently required from: dexter, fixeria, laforge. osmith has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/pysim/+/38254?usp=email ) Change subject: tests: sanitize all cards before running tests ...................................................................... Patch Set 4: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/38254?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I42eaf61280968518164f2280245136fd30a603ce Gerrit-Change-Number: 38254 Gerrit-PatchSet: 4 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-CC: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-CC: laforge <laforge(a)osmocom.org> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Wed, 02 Oct 2024 13:18:53 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[XL] Change in pysim[master]: tests: sanitize all cards before running tests
by dexter 02 Oct '24

02 Oct '24
Attention is currently required from: fixeria, laforge, osmith. dexter has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/pysim/+/38254?usp=email ) Change subject: tests: sanitize all cards before running tests ...................................................................... Patch Set 4: (1 comment) Patchset: PS1: > As discussed with dexter, added a separate jenkins job that runs nightly and can be triggered manual […] I think we should merge this patch for now and do the multi threading patch in a followup patch. Maybe we can get good enough performance that we can afford to run the sanitizer before every test cycle. -- To view, visit https://gerrit.osmocom.org/c/pysim/+/38254?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I42eaf61280968518164f2280245136fd30a603ce Gerrit-Change-Number: 38254 Gerrit-PatchSet: 4 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-CC: laforge <laforge(a)osmocom.org> Gerrit-CC: osmith <osmith(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Comment-Date: Wed, 02 Oct 2024 13:14:57 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: osmith <osmith(a)sysmocom.de> Comment-In-Reply-To: laforge <laforge(a)osmocom.org> Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-ci[master]: jobs/simtester-sanitize: new job
by dexter 02 Oct '24

02 Oct '24
Attention is currently required from: osmith. dexter has posted comments on this change by osmith. ( https://gerrit.osmocom.org/c/osmo-ci/+/38318?usp=email ) Change subject: jobs/simtester-sanitize: new job ...................................................................... Patch Set 1: Code-Review+1 (1 comment) Patchset: PS1: I can not say too much about this, but the yml file looks reasonable to me. -- To view, visit https://gerrit.osmocom.org/c/osmo-ci/+/38318?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-ci Gerrit-Branch: master Gerrit-Change-Id: Ie1846b031224a2a9604c22e7d81016c08e217bbc Gerrit-Change-Number: 38318 Gerrit-PatchSet: 1 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-Comment-Date: Wed, 02 Oct 2024 13:06:02 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes
1 0
0 0
[XL] Change in pysim[master]: tests: sanitize all cards before running tests
by dexter 02 Oct '24

02 Oct '24
Attention is currently required from: fixeria, laforge, osmith. dexter has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/pysim/+/38254?usp=email ) Change subject: tests: sanitize all cards before running tests ...................................................................... Patch Set 4: (1 comment) File contrib/jenkins.sh: https://gerrit.osmocom.org/c/pysim/+/38254/comment/370df3f5_e19bcd79?usp=em… : PS3, Line 36: tests/card_sanitizer/card_sanitizer.py > this needs to be removed, as discussed a separate jenkins job calls the script now. […] Done -- To view, visit https://gerrit.osmocom.org/c/pysim/+/38254?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I42eaf61280968518164f2280245136fd30a603ce Gerrit-Change-Number: 38254 Gerrit-PatchSet: 4 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-CC: laforge <laforge(a)osmocom.org> Gerrit-CC: osmith <osmith(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Comment-Date: Wed, 02 Oct 2024 12:47:10 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: osmith <osmith(a)sysmocom.de>
1 0
0 0
[XL] Change in pysim[master]: tests: sanitize all cards before running tests
by dexter 02 Oct '24

02 Oct '24
Attention is currently required from: dexter, fixeria, laforge. Hello Jenkins Builder, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/pysim/+/38254?usp=email to look at the new patch set (#4). The following approvals got outdated and were removed: Verified+1 by Jenkins Builder Change subject: tests: sanitize all cards before running tests ...................................................................... tests: sanitize all cards before running tests Even though our tests are written in a way that they shouldn't interfere with each other, it may happen that one testrun writes content to a file that upsets a different testrun. The resulting problems are often difficult to diagnose. To minimize the problem, let's reset the cards to a defined state before running the actual tests. This can be done using pySim-shell's export feature. We can generate a backup from a known good state and then play back the backup to reset files that have been changed. Files that didn't change will not be written thanks to the conserve_write feature of pySim-shell. Related: OS#4384 Change-Id: I42eaf61280968518164f2280245136fd30a603ce --- A tests/card_sanitizer/card_backup_3b991800118822334455667760_2222334455667788990.script A tests/card_sanitizer/card_backup_3b9a940092027593110001020221_1122334455667788990.script A tests/card_sanitizer/card_backup_3b9f95801fc78031e073f62113674d4516004301008f_89445310150011013678.script A tests/card_sanitizer/card_backup_3b9f96801f878031e073fe211b674a357530350265f8_8949440000001155314.script A tests/card_sanitizer/card_backup_3b9f96801f878031e073fe211b674a4c753034054ba9_8988211000000467343.script A tests/card_sanitizer/card_backup_3b9f96801fc78031a073be21136743200718000001a5_8988211320300000028.script A tests/card_sanitizer/card_backup_3b9f96801fc78031a073be21136744220610000001a9_8988219000000117833.script A tests/card_sanitizer/card_data.csv A tests/card_sanitizer/card_sanitizer.py 9 files changed, 18,132 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/54/38254/4 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/38254?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: newpatchset Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I42eaf61280968518164f2280245136fd30a603ce Gerrit-Change-Number: 38254 Gerrit-PatchSet: 4 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-CC: laforge <laforge(a)osmocom.org> Gerrit-CC: osmith <osmith(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
1 0
0 0
[XS] Change in osmo-ci[master]: jobs/master-builds: add param EMAIL_NOTIFICATIONS
by pespin 02 Oct '24

02 Oct '24
Attention is currently required from: osmith. pespin has posted comments on this change by osmith. ( https://gerrit.osmocom.org/c/osmo-ci/+/38320?usp=email ) Change subject: jobs/master-builds: add param EMAIL_NOTIFICATIONS ...................................................................... Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-ci/+/38320?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-ci Gerrit-Branch: master Gerrit-Change-Id: Ia8fa57f1efd04684f08db4377c42358c534faff9 Gerrit-Change-Number: 38320 Gerrit-PatchSet: 1 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-Comment-Date: Wed, 02 Oct 2024 10:05:16 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 158
  • 159
  • 160
  • 161
  • 162
  • 163
  • 164
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.