Implement M10 M11 to toggle anther 2 output pins

From the original Synthetos forum (2011–2025)

Started by dandumit on in TinyG Support. 1 reply, last activity Jan 3, 2016.

#

HEllo All,
I have assembled a custom made board implementing TinyG. I intend to drive pick and place machine with it. Since I have pneumatic z axis I need to toggle another 2 pins.

I would like to implement M10 M11 M12 and M13 to toggle 2 new pins.
I was thinking to use pins PB4 PB5 but looking on source code it looks pretty complicated to toggle pins :
gpio_set_bit_on(FLOOD_COOLANT_BIT);
if (b & 0x08) { hw.out_port[0]->OUTSET = GPIO1_OUT_BIT_bm; }
this struct implementation and binding it's not clear for me.
I need some help to drive port PB - pins PB4 PB5.

Could someone give me a hint how to implement it ?

Would be easier to implement using pins PA3 and PA4 ?

Any help , example it's greatly appreciated !

Kind regards,
Daniel

This topic is from the original forum (January 2016). Your reply starts a new discussion linked to it.

Reply

Different problem? Ask a new question

Back to TinyG Support or latest activity.