4 Commits

Author SHA1 Message Date
300bdcc810 Wear SIP: revert to TCP registration (fixes INVITE retransmit timeout)
The UDP switch made the watch register over UDP while Asterisk had
cached a TCP Contact (transport=tcp). Asterisk sent the INVITE over
TCP but got no SIP response (not even 100 Trying) -> 6.4s
retransmission timeout -> immediate voicemail.

Revert to TCP so the watch's registration matches Asterisk's cached
contact. With nat=yes now set, the TCP Contact is made public
(78.141.29.181:<port>), so the INVITE arrives over the persistent TCP
socket and baresip's response reaches Asterisk, letting the call ring
the full configured window instead of timing out.
2026-08-20 23:19:39 +01:00
c88bee33d8 Wear SIP: register over UDP (NAT-friendly Contact)
Switch outbound transport from tcp to udp. With Asterisk peer
nat=yes, Asterisk now sends the INVITE to the public source address
(78.141.29.181:<port>) instead of the watch's private Contact, so
incoming calls traverse the NAT and reach the watch.

Verified: external incoming calls now arrive (uaEvent: incoming call
from external caller logged on the watch).
2026-08-20 23:03:15 +01:00
106ef4ed9d Wear SIP: switch account to 01273961147 + NAT-survival settings
- Account line now uses 01273961147 (same credential).
- sipnat=outbound + natpinhole=yes + regint=60 keep the NAT
  mapping/keep-alive fresh so Asterisk's INVITE (sent to the public
  Contact) reaches the watch behind NAT.

Note: sipnat=outbound is ineffective here because the outbound proxy
is the server itself (no edge STUN to learn the watch's public NAT
IP); the actual NAT fix is Asterisk-side (nat=force_rport,comedia on
the peer), which makes Asterisk target the public source address.
2026-08-20 22:40:59 +01:00
15e266cb43 Wear SIP: audio routing, stock-style dialer, DTMF, incoming-call handling, telecom scaffold
- AudioRouteManager: route to onboard speaker when no BT headset is
  connected, BT SCO when one is; set MODE_IN_COMMUNICATION + focus.
- aaudio: build with AAUDIO_PERFORMANCE_MODE_NONE so Android routing
  (speakerphone) is honoured instead of being bypassed by low-latency.
- DialerScreen: restyled to a stock-dialer layout (large number display,
  3x4 keypad with sub-letters, green call FAB, backspace, recent chips).
- InCallScreen: added DTMF keypad (sendDigit) for voicemail/IVR.
- WearBaresipService: on incoming call, wake screen + vibrate + bring
  activity to foreground so Answer/Decline is visible.
- Fixed dial normalization (bare extension -> full SIP URI with domain)
  and the uap parse in uaEvent so defaultUap is set and calls connect.
- config.static: load g711/opus codecs to resolve 488 Not Acceptable Here.
- Telecom scaffold (experiment): PhoneAccount + ConnectionService handed
  incoming calls via addNewIncomingCall to test stock Wear dialer pickup.
- Submodule libbaresip-android rebuilt with g711/opus/aaudio changes.

Verified: assembleDebug green, installs and registers on Galaxy Watch,
incoming call event fires and is handled without crashing.
2026-08-20 22:06:15 +01:00