Initial commit

main
Tom Dunlap 2021-11-09 14:06:31 -05:00
parent efe30a1ae9
commit 6f68a5c0a9
2 changed files with 16 additions and 0 deletions

3
post-colour.sh 100644
View File

@ -0,0 +1,3 @@
#!/bin/sh
curl 'https://colour-time-default-rtdb.firebaseio.com/messages.json' -d '{"text": "yo", "red": 1, "green": 2, "blue": 3}'

13
update_colour.ps1 100644
View File

@ -0,0 +1,13 @@
$messages = Invoke-WebRequest 'https://colour-time-default-rtdb.firebaseio.com/messages.json?limitToLast=1&orderBy="$key"' | ConvertFrom-Json
$message = $messages.PSObject.Properties.Value
$red = [int]$message.red
$green = [int]$message.green
$blue = [int]$message.blue
echo $red
echo $green
echo $blue
$setCmd = "set-all=$red,$green,$blue"
echo $setCmd
& "C:\Program Files\AlienFX Tools\alienfx-cli.exe" $setCmd