added scripts for mikrotik devices

Cette révision appartient à :
Albirew 2024-09-03 00:10:43 +02:00
Parent e22be055ae
révision e1d77eb51e
Signé par: Albirew
ID de la clé GPG: 9D72DAEB1BB933C9
10 fichiers modifiés avec 523 ajouts et 0 suppressions

14
mikrotik/Sonore.rsc Fichier normal
Voir le fichier

@ -0,0 +1,14 @@
# Sonore
# A script used for antennas alignment: the higher-pitched the sound, the better the alignment
:local minStr -70
:local maxStr -50
:local minFreq 300
:local maxFreq 5000
:local a (($maxFreq - $minFreq) / ($maxStr - $minStr))
:local b ((($maxStr * $minFreq) - ($minStr * $maxFreq)) / ($maxStr - $minStr))
/interface wireless monitor [/interface find name=wlan1] duration=10s interval=0.02s do={
:if ($"status" = "connected-to-ess") do={
:beep frequency=(($"signal-strength" * $a) + $b)
}
}

67
mikrotik/manageVLAN.rsc Fichier normal
Voir le fichier

@ -0,0 +1,67 @@
# VLAN management script (
# Script to easily create, manage and delete VLAN
# Only need to start it once at boot
# Calls should include when needed:
# vlanID = vlan number (should be 99 (num) and not "99" (str) for vlan99)
# vlanIP = vlan IP, eg: "192.168.99.2/24" (str)
# )
# USAGE:
# add a VLAN
# $vlanAdd vlanID=99
# Add an IP to VLAN
# $vlanAddIP vlanID=99 vlanIP="192.168.99.2/24"
# Edit an VLAN IP
# $vlanModIP vlanID=99 vlanIP="192.168.99.2/24"
# Remove an IP from a specific VLAN
# $vlanDelIP vlanID=99 vlanIP="192.168.99.2/24"
# Enable a VLAN
# $vlanEn vlanID=99
# Disable a VLAN
# $vlanDis vlanID=99
# Completely remove a LAN (should add a security on webinterface to NOT remove last vlan if no more IP)
# $vlanDel vlanID=99
# perms: read,write,policy,test
:global vlanAdd do={
/log/info "[VLAN MANAGER] Creating VLAN $vlanID"
/interface/bridge/add name="br-vlan$[$vlanID]" protocol-mode=none;
/interface/vlan/add name="vlan$[$vlanID]-ether1" vlan-id=$vlanID interface=[/interface/ethernet/find];
/interface/vlan/add name="vlan$[$vlanID]-wlan1" vlan-id=$vlanID interface=[/interface/wireless/find];
/interface/bridge/port/add interface="vlan$[$vlanID]-ether1" bridge="br-vlan$[$vlanID]";
/interface/bridge/port/add interface="vlan$[$vlanID]-wlan1" bridge="br-vlan$[$vlanID]";
:if [/interface/ethernet/find name=sfp1] do={
/interface/vlan/add name="vlan$[$vlanID]-sfp1" vlan-id=$vlanID interface=[/interface/ethernet/find name=sfp1];
/interface/bridge/port/add interface="vlan$[$vlanID]-sfp1" bridge="br-vlan$[$vlanID]";
}
}
:global vlanAddIP do={
/log/info "[VLAN MANAGER] Adding $vlanIP to VLAN $vlanID"
/ip/address/add address="$[$vlanIP]" interface="br-vlan$[$vlanID]";
}
:global vlanModIP do={
/log/info "[VLAN MANAGER] Changing IP to $vlanIP on VLAN $vlanID"
/ip/address/set address="$[$vlanIP]" [/ip/address/find interface="br-vlan$[$vlanID]"];
}
:global vlanDelIP do={
/log/warning "[VLAN MANAGER] Deleting $vlanIP from VLAN $vlanID"
/ip/address/remove [/ip/address/find interface="br-vlan$[$vlanID]" address="$vlanIP"];
}
:global vlanEn do={
/log/info "[VLAN MANAGER] Enabling VLAN $vlanID"
/interface/bridge/set "br-vlan$[$vlanID]" disabled=no;
}
:global vlanDis do={
/log/warning "[VLAN MANAGER] Disabling VLAN $vlanID"
/interface/bridge/set "br-vlan$[$vlanID]" disabled=yes;
}
:global vlanDel do={
/log/warning "[VLAN MANAGER] Removing VLAN $vlanID"
/ip/address/remove [/ip/address/find interface="br-vlan$[$vlanID]"];
/interface/bridge/remove "br-vlan$[$vlanID]";
/interface/vlan/remove "vlan$[$vlanID]-ether1";
/interface/vlan/remove "vlan$[$vlanID]-wlan1";
:if [/interface/ethernet/find name=sfp1] do={
/interface/vlan/remove "vlan$[$vlanID]-sfp1";
}
}

