Homing with 2 inputs/sensors?
- hitchhiker
- Away
- Elite Member
-
Less
More
- Posts: 192
- Thank you received: 12
21 Aug 2025 20:23 #333766
by hitchhiker
Homing with 2 inputs/sensors? was created by hitchhiker
Hi!
i have here a axis which has 2 home sensors.
The first sensor is the reference.
the second is a sensor on the pulley.
how it works? Home to first sensor.. then go back until sensor 2 is active.
i the first sensor works on linuxcnc..then i add the second..
net index-sensor gpio001....
inet index-sensor joint...index-enable
but then i get error..
cant add i/o pin to index... its already output pin hm2_7192.0.gpio.005.in
in the ini i change the parameter for use index as true.. but this doesnt solve anything.
do i need to add a encoder in the bitfile or what is my failure??
thanks
i have here a axis which has 2 home sensors.
The first sensor is the reference.
the second is a sensor on the pulley.
how it works? Home to first sensor.. then go back until sensor 2 is active.
i the first sensor works on linuxcnc..then i add the second..
net index-sensor gpio001....
inet index-sensor joint...index-enable
but then i get error..
cant add i/o pin to index... its already output pin hm2_7192.0.gpio.005.in
in the ini i change the parameter for use index as true.. but this doesnt solve anything.
do i need to add a encoder in the bitfile or what is my failure??
thanks
Please Log in or Create an account to join the conversation.
- PCW
-
- Away
- Moderator
-
Less
More
- Posts: 19089
- Thank you received: 5268
21 Aug 2025 21:13 - 21 Aug 2025 21:31 #333767
by PCW
Replied by PCW on topic Homing with 2 inputs/sensors?
You cannot connect an output pin to joint.N.index-enable
because joint.N.index-enable pins are bidirectional ("Tri-State")
When index is used for homing, LinuxCNC expects to use encoder
hardware to detect the actual index pin and signal that detection
to LinuxCNC via the joint.N.index-enable pin. joint.N.index-enable
is used as a bidirectional signal, that is, when LinuxCNC detects the
coarse home position, it then sets joint.N.index-enable true. This signals
the hardware to enable index detection. When the index is detected,
the hardware normally does two things: it clears (sets to false)
joint.N.index-enable (signaling LinuxCNC that the index has been detected)
and normally also zeros the position.
Does this joint have encoder feedback or it this an open-loop step/dir system?
If no encoder (and you have an up-to-date LinuxCNC installation) , there is firmware
that supports homing to index in open loop step/dir systems, so instead of connecting
a GPIO pin to joint.N.index-enable you would connect to hm2_7i92.0.stepgen.NN.index-enable
to joint.N.index-enable.
because joint.N.index-enable pins are bidirectional ("Tri-State")
When index is used for homing, LinuxCNC expects to use encoder
hardware to detect the actual index pin and signal that detection
to LinuxCNC via the joint.N.index-enable pin. joint.N.index-enable
is used as a bidirectional signal, that is, when LinuxCNC detects the
coarse home position, it then sets joint.N.index-enable true. This signals
the hardware to enable index detection. When the index is detected,
the hardware normally does two things: it clears (sets to false)
joint.N.index-enable (signaling LinuxCNC that the index has been detected)
and normally also zeros the position.
Does this joint have encoder feedback or it this an open-loop step/dir system?
If no encoder (and you have an up-to-date LinuxCNC installation) , there is firmware
that supports homing to index in open loop step/dir systems, so instead of connecting
a GPIO pin to joint.N.index-enable you would connect to hm2_7i92.0.stepgen.NN.index-enable
to joint.N.index-enable.
Last edit: 21 Aug 2025 21:31 by PCW. Reason: correct card name
Please Log in or Create an account to join the conversation.
- hitchhiker
- Away
- Elite Member
-
Less
More
- Posts: 192
- Thank you received: 12
22 Aug 2025 05:01 #333769
by hitchhiker
Replied by hitchhiker on topic Homing with 2 inputs/sensors?
Hi
Thanks for answer.
Its openloop. I think the second sensor that wait for the metal pin on the pulley makes the homing more accurate.
Sensor 1 rough homing to a reference marked area.
Sensor 2 then fine homing.
Call it 2 state homing?
Original is the secomd sensor used for 2 things..
Thing 1 homing accurate..
Thing 2 counts the pin everytime the pulley is turned full.
The full rotation means as example 400 steps done.. is the pin triggering the sensor befor or later then its out of position.
But i only want to use the secomd sensor for more precise homing.
This is not possible right? To make it possible it needs a special component or?
i found this:
github.com/mydani/linuxcnc_misc/blob/mai...e_index_stepdir.comp
looks like inside linuxcnc there is no other option.
thanks
Thanks for answer.
Its openloop. I think the second sensor that wait for the metal pin on the pulley makes the homing more accurate.
Sensor 1 rough homing to a reference marked area.
Sensor 2 then fine homing.
Call it 2 state homing?
Original is the secomd sensor used for 2 things..
Thing 1 homing accurate..
Thing 2 counts the pin everytime the pulley is turned full.
The full rotation means as example 400 steps done.. is the pin triggering the sensor befor or later then its out of position.
But i only want to use the secomd sensor for more precise homing.
This is not possible right? To make it possible it needs a special component or?
i found this:
github.com/mydani/linuxcnc_misc/blob/mai...e_index_stepdir.comp
looks like inside linuxcnc there is no other option.
thanks
Please Log in or Create an account to join the conversation.
- rodw
-
- Offline
- Platinum Member
-
Less
More
- Posts: 11386
- Thank you received: 3821
22 Aug 2025 05:58 #333770
by rodw
Replied by rodw on topic Homing with 2 inputs/sensors?
It might not be a trivial solution, but you could write a custom home component that takes the two pins as input. eg rough, then fine.
Ref: linuxcnc.org/docs/stable/html/man/man9/homecomp.9.html
Linuxcnc does this using home_latch_velocity eg fast sensing, then slow for accuraccy on the one pin.
Ref: linuxcnc.org/docs/stable/html/man/man9/homecomp.9.html
Linuxcnc does this using home_latch_velocity eg fast sensing, then slow for accuraccy on the one pin.
Please Log in or Create an account to join the conversation.
- PCW
-
- Away
- Moderator
-
Less
More
- Posts: 19089
- Thank you received: 5268
22 Aug 2025 13:26 #333775
by PCW
Replied by PCW on topic Homing with 2 inputs/sensors?
As I explained, it is possible with firmware that has a stepgen index enable pin
No custom components are needed.
No custom components are needed.
Please Log in or Create an account to join the conversation.
- hitchhiker
- Away
- Elite Member
-
Less
More
- Posts: 192
- Thank you received: 12
23 Aug 2025 06:56 - 23 Aug 2025 07:16 #333788
by hitchhiker
Replied by hitchhiker on topic Homing with 2 inputs/sensors?
Hi
If i understand correct... i must change the firmware on my 7i92?
I need to add encoder to the bitfile.. but only the index? So it must be a index that is coming from the stepgen.. i only know how to add stepgen with step and dir to the bitfile..
I run the stepgen in position mode ..not velocity..
So instead what i try with the gpio i need a index pin in the bitfile which is linked to the stepgen, right?
Sorry i am a little bit confused and doesnt understand it.. i use linuxcnc 2.9 and a mesa 7i92. Changing the bitfile/firmware is not a problem. But i look everytime to existing files and copy from them... and i cant find a documentation about it...
it should be look like:
IOPortTag & x"NN" & StepGenTag & StepGenIndexPin, "
but i never saw something like this...
thanks
If i understand correct... i must change the firmware on my 7i92?
I need to add encoder to the bitfile.. but only the index? So it must be a index that is coming from the stepgen.. i only know how to add stepgen with step and dir to the bitfile..
I run the stepgen in position mode ..not velocity..
So instead what i try with the gpio i need a index pin in the bitfile which is linked to the stepgen, right?
Sorry i am a little bit confused and doesnt understand it.. i use linuxcnc 2.9 and a mesa 7i92. Changing the bitfile/firmware is not a problem. But i look everytime to existing files and copy from them... and i cant find a documentation about it...
it should be look like:
IOPortTag & x"NN" & StepGenTag & StepGenIndexPin, "
but i never saw something like this...
thanks
Last edit: 23 Aug 2025 07:16 by hitchhiker.
Please Log in or Create an account to join the conversation.
- hitchhiker
- Away
- Elite Member
-
Less
More
- Posts: 192
- Thank you received: 12
23 Aug 2025 08:24 - 23 Aug 2025 11:02 #333791
by hitchhiker
Replied by hitchhiker on topic Homing with 2 inputs/sensors?
ahhhhaaaaa...
i think i got the firmware fixed on my table/labor mesa 7i92....
to explain:
I have everytime i configurate a new machine or want to try something a mesa 7i92 for learning on my table...
i load the firmware file for the 7i96 and look into it and found the example where index on a stepgen was attached.
Download:
link to the 7i96 firmware files
then extract and look for:
PIN_7I96_StepIDXD_51.vhd
then i saw in the file:
(StepGenTag, x"C2", ClockLowTag, x"04", StepGenRateAddr&PadT, StepGenNumRegs, x"00", StepGenMPBitMask),
bingo!
i add the stuff to my 7i92 bitfile...
and tada after flash i saw this in my terminal output:
this is how it must look, right?
thanks
i think i got the firmware fixed on my table/labor mesa 7i92....
to explain:
I have everytime i configurate a new machine or want to try something a mesa 7i92 for learning on my table...
i load the firmware file for the 7i96 and look into it and found the example where index on a stepgen was attached.
Download:
link to the 7i96 firmware files
then extract and look for:
PIN_7I96_StepIDXD_51.vhd
then i saw in the file:
(StepGenTag, x"C2", ClockLowTag, x"04", StepGenRateAddr&PadT, StepGenNumRegs, x"00", StepGenMPBitMask),
bingo!
i add the stuff to my 7i92 bitfile...
library IEEE;
use IEEE.std_logic_1164.all; -- defines std_logic types
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;
-- Copyright (C) 2007, Peter C. Wallace, Mesa Electronics
-- http://www.mesanet.com
--
-- This program is is licensed under a disjunctive dual license giving you
-- the choice of one of the two following sets of free software/open source
-- licensing terms:
--
-- * GNU General Public License (GPL), version 2.0 or later
-- * 3-clause BSD License
--
--
-- The GNU GPL License:
--
-- This program is free software; you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation; either version 2 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program; if not, write to the Free Software
-- Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
--
--
-- The 3-clause BSD License:
--
-- Redistribution and use in source and binary forms, with or without
-- modification, are permitted provided that the following conditions
-- are met:
--
-- * Redistributions of source code must retain the above copyright
-- notice, this list of conditions and the following disclaimer.
--
-- * Redistributions in binary form must reproduce the above
-- copyright notice, this list of conditions and the following
-- disclaimer in the documentation and/or other materials
-- provided with the distribution.
--
-- * Neither the name of Mesa Electronics nor the names of its
-- contributors may be used to endorse or promote products
-- derived from this software without specific prior written
-- permission.
--
--
-- Disclaimer:
--
-- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
-- FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
-- COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
-- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
-- BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
-- LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
-- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-- LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
-- ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-- POSSIBILITY OF SUCH DAMAGE.
--
use work.IDROMConst.all;
package PIN_VMC100 is
constant ModuleID : ModuleIDType :=(
(HM2DPLLTag, x"00", ClockLowTag, x"01", HM2DPLLBaseRateAddr&PadT, HM2DPLLNumRegs, x"00", HM2DPLLMPBitMask),
(WatchDogTag, x"00", ClockLowTag, x"01", WatchDogTimeAddr&PadT, WatchDogNumRegs, x"00", WatchDogMPBitMask),
(IOPortTag, x"00", ClockLowTag, x"02", PortAddr&PadT, IOPortNumRegs, x"00", IOPortMPBitMask),
(QcountTag, x"02", ClockLowTag, x"01", QcounterAddr&PadT, QCounterNumRegs, x"00", QCounterMPBitMask),
(StepGenTag, x"C2", ClockLowTag, x"04", StepGenRateAddr&PadT, StepGenNumRegs, x"00", StepGenMPBitMask),
(PWMTag, x"00", ClockHighTag, x"00", PWMValAddr&PadT, PWMNumRegs, x"00", PWMMPBitMask),
(LEDTag, x"00", ClockLowTag, x"01", LEDAddr&PadT, LEDNumRegs, x"00", LEDMPBitMask),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000"),
(NullTag, x"00", NullTag, x"00", NullAddr&PadT, x"00", x"00", x"00000000")
);
constant PinDesc : PinDescType :=(
-- Base func sec unit sec func sec pin -- 26 HDR -- IDC DB25
IOPortTag & x"00" & StepGenTag & StepGenIndexPin, -- I/O 00 PIN 1 PIN 1 just GPIO
IOPortTag & x"01" & StepGenTag & StepGenIndexPin, -- I/O 01 PIN 2 PIN 14 just GPIO
IOPortTag & x"02" & StepGenTag & StepGenIndexPin, -- I/O 02 PIN 3 PIN 2 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 03 PIN 4 PIN 15 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 04 PIN 5 PIN 3 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 05 PIN 6 PIN 16 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 06 PIN 7 PIN 4 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 07 PIN 8 PIN 17 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 08 PIN 9 PIN 5 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 09 PIN 11 PIN 6 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 10 PIN 13 PIN 7 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 11 PIN 15 PIN 8 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 12 PIN 17 PIN 9 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 13 PIN 19 PIN 10 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 14 PIN 21 PIN 11 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 15 PIN 23 PIN 12 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 16 PIN 25 PIN 13 just GPIO
-- 26 HDR -- IDC DB25
IOPortTag & x"00" & NullTag & NullPin, -- I/O 17 PIN 1 PIN 1 just GPIO
IOPortTag & x"00" & NullTag & NullPin, -- I/O 18 PIN 2 PIN 14 just GPIO
IOPortTag & x"00" & StepGenTag & StepGenStepPin, -- I/O 19 PIN 3 PIN 2 X Step
IOPortTag & x"00" & NullTag & NullPin, -- I/O 20 PIN 4 PIN 15 just GPIO
IOPortTag & x"00" & StepGenTag & StepGenDirPin, -- I/O 21 PIN 5 PIN 3 X Dir
IOPortTag & x"00" & NullTag & NullPin, -- I/O 22 PIN 6 PIN 16 just GPIO
IOPortTag & x"01" & StepGenTag & StepGenStepPin, -- I/O 23 PIN 7 PIN 4 Y Step
IOPortTag & x"00" & NullTag & NullPin, -- I/O 24 PIN 8 PIN 17 just GPIO
IOPortTag & x"01" & StepGenTag & StepGenDirPin, -- I/O 25 PIN 9 PIN 5 Y Dir
IOPortTag & x"02" & StepGenTag & StepGenStepPin, -- I/O 26 PIN 11 PIN 6 Z Step
IOPortTag & x"02" & StepGenTag & StepGenDirPin, -- I/O 27 PIN 13 PIN 7 Z Dir
IOPortTag & x"00" & NullTag & NullPin, -- I/O 28 PIN 15 PIN 8 Spindle on/off
IOPortTag & x"03" & StepGenTag & StepGenStepPin, -- I/O 29 PIN 17 PIN 9 Spindle Step
IOPortTag & x"03" & StepGenTag & StepGenDirPin, -- I/O 30 PIN 19 PIN 10 Spindle Dir
IOPortTag & x"00" & QCountTag & QCountIdxPin, -- I/O 31 PIN 21 PIN 11 (Encoder Quad Idx)
IOPortTag & x"00" & QCountTag & QCountQAPin, -- I/O 32 PIN 23 PIN 12 (Encoder Quad A)
IOPortTag & x"00" & QCountTag & QCountQBPin, -- I/O 33 PIN 25 PIN 13 (Encoder Quad B)
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin, -- added for 34 pin 5I25
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin, -- added for IDROM v3
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,
emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin,emptypin);
end package PIN_VMC100;
Configuration Name: HOSTMOT2
General configuration information:
BoardName : MESA7I92
FPGA Size: 20 KGates
FPGA Pins: 256
Number of IO Ports: 2
Width of one I/O port: 17
Clock Low frequency: 100.0000 MHz
Clock High frequency: 175.0000 MHz
IDROM Type: 3
Instance Stride 0: 4
Instance Stride 1: 64
Register Stride 0: 256
Register Stride 1: 256
Modules in configuration:
Module: DPLL
There are 1 of DPLL in configuration
Version: 0
Registers: 7
BaseAddress: 7000
ClockFrequency: 100.000 MHz
Register Stride: 256 bytes
Instance Stride: 4 bytes
Module: WatchDog
There are 1 of WatchDog in configuration
Version: 0
Registers: 3
BaseAddress: 0C00
ClockFrequency: 100.000 MHz
Register Stride: 256 bytes
Instance Stride: 4 bytes
Module: IOPort
There are 2 of IOPort in configuration
Version: 0
Registers: 5
BaseAddress: 1000
ClockFrequency: 100.000 MHz
Register Stride: 256 bytes
Instance Stride: 4 bytes
Module: QCount
There are 1 of QCount in configuration
Version: 2
Registers: 5
BaseAddress: 3000
ClockFrequency: 100.000 MHz
Register Stride: 256 bytes
Instance Stride: 4 bytes
Module: StepGen
There are 4 of StepGen in configuration
Version: 194
Registers: 10
BaseAddress: 2000
ClockFrequency: 100.000 MHz
Register Stride: 256 bytes
Instance Stride: 4 bytes
Module: PWM
There are 0 of PWM in configuration
Version: 0
Registers: 5
BaseAddress: 4100
ClockFrequency: 175.000 MHz
Register Stride: 256 bytes
Instance Stride: 4 bytes
Module: LED
There are 1 of LED in configuration
Version: 0
Registers: 1
BaseAddress: 0200
ClockFrequency: 100.000 MHz
Register Stride: 256 bytes
Instance Stride: 4 bytes
Configuration pin-out:
IO Connections for P2
DB25 pin# I/O Pri. func Sec. func Chan Sec. Pin func Sec. Pin Dir
1 0 IOPort StepGen 0 Index (In)
14 1 IOPort StepGen 1 Index (In)
2 2 IOPort StepGen 2 Index (In)
15 3 IOPort None
3 4 IOPort None
16 5 IOPort None
4 6 IOPort None
17 7 IOPort None
5 8 IOPort None
6 9 IOPort None
7 10 IOPort None
8 11 IOPort None
9 12 IOPort None
10 13 IOPort None
11 14 IOPort None
12 15 IOPort None
13 16 IOPort None
IO Connections for P1
DB25 pin# I/O Pri. func Sec. func Chan Sec. Pin func Sec. Pin Dir
1 17 IOPort None
14 18 IOPort None
2 19 IOPort StepGen 0 Step/Table1 (Out)
15 20 IOPort None
3 21 IOPort StepGen 0 Dir/Table2 (Out)
16 22 IOPort None
4 23 IOPort StepGen 1 Step/Table1 (Out)
17 24 IOPort None
5 25 IOPort StepGen 1 Dir/Table2 (Out)
6 26 IOPort StepGen 2 Step/Table1 (Out)
7 27 IOPort StepGen 2 Dir/Table2 (Out)
8 28 IOPort None
9 29 IOPort StepGen 3 Step/Table1 (Out)
10 30 IOPort StepGen 3 Dir/Table2 (Out)
11 31 IOPort QCount 0 Quad-IDX (In)
12 32 IOPort QCount 0 Quad-A (In)
13 33 IOPort QCount 0 Quad-B (In)
this is how it must look, right?
thanks
Attachments:
Last edit: 23 Aug 2025 11:02 by hitchhiker.
Please Log in or Create an account to join the conversation.
- hitchhiker
- Away
- Elite Member
-
Less
More
- Posts: 192
- Thank you received: 12
23 Aug 2025 11:56 #333797
by hitchhiker
Replied by hitchhiker on topic Homing with 2 inputs/sensors?
Ok i connect the joint.00.index-enable with the stepgen.00.index-enable.
Activate in the ini the usage of home index.
Then i start the homing of the axis... works up to the point it waits for index.... and index signal doesnt change the state..
Again.. i use position mode not velocity mode of the stepgen.
Signal is ground to input (gpio).
Thanks
Activate in the ini the usage of home index.
Then i start the homing of the axis... works up to the point it waits for index.... and index signal doesnt change the state..
Again.. i use position mode not velocity mode of the stepgen.
Signal is ground to input (gpio).
Thanks
Please Log in or Create an account to join the conversation.
- PCW
-
- Away
- Moderator
-
Less
More
- Posts: 19089
- Thank you received: 5268
23 Aug 2025 15:09 #333807
by PCW
Replied by PCW on topic Homing with 2 inputs/sensors?
I would test this by hand by watching index.n.enable with halshow
and then:
sets index.n.enable true
(in halshow or with halcmd)
and seeing if toggling the hardware stepgen index pin clears index.n.enable
You might also verify that the GPIO pin associated with the stepgen index
changes when you toggle the stepgen index pin.
note: index.n.enable is the name of your signal that connects the joint
index enable to the stepgen index enable.
Also stepgen position mode should work but it will have a glitch at index detection.
The more standard stepgen velocity mode is better as it handles the stepgen position
jump at index detection better.
and then:
sets index.n.enable true
(in halshow or with halcmd)
and seeing if toggling the hardware stepgen index pin clears index.n.enable
You might also verify that the GPIO pin associated with the stepgen index
changes when you toggle the stepgen index pin.
note: index.n.enable is the name of your signal that connects the joint
index enable to the stepgen index enable.
Also stepgen position mode should work but it will have a glitch at index detection.
The more standard stepgen velocity mode is better as it handles the stepgen position
jump at index detection better.
Please Log in or Create an account to join the conversation.
- besriworld
- Offline
- Elite Member
-
Less
More
- Posts: 308
- Thank you received: 82
23 Aug 2025 16:37 #333814
by besriworld
Replied by besriworld on topic Homing with 2 inputs/sensors?
"
Also stepgen position mode should work but it will have a glitch at index detection. "
Can you please explain what kind of gitch this is?
Also stepgen position mode should work but it will have a glitch at index detection. "
Can you please explain what kind of gitch this is?
Please Log in or Create an account to join the conversation.
Time to create page: 0.095 seconds