Update Baresip instructions with accurate manual setup process
Based on actual user experience configuring Baresip Android app. Previous instructions were incorrect/incomplete. KEY CHANGES: 1. Removed /e/OS-specific language: - Now generic: "Use if Linphone has audio issues" - Applicable to all privacy ROMs, not just /e/OS 2. Accurate two-step setup process: - Step 1: Add account with just SIP URI (ext@domain) - Step 2: Edit account to add auth username, password, proxy - This matches actual app behavior 3. Critical field corrections: - Auth Username: JUST extension number (not ext@domain) - Outbound Proxy: JUST domain (not sip:server:port format) - Media Encryption: srtp (select from dropdown) 4. No provisioning URL: - Clarified Baresip doesn't support remote provisioning - Must configure manually (unlike Linphone) 5. Added top bar icon reference: - ☰ = Menu, ✓ = Save, ⋮ = Options - 📞 = Call, 🔊 = Speaker, 🔇 = Mute, ✕ = Hangup 6. Default action clarification: - May not exist in all Baresip versions - Provided alternatives: long-press or phone icon 7. Comprehensive troubleshooting: - Registration failure solutions - Dialing issues - Audio problems - Screen-off audio (rare with Baresip) 8. Extension dialing guidance: - Method 1: Just the number (101, 202) - Method 2: Full format (ext@domain) if needed 9. File renamed: - .conf → .txt for better readability on phones Output format: - Detailed step-by-step instructions - Quick reference summary at end - Troubleshooting section - Icon reference guide This addresses all user-reported configuration issues and provides accurate, tested setup instructions based on real app usage.
This commit is contained in:
+188
-88
@@ -1834,26 +1834,23 @@ EOSHELP
|
||||
}
|
||||
|
||||
create_baresip_config() {
|
||||
print_header "Create Baresip Account Config"
|
||||
print_header "Create Baresip Setup Instructions"
|
||||
load_config
|
||||
|
||||
local server_ip=$(hostname -I | cut -d' ' -f1)
|
||||
local domain="${DOMAIN_NAME:-$server_ip}"
|
||||
local transport="tcp"
|
||||
|
||||
if [[ "$ENABLE_TLS" == "y" && -n "$DOMAIN_NAME" ]]; then
|
||||
transport="tls"
|
||||
fi
|
||||
|
||||
echo "Baresip Config Generator"
|
||||
echo "Baresip Setup Guide Generator"
|
||||
echo "================================================"
|
||||
echo ""
|
||||
echo "Baresip works BETTER on /e/OS than Linphone!"
|
||||
echo "Better background audio handling."
|
||||
echo "Use Baresip if Linphone has audio issues (screen off, etc.)"
|
||||
echo "Baresip often works better on privacy-focused Android ROMs."
|
||||
echo ""
|
||||
echo "NOTE: Baresip does NOT support remote provisioning."
|
||||
echo " Manual configuration required."
|
||||
echo ""
|
||||
echo "Current Configuration:"
|
||||
echo " Domain: $domain"
|
||||
echo " Transport: $transport"
|
||||
echo " Server IP: $server_ip"
|
||||
echo ""
|
||||
|
||||
@@ -1866,74 +1863,176 @@ create_baresip_config() {
|
||||
read -p "Enter display name (e.g., Kitchen Phone): " display_name
|
||||
display_name=${display_name:-Extension $extension}
|
||||
|
||||
local config_file="$PROVISIONING_DIR/baresip-${extension}.conf"
|
||||
local config_file="$PROVISIONING_DIR/baresip-${extension}.txt"
|
||||
|
||||
mkdir -p "$PROVISIONING_DIR"
|
||||
|
||||
cat > "$config_file" << EOF
|
||||
# Baresip Account Configuration for Extension ${extension}
|
||||
# Generated by Easy Asterisk v0.9.9
|
||||
#
|
||||
# HOW TO USE:
|
||||
# 1. Install Baresip from F-Droid or Play Store
|
||||
# 2. Open Baresip → Menu → Accounts → Add Account
|
||||
# 3. Manually enter the SIP URI and settings below
|
||||
# OR copy this file to your phone and import
|
||||
#
|
||||
# ACCOUNT CONFIGURATION:
|
||||
# =====================
|
||||
cat > "$config_file" << 'BARESIPEOF'
|
||||
═══════════════════════════════════════════════════════════
|
||||
BARESIP SETUP INSTRUCTIONS
|
||||
Generated by Easy Asterisk v0.9.9
|
||||
═══════════════════════════════════════════════════════════
|
||||
|
||||
# Full account line format:
|
||||
<sip:${extension}@${domain}>;auth_pass=${sip_password};outbound="sip:${server_ip}:5060;transport=${transport}";regint=3600;pubint=0;answermode=manual;medianat=none
|
||||
IMPORTANT: Baresip does NOT support remote provisioning.
|
||||
You must configure manually following these steps.
|
||||
|
||||
# Explanation of parameters:
|
||||
# - sip:${extension}@${domain} = Your SIP URI
|
||||
# - auth_pass = Your password
|
||||
# - outbound = Asterisk server address
|
||||
# - regint=3600 = Re-register every hour
|
||||
# - pubint=0 = Don't publish presence
|
||||
# - answermode=manual = Don't auto-answer
|
||||
# - medianat=none = No NAT for media (LAN use)
|
||||
STEP 1: INSTALL BARESIP
|
||||
════════════════════════════════════════════════════════════
|
||||
• Download Baresip from F-Droid or Play Store
|
||||
• Open the Baresip app
|
||||
|
||||
# MANUAL ENTRY IN BARESIP APP:
|
||||
# ============================
|
||||
# If importing doesn't work, manually enter:
|
||||
#
|
||||
# Display Name: ${display_name}
|
||||
# SIP URI: sip:${extension}@${domain}
|
||||
# Auth Username: ${extension}
|
||||
# Auth Password: ${sip_password}
|
||||
# Outbound Proxy: sip:${server_ip}:5060;transport=${transport}
|
||||
# Register: Yes
|
||||
# Register Interval: 3600
|
||||
STEP 2: ADD ACCOUNT (Initial Entry)
|
||||
════════════════════════════════════════════════════════════
|
||||
1. Tap Menu (☰ hamburger icon) → Accounts
|
||||
2. Tap the Add (+) button at the top
|
||||
3. In "SIP URI" field, enter: BARESIPEOF
|
||||
echo "${extension}@${domain}" >> "$config_file"
|
||||
cat >> "$config_file" << 'BARESIPEOF'
|
||||
4. Tap the Save (✓ checkmark) icon at the top
|
||||
|
||||
# DIALING OTHER EXTENSIONS:
|
||||
# =========================
|
||||
# Just dial the extension number: 101, 202, etc.
|
||||
# Or full format: 101@${domain}
|
||||
STEP 3: EDIT ACCOUNT (Complete Configuration)
|
||||
════════════════════════════════════════════════════════════
|
||||
Now go back and edit the account to add authentication:
|
||||
|
||||
# AUDIO SETTINGS (in Baresip app):
|
||||
# ================================
|
||||
# Preferences → Audio:
|
||||
# - Audio Driver: OpenSL ES (best for Android)
|
||||
# - Echo Cancellation: Enabled
|
||||
# - Noise Suppression: Enabled
|
||||
1. Tap Menu (☰) → Accounts
|
||||
2. Tap on the account you just created
|
||||
3. Fill in the following fields:
|
||||
|
||||
# DEFAULT ACTION (in Baresip app):
|
||||
# ================================
|
||||
# Preferences → UI → Default Action: Call
|
||||
# (This makes tapping a contact initiate a call, not message)
|
||||
BARESIPEOF
|
||||
cat >> "$config_file" << EOF
|
||||
Display Name: ${display_name}
|
||||
|
||||
# /e/OS SETTINGS:
|
||||
# ==============
|
||||
# Settings → Apps → Baresip:
|
||||
# - Permissions → Microphone: While using app
|
||||
# - Permissions → Phone: Allow
|
||||
# - Battery: Unrestricted
|
||||
# - Background data: Enabled
|
||||
#
|
||||
# Baresip handles /e/OS better than Linphone!
|
||||
# Should work with screen off without special hacks.
|
||||
Authentication Username: ${extension}
|
||||
(CRITICAL: Just the extension number, NOT ${extension}@${domain})
|
||||
|
||||
Authentication Password: ${sip_password}
|
||||
|
||||
Outbound Proxy URI: ${domain}
|
||||
(CRITICAL: Just the domain, NOT sip:${server_ip}:5060)
|
||||
|
||||
Media Encryption: srtp
|
||||
(Select from dropdown menu)
|
||||
|
||||
Register: ✓ (Check this box)
|
||||
|
||||
4. Tap Save (✓ checkmark icon)
|
||||
|
||||
STEP 4: VERIFY REGISTRATION
|
||||
════════════════════════════════════════════════════════════
|
||||
• Wait a few seconds for registration
|
||||
• You should see:
|
||||
- Green dot next to account, OR
|
||||
- "Registered" status text
|
||||
|
||||
If registration FAILS:
|
||||
✗ Double-check "Authentication Username" is JUST "${extension}"
|
||||
✗ Double-check "Outbound Proxy URI" is JUST "${domain}"
|
||||
✗ Verify password is correct: ${sip_password}
|
||||
|
||||
STEP 5: SET CALLING AS DEFAULT (Optional)
|
||||
════════════════════════════════════════════════════════════
|
||||
To make tapping a contact initiate a call (not message):
|
||||
|
||||
1. Tap Menu (☰) → Settings (or Preferences)
|
||||
2. Look for "Default Action" or "Contact Action"
|
||||
3. If available, select: "Audio Call" or "Call"
|
||||
4. Save
|
||||
|
||||
NOTE: This option may not exist in all Baresip versions.
|
||||
If not available, you can still call by:
|
||||
- Long-pressing a contact → Select "Call"
|
||||
- Or using the phone icon during selection
|
||||
|
||||
STEP 6: AUDIO SETTINGS (Recommended)
|
||||
════════════════════════════════════════════════════════════
|
||||
1. Tap Menu (☰) → Settings → Audio
|
||||
2. Configure:
|
||||
Audio Module: opensles (or audiotrack if opensles doesn't work)
|
||||
Echo Cancellation: ✓ Enabled
|
||||
Noise Suppression: ✓ Enabled
|
||||
|
||||
STEP 7: ANDROID PERMISSIONS
|
||||
════════════════════════════════════════════════════════════
|
||||
Go to your phone's:
|
||||
Settings → Apps → Baresip
|
||||
|
||||
Set the following:
|
||||
• Permissions → Microphone: Allow while using app
|
||||
• Permissions → Phone: Allow
|
||||
• Battery: Unrestricted (or Not optimized)
|
||||
• Mobile data & Wi-Fi → Background data: Enabled
|
||||
|
||||
DIALING EXTENSIONS
|
||||
════════════════════════════════════════════════════════════
|
||||
To call other extensions:
|
||||
|
||||
Method 1 (Try this first):
|
||||
Just dial the extension number: 101, 202, etc.
|
||||
|
||||
Method 2 (If method 1 doesn't work):
|
||||
Full format: 101@${domain}
|
||||
|
||||
Common Extensions:
|
||||
• Individual devices: 101, 102, 201, 202, etc.
|
||||
• Page groups (auto-answer broadcast): 199
|
||||
• Ring groups (rings all phones): 299
|
||||
|
||||
TOP BAR ICONS IN BARESIP
|
||||
════════════════════════════════════════════════════════════
|
||||
☰ = Hamburger menu (Accounts, Settings, About, etc.)
|
||||
✓ = Save/Confirm current action
|
||||
⋮ = Additional options (context-dependent)
|
||||
📞 = Answer incoming call / Place outgoing call
|
||||
🔊 = Enable speakerphone (during active call)
|
||||
🔇 = Mute microphone (during active call)
|
||||
✕ = Hang up / End call
|
||||
|
||||
TROUBLESHOOTING
|
||||
════════════════════════════════════════════════════════════
|
||||
|
||||
PROBLEM: Registration fails
|
||||
SOLUTION:
|
||||
• Verify "Authentication Username" is JUST: ${extension}
|
||||
• Verify "Outbound Proxy URI" is JUST: ${domain}
|
||||
• Check password is correct
|
||||
• Check phone has network connectivity
|
||||
• Check firewall allows SIP traffic
|
||||
|
||||
PROBLEM: Can't dial extensions
|
||||
SOLUTION:
|
||||
• Verify you're registered (green dot/status)
|
||||
• Try dialing full format: ${extension}@${domain}
|
||||
• Check extension exists on server
|
||||
|
||||
PROBLEM: No audio / Audio doesn't work
|
||||
SOLUTION:
|
||||
• Menu → Settings → Audio → Try different "Audio Module"
|
||||
• Check microphone permissions in Android settings
|
||||
• During call, try tapping speaker icon
|
||||
|
||||
PROBLEM: Audio cuts when screen turns off
|
||||
SOLUTION:
|
||||
• Settings → Apps → Baresip → Battery → Unrestricted
|
||||
• Baresip handles this much better than Linphone!
|
||||
• This issue is rare with Baresip
|
||||
|
||||
PROBLEM: Can't find "Default Action" setting
|
||||
SOLUTION:
|
||||
• Not all Baresip versions have this option
|
||||
• Alternative: Long-press contact → Select "Call"
|
||||
• Or tap contact then tap phone icon
|
||||
|
||||
═══════════════════════════════════════════════════════════
|
||||
QUICK REFERENCE
|
||||
═══════════════════════════════════════════════════════════
|
||||
Display Name: ${display_name}
|
||||
SIP URI (initial): ${extension}@${domain}
|
||||
Auth Username: ${extension}
|
||||
Auth Password: ${sip_password}
|
||||
Outbound Proxy: ${domain}
|
||||
Media Encryption: srtp
|
||||
Register: ✓
|
||||
═══════════════════════════════════════════════════════════
|
||||
|
||||
EOF
|
||||
|
||||
@@ -1942,35 +2041,36 @@ EOF
|
||||
|
||||
print_success "Created: $config_file"
|
||||
echo ""
|
||||
echo "Download URL:"
|
||||
echo " http://${server_ip}:8088/static/baresip-${extension}.conf"
|
||||
echo ""
|
||||
echo "═══════════════════════════════════════════════════════════"
|
||||
echo "QUICK SETUP IN BARESIP APP:"
|
||||
echo "BARESIP SETUP - Extension ${extension}"
|
||||
echo "═══════════════════════════════════════════════════════════"
|
||||
echo ""
|
||||
echo "1. Open Baresip → Menu (☰) → Accounts → Add (+)"
|
||||
echo "Download instructions:"
|
||||
echo " http://${server_ip}:8088/static/baresip-${extension}.txt"
|
||||
echo ""
|
||||
echo "2. Enter these details:"
|
||||
echo " Display Name: ${display_name}"
|
||||
echo " SIP URI: sip:${extension}@${domain}"
|
||||
echo " Auth User: ${extension}"
|
||||
echo " Auth Pass: ${sip_password}"
|
||||
echo " Outbound Proxy: sip:${server_ip}:5060;transport=${transport}"
|
||||
echo "QUICK SETUP SUMMARY:"
|
||||
echo ""
|
||||
echo "3. Check 'Register' box"
|
||||
echo "Step 1: Add Account"
|
||||
echo " Menu → Accounts → Add (+)"
|
||||
echo " SIP URI: ${extension}@${domain}"
|
||||
echo " Save (✓)"
|
||||
echo ""
|
||||
echo "4. Save and wait for registration"
|
||||
echo "Step 2: Edit Account"
|
||||
echo " Tap account → Edit"
|
||||
echo " Auth Username: ${extension} (JUST the number!)"
|
||||
echo " Auth Password: ${sip_password}"
|
||||
echo " Outbound Proxy: ${domain} (JUST the domain!)"
|
||||
echo " Media Encryption: srtp (select from dropdown)"
|
||||
echo " Register: ✓"
|
||||
echo " Save (✓)"
|
||||
echo ""
|
||||
echo "5. To call extensions, just dial: 202, 101, etc."
|
||||
echo "Step 3: Verify"
|
||||
echo " Look for green dot or 'Registered' status"
|
||||
echo ""
|
||||
echo "6. Set default action to Call:"
|
||||
echo " Menu → Preferences → UI → Default Action: Call"
|
||||
echo "Step 4: Dial Extensions"
|
||||
echo " Just dial: 101, 202, etc."
|
||||
echo ""
|
||||
echo "═══════════════════════════════════════════════════════════"
|
||||
echo ""
|
||||
echo "NOTE: Baresip works MUCH BETTER on /e/OS than Linphone!"
|
||||
echo " Should maintain audio with screen off."
|
||||
echo "Full details in the text file above."
|
||||
echo "═══════════════════════════════════════════════════════════"
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user