blob: d63beebfd674ae4c94e9b9b39bb29c89eb71367a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
#!/usr/bin/env lua
local eyes = require "eyes"
local format = require "format"
local reading = require "reading"
for _, message in ipairs(eyes) do
local previous = 0
local deltas = {}
for _, value in reading.values(message) do
if value <= previous then
previous = previous - 83
end
table.insert(deltas, value - previous)
previous = value
end
print(format.csv(deltas))
end
|