PWM on mountaineer eth

Hello to all,
the beginner, I have to generate a square wave of frequency 36k to test a component. I can not find the code that can help me.
I started from here

PWM m1pwm = new PWM (Socket4.Pwm7, 36000, 50, true);

but it remains high and not swing
thanks
En.

Welcome to the forum!

Check this documentation:

http://www.ghielectronics.com/docs/18/pwm

Did you call m1pwm.Start()?

Cuno

Thank you all,
was wrong in giving her a dutycyle of 50 I had to give 0.5
Thanks to Architect and Cuno very helpful post!!
thanks

Glad to help!