Something like this has been done before.
https://en.wikipedia.org/wiki/Sega_v._Accolade
> As a result of the piracy and unlicensed development issues, Sega incorporated a technical protection mechanism into a new edition of the Genesis released in 1990, referred to as the Genesis III. This new variation of the Genesis included code known as the Trademark Security System (TMSS), which, when a game cartridge was inserted into the console, would check for the presence of the string "SEGA" at a particular point in the memory contained in the cartridge. If and only if the string was present, the console would run the game, and would briefly display the message: "PRODUCED BY OR UNDER LICENSE FROM SEGA ENTERPRISES LTD." This system had a twofold effect: it added extra protection against unlicensed developers and software piracy, and it forced the Sega trademark to display when the game was powered up, making a lawsuit for trademark infringement possible if unlicensed software were to be developed.
[...]
> The Ninth Circuit reversed the district court's order and ruled that Accolade's use of reverse engineering to publish Genesis titles was protected under fair use, and that its alleged violation of Sega trademarks was the fault of Sega. The case is frequently cited in matters involving reverse engineering and fair use under copyright law.