Here are some examples:
* "He shook his head weakly." (modifies the verb "shook")
* "The light was shining weakly through the fog." (modifies the adjective "shining")
* "She smiled weakly at him." (modifies the verb "smiled")
However, it's important to note that "weakly" can also be an adjective, meaning "lacking strength" or "not strong". For example: "The patient was feeling weakly."
So, the part of speech of "weakly" depends on its context within a sentence.