svi 0.3.18 → 0.3.21

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- YWJkMmRmZjkyYzAxZWNmYTcyZmE0OTYxZWZhNmVhZTBmZDA1NGQwMQ==
4
+ MjE0MWY0N2NhNjg2NWFiNjg4OWNjZjM3ZDA2MTA0YzIwNDE0NTEyMw==
5
5
  data.tar.gz: !binary |-
6
- ZWFlMjQ4ZjQ1ODZlYjQ1Nzc0MmNjMmMzMWI2ZmFlZWUwNmVmMTc4Zg==
6
+ ZjZjZThmMmQ5M2MyZGIzNDRlMDc5YTQ5NWZkYmNiNWFlM2U4MjYyNw==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- ZWNhMmIwYzUxYzlmN2NhYmExNTU2ZTU5YjRkZjBlZDI1NGU3ZjI3NjJiYTY2
10
- NDllY2UyYWVjYTc2ZmFkMjEzYjY4ZGMzMjI5ZTI1ODU2M2ZjMDZkZmU0Y2Fi
11
- ZjUxNzFiYTdkODUxNDVmYmVkZTEyNjA0MTI0MjFlNDNlZTUyNGE=
9
+ YTA3NGI5NjllMzU5YjQ3OGFiZDQwNjgxZTNkZTRjMzgyZWIyMmRiY2U2Mzk4
10
+ YzhlMWFiZTE5MzZiYzg4MmM0ZDNhYWI4NjRjNmFkNWU1ZTdiZTRmYzYyMTI3
11
+ MTQ2NjQyZmMxNjA2YTMxODQxMjk3ZmEwNWI4NWQ4M2VmN2FiZDU=
12
12
  data.tar.gz: !binary |-
13
- NjkyNTc1MjNhZWZhMWZhYzQxMDk1YjRhN2M4YzE3NTUyZWVkMWVjZWUyN2Ey
14
- M2RiMGVlMTc4MWQ4OWQyYTQ4N2UxMTE2NjQ2MGVlNjVhNzU3OTBlYmU4YzZj
15
- NzAwZWRkZDZlZTY4YjhkMWI0MzczN2Y1NTI1NjY0NTU2MjJmMWQ=
13
+ ZjAzNWVlMDBlYjAwODgzZDlhZmJjZDRlMTM0MmZiZGJmMTg0MzE0ZTI3Yjcz
14
+ MzZmOGZkYzcxMjU0NmFlOTYxNzczNmFhMzZiMzI4OTJkNTE1ZDYzNDk0OTQ4
15
+ OGUyN2ExODYzOWZlNDk1ZTc3Nzg2MDc1MThjMmVjMTg4OTA4NTc=
@@ -22,6 +22,9 @@ $svi_api_desc = {
22
22
  :random => { :response => [Integer], :args => [] },
23
23
  :gettime => { :response => [Integer], :args => [] },
24
24
  :settime => { :response => [Integer], :args => [Integer] },
25
+ :starttime => { :response => [Integer], :args => [] },
26
+ :stoptime => { :response => [Integer], :args => [] },
27
+ :isstartedtime => { :response => [Integer,Integer], :args => [] },
25
28
  :app_exist => { :response => [Integer], :args => [] },
26
29
  :app_length => { :response => [Integer], :args => [] },
27
30
  :app_checksum => { :response => [Integer], :args => [] },
@@ -9,6 +9,37 @@ command :time do |c|
9
9
  end
10
10
  end
11
11
 
12
+ c.desc 'Stop time counting'
13
+ c.command :stop do |stop|
14
+ stop.action do |global_opts, opts, args|
15
+ res = $dev.stoptime[0]
16
+
17
+ puts res[0] == 1 ? 'OK'.light_green : 'Fail'.light_red
18
+ end
19
+ end
20
+
21
+ c.desc 'Start time counting'
22
+ c.command :start do |start|
23
+ start.action do |global_opts, opts, args|
24
+ res = $dev.starttime[0]
25
+
26
+ puts res[0] == 1 ? 'OK'.light_green : 'Fail'.light_red
27
+ end
28
+ end
29
+
30
+ c.desc 'Is time initialized'
31
+ c.command :state do |state|
32
+ state.action do |global_opts, opts, args|
33
+ res = $dev.isstartedtime
34
+
35
+ if res[0] == 1
36
+ puts res[1] == 1 ? 'Started'.light_green : 'Stopped'.light_yellow
37
+ else
38
+ puts 'Fail'.light_red
39
+ end
40
+ end
41
+ end
42
+
12
43
  c.action do |global_opts, opts, args|
13
44
  res = $dev.gettime[0]
14
45
 
@@ -1 +1 @@
1
- VERSION='0.3.18'
1
+ VERSION='0.3.21'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: svi
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.18
4
+ version: 0.3.21
5
5
  platform: ruby
6
6
  authors:
7
7
  - Levenkov Artem
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-04-30 00:00:00.000000000 Z
11
+ date: 2015-05-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: libusb