1
Vote

Incoming call: RING not checked

description

When I get an incoming call on the module I don't get the "+CLIP" response, only "RING" but that does not raise an event. I've attached a debug log from PowerOn to CallEnded (hung up because I got the voicemail).
 
Proposed solution:
 
Add to Serial Reader Thread:
#region Check Incoming Call (RING)
if (response.IndexOf("RING") > 0)
{
    OnPhoneRing(this);
}
#endregion
 
Add to region DELEGATES AND EVENTS:
#region Phone ring
/// <summary>
/// Represents the delegate used for the <see cref="PhoneRing"/> event.
/// </summary>
/// <param name="sender">The object that raised the event.</param>
public delegate void PhoneRingHandler(CellularRadio sender);
/// <summary>
/// Event raised when the module detects a phone ring.
/// </summary>
public event PhoneRingHandler PhoneRing;
private PhoneRingHandler onPhoneRing;
 
/// <summary>
/// Raises the <see cref="PhoneRing"/> event.
/// </summary>
/// <param name="sender">The object that raised the event.</param>  
protected virtual void OnPhoneRing(CellularRadio sender)
{
    if (onPhoneRing == null) onPhoneRing = new PhoneRingHandler(PhoneRing);
    if (Program.CheckAndInvoke(PhoneRing, onPhoneRing, sender))
    {
        PhoneRing(sender);
    }
}
#endregion

file attachments

comments