Voir le fichier

@ -0,0 +1,33 @@
@echo off
:: Date generator for Mikrotik
:: Generate a console command based on computer's date and time
:: Command format is for RouterOS up to 7.9.2
:loop
cls
set date-day=%date:~0,2%
set date-year=%date:~6,4%
set time-hour=%time:~0,2%
set time-min=%time:~3,2%
set time-sec=%time:~6,2%
:: convert month into 3 letters shit
set month-num=%date:~3,2%
if %month-num%==01 set date-month=jan
if %month-num%==02 set date-month=feb
if %month-num%==03 set date-month=mar
if %month-num%==04 set date-month=apr
if %month-num%==05 set date-month=may
if %month-num%==06 set date-month=jun
if %month-num%==07 set date-month=jul
if %month-num%==08 set date-month=aug
if %month-num%==09 set date-month=sep
if %month-num%==10 set date-month=oct
if %month-num%==11 set date-month=nov
if %month-num%==12 set date-month=dec
echo.
echo /system clock set date=%date-month%/%date-day%/%date-year% time=%time-hour%:%time-min%:%time-sec% time-zone-name=Europe/Paris;
echo /system clock set date=%date-month%/%date-day%/%date-year% time=%time-hour%:%time-min%:%time-sec% time-zone-name=Europe/Paris; |clip
echo (copied in clipboard)
echo.
pause
goto loop

Voir le fichier

@ -0,0 +1,20 @@
@echo off
:: Date generator for Mikrotik
:: Generate a console command based on computer's date and time
:: Command format is for RouterOS 7.10 and later
:loop
cls
set date-day=%date:~0,2%
set date-year=%date:~6,4%
set time-hour=%time:~0,2%
set time-min=%time:~3,2%
set time-sec=%time:~6,2%
set date-month=%date:~3,2%
echo.
echo /system/clock/set date=%date-year%-%date-month%-%date-day% time=%time-hour%:%time-min%:%time-sec% time-zone-name=Europe/Paris;
echo /system/clock/set date=%date-year%-%date-month%-%date-day% time=%time-hour%:%time-min%:%time-sec% time-zone-name=Europe/Paris; |clip
echo (copied in clipboard)
echo.
pause
goto loop

46
mikrotik/musiques/axel-f.rsc Fichier normal
Voir le fichier

@ -0,0 +1,46 @@
:beep frequency=659 length=460ms;
:delay 460ms;
:beep frequency=784 length=340ms;
:delay 340ms;
:beep frequency=659 length=230ms;
:delay 230ms;
:beep frequency=659 length=110ms;
:delay 110ms;
:beep frequency=880 length=230ms;
:delay 230ms;
:beep frequency=659 length=230ms;
:delay 230ms;
:beep frequency=587 length=230ms;
:delay 230ms;
:beep frequency=659 length=460ms;
:delay 460ms;
:beep frequency=988 length=340ms;
:delay 340ms;
:beep frequency=659 length=230ms;
:delay 230ms;
:beep frequency=659 length=110ms;
:delay 110ms;
:beep frequency=1047 length=230ms;
:delay 230ms;
:beep frequency=988 length=230ms;
:delay 230ms;
:beep frequency=784 length=230ms;
:delay 230ms;
:beep frequency=659 length=230ms;
:delay 230ms;
:beep frequency=988 length=230ms;
:delay 230ms;
:beep frequency=1318 length=230ms;
:delay 230ms;
:beep frequency=659 length=110ms;
:delay 110ms;
:beep frequency=587 length=230ms;
:delay 230ms;
:beep frequency=587 length=110ms;
:delay 100ms;
:beep frequency=494 length=230ms;
:delay 230ms;
:beep frequency=740 length=230ms;
:delay 230ms;
:beep frequency=659 length=460ms;
:delay 575ms;

120
mikrotik/musiques/jurassic.rsc Fichier normal
Voir le fichier

