]> git.zerfleddert.de Git - fnordlicht-mini/blame - firmware/tests/save_hsv.rb
add initialization of node address via eeprom
[fnordlicht-mini] / firmware / tests / save_hsv.rb
CommitLineData
ec1bef8e 1#!/usr/bin/env ruby
2
3$:.unshift(File.dirname(__FILE__)+"/lib")
4
5require 'fnordlicht'
6require 'serialport'
7
8include Fnordlicht
9
10$dev = SerialPort.new("/dev/ttyUSB0", 19200)
11
12puts "sending sync sequence"
13sync()
14
15puts "save 11 random hue values (hsv) in eeprom"
160.upto 10 do |i|
17 hue = rand(360)
18 puts "hue: %u" % hue
19 save_hsv(255, i, hue, 255, 255, 10, 1, 10);
20 sleep 0.1
21end
Impressum, Datenschutz