It should be pretty easy to figure out to which regiment this Confederate officer belonged. One would need to know where the 1st NY Battery was located on the field, during Pickett's charge. Then one would need to know which Confederate regiment was attacking that position.
Here is where Cowan's 1st NY Battery was located:
"Woodruff's battery was in front of Ziegler's grove; on his left, in succession, Arnold's Rhode Island, Cushing's United States, Brown's Rhode Island, and Rorty’s New York. [...] Daniels's battery of horse artillery, four guns, was at the angle. Cowan's 1st New York battery, six rifles, was placed on the left of Rorty's soon after the cannonade commenced."
Not being a student of Gettysburg, I don't know exactly where this is, but it is obvious that the 1st NY Battery was to the left of Ziegler's Grove, at the far end of the line of batterys. Someone that is a student of Gettysburg, and in particular Pickett's charge, would most likely be able pinpoint this on a battlefield map and to say what Confederate unit/s attacked that position.