blinky-cloud 1.1.1 → 1.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3b680ed9b4f70efae6b215b8bfe26faa209989d0
4
- data.tar.gz: 862c8f8b973af60a36aa80e8ea71285dc01da45f
3
+ metadata.gz: 3be9d4e9ef991d1e9b9f005d597fb1966e4db951
4
+ data.tar.gz: f568de8951e153a5bd0724072401808dfb0270c3
5
5
  SHA512:
6
- metadata.gz: bf5e9648ef8a0bc2c2571ea30f17d96ea6c9590296dfd0262201195eac6b532fd8c037b6af8baa86e88db4442be4238bf97b26f7ce5b96b0c87e8a7bc89e0345
7
- data.tar.gz: 586b94ded249bef10a6a182fcd288daa3a30fd921c2d7c9ae1055bb474062ac1ea2f21b09a807d0e104b984cae4cf6d41a280c5d66d094648dc4c539d76b8a46
6
+ metadata.gz: 84948643ba0b655a99cd2b1acc1b26f23d312fff8c0459f82c211b8079db1a851c0827a1f35e17b4469f73ab6c4edd6f0587f5435e8f8bf9d2737498bc7b645d
7
+ data.tar.gz: d7a54de62ab7f4ceb2b12cddc20f8b61835a86ab86107733402317430c813616bde49f064a12b0f7d365af42ff5c2fe274eee98486b099bef0d6320da3479137
@@ -1,12 +1,12 @@
1
- (lp0
2
- (S'serial'
3
- p1
4
- S'/usr/local/bin/picocom'
5
- p2
6
- tp3
7
- a(S'build_dir'
8
- p4
9
- S'.build/uno'
10
- p5
11
- tp6
1
+ (lp0
2
+ (S'serial'
3
+ p1
4
+ S'/usr/local/bin/picocom'
5
+ p2
6
+ tp3
7
+ a(S'build_dir'
8
+ p4
9
+ S'.build/uno'
10
+ p5
11
+ tp6
12
12
  a.
data/.gitignore CHANGED
@@ -1,34 +1,34 @@
1
- *.gem
2
- *.rbc
3
- /.config
4
- /coverage/
5
- /InstalledFiles
6
- /pkg/
7
- /spec/reports/
8
- /test/tmp/
9
- /test/version_tmp/
10
- /tmp/
11
-
12
- ## Specific to RubyMotion:
13
- .dat*
14
- .repl_history
15
- build/
16
-
17
- ## Documentation cache and generated files:
18
- /.yardoc/
19
- /_yardoc/
20
- /doc/
21
- /rdoc/
22
-
23
- ## Environment normalisation:
24
- /.bundle/
25
- /lib/bundler/man/
26
-
27
- # for a library or gem, you might want to ignore these files since the code is
28
- # intended to run in multiple environments; otherwise, check them in:
29
- # Gemfile.lock
30
- # .ruby-version
31
- # .ruby-gemset
32
-
33
- # unless supporting rvm < 1.11.0 or doing something fancy, ignore this:
34
- .rvmrc
1
+ *.gem
2
+ *.rbc
3
+ /.config
4
+ /coverage/
5
+ /InstalledFiles
6
+ /pkg/
7
+ /spec/reports/
8
+ /test/tmp/
9
+ /test/version_tmp/
10
+ /tmp/
11
+
12
+ ## Specific to RubyMotion:
13
+ .dat*
14
+ .repl_history
15
+ build/
16
+
17
+ ## Documentation cache and generated files:
18
+ /.yardoc/
19
+ /_yardoc/
20
+ /doc/
21
+ /rdoc/
22
+
23
+ ## Environment normalisation:
24
+ /.bundle/
25
+ /lib/bundler/man/
26
+
27
+ # for a library or gem, you might want to ignore these files since the code is
28
+ # intended to run in multiple environments; otherwise, check them in:
29
+ # Gemfile.lock
30
+ # .ruby-version
31
+ # .ruby-gemset
32
+
33
+ # unless supporting rvm < 1.11.0 or doing something fancy, ignore this:
34
+ .rvmrc
data/Gemfile CHANGED
@@ -1,3 +1,3 @@
1
- source 'https://rubygems.org'
2
- gemspec
3
-
1
+ source 'https://rubygems.org'
2
+ gemspec
3
+
data/Gemfile.lock CHANGED
@@ -1,18 +1,19 @@
1
- PATH
2
- remote: .
3
- specs:
4
- blinky-cloud (1.1.1)
5
- blinky-tape-test-status
6
-
7
- GEM
8
- remote: https://rubygems.org/
9
- specs:
10
- blinky-tape-test-status (1.1.0)
11
- serialport
12
- serialport (1.3.0)
13
-
14
- PLATFORMS
15
- ruby
16
-
17
- DEPENDENCIES
18
- blinky-cloud!
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ blinky-cloud (1.1.3)
5
+ blinky-tape-test-status
6
+
7
+ GEM
8
+ remote: https://rubygems.org/
9
+ specs:
10
+ blinky-tape-test-status (1.1.2)
11
+ serialport
12
+ serialport (1.3.0)
13
+
14
+ PLATFORMS
15
+ ruby
16
+ x64-mingw32
17
+
18
+ DEPENDENCIES
19
+ blinky-cloud!
data/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- The MIT License (MIT)
2
-
3
- Copyright (c) 2014 Resellers
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2014 Resellers
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
21
  SOFTWARE.
data/README.md CHANGED
@@ -1,49 +1,49 @@
1
- blinky-cloud
2
- ============
3
-
4
- Beowulf cluster for BlinkyTape
5
-
6
- Requirements
7
- ============
8
-
9
- * ruby
10
- * a [blinky tape](http://blinkinlabs.com/blinkytape/)
11
-
12
- Installation
13
- ============
14
-
15
- `gem install blinky-cloud`
16
-
17
- Command Line Usage
18
- ==================
19
-
20
- As a listener:
21
-
22
- 1. Plug in your blinky tape
23
- 1. run `blinky-cloud-listen`
24
-
25
- As a broadcaster:
26
-
27
- 1. run `blinky-cloud-broadcast` passing the characters you wish to send to the
28
- blinky tape
29
-
30
- Talking to Blinky Tape
31
- ----------------------
32
-
33
- Flashing Green:
34
-
35
- `blinky-cloud-broadcast fg`
36
-
37
- Pulsing Blue:
38
-
39
- `blinky-cloud-broadcast pb`
40
-
41
- Solid White:
42
-
43
- `blinky-cloud-broadcast sw`
44
-
45
- Set Brightness to 50%:
46
-
47
- `blinky-cloud-broadcast 5`
48
-
49
- For more commands, see the [blinky tape test status README](https://github.com/integrum/blinky-tape-test-status)
1
+ blinky-cloud
2
+ ============
3
+
4
+ Beowulf cluster for BlinkyTape
5
+
6
+ Requirements
7
+ ============
8
+
9
+ * ruby
10
+ * a [blinky tape](http://blinkinlabs.com/blinkytape/)
11
+
12
+ Installation
13
+ ============
14
+
15
+ `gem install blinky-cloud`
16
+
17
+ Command Line Usage
18
+ ==================
19
+
20
+ As a listener:
21
+
22
+ 1. Plug in your blinky tape
23
+ 1. run `blinky-cloud-listen`
24
+
25
+ As a broadcaster:
26
+
27
+ 1. run `blinky-cloud-broadcast` passing the characters you wish to send to the
28
+ blinky tape
29
+
30
+ Talking to Blinky Tape
31
+ ----------------------
32
+
33
+ Flashing Green:
34
+
35
+ `blinky-cloud-broadcast fg`
36
+
37
+ Pulsing Blue:
38
+
39
+ `blinky-cloud-broadcast pb`
40
+
41
+ Solid White:
42
+
43
+ `blinky-cloud-broadcast sw`
44
+
45
+ Set Brightness to 50%:
46
+
47
+ `blinky-cloud-broadcast 5`
48
+
49
+ For more commands, see the [blinky tape test status README](https://github.com/integrum/blinky-tape-test-status)
@@ -1,8 +1,8 @@
1
- #!/usr/bin/env ruby
2
- require 'rubygems'
3
- require 'bundler/setup'
4
-
5
- require 'blinky_cloud'
6
-
7
- broadcaster = BlinkyCloud::Broadcaster.new
8
- broadcaster.broadcast! ARGV[0]
1
+ #!/usr/bin/env ruby
2
+ require 'rubygems'
3
+ require 'bundler/setup'
4
+
5
+ require 'blinky_cloud'
6
+
7
+ broadcaster = BlinkyCloud::Broadcaster.new
8
+ broadcaster.broadcast! ARGV[0]
@@ -1,9 +1,9 @@
1
- #!/usr/bin/env ruby
2
- require 'rubygems'
3
- require 'bundler/setup'
4
- require 'blinky_cloud/listener'
5
- require 'blinky_tape_test_status'
6
-
7
- blinky = BlinkyTapeTestStatus::Base.new
8
- listener = BlinkyCloud::Listener.new
9
- listener.listen(lambda {|data| blinky.write! data})
1
+ #!/usr/bin/env ruby
2
+ require 'rubygems'
3
+ require 'bundler/setup'
4
+ require 'blinky_cloud/listener'
5
+ require 'blinky_tape_test_status'
6
+
7
+ blinky = BlinkyTapeTestStatus::Base.new
8
+ listener = BlinkyCloud::Listener.new
9
+ listener.listen(lambda {|data| blinky.write! data})
data/blinky-cloud.gemspec CHANGED
@@ -1,22 +1,22 @@
1
- $:.push File.expand_path("../lib", __FILE__)
2
- require "blinky_cloud/version"
3
-
4
- Gem::Specification.new do |s|
5
- s.name = 'blinky-cloud'
6
- s.version = BlinkyCloud::VERSION
7
- s.summary = "blinky-cloud"
8
- s.description = "A Ruby interface for blinky-cloud"
9
- s.authors = ["Jade Meskill", "Roy van de Water", "Clayton Lengel-Zigich"]
10
- s.email = 'dev@integrumtech.com'
11
-
12
- s.files = `git ls-files`.split("\n")
13
- s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
14
- s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
15
- s.require_paths = ["lib"]
16
-
17
- s.add_runtime_dependency "blinky-tape-test-status"
18
-
19
- s.homepage =
20
- 'http://rubygems.org/gems/blinky-cloud'
21
- s.license = 'MIT'
22
- end
1
+ $:.push File.expand_path("../lib", __FILE__)
2
+ require "blinky_cloud/version"
3
+
4
+ Gem::Specification.new do |s|
5
+ s.name = 'blinky-cloud'
6
+ s.version = BlinkyCloud::VERSION
7
+ s.summary = "blinky-cloud"
8
+ s.description = "A Ruby interface for blinky-cloud"
9
+ s.authors = ["Jade Meskill", "Roy van de Water", "Clayton Lengel-Zigich"]
10
+ s.email = 'dev@integrumtech.com'
11
+
12
+ s.files = `git ls-files`.split("\n")
13
+ s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
14
+ s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
15
+ s.require_paths = ["lib"]
16
+
17
+ s.add_runtime_dependency "blinky-tape-test-status"
18
+
19
+ s.homepage =
20
+ 'http://rubygems.org/gems/blinky-cloud'
21
+ s.license = 'MIT'
22
+ end
data/lib/blinky_cloud.rb CHANGED
@@ -1,3 +1,3 @@
1
- require 'blinky_cloud/base'
2
- require 'blinky_cloud/broadcaster'
3
- require 'blinky_cloud/listener'
1
+ require 'blinky_cloud/base'
2
+ require 'blinky_cloud/broadcaster'
3
+ require 'blinky_cloud/listener'
@@ -1,13 +1,13 @@
1
- require 'socket'
2
-
3
- module BlinkyCloud
4
- class Base
5
- MULTICAST_ADDR = "224.0.0.1"
6
- PORT = 54321
7
-
8
- def socket
9
- @socket ||= UDPSocket.open
10
- end
11
-
12
- end
13
- end
1
+ require 'socket'
2
+
3
+ module BlinkyCloud
4
+ class Base
5
+ MULTICAST_ADDR = "224.1.1.1"
6
+ PORT = 54321
7
+
8
+ def socket
9
+ @socket ||= UDPSocket.open
10
+ end
11
+
12
+ end
13
+ end
@@ -1,9 +1,10 @@
1
- module BlinkyCloud
2
- class Broadcaster < BlinkyCloud::Base
3
- def broadcast!(data)
4
- socket.setsockopt(:IPPROTO_IP, :IP_MULTICAST_TTL, 1)
5
- socket.send(data, 0, MULTICAST_ADDR, PORT)
6
- socket.close
7
- end
8
- end
9
- end
1
+ require 'blinky_cloud/base'
2
+
3
+ module BlinkyCloud
4
+ class Broadcaster < BlinkyCloud::Base
5
+ def broadcast!(data)
6
+ socket.setsockopt(:IPPROTO_IP, :IP_MULTICAST_TTL, 1)
7
+ socket.send(data, 0, MULTICAST_ADDR, PORT)
8
+ end
9
+ end
10
+ end
@@ -1,23 +1,30 @@
1
- require "ipaddr"
2
- require 'blinky_cloud/base'
3
-
4
- module BlinkyCloud
5
- class Listener < BlinkyCloud::Base
6
- BIND_ADDR = "0.0.0.0"
7
-
8
- def listen(callback)
9
- socket = UDPSocket.new
10
- membership = IPAddr.new(MULTICAST_ADDR).hton + IPAddr.new(BIND_ADDR).hton
11
-
12
- socket.setsockopt(:IPPROTO_IP, :IP_ADD_MEMBERSHIP, membership)
13
- socket.setsockopt(:SOL_SOCKET, :SO_REUSEPORT, 1)
14
-
15
- socket.bind(BIND_ADDR, PORT)
16
-
17
- loop do
18
- message, _ = socket.recvfrom(255)
19
- callback.call(message)
20
- end
21
- end
22
- end
23
- end
1
+ require "ipaddr"
2
+ require 'blinky_cloud/base'
3
+
4
+ module BlinkyCloud
5
+ class Listener < BlinkyCloud::Base
6
+ BIND_ADDR = "0.0.0.0"
7
+
8
+ def listen(callback)
9
+ socket = UDPSocket.new
10
+ membership = IPAddr.new(MULTICAST_ADDR).hton + IPAddr.new(BIND_ADDR).hton
11
+
12
+ socket.setsockopt(:IPPROTO_IP, :IP_ADD_MEMBERSHIP, membership)
13
+ begin
14
+ socket.setsockopt(:SOL_SOCKET, :SO_REUSEPORT, 1)
15
+ rescue SocketError
16
+ end
17
+ begin
18
+ socket.setsockopt(:SOL_SOCKET, :SO_REUSEADDR, 1)
19
+ rescue SocketError
20
+ end
21
+
22
+ socket.bind(BIND_ADDR, PORT)
23
+
24
+ loop do
25
+ message, _ = socket.recvfrom(255)
26
+ callback.call(message)
27
+ end
28
+ end
29
+ end
30
+ end
@@ -1,3 +1,3 @@
1
- module BlinkyCloud
2
- VERSION = '1.1.1'
3
- end
1
+ module BlinkyCloud
2
+ VERSION = '1.1.3'
3
+ end
data/pre-push CHANGED
@@ -1,3 +1,3 @@
1
- #!/bin/sh
2
-
3
- blinky-cloud-broadcast si
1
+ #!/bin/sh
2
+
3
+ blinky-cloud-broadcast si
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: blinky-cloud
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jade Meskill
@@ -10,20 +10,20 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2014-04-09 00:00:00.000000000 Z
13
+ date: 2014-04-22 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: blinky-tape-test-status
17
17
  requirement: !ruby/object:Gem::Requirement
18
18
  requirements:
19
- - - ">="
19
+ - - '>='
20
20
  - !ruby/object:Gem::Version
21
21
  version: '0'
22
22
  type: :runtime
23
23
  prerelease: false
24
24
  version_requirements: !ruby/object:Gem::Requirement
25
25
  requirements:
26
- - - ">="
26
+ - - '>='
27
27
  - !ruby/object:Gem::Version
28
28
  version: '0'
29
29
  description: A Ruby interface for blinky-cloud
@@ -34,8 +34,8 @@ executables:
34
34
  extensions: []
35
35
  extra_rdoc_files: []
36
36
  files:
37
- - ".build/environment.pickle"
38
- - ".gitignore"
37
+ - .build/environment.pickle
38
+ - .gitignore
39
39
  - Gemfile
40
40
  - Gemfile.lock
41
41
  - LICENSE
@@ -59,12 +59,12 @@ require_paths:
59
59
  - lib
60
60
  required_ruby_version: !ruby/object:Gem::Requirement
61
61
  requirements:
62
- - - ">="
62
+ - - '>='
63
63
  - !ruby/object:Gem::Version
64
64
  version: '0'
65
65
  required_rubygems_version: !ruby/object:Gem::Requirement
66
66
  requirements:
67
- - - ">="
67
+ - - '>='
68
68
  - !ruby/object:Gem::Version
69
69
  version: '0'
70
70
  requirements: []