Hi!
I just found some time to have a look at the recent commit history and had a look at the SIM related code and had the following suggestions:
1) split the definitions from GSM TS 11.11 into a separate header file from the definitions that are OsmocomBB specific, and move the 11.11 header file into libosmocore
2) use msgb's for SIM messages. This way we can avoid all those manual buffer[N] = M type assignments and rather use msgb_put() constructs
3) even if not going for suggestion '2', it might be good to add some kind of a inline function abstracting out all the blocks that look like + buffer[0] = GSM1111_CLASS_GSM; + buffer[1] = GSM1111_INST_TERMINAL_PROFILE; + buffer[2] = 0x00; + buffer[3] = 0x00; + buffer[4] = length; with something like a "sim_buf_init(buffer, GSM11_INST_TERMINAL_PROFILE);"
Of course those are simply suggestions... maybe for the day where somebody on this list is feeling bored and is looking for a quick and easy task to resolve.
Regards, Harald
baseband-devel@lists.osmocom.org