I have know idea what filter FIR1 is.
It is up to you to find and understand its algorithm and then try to implement it using C++ code.
And no one will do this work for you. Where to search for I already showed you.
If you then will have some problems with C++ - ask in this Forum.