Code Monkey home page Code Monkey logo

blinky's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

blinky's Issues

Webmail Notifier knock-off

Hey there. I have a Webmail Notifier that I think might be a knock-off, and I was wondering if you could help me add support for it.

1.9.3-p362 :002 > blinky = Blinky.new
Blinky::NoSupportedDevicesFound: Blinky was unable to find a supported device 
The devices I did find were:
[#<LIBUSB::Device 250/1 05ac:8006 ? ? ? (Hi-speed Hub with single TT)>,
 #<LIBUSB::Device 253/1 05ac:8006 ? ? ? (Hi-speed Hub with single TT)>,
 #<LIBUSB::Device 253/2 0424:2513 ? ? ? (Hi-speed Hub with multiple TTs)>,
 #<LIBUSB::Device 250/2 0424:2513 ? ? ? (Hi-speed Hub with multiple TTs)>,
 #<LIBUSB::Device 250/3 05ac:850a ? ? ? (Interface Association Descriptor)>,
 #<LIBUSB::Device 253/3 05ac:8404 ? ? ? (MassStorage SCSI Bluk-Only)>,
 #<LIBUSB::Device 250/5 05ac:024c Apple Inc. Apple Internal Keyboard / Trackpad ? (HID (01,01), HID (00,00), HID (01,02))>,
 #<LIBUSB::Device 253/4 1294:1320 MAIL MAIL ? (HID (00,00))>]


    from /Users/pete/.rvm/gems/ruby-1.9.3-p362/gems/blinky-0.0.10/lib/blinky/light_factory.rb:14:in `detect_lights'

Had a bit of a poke about:

1.9.3-p362 :007 > mail = USB.devices[7]
 => #<LIBUSB::Device 253/4 1294:1320 MAIL MAIL ? (HID (00,00))> 
1.9.3-p362 :008 > mail.id
mail.idProduct  mail.idVendor 
1.9.3-p362 :008 > mail.idVendor
 => 4756 
1.9.3-p362 :009 > mail.idProduct
 => 4896 

The idVendor and idProduct don't match inside recipes.rb:

recipe DreamCheeky::WebmailNotifier,  {:usb_vendor_id => 0x1d34, 
                                       :usb_product_id => 0x0004, 
                                       :description => "Dream Cheeky Webmail Notifier"}

I don't have any idea how to do this, but I'm willing to invest time to find out how. If you could give me a couple of tips, it would be much appreciated.

Blinkt! only supported on Linux

I'm working on a PR to add Blinkt! support to blinky, but it turns out the blinkt Gem has dependencies that are Linux-only (and very Linux-only, relying on kernel functionality not present in other OSs).

Assuming non-Linux OSs are important targets for blinky (e.g. mention of Windows in the docs), I wonder how to proceed here.

There's an open issue on bundler about supporting OS-specific groups, but no progress as of yet.

I guess I could always maintain a Blinkt!-specific fork, but that feels a bit hacky.

Thoughts?

Unable to install on OS X 10.8.3

Very excited to use this!
I have the latest command-line tools and brew is updated. Libusb installs no problem.
When I 'sudo gem install blinky' on 10.8.3 it fails, please help.
Install ends with:
"Configuring libffi for i386
configure: WARNING: if you wanted to set the --build type, don't use --host.
If a cross compiler is detected then cross compile mode will be used
configure: error: in /Library/Ruby/Gems/1.8/gems/ffi-1.8.1/ext/ffi_c/libffi-i386': configure: error: C compiler cannot create executables" Seeconfig.log' for more details
make[1]: *** No targets specified and no makefile found. Stop.

Port to Java

Hey @perryn I am currently working on porting this project to java, I am going to be basing myself a lot on the structure of this one so I just wanted to both give you a heads up and to confirm if you were ok with it.

I am also still not set on the name but one of my choices was jblinky, which also made me wonder if you had any issue with that as well.

Let me know any comments or concerns, thank you!

LIBUSB::ERROR_ACCESS in libusb_open

Hi Perryn,

I have done everything to make this work, but everytime I initialize Blinky, I always got this error message. Can you help me with this?

arvin@arvin-VirtualBox:~$ irb
r2.2.0 :001 > require 'blinky'
=> true
2.2.0 :002 > l = Blinky.new
LIBUSB::ERROR_ACCESS: LIBUSB::ERROR_ACCESS in libusb_open
from /home/arvin/.rvm/gems/ruby-2.2.0/gems/libusb-0.2.2/lib/libusb/constants.rb:46:in raise_error' from /home/arvin/.rvm/gems/ruby-2.2.0/gems/libusb-0.2.2/lib/libusb/device.rb:58:inopen'
from /home/arvin/.rvm/gems/ruby-2.2.0/gems/libusb-0.2.2/lib/libusb/compat.rb:175:in open' from /home/arvin/.rvm/gems/ruby-2.2.0/gems/blinky-0.0.12/lib/blinky/light_factory.rb:11:inblock in detect_lights'
from /home/arvin/.rvm/gems/ruby-2.2.0/gems/blinky-0.0.12/lib/blinky/light_factory.rb:7:in each' from /home/arvin/.rvm/gems/ruby-2.2.0/gems/blinky-0.0.12/lib/blinky/light_factory.rb:7:indetect_lights'
from /home/arvin/.rvm/gems/ruby-2.2.0/gems/blinky-0.0.12/lib/blinky.rb:26:in `initialize'

Failed to run blinky under Ubuntu 12.04

$ sudo ruby1.9.3 test.rb
/var/lib/gems/1.9.1/gems/libusb-0.2.2/lib/libusb/constants.rb:46:in `raise_error': LIBUSB::ERROR_IO in libusb_submit_transfer (LIBUSB::ERROR_IO)
    from /var/lib/gems/1.9.1/gems/libusb-0.2.2/lib/libusb/transfer.rb:135:in `submit!'
    from /var/lib/gems/1.9.1/gems/libusb-0.2.2/lib/libusb/transfer.rb:162:in `submit_and_wait!'
    from /var/lib/gems/1.9.1/gems/libusb-0.2.2/lib/libusb/dev_handle.rb:390:in `control_transfer'
    from /var/lib/gems/1.9.1/gems/libusb-0.2.2/lib/libusb/compat.rb:316:in `usb_control_msg'
    from /var/lib/gems/1.9.1/gems/blinky-0.0.12/lib/device_recipes/delcom_engineering/visual_indicator_gen_two.rb:35:in `set_colour'
    from /var/lib/gems/1.9.1/gems/blinky-0.0.12/lib/device_recipes/delcom_engineering/visual_indicator_gen_two.rb:27:in `off!'
    from /var/lib/gems/1.9.1/gems/blinky-0.0.12/lib/device_recipes/delcom_engineering/visual_indicator_gen_two.rb:22:in `warning!'
    from test.rb:5:in `<main>'
[  256.978955] usb 2-1.2: usbfs: process 3627 (ruby1.9.3) did not claim interface 0 before use
$ gem list

*** LOCAL GEMS ***

blinky (0.0.12)
chicanery (0.1.5)
ffi (1.9.3)
libusb (0.2.2)
mini_portile (0.5.3)
nokogiri (1.6.1)
$ dpkg -s libusb-1.0-0-dev
Package: libusb-1.0-0-dev
Status: install ok installed
Priority: optional
Section: libdevel
Installed-Size: 898
Maintainer: Ubuntu Developers <[email protected]>
Architecture: amd64
Source: libusb-1.0
Version: 2:1.0.9~rc3-2ubuntu1
Depends: libusb-1.0-0 (= 2:1.0.9~rc3-2ubuntu1), libc6-dev | libc-dev
Description: userspace USB programming library development files
 Library for programming USB applications without the knowledge
 of Linux kernel internals.
Homepage: http://www.linux-usb.org/
Original-Maintainer: Aurelien Jarno <[email protected]>

Not sure what's the cause

Installing Gem issue

I get this error on Ubuntu 13.11 when installing the Gem....

eddie@ubuntu13-10:~$ sudo gem install blinky
Building native extensions.  This could take a while...
ERROR:  Error installing blinky:
    ERROR: Failed to build gem native extension.

        /usr/bin/ruby1.9.1 extconf.rb
/usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- mkmf (LoadError)
    from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
    from extconf.rb:4:in `<main>'


Gem files will remain installed in /var/lib/gems/1.9.1/gems/ffi-1.9.3 for inspection.
Results logged to /var/lib/gems/1.9.1/gems/ffi-1.9.3/ext/ffi_c/gem_make.out

Any ideas?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.