Unless there is another constitutional provision of which I am unaware, this situation of a deadlocked Congress supersedes IN THESE CIRCUMSTANCES succession installing the Speaker as POTUS automatically. Congress (one Member, one vote) may elect the Speaker in these circumstances, unless you know of some other controlling constitutional provision.
Given the current atmosphere of toxic partisanship and toxic factionalism within the parties, Congress (both houses by mere unvetoable legislation) may choose the corporate tool of their choosing and replace the voters choices for four years. Or, a Demonratic House could give us POTUS Pelosi.
God bless!
You are right that the Speaker would become president on January 20 if the House and Senate had not yet picked a president, BUT he would only be acting president. As soon as the House broke its deadlock (one state one vote), their selection would become president, and if the Senate broke its deadlock, their selection would become acting president instead of the Speaker until the House broke its deadlock. As Section 3 of the 20th Amendment puts it, whoever is next in the line of succession (currently the Speaker) “shall act [as President] until a President or Vice President shall have qualified.”