Error Building OsmoTRX for LimeSDR from source

following @andrewback suggestion to compile/build from source.

running Ubuntu 18.04 on a vm.
following this link LimeSDR Build From Source - OsmoTRX - Open Source Mobile Communications

(other errors/warning happen when installing , missing dependencies and repos.
to be able to follow the first 2 stage u need sudo apt install autoconf-archive pkg-config libboost-all-dev libfftw3-dev libtalloc-dev libusrp-dev libpcsclite-dev libgnutls28-dev libgnutls-dev )

error comes when trying to follow
stage

Build osmo-trx-lms

make -j5

sdr@ubuntu:~/osmo-trx$ make -j5
make all-recursive
make[1]: Entering directory ‘/home/sdr/osmo-trx’
Making all in doc
make[2]: Entering directory ‘/home/sdr/osmo-trx/doc’
Making all in examples
make[3]: Entering directory ‘/home/sdr/osmo-trx/doc/examples’
make[3]: Nothing to be done for ‘all’.
make[3]: Leaving directory ‘/home/sdr/osmo-trx/doc/examples’
Making all in manuals
make[3]: Entering directory ‘/home/sdr/osmo-trx/doc/manuals’
make[3]: Nothing to be done for ‘all’.
make[3]: Leaving directory ‘/home/sdr/osmo-trx/doc/manuals’
make[3]: Entering directory ‘/home/sdr/osmo-trx/doc’
make[3]: Nothing to be done for ‘all-am’.
make[3]: Leaving directory ‘/home/sdr/osmo-trx/doc’
make[2]: Leaving directory ‘/home/sdr/osmo-trx/doc’
Making all in CommonLibs
make[2]: Entering directory ‘/home/sdr/osmo-trx/CommonLibs’
make[2]: Nothing to be done for ‘all’.
make[2]: Leaving directory ‘/home/sdr/osmo-trx/CommonLibs’
Making all in GSM
make[2]: Entering directory ‘/home/sdr/osmo-trx/GSM’
make[2]: Nothing to be done for ‘all’.
make[2]: Leaving directory ‘/home/sdr/osmo-trx/GSM’
Making all in Transceiver52M
make[2]: Entering directory ‘/home/sdr/osmo-trx/Transceiver52M’
Making all in arch
make[3]: Entering directory ‘/home/sdr/osmo-trx/Transceiver52M/arch’
Making all in common
make[4]: Entering directory ‘/home/sdr/osmo-trx/Transceiver52M/arch/common’
make[4]: Nothing to be done for ‘all’.
make[4]: Leaving directory ‘/home/sdr/osmo-trx/Transceiver52M/arch/common’
Making all in x86
make[4]: Entering directory ‘/home/sdr/osmo-trx/Transceiver52M/arch/x86’
make[4]: Nothing to be done for ‘all’.
make[4]: Leaving directory ‘/home/sdr/osmo-trx/Transceiver52M/arch/x86’
make[4]: Entering directory ‘/home/sdr/osmo-trx/Transceiver52M/arch’
make[4]: Nothing to be done for ‘all-am’.
make[4]: Leaving directory ‘/home/sdr/osmo-trx/Transceiver52M/arch’
make[3]: Leaving directory ‘/home/sdr/osmo-trx/Transceiver52M/arch’
Making all in device
make[3]: Entering directory ‘/home/sdr/osmo-trx/Transceiver52M/device’
Making all in lms
make[4]: Entering directory ‘/home/sdr/osmo-trx/Transceiver52M/device/lms’
CXX LMSDevice.lo
LMSDevice.cpp: In member function ‘virtual int LMSDevice::open(const string&, int, bool)’:
LMSDevice.cpp:160:41: error: too few arguments to function ‘int LMS_VCTCXORead(lms_device_t*, uint16_t*, bool)’
if (LMS_VCTCXORead(m_lms_dev, &dac_val) < 0)
^
In file included from LMSDevice.h:29:0,
from LMSDevice.cpp:23:
/usr/local/include/lime/LimeSuite.h:993:26: note: declared here
API_EXPORT int CALL_CONV LMS_VCTCXORead(lms_device_t * dev, uint16_t val, bool memory);
^~~~~~~~~~~~~~
LMSDevice.cpp:163:41: error: too few arguments to function ‘int LMS_VCTCXOWrite(lms_device_t
, uint16_t, bool)’
if (LMS_VCTCXOWrite(m_lms_dev, dac_val) < 0)
^
In file included from LMSDevice.h:29:0,
from LMSDevice.cpp:23:
/usr/local/include/lime/LimeSuite.h:982:26: note: declared here
API_EXPORT int CALL_CONV LMS_VCTCXOWrite(lms_device_t * dev, uint16_t val, bool memoty);
^~~~~~~~~~~~~~~
Makefile:449: recipe for target ‘LMSDevice.lo’ failed
make[4]: *** [LMSDevice.lo] Error 1
make[4]: Leaving directory ‘/home/sdr/osmo-trx/Transceiver52M/device/lms’
Makefile:432: recipe for target ‘all-recursive’ failed
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory ‘/home/sdr/osmo-trx/Transceiver52M/device’
Makefile:833: recipe for target ‘all-recursive’ failed
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory ‘/home/sdr/osmo-trx/Transceiver52M’
Makefile:516: recipe for target ‘all-recursive’ failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory ‘/home/sdr/osmo-trx’
Makefile:447: recipe for target ‘all’ failed
make: *** [all] Error 2

Additional parameter has been added to LMS_VCTCXORead(), LMS_VCTCXOWrite() functions for saving value to non-volatile storage. So either dont’t use the latest LimeSuite master(e.g. use stable branch or release v18.10.0 tag) or modify osmo-trx/Transceiver52M/device/lms/LMSDevice.cpp:
replace :

if (LMS_VCTCXORead(m_lms_dev, &dac_val) <0)
with:
if (LMS_VCTCXORead(m_lms_dev, &dac_val, false) <0)

and

if (LMS_VCTCXOWrite(m_lms_dev, &dac_val) < 0)
with:
if (LMS_VCTCXOWrite(m_lms_dev, &dac_val, false) < 0)

Edit: fixed LMS_VCTCXORead instead of LMS_VCTCXOWrite

the latest " release " (v4.0) does not recognize --with-lms

and u meant

if (LMS_VCTCXOWrite(m_lms_dev, &dac_val) < 0)
with:
if (LMS_VCTCXOWrite(m_lms_dev, &dac_val, false) < 0)

:smiley:
thanks that worked !

1 Like

Hi,

I created a ticket upstream in osmo-trx: https://osmocom.org/issues/3729

I’ll work on it sooon so both >18.10 and <=18.10 are supported (API change detected through autotools).

good job .

i were looking to report that issue , but they had no place in github to do that …

Hi,

fixed in osmo-trx 03b11620d9314465f8482ff234b78441496111a0 (current master).