Latest 1.0
Homepage https://github.com/adventam10/AMSpeedMeter
License MIT
Platforms ios 9.0, requires ARC
Authors

AMSpeedMeterView

AMSpeedMeterView is a view can display the value at regular time intervals.

Demo

speedmeter

Variety

speedmeter

Usage

// property
private let speedMeterView = AMSpeedMeterView()
private var timer:Timer?

override func viewDidLoad() {
super.viewDidLoad()

// customize here

view.addSubview(speedMeterView)
timer = Timer.scheduledTimer(timeInterval: 0.5,
target: self,
selector: #selector(self.timerAction(teimer:)),
userInfo: nil,
repeats: true)
}

/// Timer Action
@objc func timerAction(teimer:Timer) {

/// set CGFloat value
speedMeterView.currentValue = value
}

Installation

CocoaPods

Add this to your Podfile.

pod 'AMSpeedMeter'

Carthage

Add this to your Cartfile.

github "adventam10/AMSpeedMeter"

License

MIT

Latest podspec

{
    "name": "AMSpeedMeter",
    "version": "1.0",
    "summary": "AMSpeedMeterView is a view can display the value at regular time intervals.",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "homepage": "https://github.com/adventam10/AMSpeedMeter",
    "authors": {
        "am10": "[email protected]"
    },
    "source": {
        "git": "https://github.com/adventam10/AMSpeedMeter.git",
        "tag": "1.0"
    },
    "platforms": {
        "ios": "9.0"
    },
    "requires_arc": true,
    "source_files": "AMSpeedMeter/*.{swift}",
    "swift_version": "4.0"
}

Pin It on Pinterest

Share This