You are allowed to bring in up to $10,000 USD I believe. More than that you would need to declare. However, bringing dollars isn't the best way to go. You sometimes lose on the exchange rate for example, if you choose the dollar instead of pesos option when purchasing goods or services. And smaller places may not even take them.
As Steve says, you are better off talking to your bank, telling them you are going to be in Mexico for a long time and plan to make frequent withdrawals from from your account. This keeps the alarm bells from going off when they see your debit card suddenly starting to be used in Mexico. Also get the limit raised as high as possible. That is the amount you can take out from the bank in a 24 hour period.
My limit is $6000 on one bank account and if I have to stockpile cash fast (something that happens often as this is a country where Cash is Truly King) I have another bank and debit card. So in a pinch, I can withdraw $12,000 pesos in a 24 hour period. There is a fee from both the ATM local bank and your bank back home. But its worth it for the convenience.
I only use the Banamex machines which are swipes. There are several in the Banamex office on the 30 Avenida between Salas and Calle 1 Sur. There is one in the Mega. Mega has the option to have everything in English which is nice if you are new to the 'chines and don't speak any espanol as yet.
I used to advise against using credit cards here and I still don't like the idea for restaurants, rental cars and other tourist service oriented stuff. But I have had no problem using my US card at Mega, Ched and Sam's Club and am not charged a credit card fee at any of these stores. I also use it for my dentist and probably would use it for other medical services at Clinica San Miguel. So you can pay for groceries and medical services with a US or Canadian credit card and that cuts Waaaaay down on the amount of cash you need to keep around.
Again, you'll want to let your credit card company know you are going to be using the card in Mexico. And check your account statements monthly just to be on the safe side. There is a lot of credit card theft in these parts. But as I said, no problem in the last two years at the stores and medical services mentioned.