Visiting the magistrates/local court is a good idea.
I have spent a lot of time in one of the Sydney local courts and found that with a lot small drug charges (especially involving pot), the magistrate would let punter off with only a warning.
I even heard a magistrate (a cool one) have a go at the policeman who arrested a girl with 3g of pot, saying that bringing judicial proceedings based on that amount of gear was a waste of money and resourses! She had her car searched and was (perhaps rightly so) argumentative with the policeman. He was clearly having a 'small penis day' and needed the rush of a pointless arrest.
She was also lucky because her parents got her a barrister. I know that not all of us are that fortunate, but it really really makes a difference. The legal fraternity (and it is indeed that, a fraternity) is incestuous and nepotistic and it's good to know that the person representing you knows the magistrate/judge because their kids go to the same school and play rugby together on the weekend.
I know this has been said before, but if you are dealing have a lawyer hooked up before something goes wrong. And someone who is not anti-drugs is definately the go.