Binding CDS call with Serial output | Telit Cinterion IoT Developer Community
July 25, 2016 - 4:51pm, 5611 views
Hi all!
I'm trying to create a bridge connection between a GSM call and other device (via Serial port) using Gemalto Concept Board.
Up to now, I'm managing the calls with the code provided in Call4Fan. But as PPP from Java is not suported (link) I don't know how to do it.
I suspect that ATO command it's what I'm looking for but I don't know how I can bind it to the serial output.
Any sugestion?
Thanks in advance.
Hi,
I suppose, by GSM call, you mean CSD? If so try to send ATA when the ring comes. Then use ATCommend methods:
getDataInputStream();
getDataOuputStream();
Than you can write a simple code to bind this into CommConnection streams.
Hope this helps.
Best regards,
Michał
Hi!
First all all, thank you for the help. It was exactly what I needed.
I've implemented the answer call in the RING Listener.
And the binding method:
The problem is that an IOException occurs: ATCommand class instance is not in transparent data mode.
I googled it and I found a thread in the forum. It seems it's not closed as I tried the Jure's solution and didn't work for me.
Any idea about what is happening?
Hi,
Can you show me how do you create ATCommand object?
Best regards,
Michał
Sure!
ATCommand m_Cmd is a global variable that is initialized at the constructor and used at the Listener.
Here is the code:
Change:
To:
(description of this parameter is in Java Doc)
Best regards,
Michał
Hi,
I could find the documentation for the ATCommand. Could you please link me to that?
Anyway I've tried to change new ATCommand(false) to ATCommand(true) but didn't solve the problem.
In fact. I've created 2 ATCommand Objects. One to attach the Listener and other to send commands inside the listener and this is the behaviour when we change between true & false in ATCommand when creating:
ATCommand(true) in the constructor: IllegalStateException. openATCommand: no channel available.
ATCommand(false) in the constructor and ATCommand(true) in Listener. openATCommand: no channel available ((when calling)).
ATCommand(false) in the constructor and ATCommand(false). IOException: ATCommand class instance is not in transparent data mode
After installing WTK for Gemalto modules, you will find documentation here:
file:///C:/Program%20Files%20(x86)/Cinterion/CMTK/EHS5/WTK/doc/html_impng/index.html
ATCommand(true) in the constructor: IllegalStateException. openATCommand: no channel available.
Is thrown, because to many interpreters were created at one boot time, and not released by release() method. It is not enought to stop MIDlet to release ATCommand object. The release() method ***** to be used.
As for ATCommands. I suggest you to first write a test MIDlet, with only one instance of ATCommand object with 'true' parameter, and use it for CSD. Run this MIDlet fater module is reboot.
hi!
Solved the problem of "openATCommand: no channel available" and using new ATCommand(true).
I'm still getting the "IOException: ATCommand class instance is not in transparent data mode" while the communication.
The piece of code that fails is:
It fails after a while when executing pipe()
I hope it give you more information to know the problem.
Best regards!
Hello,
I can't see in your code that you verify the ATA reply and wait for "CONNECT" URC.
Could you also send the ATI1 reply so taht we could verify the firmware version.
Regards,
Bartłomiej
Pages