He has the right to petition, he does not have the right or obligation to attend.
The petitioner is represented by council. Trump would say or do nothing but watch.
He is however obligated to be in court for his felony trial.
When one's liberty is at stake they certainly have the right to attend.
>> The petitioner is represented by council
Pray tell WHAT council represents Petitioner Trump, Oh Learned One?
The Student Council?
The local Boy Scout Council?
Or perchance did you mean “counsel”, you who are so wise in the ways of... well, apparently everything? Except maybe spelling and grammar?