From 2e2db9d427e8ea751d6189c4e084da3daf6a8567 Mon Sep 17 00:00:00 2001 From: tth Date: Sat, 31 Oct 2020 01:08:23 +0100 Subject: [PATCH] loth project, next step --- Loth/README.md | 13 ++++++++++++- Loth/config.sh | 5 +++++ Loth/play.sh | 19 +++++++++++++++++++ Loth/sender.sh | 10 +++++++--- 4 files changed, 43 insertions(+), 4 deletions(-) create mode 100644 Loth/config.sh create mode 100755 Loth/play.sh diff --git a/Loth/README.md b/Loth/README.md index 71fc450..035f5ce 100644 --- a/Loth/README.md +++ b/Loth/README.md @@ -1,8 +1,19 @@ # Loth Hacks for fun and profit +Le problème est complxe : comment découvrir l'adresse IP d'un machin +qui tourne avec MadMapper ? + +Il y a toute une procédure vu que leur truc utilise __Bonjour__ pour +découvrir leurs adresses IP. + +`$ mdns-scan` + ## en shell -Voir `sender.sh` +Les paramètres sont dans `config.sh` pour adresser les madboites +vidéo et lumière. + +Voir `play.sh`. ## en C diff --git a/Loth/config.sh b/Loth/config.sh new file mode 100644 index 0000000..74561c1 --- /dev/null +++ b/Loth/config.sh @@ -0,0 +1,5 @@ + +# config pour le MapMachin + +R_IP="10.20.25.6" +R_PORT="1111" diff --git a/Loth/play.sh b/Loth/play.sh new file mode 100755 index 0000000..0f35641 --- /dev/null +++ b/Loth/play.sh @@ -0,0 +1,19 @@ +#!/bin/bash + +source config.sh + +function envoyer +{ +msg=$1 +echo $msg +oscsend $R_IP $R_PORT $msg +} + +envoyer "/play" +sleep 15 +envoyer "/pause" + + + + + diff --git a/Loth/sender.sh b/Loth/sender.sh index 75ed1ad..dae6a55 100755 --- a/Loth/sender.sh +++ b/Loth/sender.sh @@ -1,7 +1,11 @@ #!/bin/bash -R_IP="localhost" -R_PORT="2222" +# +# c'est juste du code d'exemple +# + +R_IP="10.20.31.170" +R_PORT="1111" DEVICE=42 @@ -12,7 +16,7 @@ oscsend $R_IP $R_PORT $oscpath s "===========" for foo in $(seq 20 7 80) do echo " " $foo - message=$(printf "0x%02x" $foo) + message=$(printf " 0x%02x" $foo) oscsend $R_IP $R_PORT $oscpath s "$message" sleep 1 done