Mesa - Can unused step & direction outputs be used as o/p's for other purposes?

More
20 Nov 2025 17:29 #338811 by slowpoke
If yes, where do I find them in HALSHOW?

I'm making a little interface board and have some leftover space, so I could gain a few extra o/p points if I can take advantage of these, perhaps drive a few SSR's.

Mesa 7i96s

Please Log in or Create an account to join the conversation.

  • tommylight
  • tommylight's Avatar
  • Away
  • Moderator
  • Moderator
More
20 Nov 2025 17:40 #338814 by tommylight
All Mesa cards have the ability to use every pin as I/O if not used for special purposes, like stepgen or PWM or encoder, so you can use the step/dir of stepgen 4 (5'th stepgen) by loading just 4 stepgens.
No idea about the pinout though, been a long time, but manual should have everything explained.

Please Log in or Create an account to join the conversation.

More
20 Nov 2025 17:50 - 20 Nov 2025 17:53 #338816 by PCW
Yes, special function pins revert to GPIO if the special function is disabled in HAL

For example on a 7I96S, if you only need 4 step/dir pairs you set num_stepgens=4 in the hal file
and then the GPIO pins that would have been STEP4 and DIR4  become GPIO 25 and 26

To use these GPIO pins as outputs, you must set them into output mode:

setp hm2_7i96s.0.gpio.025.is_output true
setp hm2_7i96s.0.gpio.026.is_output true

and then link the output to the desired signal

net  some_output hm2_7i96s.0.gpio.025.out

You may need to invert the output and choose the proper + or - pin
to insure that the output is low at power up or when you exit from LinuxCNC:

setp hm2_7i96s.0.gpio.025.invert_output true


To determine the terminal block to GPIO pin mapping, look at the appropriate .pin file
or run:

mesaflash --device [cardname] --addr [card_address] --readhmid




 
Last edit: 20 Nov 2025 17:53 by PCW.
The following user(s) said Thank You: tommylight, slowpoke

Please Log in or Create an account to join the conversation.

More
20 Nov 2025 18:47 #338820 by slowpoke

Please Log in or Create an account to join the conversation.

Moderators: PCWjmelson
Time to create page: 0.186 seconds
Powered by Kunena Forum