diff --git a/public/cuelist.json b/public/cuelist.json index 061f2c2..6b06c1a 100644 --- a/public/cuelist.json +++ b/public/cuelist.json @@ -13,7 +13,7 @@ "name": "Q2", "type": "announce", "description": "announce", - "audioCue": "Q2" + "audioCue": "Q1" }, { "id": 3, @@ -40,7 +40,7 @@ "name": "Q5", "type": "bg", "description": "(END)", - "audioCue": "Q6", + "audioCue": "Q4", "status":"end", "lightCue":"fade_in_light", "clientCue":"Q6" diff --git a/src-tauri/src/lib.rs b/src-tauri/src/lib.rs index 55cff7d..3cde69d 100644 --- a/src-tauri/src/lib.rs +++ b/src-tauri/src/lib.rs @@ -46,7 +46,7 @@ async fn send_osc_message( target: &str, ) -> Result<(), String> { // print - println!("Sending OSC message: {}", message); + println!("Sending OSC message:{} {} {}", target, key,message); let sock = UdpSocket::bind(host).await.unwrap(); let remote = SocketAddrV4::from_str(target).unwrap(); @@ -74,10 +74,10 @@ async fn setup_osc_server(app_handle: AppHandle) { loop { match sock.recv_from(&mut buf).await { Ok((size, addr)) => { - println!("Received packet with size {} from: {}", size, addr); + //println!("Received packet with size {} from: {}", size, addr); if let Ok((_, packet)) = rosc::decoder::decode_udp(&buf[..size]) { if let OscPacket::Message(msg) = packet { - println!("OSC message: {:?}", msg); + //println!("OSC message: {:?}", msg); app_handle .emit( diff --git a/src/App.jsx b/src/App.jsx index 6b79d43..9103781 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -8,7 +8,7 @@ import { Light } from "./utils/light"; const DefaultFadeDuration = 3; // 1 second -const CLIENT_COUNT=12; +const CLIENT_COUNT=13; const CueType={ Bg: 'bg', @@ -42,7 +42,7 @@ function App() { key: addr, message: `${id}#${message}`, host:'0.0.0.0:0', - target:'192.168.234.255:8000', + target:'192.168.51.255:8000', }); } @@ -54,7 +54,7 @@ function App() { key: addr, message, host:'0.0.0.0:0', - target:'192.168.234.255:58100', + target:'192.168.51.100:58200', }); } @@ -63,6 +63,7 @@ function App() { const addr= message.addr; const [id, status, name]= message.args[0]?.split('#'); + // console.log('receive osc:', id, status,name); switch(addr){ case OSC_ADDRESS.CLIENT_STATUS: @@ -292,7 +293,7 @@ function App() {
{Array.from(Array(CLIENT_COUNT).keys()).map((i) => { - const id=i+1; + const id=(i+1).toString().padStart(2,'0'); const log = clientStatus[id.toString()]; return (