Skip to content

romiisromie/GuardAurora

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

13 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

WhatsApp Image 2026-04-20 at 4 21 39 PM

πŸ›‘οΈ GuardAurora β€” Launch in VS Code

Project Structure

GuardAurora/
β”œβ”€β”€ App.tsx                         ← entry point
β”œβ”€β”€ app.json                        ← Expo config
β”œβ”€β”€ package.json                    ← dependencies (Expo 52)
β”œβ”€β”€ babel.config.js
β”œβ”€β”€ tsconfig.json
β”œβ”€β”€ assets/
β”‚   └── logo.png                    ← GuardAurora logo
└── src/
    β”œβ”€β”€ theme/index.ts              ← colors, spacing, radii
    β”œβ”€β”€ store/AppContext.tsx        ← global state
    β”œβ”€β”€ hooks/
    β”‚   β”œβ”€β”€ useAudioMonitor.ts     ← AI microphone analysis
    β”‚   β”œβ”€β”€ useLocation.ts         ← GPS tracking
    β”‚   └── useShakeDetector.ts    ← silent SOS (shake)
    β”œβ”€β”€ components/ui.tsx          ← UI: PulseRing, SoundWave, buttons
    β”œβ”€β”€ screens/
    β”‚   β”œβ”€β”€ HomeScreen.tsx         ← main screen with SOS
    β”‚   β”œβ”€β”€ MapScreen.tsx          ← map + safe routes
    β”‚   β”œβ”€β”€ ChatScreen.tsx         ← AI chat (Claude API)
    β”‚   β”œβ”€β”€ ContactsScreen.tsx     ← trusted contacts
    β”‚   └── HistoryScreen.tsx      ← event log
    └── navigation/index.tsx       ← bottom tab navigation

πŸš€ Launch (Step by Step in VS Code)

1. Open the folder in VS Code

File β†’ Open Folder β†’ select GuardAurora

2. Open the terminal in VS Code

Ctrl + `  (or Terminal β†’ New Terminal)

3. Install dependencies

npm install

4. Start Expo

npx expo start

After this, a QR code will appear in the terminal.

5. Open on your phone

  1. Download Expo Go from the App Store (iPhone) or Play Store (Android)
  2. iPhone: Open the camera and point it at the QR code
  3. Android: Open Expo Go β†’ tap "Scan QR code"
  4. The app will launch on your phone!

πŸ“± How to Use

Action Result
Press the large SOS button 3‑second countdown β†’ SOS activation
Press "Cancel" during countdown SOS cancelled
Shake the phone 3 times Silent SOS (no button presses)
Press "Enable Monitoring" button AI listens to the microphone
Map tab β†’ "Get Location" GPS coordinates
Map tab β†’ tap on a location Build a route
AI Chat tab Chat with GuardAurora AI
Contacts tab β†’ "+" Add a trusted contact

πŸ”§ Troubleshooting

Error "Metro bundler failed"

npx expo start --clear

Dependency errors

npm install --legacy-peer-deps

Update Expo Go on your phone

Uninstall and reinstall Expo Go from the app store.

TypeScript error

Strict mode is already disabled in tsconfig.json β€” everything should work.


πŸ› οΈ Next Steps (Optional)

Real SMS via Twilio

In src/store/AppContext.tsx, inside the activateSOS() function, add:

await fetch('https://api.twilio.com/2010-04-01/Accounts/ACCOUNT_SID/Messages.json', {
  method: 'POST',
  headers: {
    'Authorization': 'Basic ' + btoa('ACCOUNT_SID:AUTH_TOKEN'),
    'Content-Type': 'application/x-www-form-urlencoded',
  },
  body: `To=${contact.phone}&From=+1NUMBER&Body=🚨 SOS! ${name} is in danger. GPS: ${latitude},${longitude}`,
});

Push Notifications

npx expo install expo-notifications

Data Persistence

npx expo install @react-native-async-storage/async-storage

🎨 Color Customization

All colors are in src/theme/index.ts:

Colors.rose      // #e8547a  β€” SOS, main accent
Colors.lavender  // #c084fc  β€” monitoring, navigation
Colors.mint      // #67e8c4  β€” safety, GPS
Colors.danger    // #ff4757  β€” threat, alert
Colors.bg        // #0d0118  β€” dark background