JARVIS / request_mic.py
Khanna, Videh Rakesh Rakesh
Claude Opus 4.6 (1M context)
JARVIS v2 — full system control, battery efficient, multi-platform
f7f801d
Raw History Blame Contribute Delete
385 Bytes
"""Run this once to trigger macOS microphone permission dialog."""
import speech_recognition as sr
print("Requesting microphone access...")
print("If you see a macOS popup, click ALLOW.")
print()
mic = sr.Microphone()
rec = sr.Recognizer()
with mic as source:
rec.adjust_for_ambient_noise(source, duration=2)
print("Microphone access GRANTED!")
print("You can close this window.")