Commit graph

487 commits

Author SHA1 Message Date
James Rich
deb36b6647
fix: Refactor BLE exceptions and handle ServiceAction exceptions (#2294) 2025-06-29 07:45:09 -05:00
James Rich
7e6bf21e2d
fix: Clear notifications on device switch (#2281)
Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com>
2025-06-28 14:50:05 +00:00
Łukasz Kosson
20f5888380
feat: split message notifications into direct- and broadcast messages (#2217) 2025-06-22 07:41:17 -05:00
Łukasz Kosson
9b0dcfdeab
fix: ignore non-local localStats telemetry (#2206) 2025-06-21 20:21:14 -05:00
James Rich
38b949f9c1
fix: Propagate reply ID for DataPackets (#2177) 2025-06-19 18:20:07 -05:00
Jeremiah K
67ffaca01c
fix (#2165): position exchange not working (#2169)
Co-authored-by: James Rich <2199651+jamesarich@users.noreply.github.com>
2025-06-19 16:42:48 +00:00
James Rich
357efa9028
feat: Implement message reply functionality (#2147) 2025-06-17 20:15:07 -05:00
James Rich
606d1520d8
refactor: Client Notification Support (#2095) 2025-06-12 20:00:28 -05:00
Benjamin Faershtein
39590b75ee
Fixed nodeDB reset even on remote nodeDB reset (#2087) 2025-06-12 16:20:49 -05:00
Łukasz Kosson
f5b34d6408
fix: cancel new message notification when message is marked as read (#2057)
Co-authored-by: James Rich <2199651+jamesarich@users.noreply.github.com>
2025-06-09 12:45:20 -05:00
Łukasz Kosson
9a371ee9cd
feat: show per-message SNR, RSSI and hop count (#2040)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-06 15:41:25 -05:00
James Rich
8bbc5bfc56
revert: do not clear databases on disconnect (#2011)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-06-03 19:58:52 -05:00
James Rich
38982bc37b
refactor: recommended and required firmware updates (#2012) 2025-06-03 19:58:21 -05:00
James Rich
25ecdc912e
fix: clear data when changing devices (#1985) 2025-05-30 13:17:09 -05:00
James Rich
77ca2d62f0
refactor: Move MIN_DEVICE_VERSION to build config (#1946) 2025-05-27 08:45:57 -05:00
James Rich
d04378a026
feat: filter visibility, add unmessageable toggle (#1915) 2025-05-23 02:39:46 +00:00
James Rich
02bb3f02e4
feat: network module (#1905) 2025-05-22 08:30:08 -05:00
James Rich
e1c1cef79b
fix: Ensure handleReceivedUser is called when adding contacts (#1886) 2025-05-21 03:34:52 +00:00
James Rich
c99fe642b5
feat: Add Contact Sharing via QR code (#1859) 2025-05-20 13:36:11 -05:00
James Rich
18c204741a
feat: Update connected count string in strings.xml and MeshService.kt (#1776) 2025-04-22 09:54:10 -05:00
James Rich
5d5a4938a2
fix: clear local DB after reset (#1746) 2025-04-21 13:52:41 -05:00
James Rich
d0816d3495
fix: Remove nodeDb size from status string (#1734) 2025-03-31 12:17:33 -05:00
niccellular
3bc4454c0e
Expose wantAck in Mesh Packet (#1703)
* Expose wantAck in Mesh Packet

* Update DataPacket.kt

* Update DataPacket.kt

* Update DataPacket.kt

* Update DataPacket.kt

* Refactor: Change wantAck field type in DataPacket

- Changed the `wantAck` field in `DataPacket` from `Int` to `Boolean`.
- Updated read/write and equals/hashcode functions accordingly.

* Update MeshService.kt

* Update MeshService.kt

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: James Rich <2199651+jamesarich@users.noreply.github.com>
2025-03-21 20:51:52 -05:00
Ken Piper
ff261c2304
fix: Add some smarts to low battery notification triggers (#1686)
* Add some smarts to low battery notification triggers

* Always bypass cooldown on critically-low battery

* thx detekt

* revert whitespace changes

* Switch newer timestamp code to more widely-compatible version

---------

Co-authored-by: James Rich <2199651+jamesarich@users.noreply.github.com>
2025-03-19 04:39:52 -05:00
James Rich
f3ba084d5b
fix #1678: Update MeshService.kt to store the channel for received packets. (#1683)
* Update MeshService.kt to store the channel for received packets.

The channel for received packets is now stored, allowing for better tracking and management.

* Update node info creation to include channel data

- Updates `getOrCreateNodeInfo` to accept a channel parameter and to save the channel to the node info during instantiation of a new/unknown node.
- Updates `updateNodeInfo` to accept a channel parameter and pass it to the updated function.
- Updates call to `updateNodeInfo` in `handleReceivedData` to pass the packet channel data to it.
2025-03-17 17:47:48 -05:00
James Rich
5846bf5ee4
feat: Improve (battery) notification behavior (#1661)
* feat: Improve notification behavior

- Changes low battery notifications to be non-cancelable
- Cancel low battery notifications when battery level is no longer low.
- Add notification groups and improve notification settings.
- Add vibration to low battery notifications.

* Improve low battery notification

Add battery level progress bar to the low battery notification.
2025-03-12 05:02:14 -05:00
Ken Piper
c7c29cb1c1
feat: Initial implementation of low battery notifications for nodes (#1653)
* Add initial implementation of low battery notifications for locally-connected and favorite nodes

* Hopefully make detekt happy

* detekt pls.

* Deduplicate some of the code

* detekt'd
2025-03-08 04:52:30 -06:00
James Rich
f7731f0c98
chore: Update minimum required firmware version (#1658)
Updated the minimum required firmware version to 2.3.15.
2025-03-07 14:27:28 -06:00
James Rich
d78bea2365
feat: Show ALERT_APP notifications and override DND (#1515)
* feat: Show alert notifications and override silent mode

This commit adds support for showing alert notifications with high priority and the ability to override silent mode to ensure they are delivered to the user.

The changes include:
- Adding `showAlertNotification` function which overrides silent mode and configures a custom volume, shows a notification with high priority.
- Creating a new notification channel for alerts.
- Adding the alert app port number to the list of remembered data types.
- Modifying `rememberDataPacket` to check for alert app messages and show alert notification.

* Add notification policy access permission and DND override for alerts

This commit adds the `ACCESS_NOTIFICATION_POLICY` permission to the manifest and requests this permission from the user. It also adds a check for notification policy access in the MainActivity, and if it's not granted, shows a rationale dialog.

Additionally, the commit adds a notification override to the `showAlertNotification` function in `MeshServiceNotifications` to temporarily disable DND for alert notifications and restore the original ringer settings afterwards.

* Refactor: Enhance Android Notification and DND Handling

-   **Notification Channel Improvements:**
    -   Added `notificationLightColor` for better customization.
    -   Set `enableLights` and `enableVibration` in the alert channel.
    -   Use `alert.mp3` sound for alert channel.
-   **DND Permission Request:**
    -   Introduced a new permission request flow for Do Not Disturb (DND) access.
    -   Show a rationale dialog before requesting permission.
    -   Persist if rationale was shown to avoid re-prompting.
    - Added a `notificationPolicyAccessLauncher` to handle the permission request result.
-   **Critical Alert Text**
    - Added critical alert text in strings.
    - Used critical alert text if the alert message is empty.
-   **Other Changes**
    - Removed unused imports and constants.
    - Updated snackbar to support action.

* Refactor alert notification logic

- Change `notificationLightColor` to be lazy initialized.
- Update alert notification to use `CATEGORY_ALARM`.
- Use `dataPacket.alert` instead of `dataPacket.text` for alert content.
- Add `alert` property to `DataPacket` to handle alert messages.

* Set notification light color back to blue.

* Request notification permissions on grant

The app now checks for notification policy access after notification permissions are granted.

* make detekt happy

* updates dnd dialog text

* Refactor notification channel creation and critical alerts

- Initialize notification channels on service creation.
- Remove `ACCESS_NOTIFICATION_POLICY` permission.
- Modify the logic for requesting "Do Not Disturb" override permission to align with channel settings.
- Add new string resources for Alerts Channel Settings.
- Update wording for critical alert DND override.
- Update DND override request flow.
- Create notification channels on the service creation using `initChannels`.
- Adjust logic to check for "Do Not Disturb" override permission to align with notification channel settings.
- Ensure notification channels are created only if they do not already exist.

* refactor: Update DnD dialog with instructions for Samsung

- Renamed "Alerts Channel Settings" to "Channel Settings".
- Added Samsung-specific instructions and a link to Samsung's support page for Do Not Disturb mode in the alerts dialog.
- Updated the dialog to display Samsung-specific instructions when on a Samsung device.

* Refactor critical alerts instructions

- Updated the critical alerts instructions to include a link to Samsung's support page directly within the alert dialog.
- Removed the separate "Samsung Instructions" string and incorporated the information into the main instruction text, improving clarity and reducing redundancy.
- Made improvements to the UI.
2025-03-05 07:28:52 -06:00
Ken Piper
e15ad23c46
feat: Initial implementation of adding nodes to favorites (#1520)
* Implement initial support for adding and removing nodes from favorites

* Make favorite nodes' names show up bold in the node list

* Forgot to add this here when I was fixing the previous merge conflicts. Whoops!

* Make detekt happy

---------

Co-authored-by: James Rich <2199651+jamesarich@users.noreply.github.com>
2025-02-16 06:02:02 -06:00
andrekir
13b615a470 chore: update license header 2025-01-02 07:00:51 -03:00
Andre K
60e7e18116
feat(config): implement excluded modules validation (#1460)
* feat(config): implement excluded modules validation

* feat: hide excluded configs from metadata

* refactor: save local metadata from WantConfig

* refactor: delete metadata from deleted nodes

* fix: always request metadata for admin routes

* feat: show node firmware when metadata is available

* refactor: rename filter function

* feat: add `ServiceAction` request metadata
2025-01-02 06:38:33 -03:00
andrekir
1ea55b2209 refactor: move ignore node to is_ignored field in NodeInfo 2024-12-07 08:18:18 -03:00
James Rich
2234f5a713
feat: add emoji reactions to message bubbles (#1421)
* Add tapback emojis to message bubbles

Added TapBackEmojiItem composable to display tapback emojis.
Included it in MessageItem composable for incoming messages.
Added a FlowRow to show tapback emojis below the message bubble.

* feat: Add EmojiPicker View

* feat: show emojis for local messages

* feat: Add emoji tapbacks to messages

This commit introduces the ability to send and receive emoji tapbacks for messages.

- Adds emoji and replyId fields to DataPacket.
- Adds emoji tapback support to the MeshService
- Modifies UIState to handle emojis in message lists.

* feat: store tapbacks in database

Store tapbacks in the database and display them in the message list.
- Add a new table to the database to store tapbacks.
- Add a new DAO method to insert and retrieve tapbacks.
- Update the message list UI to display tapbacks.

* refactor: relation db and other changes

---------

Co-authored-by: Andre K <andrekir@pm.me>
2024-12-03 08:57:35 -03:00
andrekir
6678df78b0 fix: text messages sent from connected standalone devices 2024-11-30 07:43:56 -03:00
andrekir
1219d3037e chore: add GPL-3.0 license headers to source files 2024-11-26 08:54:18 -03:00
andrekir
80f8f2a591 refactor: implement repository pattern replacement for AIDL methods 2024-11-21 20:30:25 -03:00
andrekir
02af81aeb0 fix: nodelist sort by viaMqtt 2024-11-15 06:49:40 -03:00
andrekir
cfdb245da2 refactor: convert connectionState to StateFlow 2024-11-12 09:15:45 -03:00
James Rich
80e915a36c
feat: show unique messaging notifications per contact (#1381)
* Show unique notifications per contact

Instead of a single notification for all messages, each contact now has its own, unique notification. This uses the `NotificationCompat.MessagingStyle` and the contact's name to create distinct notifications, enhancing message organization.

* feat: Add notification tap action to open contacts tab

This is done by:
- Adding an intent extra to the notification with the contact key for future use to navigate to the message thread.
- Adding a new action to the MainActivity to handle the intent.
- Updating the message notification to include the intent.

* Open message notification to the correct conversation

Adds an extra to the message notification intent to open the correct conversation. This ensures that when a user taps on a message notification, they are taken to the conversation with the sender of that message.
2024-11-04 19:05:39 -03:00
andrekir
414e0bb544 fix: clear public keys if the user is licensed 2024-11-03 06:48:32 -03:00
andrekir
605ef120c9 fix: remove build timestamp (breaking reproducible builds)
reverts 9f099f3edf
2024-11-02 06:13:36 -03:00
andrekir
1e081b4b30 refactor: improve handling for old firmware 2024-10-29 07:41:39 -03:00
andrekir
5cf9741b13 refactor: unified getUser repository call for convention 2024-10-25 07:50:34 -03:00
andrekir
9f099f3edf feat: replace invalid MeshPacket times (earlier than build time) 2024-10-23 19:20:28 -03:00
andrekir
199b9a29d5 refactor: extract traceroute text from MeshService 2024-10-23 19:05:43 -03:00
andrekir
7289896956 refactor: remove largeIcon from notifications 2024-10-22 12:13:34 -03:00
andrekir
8af78bc2eb fix(config): show error when radio disconnects before receiving confirmation 2024-10-19 13:29:39 -03:00
James Rich
f6ec3e8bab
feat: Add notification for new node seen (#1316)
* Add notification for new node seen

This change adds a new notification that is displayed when a new node is seen.
The notification includes the node's
 name.
It also updates the message notification to include the node name.

* Show individual notification for each new node

* Add new nodes notifications

Adds a new notification channel for new nodes seen.
This channel is set to high importance with sound and light.
2024-10-15 06:07:22 -03:00
andrekir
af56fff216 fix: position packet want_response handling
Process valid position broadcasts with `want_response` true except from position requests with an empty payload (latitude and longitude are zeroes).
2024-10-14 18:26:59 -03:00