May I ask why you find yourself semi-unemployable? I'm in kind of a similar position as the OP in that I have a significant nest egg so that even if I spend a few years derping around and failing at a bunch of things, I figure that I just need to stop before that nest egg gets anywhere near dangerously low and go back to looking for freelance or consulting work, even at lower rates, should that become necessary to survive. I'm asking about your situation in case there are other pitfalls I need to be wary of.
I am right now an illegal alien in a country (not the US). My home country monthly wage is 5 dollars or so, so returning is not an option unless I can get a remote job.
Without knowing your situation, if you're a good developer it may be possible to get an H1B visa which would allow you to work as a software developer in the US.
I love to program but I am a career switcher. All my professional experience is in logistics, I have a B.S but not in CS, also I am 41. By all means if you have any tip to get a H1B (I have heard is crazy competitive) let me know.
Upwork rejected my resume some months ago. I am enhancing my portfolio to give it a shot again in the next weeks. I want to diversify my income so I have thought about producing digital products, but I need food-rent money now so that it is what I am prioritizing. I am also working on my Algorithms/Data Structures skills to try in TopTal, I dont know if you have any experience with them.