@ -0,0 +1,120 @@
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=466 length=1775ms;
:delay 1800ms;
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=466 length=1775ms;
:delay 1800ms;
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=466 length=875ms;
:delay 900ms;
:beep frequency=523 length=275ms;
:delay 300ms;
:beep frequency=523 length=875ms;
:delay 900ms;
:beep frequency=622 length=275ms;
:delay 300ms;
:beep frequency=622 length=1775ms;
:delay 1800ms;
:beep frequency=587 length=275ms;
:delay 300ms;
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=523 length=875ms;
:delay 900ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=349 length=575ms;
:delay 600ms;
:beep frequency=587 length=275ms;
:delay 300ms;
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=523 length=1775ms;
:delay 1800ms;
:beep frequency=698 length=275ms;
:delay 300ms;
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=622 length=875ms;
:delay 900ms;
:beep frequency=587 length=275ms;
:delay 300ms;
:beep frequency=587 length=875ms;
:delay 900ms;
:beep frequency=523 length=275ms;
:delay 300ms;
:beep frequency=523 length=2075ms;
:delay 2600ms;
:delay 600ms;
#refrain
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=466 length=575ms;
:delay 600ms;
:beep frequency=349 length=575ms;
:delay 600ms;
:beep frequency=311 length=575ms;
:delay 600ms;
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=466 length=575ms;
:delay 600ms;
:beep frequency=349 length=575ms;
:delay 600ms;
:beep frequency=311 length=575ms;
:delay 600ms;
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=466 length=875ms;
:delay 900ms;
:beep frequency=349 length=575ms;
:delay 600ms;
:beep frequency=466 length=575ms;
:delay 600ms;
:beep frequency=415 length=1775ms;
:delay 1800ms;
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=466 length=575ms;
:delay 600ms;
:beep frequency=349 length=575ms;
:delay 600ms;
:beep frequency=311 length=575ms;
:delay 600ms;
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=466 length=575ms;
:delay 600ms;
:beep frequency=349 length=575ms;
:delay 600ms;
:beep frequency=311 length=575ms;
:delay 600ms;
:beep frequency=466 length=275ms;
:delay 300ms;
:beep frequency=440 length=275ms;
:delay 300ms;
:beep frequency=466 length=2175ms;
:delay 2000ms;

Voir le fichier

