emcoturn 120 / 220 tool turret hal outputs

More
03 Aug 2019 09:24 #141262 by Erikcnc

Looks like the emcochanger.forward signal needs to be linked to the 2 complementary direction signals on the LM298

To do this with the current firmware would require disabling one more stepgens and using one of the free pins of say stepgen3 for the direction signals.

It would probably be cleaner if I made firmware that left the DIR pin of Stepgen4 a GPIO pin instead of the PWM direction pin (which is under control of the PWM gen)

EDIT
freeby.mesanet.com/7i76e_7i76pdpo.bit

Here is firmware that has stepgen4 STEP pin replaced with PWM but left Stepgen4s DIR pin as GPIO
(GPIO8) so it can output the toolchanger forward pin


Thanks!!

so this should do the trick? without any adjusting to wiring and hal file?
I am going to flash the firmware right now.

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

More
03 Aug 2019 11:55 #141265 by Erikcnc
I succesfully flashed the firmware.

now its rotating the other way and does not change direction.

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

More
03 Aug 2019 13:44 - 03 Aug 2019 13:44 #141272 by Erikcnc
i was measuring the dir and step.

at a tool change, and it founds the tool between step + and step - it changes polarity.
dir + always stays 5v
while idle, (at the right tool) step - stays 0.5v. (to keep force on the lock pin)

So i wired in1 and in2 to step + and step -.
ENA to Dir +

it is switching direction now, but keeps running at full speed because the Ena getting continual 5v.

so between dir+ and dir - its not switching polarity, but it does at step + and step -.
but also step - goes to 0.5v at founding the right tool. whats needed for the ENA.
Last edit: 03 Aug 2019 13:44 by Erikcnc.

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

More
03 Aug 2019 14:06 - 03 Aug 2019 14:07 #141273 by PCW
Step4- --> LM298 enable
Dir4+ LM298 --> IN1
Dir4- LM298 --> IN2

In hal file, connect DIR4 (GPIO8) to emcochanger.forward
and set GPIO8 to output mode

(you may need to swap Dir4+ and Dir4- to get the right directions)
Last edit: 03 Aug 2019 14:07 by PCW.
The following user(s) said Thank You: Erikcnc

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

More
03 Aug 2019 14:27 - 03 Aug 2019 14:28 #141275 by Erikcnc

Step4- --> LM298 enable
Dir4+ LM298 --> IN1
Dir4- LM298 --> IN2

In hal file, connect DIR4 (GPIO8) to emcochanger.forward
and set GPIO8 to output mode

(you may need to swap Dir4+ and Dir4- to get the right directions)


oke.

Do you suggest it like this?

setp hm2_7i76e.0.gpio.008.is_output true

net sig-forward emcochanger.forward => setp hm2_7i76e.0.gpio.008.out

it did not make difference
Last edit: 03 Aug 2019 14:28 by Erikcnc.

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

More
03 Aug 2019 14:36 #141277 by PCW
That "setp" doesn't belong there

I would verify that the DIR4+ and DIR4- signals change with
the state of emcochanger.forward
The following user(s) said Thank You: Erikcnc

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

More
03 Aug 2019 15:18 - 03 Aug 2019 18:29 #141278 by Erikcnc

PCW wrote: That "setp" doesn't belong there

I would verify that the DIR4+ and DIR4- signals change with
the state of emcochanger.forward



my apologies, i am struggling with this one.

i thought i had this one right.
Last edit: 03 Aug 2019 18:29 by Erikcnc.

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

More
03 Aug 2019 18:27 - 03 Aug 2019 18:28 #141281 by Erikcnc
With only
net sig-forward emcochanger.forward => setp hm2_7i76e.0.gpio.008.out

it doesn`t make any changes.
when asking a tool changes, it is getting from false to true, and stays true in halshow
Last edit: 03 Aug 2019 18:28 by Erikcnc.

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

More
03 Aug 2019 18:41 #141284 by PCW
setp makes no sense there (i'm suprised it does not cause a syntax error)

it should be

net sig-forward emcochanger.forward => hm2_7i76e.0.gpio.008.out
The following user(s) said Thank You: Erikcnc

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

More
03 Aug 2019 18:52 - 03 Aug 2019 18:52 #141285 by Erikcnc

setp makes no sense there (i'm suprised it does not cause a syntax error)

it should be

net sig-forward emcochanger.forward => hm2_7i76e.0.gpio.008.out


Oehps, typo in my reaction here. sorry. thats why i didn't follow. sorry.

this is what i add without any changes.
setp hm2_7i76e.0.gpio.008.is_output true

net sig-forward emcochanger.forward => hm2_7i76e.0.gpio.008.out
Last edit: 03 Aug 2019 18:52 by Erikcnc.

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

Time to create page: 0.168 seconds
Powered by Kunena Forum