- Posts: 2203
- Thank you received: 486
Fitting an encoder on a Tormach 1100
8 years 6 months ago #108428
by Clive S
The P2 figures above seem to be same as the pins number in the 7i85s man.
The bit file I used was made by Peter to be able to use the Tormach file and have encoders on the P2 of the 5i25 with the 7i85s.
I haven't changed any hal loadrt stuff yet.
I am not sure what to change in the hal file to show the encoders on the 7i85s
Replied by Clive S on topic Fitting an encoder on a Tormach 1100
andypugh wrote: That looks like either the wrong bitfile or your "num_encoders" in the "loadrt hm2_pci" needs to be changed.
The P2 figures above seem to be same as the pins number in the 7i85s man.
The bit file I used was made by Peter to be able to use the Tormach file and have encoders on the P2 of the 5i25 with the 7i85s.
I haven't changed any hal loadrt stuff yet.
I am not sure what to change in the hal file to show the encoders on the 7i85s
The following user(s) said Thank You: Mwmx54
Please Log in or Create an account to join the conversation.
8 years 6 months ago #108430
by andypugh
Replied by andypugh on topic Fitting an encoder on a Tormach 1100
If everything was set up right then the pins shown as "ioport" would show up as "encoder phase A" and such.
You won't even have HAL pins to connect until that is sorted out.
How many encoders are you asking for in the "loadrt hm2_pci" line in your HAL file?
You won't even have HAL pins to connect until that is sorted out.
How many encoders are you asking for in the "loadrt hm2_pci" line in your HAL file?
Please Log in or Create an account to join the conversation.
8 years 6 months ago #108433
by Clive S
Replied by Clive S on topic Fitting an encoder on a Tormach 1100
@Andy
This is a snippet from the ini and hal file. I see that encoders=0 But I need the encoders to be on the 5i25 P2 only. How do I achieve this.
#### this is from the tormach_mill_base.ini
[HOSTMOT2]
DRIVER=hm2_pci
BOARD=5i25
DRIVER_PARAMS="config= num_encoders=0 num_pwmgens=1 num_3pwmgens=0 num_stepgens=5 "
BITFILE0=mesa/tormach_mill3.bit
DPLL_TIMER_NUMBER = 1
DPLL_TIMER_US= -100
[HAL]
HALUI = halui
HALFILE = tormach_mill_mesa.hal
POSTGUI_SHUTTLEXPRESS_HALFILE = millshuttlexpress.hal
POSTGUI_HALFILE = postgui_tormach_mill.hal
####This is from the tormach_mill_mesa.hal #####
loadrt trivkins
loadrt [EMCMOT]EMCMOT servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[TRAJ]AXES num_dio=64 num_aio=64
loadrt hostmot2
loadrt [HOSTMOT2]DRIVER [HOSTMOT2]DRIVER_PARAMS
loadrt estop_latch
loadrt toggle count=1
loadrt not names=prog-not-idle,a
This is a snippet from the ini and hal file. I see that encoders=0 But I need the encoders to be on the 5i25 P2 only. How do I achieve this.
#### this is from the tormach_mill_base.ini
[HOSTMOT2]
DRIVER=hm2_pci
BOARD=5i25
DRIVER_PARAMS="config= num_encoders=0 num_pwmgens=1 num_3pwmgens=0 num_stepgens=5 "
BITFILE0=mesa/tormach_mill3.bit
DPLL_TIMER_NUMBER = 1
DPLL_TIMER_US= -100
[HAL]
HALUI = halui
HALFILE = tormach_mill_mesa.hal
POSTGUI_SHUTTLEXPRESS_HALFILE = millshuttlexpress.hal
POSTGUI_HALFILE = postgui_tormach_mill.hal
####This is from the tormach_mill_mesa.hal #####
loadrt trivkins
loadrt [EMCMOT]EMCMOT servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[TRAJ]AXES num_dio=64 num_aio=64
loadrt hostmot2
loadrt [HOSTMOT2]DRIVER [HOSTMOT2]DRIVER_PARAMS
loadrt estop_latch
loadrt toggle count=1
loadrt not names=prog-not-idle,a
Please Log in or Create an account to join the conversation.
8 years 6 months ago #108434
by andypugh
Replied by andypugh on topic Fitting an encoder on a Tormach 1100
It depends on the bitfile where the encoders end up. Try enabling them all and see what you get.
(just deleting the "num_encoders=0" will default to all available encoders.)
It doesn't really matter if you do end up with encoders on some P1 pins as long as the pin direction doesn't change the pins are still available s GPIO inputs.
But as a first step enable the encoders and see what you get.
(just deleting the "num_encoders=0" will default to all available encoders.)
It doesn't really matter if you do end up with encoders on some P1 pins as long as the pin direction doesn't change the pins are still available s GPIO inputs.
But as a first step enable the encoders and see what you get.
Please Log in or Create an account to join the conversation.
8 years 6 months ago - 8 years 6 months ago #108435
by Clive S
Thanks for the rapid response. Yes they are there but is it possible for them to just be on the P2 as I have a feeling that they will interfere with other things on P3.
edit: for info I don't have the main Tormach BOB connected at this time
further edit: changing encoder=1 I get one encoder on P2 encoder =2 I get two but encoder 3 or 4 I still get 2
Below is deleting out completely the encoder=0 string
2/hm2_5i25.0: IO Pin 012 (P3-09): StepGen #3, pin Step (Output)
hm2/hm2_5i25.0: IO Pin 013 (P3-10): Muxed Encoder #2, pin Muxed Index (Input)
hm2/hm2_5i25.0: IO Pin 014 (P3-11): Muxed Encoder #2, pin Muxed A (Input)
hm2/hm2_5i25.0: IO Pin 015 (P3-12): Muxed Encoder #2, pin Muxed B (Input)
hm2/hm2_5i25.0: IO Pin 016 (P3-13): IOPort
hm2/hm2_5i25.0: IO Pin 017 (P2-01): IOPort
hm2/hm2_5i25.0: IO Pin 018 (P2-14): IOPort
hm2/hm2_5i25.0: IO Pin 019 (P2-02): IOPort
hm2/hm2_5i25.0: IO Pin 020 (P2-15): IOPort
hm2/hm2_5i25.0: IO Pin 021 (P2-03): IOPort
hm2/hm2_5i25.0: IO Pin 022 (P2-16): IOPort
hm2/hm2_5i25.0: IO Pin 023 (P2-04): IOPort
hm2/hm2_5i25.0: IO Pin 024 (P2-17): IOPort
hm2/hm2_5i25.0: IO Pin 025 (P2-05): IOPort
hm2/hm2_5i25.0: IO Pin 026 (P2-06): IOPort
hm2/hm2_5i25.0: IO Pin 027 (P2-07): Muxed Encoder Select #0, pin Mux Select 0 (Output)
hm2/hm2_5i25.0: IO Pin 028 (P2-08): Muxed Encoder #0, pin Muxed A (Input)
hm2/hm2_5i25.0: IO Pin 029 (P2-09): Muxed Encoder #0, pin Muxed B (Input)
hm2/hm2_5i25.0: IO Pin 030 (P2-10): Muxed Encoder #0, pin Muxed Index (Input)
hm2/hm2_5i25.0: IO Pin 031 (P2-11): Muxed Encoder #1, pin Muxed A (Input)
hm2/hm2_5i25.0: IO Pin 032 (P2-12): Muxed Encoder #1, pin Muxed B (Input)
hm2/hm2_5i25.0: IO Pin 033 (P2-13): Muxed Encoder #1, pin Muxed Index (Input)
Replied by Clive S on topic Fitting an encoder on a Tormach 1100
But as a first step enable the encoders and see what you get.
Thanks for the rapid response. Yes they are there but is it possible for them to just be on the P2 as I have a feeling that they will interfere with other things on P3.
edit: for info I don't have the main Tormach BOB connected at this time
further edit: changing encoder=1 I get one encoder on P2 encoder =2 I get two but encoder 3 or 4 I still get 2
Below is deleting out completely the encoder=0 string
2/hm2_5i25.0: IO Pin 012 (P3-09): StepGen #3, pin Step (Output)
hm2/hm2_5i25.0: IO Pin 013 (P3-10): Muxed Encoder #2, pin Muxed Index (Input)
hm2/hm2_5i25.0: IO Pin 014 (P3-11): Muxed Encoder #2, pin Muxed A (Input)
hm2/hm2_5i25.0: IO Pin 015 (P3-12): Muxed Encoder #2, pin Muxed B (Input)
hm2/hm2_5i25.0: IO Pin 016 (P3-13): IOPort
hm2/hm2_5i25.0: IO Pin 017 (P2-01): IOPort
hm2/hm2_5i25.0: IO Pin 018 (P2-14): IOPort
hm2/hm2_5i25.0: IO Pin 019 (P2-02): IOPort
hm2/hm2_5i25.0: IO Pin 020 (P2-15): IOPort
hm2/hm2_5i25.0: IO Pin 021 (P2-03): IOPort
hm2/hm2_5i25.0: IO Pin 022 (P2-16): IOPort
hm2/hm2_5i25.0: IO Pin 023 (P2-04): IOPort
hm2/hm2_5i25.0: IO Pin 024 (P2-17): IOPort
hm2/hm2_5i25.0: IO Pin 025 (P2-05): IOPort
hm2/hm2_5i25.0: IO Pin 026 (P2-06): IOPort
hm2/hm2_5i25.0: IO Pin 027 (P2-07): Muxed Encoder Select #0, pin Mux Select 0 (Output)
hm2/hm2_5i25.0: IO Pin 028 (P2-08): Muxed Encoder #0, pin Muxed A (Input)
hm2/hm2_5i25.0: IO Pin 029 (P2-09): Muxed Encoder #0, pin Muxed B (Input)
hm2/hm2_5i25.0: IO Pin 030 (P2-10): Muxed Encoder #0, pin Muxed Index (Input)
hm2/hm2_5i25.0: IO Pin 031 (P2-11): Muxed Encoder #1, pin Muxed A (Input)
hm2/hm2_5i25.0: IO Pin 032 (P2-12): Muxed Encoder #1, pin Muxed B (Input)
hm2/hm2_5i25.0: IO Pin 033 (P2-13): Muxed Encoder #1, pin Muxed Index (Input)
Last edit: 8 years 6 months ago by Clive S.
Please Log in or Create an account to join the conversation.
8 years 6 months ago #108436
by andypugh
Replied by andypugh on topic Fitting an encoder on a Tormach 1100
Muxed Encoders 0 and 1 are on P2, encoder 2 is on P3. That is the way the bitfile is set up.
So num_encoders=2 will give you two muxed encoders on P2 / 7i85S and none on P3.
Reading back this seems to be what you asked for.
Each Muxed-encoder channel on the 5i25 gives two encoder channels on the 7i85S (As they are multiplexed)
So the setup as listed in your last post will have 5 physical encoder channels, one of which is connected to the Tormach BoB and might be unwanted. (Or might not, I know almost nothing about the Tormach / Pathpilot setup)
With num_encoders=2 I think you will end up with 4 sets of HAL encoder pins (counts / rawcounts / position / index-enable)
So num_encoders=2 will give you two muxed encoders on P2 / 7i85S and none on P3.
Reading back this seems to be what you asked for.
Each Muxed-encoder channel on the 5i25 gives two encoder channels on the 7i85S (As they are multiplexed)
So the setup as listed in your last post will have 5 physical encoder channels, one of which is connected to the Tormach BoB and might be unwanted. (Or might not, I know almost nothing about the Tormach / Pathpilot setup)
With num_encoders=2 I think you will end up with 4 sets of HAL encoder pins (counts / rawcounts / position / index-enable)
Please Log in or Create an account to join the conversation.
Time to create page: 0.365 seconds