- Posts: 346
- Thank you received: 22
7i95T spindle control via Modbus RS485 and SPINX1A
2 years 3 weeks ago - 2 years 3 weeks ago #311719
by vmihalca
Replied by vmihalca on topic 7i95T spindle control via Modbus RS485 and SPINX1A
Hi Peter,
I've made the connections on the hal side, set up the gpio009 as output and it lights up when I start the spindle forward.
I also see values on pins pwmgen.00.value and pwmgen.00.enable when I start the spindle.
I might be dumb, but for my safety, can you tell me how to wire the SPINX1A on the input side?
The pinout for mesa 7i95 is:
1: GND
2: STEP4-
3: STEP4+
4: DIR4-
5: DIR4+:
6: +5VP
The pinout for SPINX1A is:
1 GND
2 GND
3 PWM - ACTIVE HIGH
4 ENABLE - ACTIVE LOW
5 DIR - ACTIVE HIGH => CW
6 +5V
For now I connected the obvious ones: GND and +5VP
I will use the enable from the 7i95 outputs, but I am not sure there how exactly to wire that.
I have OUT+ and OUT-, but I don't know which of these should go to the enable pin and which to GND or +5v
Also on the PWM pin from SPINX board, what should I use as input, the STEP4- or STEP4+?
Also the same wiring question for the DIR pin of SPINX.
Thanks in advance
I've made the connections on the hal side, set up the gpio009 as output and it lights up when I start the spindle forward.
I also see values on pins pwmgen.00.value and pwmgen.00.enable when I start the spindle.
I might be dumb, but for my safety, can you tell me how to wire the SPINX1A on the input side?
The pinout for mesa 7i95 is:
1: GND
2: STEP4-
3: STEP4+
4: DIR4-
5: DIR4+:
6: +5VP
The pinout for SPINX1A is:
1 GND
2 GND
3 PWM - ACTIVE HIGH
4 ENABLE - ACTIVE LOW
5 DIR - ACTIVE HIGH => CW
6 +5V
For now I connected the obvious ones: GND and +5VP
I will use the enable from the 7i95 outputs, but I am not sure there how exactly to wire that.
I have OUT+ and OUT-, but I don't know which of these should go to the enable pin and which to GND or +5v
Also on the PWM pin from SPINX board, what should I use as input, the STEP4- or STEP4+?
Also the same wiring question for the DIR pin of SPINX.
Thanks in advance
Last edit: 2 years 3 weeks ago by vmihalca.
Please Log in or Create an account to join the conversation.
2 years 3 weeks ago #311729
by PCW
Replied by PCW on topic 7i95T spindle control via Modbus RS485 and SPINX1A
If you use an isolated output for the enable, you would wire:
OUT+ to /ENABLE
OUT- to GND
For the PWM (assuming you are using 2PWM firmware so both step/dir 4 and 5 are PWM outputs)
you would wire STEP+ to PWM
Not sure about the direction off-hand
OUT+ to /ENABLE
OUT- to GND
For the PWM (assuming you are using 2PWM firmware so both step/dir 4 and 5 are PWM outputs)
you would wire STEP+ to PWM
Not sure about the direction off-hand
The following user(s) said Thank You: vmihalca
Please Log in or Create an account to join the conversation.
2 years 3 weeks ago #311746
by vmihalca
Replied by vmihalca on topic 7i95T spindle control via Modbus RS485 and SPINX1A
Please let me know when you know about how should I link the dir pin to GPIO pins
Please Log in or Create an account to join the conversation.
2 years 3 weeks ago #311750
by PCW
Replied by PCW on topic 7i95T spindle control via Modbus RS485 and SPINX1A
I would connect the SPINX1A direction pin to DIR+
How this is connected in the hal file depends on the precise firmware used
(a mesaflash --readhmid printout would help here)
How this is connected in the hal file depends on the precise firmware used
(a mesaflash --readhmid printout would help here)
Please Log in or Create an account to join the conversation.
2 years 3 weeks ago - 2 years 3 weeks ago #311807
by vmihalca
Replied by vmihalca on topic 7i95T spindle control via Modbus RS485 and SPINX1A
I have connected the pins as following but I think something is off with the firmware of the board or smth.
TB4, Pin1 (GND) -> SPINX1A, Pin1 (GND)
TB4, Pin2 (STEP-) -> not connected
TB4, Pin3 (STEP+) -> SPINX1A, Pin3 (PWM)
TB4, Pin4 (DIR-) -> not connected
TB4, Pin5 (DIR+) -> SPINX1A, Pin5 (DIR)
TB4, Pin6 (+5v) -> SPINX1A, Pin6 (+5v)
TB5, Pin24 (Out5+) -> SPINX1A, Pin4 (ENA)
TB5, Pin23 (Out5-) -> SPINX1A, Pin2 (GND)
In hal I have added:
net spindir spindle.0.forward => hm2_7i95.0.gpio.009.out
Checked the pins in hal configuration, I can see the pwm being enabled, and I can see a value that changes as I change the spindle override. This value is either positive or negative depending on the spindle direction.
The problem is that the Speed LED on the SPINX board is always on. When I start the spindle in reverse it says on, when I move it forward it turns off. I think the Dir LED should behave like this not the speed pin.
The enable pin lights on when I start the spindle in any direction.
From what I read on a separate thread, the DIR led on the SPINX board should turn off in one of the directions. For me its the SPEED LED.
Also when I play with the spindle override the DIR pin dims when I increase the spindle speed and it lights up when I decrease the spindle speed. The dimming of the led proportional with the spindle I think its expected, but it should be the SPEED pin not the DIR pin.
I checked the wiring several times, so this leads me to believe that somehow the pin allocation on the mesa board is not correct.
I've used the firmware provided by you in the begining of this thread.
Please let me know your thoughts on this matter.
TB4, Pin1 (GND) -> SPINX1A, Pin1 (GND)
TB4, Pin2 (STEP-) -> not connected
TB4, Pin3 (STEP+) -> SPINX1A, Pin3 (PWM)
TB4, Pin4 (DIR-) -> not connected
TB4, Pin5 (DIR+) -> SPINX1A, Pin5 (DIR)
TB4, Pin6 (+5v) -> SPINX1A, Pin6 (+5v)
TB5, Pin24 (Out5+) -> SPINX1A, Pin4 (ENA)
TB5, Pin23 (Out5-) -> SPINX1A, Pin2 (GND)
In hal I have added:
net spindir spindle.0.forward => hm2_7i95.0.gpio.009.out
Checked the pins in hal configuration, I can see the pwm being enabled, and I can see a value that changes as I change the spindle override. This value is either positive or negative depending on the spindle direction.
The problem is that the Speed LED on the SPINX board is always on. When I start the spindle in reverse it says on, when I move it forward it turns off. I think the Dir LED should behave like this not the speed pin.
The enable pin lights on when I start the spindle in any direction.
From what I read on a separate thread, the DIR led on the SPINX board should turn off in one of the directions. For me its the SPEED LED.
Also when I play with the spindle override the DIR pin dims when I increase the spindle speed and it lights up when I decrease the spindle speed. The dimming of the led proportional with the spindle I think its expected, but it should be the SPEED pin not the DIR pin.
I checked the wiring several times, so this leads me to believe that somehow the pin allocation on the mesa board is not correct.
I've used the firmware provided by you in the begining of this thread.
Please let me know your thoughts on this matter.
Last edit: 2 years 3 weeks ago by vmihalca.
Please Log in or Create an account to join the conversation.
2 years 3 weeks ago #311811
by PCW
Replied by PCW on topic 7i95T spindle control via Modbus RS485 and SPINX1A
The speed and direction LEDS are reversed on the first REV SPINX1A cards
This is mentioned in the manual:
Note that on SPINX1A cards previous to revision A, the DIR CW and
SPEED LED labels are swapped.
This is mentioned in the manual:
Note that on SPINX1A cards previous to revision A, the DIR CW and
SPEED LED labels are swapped.
Please Log in or Create an account to join the conversation.
Time to create page: 0.269 seconds