I am currently facing an issue where my last device can't connect to the wifi network.
According to LuCI Overview section, I have 32 associations on my radio1 wireless.
I am not talking about bandwidth issue. It's just that when any device attempts to connect to the network when there are already 32 connected to it, that device simply cannot connect at all.
A quick Googling mentions theoretical limit of 65535 concurrent connections, and there's also another mention of 256 connections. Either way, 32 is a lot fewer than that, and most are just smart devices (as I am sure like most people are configured these days).
Is there any setting in OpenWrt that's limiting the maximum number of connections, or is this a hardware problem (according to Googling this type of issue does not appear to be hardware related, but I would be glad to be corrected). If it's just a matter of going out and getting an expensive router that would be the easiest solution, but if not, I am hoping someone can give me some pointers.
It depends, on the hardware and to some extent also driver and firmware. The AP (and that goes down to the wireless hardware) needs to account for each connected client, reserve some (partially on-chip-) RAM for each connected STA and keep track of them (including buffering for power-saving clients), that limits the number of concurrently connected clients way before the theoretical limits. Then you also need to consider the mere availability of airtime slots, especially with older STAs in the mix (even if you don't have any, unless you're running in greenfield mode the AP still needs to account for older clients) - before even thinking about interference from your neighbours.
In the 802.11g/n days, the practical limit (independent of the hardware) was indeed somewhere in the lower- to mid thirty range, just because of beacons and responses from connected clients filled up the airtime (without any active traffic) leaving no space for additional clients (aside from the effects of the remaining achievable per-device throughput, your frequency band is simply shared by all devices, including those of your neighbours). With 802.11ac and 802.11ax these limits have been pushed considerably (into the low hundreds at most), but they're still there (and any older STA in range and up to three times the range you can see, has a negative impact on the system as a whole).
In case of ath10k-ct, you can fine-tune to the number of possible STAs (by reshufflling ressources from other tasks), other chipsets may have fixed limits (which are rarely documented), e.g. ath9k_htc has (depending on driver/ firmware version) a hard limit between 4-8 connected STAs (the on-device RAM simply doesn't allow more space).
The enterprise solution of this problem is hardware, more APs, tuned-down tx-power, Mu-MIMO (802.11ac/ wave2 and upwards) semi-directional antennas and a clever spatial distribution of APs, channels and active client-steering.
I know I am playing in larger waters than is appropriate for me here - I am an average guy having an issue with my home network, not enterprise so most of what you said is above me - but it sounds like maybe I can just make this an excuse to go out and get a new router.
My current router is TP-Link Archer AC2600. It is somewhat dated, I think. I have no expertise to evaluate whether the 512MB RAM that my hardware has available is enough "for each connected STA and keep track of them", and I think my router is from "the 802.11g/n days" (maybe I am wrong).
I still wonder though, because the behaviour I am seeing is that the last device simply cannot connect to the network at all as opposed to it being able to connect, but then showing quality issues. I don't see my network struggling incrementally as I add more devices, but rather, that last device is simply "denied entry" when all the other devices that are connected have no issue whatsoever. If this was about RAM, for example, then I would expect to have that last device connect, but then experience problems like slow speed, connection dropping, etc etc, but that's not what it was so I expected my problem to be caused by some sort of an artificially set limit somewhere (32 is somehow a familiar and a seemingly significant number in computing too... 32, 64, 128, 254... yeah).
Thank you again, and if you wouldn't mind commenting on what I just said for any inaccuracy, misunderstanding, suggestions or recommendations, I would appreciate it very much again.
ath10k-ct refers to the default driver and firmware OpenWrt uses for the wireless chipset (QCA9980) of your router (in contrast to the upstream/ QCA variant of ath10k and its firmware), this driver (technically its firmware) can be configured as described in https://www.candelatech.com/ath10k-10.4.php#config.
If you do decide to improve things with more hardware, for example you could simply add an access point, put it on different channels, with the same SSID and security settings... place it in a spot where you have relatively poor signal. By doing this you'll split your client devices between the two access points which reduces the load on individual access points, and also get better signal because you'll be "filling in" whatever region has poor signal. The devices will roam between them.
First sanity check, just divide half of the maximum attainable link rate by 1000 and check how much is left over per client. Yes, not all clients will be very active at the same time, but for this first approximation we're neither taking background management traffic and interference into account.
Second sanity check, have a look at CandelaTech's product portfolio, to a large extent they're selling network simulators - special equipment to simulate many clients at the same time - just compare prices, to get an idea how likely the 'over 1000 clients per access point' marketing blurb is.