gundami

Untitled

Nov 6th, 2025 (edited)
30
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.96 KB | None | 0 0
  1. -- master.lua
  2. -- Broadcast a long test paragraph to all terminals for TTS playback
  3.  
  4. local modemSide = "back" -- change this to the side your wireless modem is on
  5. rednet.open(modemSide)
  6.  
  7. -- The long test paragraph to broadcast (can be edited)
  8. local testParagraph = [[
  9. Good afternoon, everyone. This is a system test of the text-to-speech broadcast network. In a few moments, you will hear a series of sentences designed to evaluate clarity, pronunciation, and synchronization across all connected speakers.
  10. ]]
  11.  
  12. -- Optional: number of times to broadcast (1 = once)
  13. local repeatCount = 1
  14.  
  15. -- Optional: seconds to wait between repeats
  16. local repeatDelay = 2
  17.  
  18. for i = 1, repeatCount do
  19. print(string.format("Broadcasting TTS message (%d/%d)...", i, repeatCount))
  20. rednet.broadcast({ type = "tts", text = testParagraph })
  21. print("Broadcast sent.")
  22. if i < repeatCount then
  23. sleep(repeatDelay)
  24. end
  25. end
  26.  
  27. print("All broadcasts completed.")
  28.  
Advertisement
Add Comment
Please, Sign In to add comment