You can take it throughout pregnancy, however the main risk of issues regarding aspirin is during the third trimester when labour might occur because it can increase bleeding.
I personally will be taking it for the duration of the first trimester (when most miscarriages occur) and discuss with my doctor about staying on it during the second trimeter, but i will definately have stopped before the third trimester because even if the worst happens and complications arise - the baby should have a good chance of survival.
It would be a sensible idea to mention it to your midwife asap though.