@ -0,0 +1,74 @@
##
### (c)Peter 'grin' Gervai, 2017
##
## CC_BY-SA-4.0 / GPLv3+
##
:local chan1 "880,2,0,1,880,2,0,4,880,2,0,4,698,2,0,1,880,2,0,4,1047,2,0,22,698,2,0,7,523,2,0,7,440,2,0,7,587,2,0,4,659,2,0,4,622,2,0,1,587,2,0,4,523,2,0,2,880,2,0,2,1047,2,0,2,1175,2,0,4,932,2,0,1,1047,2,0,4,880,2,0,4,698,2,0,1,784,2,0,1,659,2,0,7,698,2,0,7,523,2,0,7,440,2,0,7,587,2,0,4,659,2,0,4,622,2,0,1,587,2,0,4,523,2,0,2,880,2,0,2,1047,2,0,2,1175,2,0,4,932,2,0,1,1047,2,0,4,880,2,0,4,698,2,0,1,784,2,0,1,659,2,0,13,1047,2,0,1,988,2,0,1,932,2,0,1,831,2,0,4,880,2,0,4,554,2,0,1,587,2,0,1,698,2,0,4,587,2,0,1,698,2,0,1,784,2,0,7,1047,2,0,1,988,2,0,1,932,2,0,1,831,2,0,4,880,2,0,4,1397,2,0,4,1397,2,0,1,1397,2,0,16,1047,2,0,1,988,2,0,1,932,2,0,1,831,2,0,4,880,2,0,4,554,2,0,1,587,2,0,1,698,2,0,4,587,2,0,1,698,2,0,1,784,2,0,7,831,2,0,7,784,2,0,7,698,2,0,28,1047,2,0,1,988,2,0,1,932,2,0,1,831,2,0,4,880,2,0,4,554,2,0,1,587,2,0,1,698,2,0,4,587,2,0,1,698,2,0,1,784,2,0,7,1047,2,0,1,988,2,0,1,932,2,0,1,831,2,0,4,880,2,0,4,1397,2,0,4,1397,2,0,1,1397,2,0,16,1047,2,0,1,988,2,0,1,932,2,0,1,831,2,0,4,880,2,0,4,554,2,0,1,587,2,0,1,698,2,0,4,587,2,0,1,698,2,0,1,784,2,0,7,831,2,0,7,784,2,0,7,698,2,0,22,698,2,0,1,698,2,0,4,698,2,0,4,698,2,0,1,784,2,0,4,880,2,0,1,698,2,0,4,587,2,0,1,523,2,0,10,698,2,0,1,698,2,0,4,698,2,0,4,698,2,0,1,784,2,0,1,880,2,0,25,698,2,0,1,698,2,0,4,698,2,0,4,698,2,0,1,784,2,0,4,880,2,0,1,698,2,0,4,587,2,0,1,523,2,0,10,880,2,0,1,880,2,0,4,880,2,0,4,698,2,0,1,880,2,0,4,1047,2,0,22,698,2,0,7,523,2,0,7,440,2,0,7,587,2,0,4,659,2,0,4,622,2,0,1,587,2,0,4,523,2,0,2,880,2,0,2,1047,2,0,2,1175,2,0,4,932,2,0,1,1047,2,0,4,880,2,0,4,698,2,0,1,784,2,0,1,659,2,0,7,698,2,0,7,523,2,0,7,440,2,0,7,587,2,0,4,659,2,0,4,622,2,0,1,587,2,0,4,523,2,0,2,880,2,0,2,1047,2,0,2,1175,2,0,4,932,2,0,1,1047,2,0,4,880,2,0,4,698,2,0,1,784,2,0,1,659,2,0,7,880,2,0,1,698,2,0,4,523,2,0,7,554,2,0,4,587,2,0,1,932,2,0,4,932,2,0,1,587,2,0,10,659,2,0,2,1175,2,0,2,1175,2,0,2,1175,2,0,2,1047,2,0,2,932,2,0,2,880,2,0,1,698,2,0,4,587,2,0,1,523,2,0,10,880,2,0,1,698,2,0,4,523,2,0,7,554,2,0,4,587,2,0,1,932,2,0,4,932,2,0,1,587,2,0,10,659,2,0,1,932,2,0,4,932,2,0,1,932,2,0,2,880,2,0,2,784,2,0,2,698,2,0,22,880,2,0,1,698,2,0,4,523,2,0,7,554,2,0,4,587,2,0,1,932,2,0,4,932,2,0,1,587,2,0,10,659,2,0,2,1175,2,0,2,1175,2,0,2,1175,2,0,2,1047,2,0,2,932,2,0,2,880,2,0,1,698,2,0,4,587,2,0,1,523,2,0,10,880,2,0,1,698,2,0,4,523,2,0,7,554,2,0,4,587,2,0,1,932,2,0,4,932,2,0,1,587,2,0,10,659,2,0,1,932,2,0,4,932,2,0,1,932,2,0,2,880,2,0,2,784,2,0,2,698,2,0,22,698,2,0,1,698,2,0,4,698,2,0,4,698,2,0,1,784,2,0,4,880,2,0,1,698,2,0,4,587,2,0,1,523,2,0,10,698,2,0,1,698,2,0,4,698,2,0,4,698,2,0,1,784,2,0,1,880,2,0,25,698,2,0,1,698,2,0,4,698,2,0,4,698,2,0,1,784,2,0,4,880,2,0,1,698,2,0,4,587,2,0,1,523,2,0,10,880,2,0,1,880,2,0,4,880,2,0,4,698,2,0,1,880,2,0,4,1047,2,0,22,880,2,0,1,698,2,0,4,523,2,0,7,554,2,0,4,587,2,0,1,932,2,0,4,932,2,0,1,587,2,0,10,659,2,0,2,1175,2,0,2,1175,2,0,2,1175,2,0,2,1047,2,0,2,932,2,0,2,880,2,0,1,698,2,0,4,587,2,0,1,523,2,0,10,880,2,0,1,698,2,0,4,523,2,0,7,554,2,0,4,587,2,0,1,932,2,0,4,932,2,0,1,587,2,0,10,659,2,0,1,932,2,0,4,932,2,0,1,932,2,0,2,880,2,0,2,784,2,0,2,698,2,"
:local chan2 "494,2,0,1,494,2,0,4,494,2,0,4,494,2,0,1,494,2,0,4,659,2,0,10,523,2,0,10,440,2,0,7,349,2,0,7,262,2,0,7,349,2,0,4,392,2,0,4,370,2,0,1,349,2,0,4,349,2,0,2,523,2,0,2,659,2,0,2,698,2,0,4,587,2,0,1,659,2,0,4,587,2,0,4,440,2,0,1,466,2,0,1,392,2,0,7,440,2,0,7,349,2,0,7,262,2,0,7,349,2,0,4,392,2,0,4,370,2,0,1,349,2,0,4,349,2,0,2,523,2,0,2,659,2,0,2,698,2,0,4,587,2,0,1,659,2,0,4,587,2,0,4,440,2,0,1,466,2,0,1,392,2,0,13,880,2,0,1,831,2,0,1,784,2,0,1,659,2,0,4,698,2,0,4,440,2,0,1,466,2,0,1,523,2,0,4,349,2,0,1,440,2,0,1,466,2,0,7,880,2,0,1,831,2,0,1,784,2,0,1,659,2,0,4,698,2,0,4,932,2,0,4,932,2,0,1,932,2,0,16,880,2,0,1,831,2,0,1,784,2,0,1,659,2,0,4,698,2,0,4,440,2,0,1,466,2,0,1,523,2,0,4,349,2,0,1,440,2,0,1,466,2,0,7,554,2,0,7,466,2,0,7,440,2,0,28,880,2,0,1,831,2,0,1,784,2,0,1,659,2,0,4,698,2,0,4,440,2,0,1,466,2,0,1,523,2,0,4,349,2,0,1,440,2,0,1,466,2,0,7,880,2,0,1,831,2,0,1,784,2,0,1,659,2,0,4,698,2,0,4,932,2,0,4,932,2,0,1,932,2,0,16,880,2,0,1,831,2,0,1,784,2,0,1,659,2,0,4,698,2,0,4,440,2,0,1,466,2,0,1,523,2,0,4,349,2,0,1,440,2,0,1,466,2,0,7,554,2,0,7,466,2,0,7,440,2,0,22,554,2,0,1,554,2,0,4,554,2,0,4,554,2,0,1,622,2,0,4,523,2,0,1,440,2,0,4,440,2,0,1,349,2,0,10,554,2,0,1,554,2,0,4,554,2,0,4,554,2,0,1,622,2,0,1,523,2,0,25,554,2,0,1,554,2,0,4,554,2,0,4,554,2,0,1,622,2,0,4,523,2,0,1,440,2,0,4,440,2,0,1,349,2,0,10,494,2,0,1,494,2,0,4,494,2,0,4,494,2,0,1,494,2,0,4,659,2,0,10,523,2,0,10,440,2,0,7,349,2,0,7,262,2,0,7,349,2,0,4,392,2,0,4,370,2,0,1,349,2,0,4,349,2,0,2,523,2,0,2,659,2,0,2,698,2,0,4,587,2,0,1,659,2,0,4,587,2,0,4,440,2,0,1,466,2,0,1,392,2,0,7,440,2,0,7,349,2,0,7,262,2,0,7,349,2,0,4,392,2,0,4,370,2,0,1,349,2,0,4,349,2,0,2,523,2,0,2,659,2,0,2,698,2,0,4,587,2,0,1,659,2,0,4,587,2,0,4,440,2,0,1,466,2,0,1,392,2,0,7,698,2,0,1,587,2,0,4,440,2,0,7,440,2,0,4,466,2,0,1,698,2,0,4,698,2,0,1,466,2,0,10,523,2,0,2,932,2,0,2,932,2,0,2,932,2,0,2,880,2,0,2,784,2,0,2,698,2,0,1,587,2,0,4,466,2,0,1,440,2,0,10,698,2,0,1,587,2,0,4,440,2,0,7,440,2,0,4,466,2,0,1,698,2,0,4,698,2,0,1,466,2,0,10,523,2,0,1,784,2,0,4,784,2,0,1,784,2,0,2,698,2,0,2,659,2,0,2,523,2,0,1,440,2,0,4,440,2,0,1,349,2,0,10,698,2,0,1,587,2,0,4,440,2,0,7,440,2,0,4,466,2,0,1,698,2,0,4,698,2,0,1,466,2,0,10,523,2,0,2,932,2,0,2,932,2,0,2,932,2,0,2,880,2,0,2,784,2,0,2,698,2,0,1,587,2,0,4,466,2,0,1,440,2,0,10,698,2,0,1,587,2,0,4,440,2,0,7,440,2,0,4,466,2,0,1,698,2,0,4,698,2,0,1,466,2,0,10,523,2,0,1,784,2,0,4,784,2,0,1,784,2,0,2,698,2,0,2,659,2,0,2,523,2,0,1,440,2,0,4,440,2,0,1,349,2,0,10,554,2,0,1,554,2,0,4,554,2,0,4,554,2,0,1,622,2,0,4,523,2,0,1,440,2,0,4,440,2,0,1,349,2,0,10,554,2,0,1,554,2,0,4,554,2,0,4,554,2,0,1,622,2,0,1,523,2,0,25,554,2,0,1,554,2,0,4,554,2,0,4,554,2,0,1,622,2,0,4,523,2,0,1,440,2,0,4,440,2,0,1,349,2,0,10,494,2,0,1,494,2,0,4,494,2,0,4,494,2,0,1,494,2,0,4,659,2,0,10,523,2,0,10,698,2,0,1,587,2,0,4,440,2,0,7,440,2,0,4,466,2,0,1,698,2,0,4,698,2,0,1,466,2,0,10,523,2,0,2,932,2,0,2,932,2,0,2,932,2,0,2,880,2,0,2,784,2,0,2,698,2,0,1,587,2,0,4,466,2,0,1,440,2,0,10,698,2,0,1,587,2,0,4,440,2,0,7,440,2,0,4,466,2,0,1,698,2,0,4,698,2,0,1,466,2,0,10,523,2,0,1,784,2,0,4,784,2,0,1,784,2,0,2,698,2,0,2,659,2,0,2,523,2,0,1,440,2,0,4,440,2,0,1,349,2,"
:local chan3 "196,2,0,1,196,2,0,4,196,2,0,4,196,2,0,1,196,2,0,4,523,2,0,10,262,2,0,10,262,2,0,7,220,2,0,7,175,2,0,7,233,2,0,4,262,2,0,4,247,2,0,1,233,2,0,4,220,2,0,2,349,2,0,2,440,2,0,2,466,2,0,4,392,2,0,1,440,2,0,4,349,2,0,4,294,2,0,1,330,2,0,1,262,2,0,7,262,2,0,7,220,2,0,7,175,2,0,7,233,2,0,4,262,2,0,4,247,2,0,1,233,2,0,4,220,2,0,2,349,2,0,2,440,2,0,2,466,2,0,4,392,2,0,1,440,2,0,4,349,2,0,4,294,2,0,1,330,2,0,1,262,2,0,7,175,2,0,7,262,2,0,7,349,2,0,4,233,2,0,7,349,2,0,1,349,2,0,4,233,2,0,4,175,2,0,7,220,2,0,7,262,2,0,1,349,2,0,4,1047,2,0,4,1047,2,0,1,1047,2,0,4,262,2,0,4,175,2,0,7,262,2,0,7,349,2,0,4,233,2,0,7,349,2,0,1,349,2,0,4,233,2,0,4,175,2,0,4,277,2,0,7,311,2,0,7,349,2,0,7,262,2,0,1,262,2,0,4,175,2,0,4,175,2,0,7,262,2,0,7,349,2,0,4,233,2,0,7,349,2,0,1,349,2,0,4,233,2,0,4,175,2,0,7,220,2,0,7,262,2,0,1,349,2,0,4,1047,2,0,4,1047,2,0,1,1047,2,0,4,262,2,0,4,175,2,0,7,262,2,0,7,349,2,0,4,233,2,0,7,349,2,0,1,349,2,0,4,233,2,0,4,175,2,0,4,277,2,0,7,311,2,0,7,349,2,0,7,262,2,0,1,262,2,0,4,175,2,0,4,139,2,0,7,208,2,0,7,277,2,0,4,262,2,0,7,175,2,0,7,131,2,0,4,139,2,0,7,208,2,0,7,277,2,0,4,262,2,0,7,175,2,0,7,131,2,0,4,139,2,0,7,208,2,0,7,277,2,0,4,262,2,0,7,175,2,0,7,131,2,0,4,196,2,0,1,196,2,0,4,196,2,0,4,196,2,0,1,196,2,0,4,523,2,0,10,262,2,0,10,262,2,0,7,220,2,0,7,175,2,0,7,233,2,0,4,262,2,0,4,247,2,0,1,233,2,0,4,220,2,0,2,349,2,0,2,440,2,0,2,466,2,0,4,392,2,0,1,440,2,0,4,349,2,0,4,294,2,0,1,330,2,0,1,262,2,0,7,262,2,0,7,220,2,0,7,175,2,0,7,233,2,0,4,262,2,0,4,247,2,0,1,233,2,0,4,220,2,0,2,349,2,0,2,440,2,0,2,466,2,0,4,392,2,0,1,440,2,0,4,349,2,0,4,294,2,0,1,330,2,0,1,262,2,0,7,175,2,0,7,247,2,0,1,262,2,0,4,349,2,0,4,233,2,0,4,233,2,0,4,349,2,0,1,349,2,0,1,233,2,0,4,196,2,0,7,233,2,0,1,262,2,0,4,330,2,0,4,262,2,0,4,262,2,0,4,349,2,0,1,349,2,0,1,262,2,0,4,175,2,0,7,247,2,0,1,262,2,0,4,349,2,0,4,233,2,0,4,233,2,0,4,349,2,0,1,349,2,0,1,233,2,0,4,262,2,0,1,262,2,0,4,262,2,0,1,262,2,0,2,294,2,0,2,330,2,0,2,349,2,0,4,262,2,0,4,175,2,0,10,175,2,0,7,247,2,0,1,262,2,0,4,349,2,0,4,233,2,0,4,233,2,0,4,349,2,0,1,349,2,0,1,233,2,0,4,196,2,0,7,233,2,0,1,262,2,0,4,330,2,0,4,262,2,0,4,262,2,0,4,349,2,0,1,349,2,0,1,262,2,0,4,175,2,0,7,247,2,0,1,262,2,0,4,349,2,0,4,233,2,0,4,233,2,0,4,349,2,0,1,349,2,0,1,233,2,0,4,262,2,0,1,262,2,0,4,262,2,0,1,262,2,0,2,294,2,0,2,330,2,0,2,349,2,0,4,262,2,0,4,175,2,0,10,139,2,0,7,208,2,0,7,277,2,0,4,262,2,0,7,175,2,0,7,131,2,0,4,139,2,0,7,208,2,0,7,277,2,0,4,262,2,0,7,175,2,0,7,131,2,0,4,139,2,0,7,208,2,0,7,277,2,0,4,262,2,0,7,175,2,0,7,131,2,0,4,196,2,0,1,196,2,0,4,196,2,0,4,196,2,0,1,196,2,0,4,523,2,0,10,262,2,0,10,175,2,0,7,247,2,0,1,262,2,0,4,349,2,0,4,233,2,0,4,233,2,0,4,349,2,0,1,349,2,0,1,233,2,0,4,196,2,0,7,233,2,0,1,262,2,0,4,330,2,0,4,262,2,0,4,262,2,0,4,349,2,0,1,349,2,0,1,262,2,0,4,175,2,0,7,247,2,0,1,262,2,0,4,349,2,0,4,233,2,0,4,233,2,0,4,349,2,0,1,349,2,0,1,233,2,0,4,262,2,0,1,262,2,0,4,262,2,0,1,262,2,0,2,294,2,0,2,330,2,0,2,349,2,0,4,262,2,0,4,175,2,"
# slot timespan (~20ms)
:local st 20
# speed (~500ms)
:local spd ( $st * 2 )
:local slotlen ($spd / $st / 3)
:local slottime ($st . "ms")
:local c1 [:toarray $chan1]
:local c2 [:toarray $chan2]
:local c3 [:toarray $chan3]
:local chan ({$c1},{$c2})
:set $chan [:put ($chan, {$c3})]
:local voice {0;0;0}
# slot left for a tune to go
:local sleft
:set $sleft {0;0;0}
# position in a channel
:local cpointer
# this should fucking zero it, why doesn't it
:set $cpointer {0;0;0}
# force it down into its throat
:for i from=0 to=2 do={
:set ($cpointer->$i) 0
:set ($sleft->$i) 0
:put ("Cpointer $i = " . ($cpointer->$i))
}
:local running 1
:do {
# prepare actual voice for every channel
:for c from=0 to=2 do={
:if ( ($sleft->$c) > 1 ) do={
# same voice
:set ($sleft->$c) (($sleft->$c) - 1)
#:put ( "keep c=$c s=" . ($sleft->$c))
} else={
# new voice
#:put (">> c=$c p=" . ($cpointer->$c) ." v=" . ($chan->$c->($cpointer->$c)))
:set ($voice->$c) ($chan->$c->($cpointer->$c))
:set ($cpointer->$c) (($cpointer->$c)+1)
#:put (">> c=$c p=" . ($cpointer->$c) ." s=" . ($chan->$c->($cpointer->$c)))
:set ($sleft->$c) ($chan->$c->($cpointer->$c))
:set ($cpointer->$c) (($cpointer->$c)+1)
:if ( $cpointer->$c > [:len ($chan->$c)] ) do={
:set $running 0
}
}
}
:for i from=0 to=$slotlen do={
:for c from=0 to=2 do={
:if ( ($voice->$c) > 0 ) do={
:beep length=$slottime frequency=($voice->$c)
}
:delay $slottime
}
}
#:set $running 0
} while=( $running = 1)

