Oyster shell will serve some of the purpose of grit, but its value in that role is limited.
The biggest difference is solubility. Oyster shell will have some sharp edges in it fresh-crushed out of the bag. But it is soluble and digestable (that's how it's calcium nourishes the bird). As it is dissolved and digested, the edges useful for grinding food in the gizzard dull and round off, and become useless as a grit to grind up large or fibrous chunks. Remember, this stuff was produced by a living creature.
Grit, on the other hand . . . is stone. Typically granite or another volcanic rock, as opposed to limestone (which is nothing but the compressed shells of ancient critters other than oysters, again, the shells of a once-living creature, little different from oyster shell) so not at all soluble and difficult to digest. It doesn't dissolve. If anything, it erodes in the gizzard from use, and passes through as something smooth that doesn't get digested much, if at all on its final trip out of the chicken.
Your birds know the difference and will find the balance from the two. Oyster shells are good to have out for them for when their individual needs for calcium may not be met by the content of their processed feed. Grit, whether from ranging, from a feeder, or off the dirt floor of the coop, is something all of them need.