Crack the code using the given clues:
I am a 4 digit odd number.
4th digit is odd and is less than 3.
1st digit is 2 more than the 4th digit.
2nd digit is the smallest prime number.
Sum of first 3 digits is equal to 12.
Only odd number less than 3 is 1.
1st digit is 2 more than the 4th digit which is equal to 3.
2nd digit is the smallest prime number which is equal to 2.
Sum of the first 3 digits is 12, so the 3rd digit will be 12-3-2=7. Putting all the digits together, we get 3271.