Ifan04 install question

Hopefully this topic is in the right area. I just installed the ifan04 flashed with phone into a brand new fan. Everything works great. The fan housing where you would typically hide the receiver is too small. I had to double sided tape the receiver to the ceiling next to the fan. It doesn’t look terrible but I’d rather have it completely hidden. Does anyone know if it’s a no no to hide it in the ceiling rafters? I know it may impact the signal bit. Just wondering if that would against code to put it up there?

I had to put one of mine up there. No idea about code though. It does have weaker reception but seems to work just fine regardless.

Thank you for the reply. I am going to be working on placing mine in the ceiling also