It's quite possible to make such a thing during the Hellenistic era. I'm indeed at once reminded of heron, just as
@piratedude wrote. But keep in mind: you're ultimately still talking about a "party trick machine", or - to be a bit more kind - a "proof of concept" that cannot be cost-effectively used for anything practical at the time. (Same as goes in OTL for Heron's 'steam engine'.)
The greatest possible benefit of this is that the invention of this impressive thing becomes a
cause célèbre, and thus lead to greater interest in the science behind it all. As I have often observed: one of the note-worthy things about the late Hellenistic era is that certain purely scientific understanding was lost, apparently because it didn't interest the Romans as much. The Romans advanced practical (e.g. engineering) know-how, but we can tell from Roman commentaries relating to ealier greek math texts that the Roman commentators literally failed to grasp the full mathematical principles involved.
If an impressive invention like this provides a reason to be interested in theoretical science - because it proves that such science can yield technological feats - then perhaps this helps motivate some key Roman thinkers to have more regard for the purely theoretical. I'm not saying "ow, wow, this mean we get a scientific revolution"... but it might lay the seeds for such a thing, a few centuries down the line. One little discovery leads to another, and so on and so forth. It's not a given, but it's not any kind of ASB, either.