From: Denis Kenzior <denkenz@gmail.com>
To: ofono@ofono.org
Subject: Re: [PATCH] Added Wavecom modem plugin.
Date: Mon, 19 Apr 2010 16:29:37 -0500 [thread overview]
Message-ID: <201004191629.37572.denkenz@gmail.com> (raw)
In-Reply-To: <1271705668-23970-1-git-send-email-matgnt@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1814 bytes --]
Hi Matthias,
> The Wavecom WMP100 assumes CPIN to be the final response, therefore some
> special handling is neccessary (see
> 6d28f82dc1ccb3de3a028a88eafb96fb001c7e61). Now the vendor id
> OFONO_VENDOR_WAVECOM is passed with all "*create" functions.
You should also set your authorship information correctly. E.g. first + last
name.
> + options = g_hash_table_new_full(g_str_hash, g_str_equal,
> + g_free, g_free);
> + if (!options)
> + return -ENOMEM;
> +
> + for (i = 0; tty_opts[i]; i++) {
> + value = ofono_modem_get_string(modem, tty_opts[i]);
> +
> + if (value == NULL)
> + continue;
> +
> + g_hash_table_insert(options, g_strdup(tty_opts[i]),
> + g_strdup(value));
> + }
> +
> + channel = g_at_tty_open(device, options);
I suggest hardcoding these options (see calypso.c) unless you really want to
change them from modem.conf for some reason.
> + value = ofono_modem_get_string(modem, "GsmSyntax");
> + if (value) {
> + if (g_str_equal(value, "V1"))
> + syntax = g_at_syntax_new_gsmv1();
> + else if (g_str_equal(value, "Permissive"))
> + syntax = g_at_syntax_new_gsm_permissive();
> + else
> + return -EINVAL;
> + } else {
> + syntax = g_at_syntax_new_gsmv1();
> + }
Same here, you should know whether the wavecom is 27.007 compliant or not.
> + ofono_devinfo_create(modem, OFONO_VENDOR_WAVECOM, "atmodem", chat);
> + ofono_sim_create(modem, OFONO_VENDOR_WAVECOM, "atmodem", chat);
> + ofono_voicecall_create(modem, OFONO_VENDOR_WAVECOM, "atmodem", chat);
You really don't want to do that, only pass it to the place where it is
relevant (e.g. the SIM atom.) That way we know what quirks the modem actually
has instead of looking at all drivers just to find it has completely stock
behavior.
Regards,
-Denis
next prev parent reply other threads:[~2010-04-19 21:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-19 19:34 [PATCH] Added Wavecom modem plugin Matthias
2010-04-19 21:29 ` Denis Kenzior [this message]
2010-04-20 0:09 ` Matthias =?unknown-8bit?q?G=C3=BCnther?=
2010-04-20 17:03 ` Denis Kenzior
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201004191629.37572.denkenz@gmail.com \
--to=denkenz@gmail.com \
--cc=ofono@ofono.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.