14
mikrotik/musiques/mario.rsc Fichier normal
Voir le fichier

@ -0,0 +1,14 @@
:beep frequency=660 length=100ms;
:delay 150ms;
:beep frequency=660 length=100ms;
:delay 300ms;
:beep frequency=660 length=100ms;
:delay 300ms;
:beep frequency=510 length=100ms;
:delay 100ms;
:beep frequency=660 length=100ms;
:delay 300ms;
:beep frequency=770 length=100ms;
:delay 550ms;
:beep frequency=380 length=100ms;
:delay 575ms;

98
mikrotik/musiques/nowel.rsc Fichier normal
Voir le fichier

@ -0,0 +1,98 @@
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=659 length=300ms
:delay 600ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=659 length=300ms
:delay 600ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=783 length=150ms
:delay 300ms;
:beep frequency=523 length=150ms
:delay 300ms;
:beep frequency=587 length=150ms
:delay 300ms;
:beep frequency=659 length=300ms
:delay 750ms;
:beep frequency=698 length=150ms
:delay 300ms;
:beep frequency=698 length=150ms
:delay 300ms;
:beep frequency=698 length=300ms
:delay 450ms;
:beep frequency=698 length=225ms
:delay 150ms;
:beep frequency=698 length=150ms
:delay 300ms;
:beep frequency=659 length=225ms
:delay 300ms;
:beep frequency=659 length=300ms
:delay 525ms;
:beep frequency=659 length=225ms
:delay 125ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=587 length=150ms
:delay 300ms;
:beep frequency=587 length=150ms
:delay 300ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=587 length=750ms
:delay 675ms;
:beep frequency=783 length=525ms
:delay 750ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=659 length=300ms
:delay 600ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=659 length=300ms
:delay 600ms;
:beep frequency=659 length=150ms
:delay 300ms;
:beep frequency=783 length=150ms
:delay 300ms;
:beep frequency=523 length=150ms
:delay 300ms;
:beep frequency=587 length=150ms
:delay 300ms;
:beep frequency=659 length=300ms
:delay 750ms;
:beep frequency=698 length=150ms
:delay 300ms;
:beep frequency=698 length=150ms
:delay 300ms;
:beep frequency=698 length=300ms
:delay 450ms;
:beep frequency=698 length=225ms
:delay 150ms;
:beep frequency=698 length=150ms
:delay 300ms;
:beep frequency=659 length=225ms
:delay 300ms;
:beep frequency=659 length=300ms
:delay 525ms;
:beep frequency=659 length=150ms
:delay 125ms;
:beep frequency=783 length=150ms
:delay 300ms;
:beep frequency=783 length=150ms
:delay 300ms;
:beep frequency=698 length=150ms
:delay 300ms;
:beep frequency=587 length=150ms
:delay 300ms;
:beep frequency=523 length=375ms
:delay 300ms;

37
mikrotik/musiques/vador.rsc Fichier normal
Voir le fichier

@ -0,0 +1,37 @@
:beep frequency=500 length=500ms;
:delay 500ms;
:beep frequency=500 length=500ms;
:delay 500ms;
:beep frequency=500 length=500ms;
:delay 500ms;
:beep frequency=400 length=500ms;
:delay 400ms;
:beep frequency=600 length=200ms;
:delay 100ms;
:beep frequency=500 length=500ms;
:delay 500ms;
:beep frequency=400 length=500ms;
:delay 400ms;
:beep frequency=600 length=200ms;
:delay 100ms;
:beep frequency=500 length=500ms;
:delay 1000ms;
:beep frequency=750 length=500ms;
:delay 500ms;
:beep frequency=750 length=500ms;
:delay 500ms;
:beep frequency=750 length=500ms;
:delay 500ms;
:beep frequency=810 length=500ms;
:delay 400ms;
:beep frequency=600 length=200ms;
:delay 100ms;
:beep frequency=470 length=500ms;
:delay 500ms;
:beep frequency=400 length=500ms;
:delay 400ms;
:beep frequency=600 length=200ms;
:delay 100ms;
:beep frequency=500 length=500ms;
:delay 1000ms;