My former vehicle was a 2001 Sonoma with a vortec v6, which may be a similar engine configuration to your blazer, though I am not certain.
I had a very similar problem to yours, with a flashing check engine light. As other posters have indicated, that is really bad. Do not drive it.
My truck was suffering from a multi cylinder misfire.
My mechanic replaced the plugs, wires, and an oxygen sensor. That fixed the problem for a while, but it came back. Ultimately, he had to replace the fuel injectors, and that solved the problem.
Since your sticker is expired, I would have it towed to a mechanic. Get it fixed. Then, take it somewhere to be inspected ( or better yet, maybe the mechanic can inspect it for you). You will probably fail the inspection, because the vehicle's computer will not have accumulated enough data for the emissions test (assuming that is part of your inspection).
I don't know what new jersey's laws are, but in Massachusetts, if you fail your inspection, you get something like 30 days to fix it, and in the interim they give you a temporary sticker indicating you failed, and when you need to have the vehicle reinspected.
If you drive the vehicle regularly for a couple of weeks, you should build up enough mileage for your computer to be fully reset. Then you should be able to pass the inspection.