diff --git a/2_vent_vklop.sh b/2_vent_vklop.sh index 53b8fed..5add5c2 100755 --- a/2_vent_vklop.sh +++ b/2_vent_vklop.sh @@ -5,12 +5,20 @@ source .env ventilator=$1 if [[ ! $ventilator ]]; then - echo "Izberi ventilator (1 ali 2 kot parameter)" + echo "Izberi ventilator (1 ali 2 kot parameter; 3 za oba ter 0 za izklop)" exit 0 fi -url="$VIR/?m=1&o=$ventilator" +if [[ $ventilator = 1 ]]; then + url="$VIR/cm?cmnd=PojdiLevo%202000" +elif [[ $ventilator = 2 ]]; then + url="$VIR/cm?cmnd=PojdiDesno%202000" +elif [[ $ventilator = 3 ]]; then + url="$VIR/cm?cmnd=PojdiRavno%202000" +elif [[ $ventilator = 0 ]]; then + url="$VIR/cm?cmnd=UgasniVse" +else + echo "Izbrana možnost ($ventilator) je neveljavna" +fi curl "$url" -sleep 2 -curl "$url" diff --git a/etc_janus_janus.plugin.streaming.jcfg b/etc_janus_janus.plugin.streaming.jcfg index 1718a65..d96cdb3 100644 --- a/etc_janus_janus.plugin.streaming.jcfg +++ b/etc_janus_janus.plugin.streaming.jcfg @@ -1,9 +1,12 @@ rtp-cam: { type = "rtp" - id = 666 description = "esp32 cam!" + id = 666 + description = "esp32 cam!" metadata = "You can use this metadata section to put any info you want!" - audio = false video = true + audio = false + video = true videoport = 8004 videopt = 100 + videortpmap = "VP8/90000" videocodec = "vp8" }