Dear baseband-developers team, Would you be so kind to advise me on the following: I desire (dramatically want very much) to learn / understand Osmocom projects. I am a beginner in programming and i try to understand / learn C files that the project is build of. As an example i tried to learn / understand for example an Osmocom message buffer — msgb.h file. But immediately faced some syntax difficulties: This is the extract of msgb.h file: struct msgb { struct llist_head list; /*!< \brief linked list header */
/* Part of which TRX logical channel we were received / transmitted */ /* FIXME: move them into the control buffer */ union { void *dst; /*!< \brief reference of origin/destination */ struct gsm_bts_trx *trx; }; As it can be seen a structure «msgb» has as one of its components another structure — «gsm_bts_trx» But in whole Osmocom BB project files i could not find definition / description of struct «gsm_bts_trx». Would you kindly advise me please how to see which components / constituents / elements are in this gsm_bts_trx structure? From which components is struct gsm_bts_trx build of? Thank you so much for your kind advise. -- Mario Lucas
Hello Mario,
I think you have not checked everywhere :). Even a quick google search (if you don't want use grep) for gsm_bts_trx returns the file: bts_trx.h https://github.com/osmocom/osmo-bts/blob/master/include/osmo-bts/bts_trx.h
Cheers, Domi
On Thu, Nov 19, 2020 at 7:28 PM Mario Lucas mariolucas75@mail.ru wrote:
Dear baseband-developers team,
Would you be so kind to advise me on the following:
I desire (dramatically want very much) to learn / understand Osmocom projects. I am a beginner in programming and i try to understand / learn C files that the project is build of.
As an example i tried to learn / understand for example an Osmocom message buffer — msgb.h file.
But immediately faced some syntax difficulties:
This is the extract of msgb.h file:
struct msgb { struct llist_head list; /*!< \brief linked list header */
/* Part of which TRX logical channel we were received / transmitted */ /* FIXME: move them into the control buffer */ union { void *dst; /*!< \brief reference of origin/destination */ struct gsm_bts_trx *trx; };As it can be seen a structure «msgb» has as one of its components another structure — «gsm_bts_trx»
But in whole Osmocom BB project files i could not find definition / description of struct «gsm_bts_trx».
Would you kindly advise me please how to see which components / constituents / elements are in this gsm_bts_trx structure? From which components is struct gsm_bts_trx build of?
Thank you so much for your kind advise.
-- Mario Lucas
On Thu, Nov 19, 2020 at 09:27:39PM +0300, Mario Lucas wrote:
As it can be seen a structure «msgb» has as one of its components another structure — «gsm_bts_trx»
to be specific, the gsm_bts_trx is not a component of the msgb, but a _pointer_ to the gsm_bts_trx (i.e. a reference) may be present in the msgb.
But in whole Osmocom BB project files i could not find definition / description of struct «gsm_bts_trx».
libosmocore is primarily used by dozens of other osmocom projects, particularly every Osmocom CNI project. The gsm_bts_trx is likely used in osmo-bsc and osmo-bts.
Dear baseband-developers team, Thank you for your advise. Would you please advise — in order to learn / understand structure of C coding in Osmocom things, which relatively easy osmocom sub-project would you advise me to start to / learn? I mean instead of rush and head hit against some difficult C codes in Osmocom — to have relatively easy kind of «sub-project» of Osmococom for start learning purposes…. Thank you
Четверг, 19 ноября 2020, 23:45 +04:00 от Harald Welte laforge@osmocom.org: On Thu, Nov 19, 2020 at 09:27:39PM +0300, Mario Lucas wrote:
As it can be seen a structure «msgb» has as one of its components another structure — «gsm_bts_trx»
to be specific, the gsm_bts_trx is not a component of the msgb, but a _pointer_ to the gsm_bts_trx (i.e. a reference) may be present in the msgb.
But in whole Osmocom BB project files i could not find definition / description of struct «gsm_bts_trx».
libosmocore is primarily used by dozens of other osmocom projects, particularly every Osmocom CNI project. The gsm_bts_trx is likely used in osmo-bsc and osmo-bts.
--
- Harald Welte < laforge@osmocom.org > http://laforge.gnumonks.org/
============================================================================ "Privacy in residential applications is a desirable marketing option." (ETSI EN 300 175-7 Ch. A6)
-- Mario Lucas
On Thu, Nov 19, 2020 at 10:57:14PM +0300, Mario Lucas wrote:
I mean instead of rush and head hit against some difficult C codes in Osmocom — to have relatively easy kind of «sub-project» of Osmococom for start learning purposes….
Sorry to dissappoint you, but all of Osmocom code is inherently relatively complex. It is neither practical nor required to understand all of it, we are numerous "experts" with knowledge in specific parts.
The only way that I gained knowledge about Osmocom so far is that I get a specific task ("Implement X" or "Fix Y") and then bang my head against it until I understand what is going on. It is almost never easy, I often need help first.
If you could formulate a specific motivation, a specific aspect of what part of GSM you are interested in, that could help you to gain some entry and ask helpful questions.
Knowing C is a necessary prerequisite, I'd say it is prohibitively hard to learn C *and* Osmocom code at the same time.
~N
baseband-devel@lists.osmocom.org