Android XML Question

I am a second-year computer science student helping a professor in another department develop a custom app for a research project. My task right now is to write code to flash an image on a screen, accompanied by an audible sound, at timed intervals.

I’ve had no experience with Android app development before this. Based on what I know, I think I can add PNG files to the res/drawable folder and incorporate them in an XML layout that I can then reference in the timer code.

Here is my question: Can I have a black background, and then flash, say, a yellow star using PNGs bundled in XML code and cast as a layout? I don’t know the terminology. Would this best be done in a view? If a layout is better, what sort of layout? Linear?

Thank you,