diff options
author | Christopher Vogl <christopher.vogl@hale.at> | 2012-12-17 17:07:51 +0100 |
---|---|---|
committer | Denis Kenzior <denkenz@gmail.com> | 2012-12-17 10:17:19 -0600 |
commit | 157c365ca58517ef42fe42d523d7ebd9af610db7 (patch) | |
tree | 5d7e026dacda0f156c82a5f0819504420b2b2966 /plugins/telit.c | |
parent | 404f2e3cb937d53f70750b0e1834d63a834bb7bf (diff) | |
download | ofono-157c365ca58517ef42fe42d523d7ebd9af610db7.tar.bz2 |
telit: set baud rate to 115200
Telit HE910 needs the baud rate to be set.
Diffstat (limited to 'plugins/telit.c')
-rw-r--r-- | plugins/telit.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/plugins/telit.c b/plugins/telit.c index fe2ccd6f..79bc4219 100644 --- a/plugins/telit.c +++ b/plugins/telit.c @@ -186,6 +186,7 @@ static GAtChat *open_device(struct ofono_modem *modem, GAtSyntax *syntax; GIOChannel *channel; GAtChat *chat; + GHashTable *options; device = ofono_modem_get_string(modem, key); if (device == NULL) @@ -193,7 +194,16 @@ static GAtChat *open_device(struct ofono_modem *modem, DBG("%s %s", key, device); - channel = g_at_tty_open(device, NULL); + options = g_hash_table_new(g_str_hash, g_str_equal); + if (options == NULL) + return NULL; + + g_hash_table_insert(options, "Baud", "115200"); + + channel = g_at_tty_open(device, options); + + g_hash_table_destroy(options); + if (channel == NULL) return NULL; |