Last active
          August 29, 2015 13:56 
        
      - 
      
- 
        Save uwekamper/9079899 to your computer and use it in GitHub Desktop. 
    Matelight in Ruby
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | require 'socket' | |
| # 3 colors by 30 pixels by 16 pixels + 4 bytes of checksum (which is never checked) = 1924 byts | |
| frame = (1..1924).map{|x|"\xFF"} * "" | |
| u1 = UDPSocket.new | |
| u1.send a, 0, "matelight", 1337 | |
| # For the emulator use: | |
| u1.send a, 0, "127.0.0.1", 1337 | 
        
      
            XenGi
  
      
      
      commented 
        Mar 2, 2014 
      
    
  
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment