blob: 6af248c233b09fd43896152b0ed36d995e72c9fe (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
clear//
//Variables
R1 = 240.0 //Resistance1 (in ohm)
R2 = 2.4 * 10**3 //Resistance2 (in ohm)
VREF = 1.25 //Reference voltage (in volts)
//Calculation
Vo = VREF * (R2/R1 + 1) //Regulated dc output voltage (in volts)
//Result
printf("\n Regulated dc output voltage is %0.3f V.",Vo)
|