Knuckles made his first appearance in 1994 in Sonic the Hedgehog 3 for Sega Genesis, but wasn't a playable character until its sequel, Sonic & Knuckles, was released later that year. Sonic & Knuckles used special lock-on technology that allowed players to play as Knuckles in the previous three Sonic games, Sonic the Hedgehog, Sonic the Hedgehog 2, and Sonic the Hedgehog 3. Those games can be found on multiple systems today – PS2 and Gamecube, and DS in Sonic collections.
The original four Sonic games feature basic platformer gameplay. You basically have to move your character through the level, defeating enemies and avoiding traps until you reach the goal at the end. At the end of each zone, you fight Robotnik in one of his many robotic creations.
Knuckles' largest appearance was in Knuckles' Chaotix, a rather obscure game that released in 1995 for the Sega 32X. I unfortunately never got my hands on a copy of this game, so I haven't played it. From what I've read, though, Knuckles and his friends are guarding an island called Carnival Island. Robotnik goes to the island to steal a powerful emerald that is powering the island. He ends up freezing Knuckles' friends in time, and Knuckles has to recue his friends and save the island. Sounds like a typical Sonic game to me. I love the fact that an emerald was involved. Knuckles just can't get away from the Master Emerald in canon.
Knuckles' story got deep in the Sonic Adventure games released for Dreamcast in 1998 and 2001, and later released for Gamecube. In the first one, Robotnik tried to steal the Master Emerald from the Floating Island where Knuckles was guarding it. Knuckles smashed the emerald in many pieces to prevent Robotnik from stealing it. He has to search for the pieces of the broken emerald, and gets mixed up in Sonic's story, where he has to help defeat Chaos, Robotnik's newest weapon. The sequel is pretty similar. A "treaure hunter" named Rouge, tries to steal the Emerald from Knuckles, and it ends up broken into many pieces again, causing Knuckles to search for them a second time.
Those two games were the first time I got to really see Knuckles' story from his point of view, and I loved it. I got to see his fate, and his reason for fighting. I loved that Sega finally gave Knuckles depth. It's where I truly began to appreciate him.
Knuckles' gameplay for those games is pretty simple. Knuckles has to look for shattered pieces of the Master Emerald. It is unique and fun gameplay, and is a welcome distraction from the typical platformy gameplay we have to experience in Sonic's parts. At points, Knuckles has boss battles just like Sonic, and you get to use abilities unique to him, like gliding and punching.
Sonic Heroes loosely follows the Sonic Adventure storyline, but was meant to be more of a stand-alone game. Knuckles' role isn't super prominent, and nothing is really added to his story. He is part of Team Sonic with Sonic and Tails, and is the Power Character for that trio. They basically band together to fight Robotnik again, who supposedly left a message stating he will take over the world in three days. Oh look, Sonic, Tails, and Knuckles are saving the day again.
Knuckles has made small appearances in games since Sonic Heroes, but he's mostly a side character, if that, and none of them affect his story or character traits. I'm awaiting the next big Knuckles-centric game. Maybe another Sonic Adventure? Come on, Sega. :D