Ohm = (Vcc - Vcz) : (30 + mA) x 1000
... but in my opinion the problem is that i'm tring to find a resistor value , that is common in the voltage 9, 12,24.
So considering your formula :
24v-6,8=17,2 --> 17,2V/0,06A=286ohm
ok .. i install a 286ohm resistor.
What's happened when the voltage is 12?
12-6,8=5,2
5,2/x=286 ---> 0,018A , i need 60mA!
and 9V?
9-6,8=2,2/x=286 --> 0,007A, i always need 60mA!!
So my exercise is to find a value that can provide 60mA at 9V ... and more with 12 and 24.
Considering the same formula it could be 36ohm, in this case i have:
9v ---> 60mA , 200mW
12v ---> 145mA , 900 mW
24 ---> 475mA , 8,7W !!! <----- this is my problem i suppose.
Maybe my exercise is without reason, but my goal is to obtain minimum 60mA with 3 different source voltage 9,12,24v
Thanks
Mirko