M66 waiting for an input RISE or FALL not working?

If you have a question about the software please ask it here.

M66 waiting for an input RISE or FALL not working?

Postby Miaho » Tue Jul 07, 2020 3:38 pm

Hi,

I trying to get the M66 gcode to wait for a RISE or FALL input signal on PIN 2 PORT 1 of the UC300ETH-5LPT board.

I'm triggering the input using an digital IO pin on the Arduino by setting it HIGH, delay for a second, and setting it LOW again.

In UCCNC diagnostics I can confirm the Port #1 I2 goes from black, to green, to black again in sync with the Arduino output.

The G-code I'm using to wait for the input is:

G0 X10
M66 P2 E1 L1 (or L2)
G0 X0

The G-Code cycle does stop at the M66 line, but doesn't seem to recognize the input trigger, and therefore never moves to the next line.

Any ideas, what am I missing?

Thanks,
Miaho
Miaho
 
Posts: 7
Joined: Tue Jul 07, 2020 3:17 pm

Re: M66 waiting for an input RISE or FALL not working?

Postby ger21 » Tue Jul 07, 2020 7:29 pm

Try adding a Q value.
Gerry
UCCNC 2022 Screenset - http://www.thecncwoodworker.com/2022.html
ger21
 
Posts: 2714
Joined: Sat Sep 03, 2016 2:17 am

Re: M66 waiting for an input RISE or FALL not working?

Postby Miaho » Tue Jul 07, 2020 8:36 pm

Thanks, but still no joy. Still ignoring the input signal, only waits for Q seconds and then moves onto the next line of g-code, which wouldn't be ideal.
Miaho
 
Posts: 7
Joined: Tue Jul 07, 2020 3:17 pm

Re: M66 waiting for an input RISE or FALL not working?

Postby Miaho » Tue Jul 07, 2020 9:02 pm

Got it working...

In the UCCNC_usersmanual.pdf it states the following...

P specifies the digital input pin number
E specifies the digital input port number

But using P as the PORT number and E as the PIN number works :D
Miaho
 
Posts: 7
Joined: Tue Jul 07, 2020 3:17 pm


Return to Ask a question from support here

Who is online

Users browsing this forum: Google [Bot] and 34 guests