Need PID coding for emg sensor used in arm

i am making emg based prosthetic leg.for that i need pid based emg sensor coding. kindly give me if any body have.
Thank you