     open var color: UIColor = UIColor.clear
     open var innerRadius: CGFloat = 0
     open var outerRadius: CGFloat = 0
-    open var startAngle: CGFloat = CGFloat(M_PI+M_PI_2)
+    open var startAngle: CGFloat = CGFloat(Double.pi+Double.pi/2)
     open var endAngle: CGFloat = 0
     open var strokeInnerCircle: Bool = false
     open var strokeOuterCircle: Bool = false

    }
    open var percent: CGFloat {
        get {
            return (endAngle - CGFloat(M_PI+M_PI_2))/CGFloat(M_PI*2)
        }
        set {
            let angle = (newValue >= 1) ? CGFloat(3*M_PI+M_PI_2) : (CGFloat(M_PI+M_PI_2) + newValue*CGFloat(M_PI*2))
            self.endAngle = angle
        }
    }

        path.fill()
        
        if strokeInnerCircle {
            let inner = UIBezierPath(arcCenter: center, radius: innerRadius, startAngle: 0, endAngle: CGFloat(Double.pi)*2, clockwise: true)
            inner.addArc(withCenter: center, radius: innerRadius + strokeWidth, startAngle: CGFloat(Double.pi)*2, endAngle: 0, clockwise: false)
            inner.fill()
        }
        if strokeOuterCircle {
            let outer = UIBezierPath(arcCenter: center, radius: outerRadius, startAngle: 0, endAngle: CGFloat(Double.pi)*2, clockwise: true)
            outer.addArc(withCenter: center, radius: outerRadius - strokeWidth, startAngle: CGFloat(Double.pi)*2, endAngle: 0, clockwise: false)
            outer.fill()
        }
        
