Commit graph

1921 commits

Author SHA1 Message Date
Eric House
fc30abd126 move methods from util to dutil 2024-10-31 10:16:03 -07:00
Eric House
b2ffd915dd remove compile-command here too 2024-10-10 07:40:38 -10:00
Eric House
f4af1d69ea for emacs: move compile-command into directory-scoped file 2024-10-10 07:40:38 -10:00
Eric House
5504ca03d9 add stats entries for Bluetooth send/receive 2024-09-21 22:09:22 -07:00
Eric House
2a8a9b442a use dutil_phoneNumbersSame() instead of strcmp() 2024-09-21 22:09:22 -07:00
Eric House
2d9cb93ae6 add to test ability to invite using known players 2024-09-21 22:09:22 -07:00
Eric House
aee9dec0f4 don't ack using method other than how message arrived
I'm getting tons of SMS messages sent in response to a flood of
incoming MQTT messages: bad. And don't think it makes much sense to
try to ack other than how the message was delivered anyway.
2024-09-05 20:20:03 -07:00
Eric House
4d03261084 tweak logging 2024-09-05 20:19:59 -07:00
Eric House
c23904fbb0 get qos from server, and use unless overridden by local settings 2024-09-02 12:49:06 -07:00
Eric House
4b1faec5f4 set ack timer to 5 seconds instead of 7.5 2024-09-02 12:49:06 -07:00
Eric House
a15bb77fd9 fix bug determining to quit after too many passes
I was counting all passes in a game, not just in a row starting with
the last. Longstanding bug!
2024-08-28 22:07:04 -07:00
Eric House
4b730cf0b5 remove useless debug-only menuitem 2024-08-28 20:14:01 -07:00
Eric House
dfa0502a06 always generate gameID using the same function
Android was using curSeconds(): bad!
2024-08-26 11:29:09 -07:00
Eric House
5347762300 rewrite xwmutex to use a single thread 2024-08-26 10:13:49 -07:00
Eric House
df84bf6145 includ NBS sends/receives in stats on Android 2024-08-24 15:32:29 -07:00
Eric House
e492d8f7b5 mutex tweaks 2024-08-24 09:46:43 -07:00
Eric House
28edeb1877 add creation time to stats
Useful, especially when it's getting reset mysteriously -- which was
probably the Android timers bug
2024-08-24 09:41:22 -07:00
Eric House
a5132f22a4 rewrite lock detector to not use pthread_cancel
...which isn't available on Android
2024-08-22 22:00:37 -07:00
Eric House
466abffc43 rewrite mutex stuff to make timeout/asserting easier 2024-08-20 22:03:08 -07:00
Eric House
db35adbada use xwmutex more 2024-08-20 06:57:23 -07:00
Eric House
c45638e037 pool acks and send using a timer (untested on Android) 2024-08-19 06:56:33 -07:00
Eric House
faf398790c cleanup; use new mutex for mempool 2024-08-17 22:03:37 -07:00
Eric House
2993e82ec7 fix assertion by implementing kplr_nameForAddress() fully 2024-08-15 17:38:34 -07:00
Eric House
0bd0d31d42 use new timers for stats saving on Android too 2024-08-13 13:58:45 -07:00
Eric House
f406757fb2 add generic timers (with dutil component for scheduling) 2024-08-12 21:11:14 -07:00
Eric House
ad651c6cba more work on stats 2024-08-11 20:45:11 -07:00
Eric House
0a992c5a4b move mutex into a struct (for future dev advantage) 2024-08-11 19:59:38 -07:00
Eric House
464e124038 add debug-only stats submenu, and ability to print stats
They won't persist on Android if I count on dutil shutting down, since
there's no such thing. So I save on every change, which is way too
often but good enough for now.
2024-08-10 20:54:56 -07:00
Eric House
2f8164d8c7 add test for email-style invitation 2024-08-09 10:48:27 -07:00
Eric House
c09ac28759 fix warnings about zeroing static structs (no behavior change) 2024-08-07 22:29:46 -07:00
Eric House
7286156c87 add a few more stats 2024-08-07 22:13:02 -07:00
Eric House
4ab6b1930f new stats module gathering data for debugging and upload (soon) 2024-08-07 08:16:12 -07:00
Eric House
72082cde0d add mutex utility
since I'm using them more now
2024-08-06 10:23:20 -07:00
Eric House
696c47ace4 fix harvesting of known player names to not mismatch name/address
The buggy code assumed two arrays were in sync that weren't guaranteed
to be so. So now I'm leveraging rematch code that already put
addresses in player order.
2024-07-30 16:15:44 -07:00
Eric House
daacc66ffe send ack info as array for later optimization 2024-07-30 16:15:44 -07:00
Eric House
2f91ff1f78 display known player names for pending invites
When an invitation is pending for a player in GameSummary or
scoreboard, show "<Name> invited" instead of "remote missing."
2024-07-28 08:48:33 -07:00
Eric House
f3fb43e93b handle invitations for excessive new addresses
Deal with somebody creating a new invitation, e.g. because it's been
realized that an existing one won't be accepted. Unused channels are
used first (though there will be none in a 4-device game), then
channels with old invites (only) are recycled.
2024-07-28 08:48:33 -07:00
Eric House
d61b4ce485 make comms choose channel for invitations
Since server will ultimately assign them as registrations come in
there's no point in trying to force an order earlier.
2024-07-28 08:48:33 -07:00
Eric House
b8e2877880 remove some logging 2024-07-28 08:48:33 -07:00
Eric House
ae03f4ed5b trivial API change 2024-07-28 08:48:33 -07:00
Eric House
a3078fb549 cleanup: fix flashing quarantine count and reduce logging 2024-07-19 22:48:34 -07:00
Eric House
3ee909df7d use mutex in comms
I've long had logging to detect (and assert(0))when two methods access
comms at the same time on different threads. I'm getting that
assertion more often now due, I guess, to subtle changes introduced by
the kotlin port. I wanted to avoid a mutex in cross-platform code, but
I've been using them without problems in a couple of less critical
modules so let's just do the simple thing.
2024-07-18 08:38:24 -07:00
Eric House
9c96397ece plug memory leak 2024-07-09 21:43:43 -07:00
Eric House
41e1a2e3c3 cleanup, esp. to remove some nullable params
squash me
2024-07-07 20:17:10 -07:00
Eric House
6e1b36f38f remove assertion firing when relay games present 2024-07-02 22:25:55 -07:00
Eric House
840086e98c remove mistaken assertion 2024-05-27 10:01:08 -07:00
Eric House
3d51de4bf7 fix crash tile-picking when too few tiles left 2024-05-17 08:41:51 -07:00
Eric House
18bbc37516 cleanup and fix for release builds 2024-04-26 10:29:43 -07:00
Eric House
21990ece1c Display "legal phonies" using same code as studylist words
Converted studylist to Kotlin, then made most of it a superclass
from which legal phonies display also inherits
2024-04-26 10:29:40 -07:00
Eric House
cb540c23c0 add (unused still) timers to dutil
I'll want timers and idle procs for device operations, not just games.
2024-04-26 09:33:59 -07:00