ok so firstly, I'm assuming you typed this out as opposed to using pastebin or copying the contents of the file from disk, as this wouldn't even compile, you're missing a closing " on line 2.
However assuming that you're not missing this… So the error "too long without yielding" occurs for the reason that if neither of your conditions are true, your computer runs without taking a break to let others to run. With the current implementation of ComputerCraft only one computer is running at a given time meaning that a computer must give up (a.k.a. yield) its processor time to allow others to run, failure to do so will result in the programs termination.
The solution that I suggest however instead of using sleeps is to tell the computer to wait for a change in redstone (MFR included) like so
local s = peripheral.wrap("back") --# localise all your variables
print("Started successfully")
while true do
local input = rs.getBundledInput("bottom") --# rs is the same as redstone, just shorthand
local redalert = colors.test(input, colors.red)
local intruder = colors.test(input, colors.blue)
if redalert then --# we don't need == true, redalert is already a boolean, why should we do true == true or false == true, we already know the answer
print("Red alert")
s.speak("Red alert")
end
if intruder then --# same goes here
print("intruder alert")
s.speak("intruder alert")
end
os.pullEvent("redstone") --# wait here until something with the redstone changes
end
Now if there are any other errors that are not "too long without yielding" just tell us the precise error message as they help us tell you exactly why they are happening.
EDIT: Aaaannnd ninja'd by a post that didn't show up when I refreshed, only when I posted….. :/