There are several things that you can do to help get accustomed to a new site:
Read the site's FAQ
While this might not tell you everything about the rules of the site, it will definitely give you a good place to start to get a broad feel for what the site is about. The FAQ tells you broadly what is on topic as well as what the site is not about.
Check out the Per-Site Meta
Every site has it's own Per-site meta. Checking out meta is key to understanding the politics of the site. Meta is where you'll learn what issues the community has faced and what that community has agreed to do to resolve those issues. Reading the Meta posts can help you avoid being "that guy", the one that goes right to the questions page and asks a question that breaks a rule that was just agreed on in a recent, active Meta post.
Reading and understanding this information will help save you the embarrassment of breaking a known, agreed upon rule. Furthermore, this also clarifies what's still being debated within that community, which might be different than what's being debated on other sites.
Keep in mind that, if you have a question about the site, chances are someone else already has asked that same question earlier. Be sure to search well before you create a meta post yourself, as most of the community frowns upon obvious duplicate questions.
Read some of the questions and answers
Of course, looking at what others have asked and how the community responds to those questions is a great way to get a feel for what the community agrees is a good question or answer for the site.
Specifically, look at the closed questions and pay attention to what the asker specifically did or didn't do that led to the question closure. On open questions, look for comments that hint that the original question may have been slightly incomplete or too broad, but with edits, it was brought up to speed. You can also check the revision history of the questions to see what prompted users to post comments that ask for specific information or improvements.
When looking at the answers, look at what gets upvoted and what gets downvoted. This should encourage you to formulate your posts in a manner that's most acceptable.
Join Chat
If you have enough reputation to chat, then another way you can get a feel for the community is to ask the community what they think of your question. They will give you an idea of whether or not it's on topic or not, and they can offer you some tips to improve your question, if needed.
If you don't have enough reputation to chat but have at least 5 reputation points, you can always ask if your question is on topic on the meta site. Again, just be sure to search first to see if there is evidence that your question wouldn't be a good fit.
Create a Post
After you've done the above due diligence, it's time to dip a toe in the water. Try answering a question (or ask one if you're feeling brave). Start slow so that you have time to get some feedback and make adjustments. If you see upvotes, then chances are you have a good understanding of what's expected.
If you get downvoted, the first thing to do is to not panic. Don't get offended. Downvotes are a tool the community uses to help keep crappy content off the site. Don't take it personal.
Instead, consider posting a polite comment asking for advice on what's wrong with your answer. Chances are, the downvoter, or even someone else, may reply and give you information that could help you turn the question/answer around. Keep in mind that the person offering the suggestion may not be the downvoter, so be cordial, polite, and take the tips this person has provided as helpful advice.
Try to fix the problem as best you can, and then use this information as a learning tool for the future. If you're lucky, you may even turn your answer around and get some upvotes, which tells you you're doing things the right way, despite the initial roadblocks.
Spend time on the site
In summary, by spending some time on the site and looking at the site governance in meta, what questions are closed, what questions and answers are accepted by the community, upvoted, and downvoted, you should see a pattern that you can then use to help guide you to being a good, contributing member of that community. Good luck!