0-5V Ramp Output

I do not think you are using pulseIn() correctly. The pulseIn() function is used to measure how long between when the pin goes LOW and when it goes HIGH again, or between when it goes HIGH and when it goes LOW again.

It is not meant to measure any kind of elapsed time. The millis() function is for that.

What do you have connected to pins 12 and 13?

The comments indicate that ch1 is supposed to be some measure of RSSI. Timing how long a pulse is won't tell you that.