The rules have changed many, many times over the years so definitely check the TSA web-site. I would even print it out & take it with me just in case you get one of the "I'm smarter than you" TSA agents.
I bought a very small cheap plastic sewing machine that easily fits in a carry-on but it's crap to sew with so now I'm keeping an eye out for a good, used 3/4 size machine. I don't plan on taking it on an airplane until next year so I've got time to find a bargain.