Is there a rule of thumb for the pronunciation of О?
As in when to pronounce it as O, when as A and when as that weird sound in between the 2.
Only one syllable is given stress in any Russian word. If the 'o' is in the stressed position, it sounds like 'oh' (although it's a shorter, more crisp 'oh' with rounded lips, not the long dipthongy 'o-oh' that we tend to do in English). If the 'o' is one stress to the left of the stressed syllable, it sounds like 'ah'. If the 'o' is in any syllable further away from the stressed syllable, or anywhere after the stressed syllable, it sounds like schwa ('uh').
я́блоко = YAH-bluh-kuh
окно́ = ahk-NOH
молоко́ = мuh-lah-KOH
Or correct IPA transcription: [ˈjæbləkə], [ɐkˈno], [məlɐˈko]
A bit different. Look at greenq's answer above for the correct IPA transcriptions. Russian 'а' is usually [a]: https://en.wikipedia.org/wiki/Open_central_unrounded_vowel
Russian 'о' is never [a], only [o], [ɐ], or [ə]. However, the Russian 'а' also reduces in unaccented positions, so in the immediate pre-stress position, both 'о' and 'а' sound like [ɐ] and in other unaccented positions both 'о' and 'а' sound like [ə].
голова = [ɡəɫ̪ɐˈva]
Listen to the difference: https://upload.wikimedia.org/wikipedia/commons/d/da/Ru-%D0%B3%D0%BE%D0%BB%D0%BE%D0%B2%D0%B0.ogg
Just remember it's vowel reduction. The further away from the stress and anywhere after the stress, the more reduced the sound will be (generally). It happens with all of the vowels to some extent. See https://en.wikipedia.org/wiki/Russian_phonology
I believe it only ever sounds like o in the stressed syllable of a word. I'm not sure how it behaves when there is a secondary stress.
It sounds like uh in other positions except in the syllable just before the stress, where it sounds like ah.
Ё always sounds like yo because it is always stressed.
Just to let everybody know, stressed "O" is pronounced with subtle "W" at the beginning of the sound. But don't mess with this at the beginning of your russian course lest it should add more complication. If you pronounce words with no vowel reduction at least they will be intelligible all the way.
There are regions and dialects where every O is pronounced like 'oh'. https://ru.wikipedia.org/wiki/%D0%9E%D0%BA%D0%B0%D0%BD%D1%8C%D0%B5
But for most it sounds kinda weird and funny.
Since when reason has anything to do with pronunciation? :)
But seriously this "okanye" is usually perceived as a property of a rural, not-so-well-educated people ("деревенщина").
But on the other hand, if your goal is not to sound like an average Russian, but to simply make yourself understood, you can pretty much just read vowels for what they are, just know when the preceding consonant is softened and when е, ё, ю, я start with j-sound (first letter of the word, after a vowel and after Ь and Ъ) and when not (all other cases), and you're all set up. You will sound a bit unnatural (you will anyway) but you will be perfectly understood.
I, for the life of me, can't tell the difference between English mAn and mEn (mind you, I have good ear!) and I'm fine :)
I think that stresses are much more important than the difference between oh, ah and uh sounds.