Help needed to get my 7i76E + 7i85S + 7i73 on my mill going.

More
05 Sep 2018 11:57 #117093 by andypugh
linuxcnc.org/docs/2.7/html/man/man9/message.9.html

I suggest initially

names=gear1,gear2,gear3... messages="gear 1,gear 2,gear 3..."

And, to be clear, ... means I couldn't be bothered to type them all.
Only put spaces where there are spaces in the examples.

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

More
05 Sep 2018 12:29 - 05 Sep 2018 12:29 #117094 by tecno
OK, does this look OK with following lines in hal?
loadrt GB_2speed
loadrt message names=gear1,gear2,gear3,gear4,gear5,gear6,gear7,gear8,gear9,gear10,gear11,gear12,gear13 messages="G1 80-125,G2 126-160,G3 161-215,G4 216-270,G5 271-360,G6 361-450,G7 451-595,G8 596-750,G9 751-1000,G10 1001-1190,G11 1191-1500,G12 1501-2000,G13 2001-2500"
loadrt bitslice


addf GB_2speed.0 servo-thread
addf gear1 servo-thread
addf gear2 servo-thread
addf gear3 servo-thread
addf gear4 servo-thread
addf gear5 servo-thread
addf gear6 servo-thread
addf gear7 servo-thread
addf gear8 servo-thread
addf gear9 servo-thread
addf gear10 servo-thread
addf gear11 servo-thread
addf gear12 servo-thread
addf gear13 servo-thread
addf bitslice.0 servo-thread
Last edit: 05 Sep 2018 12:29 by tecno.

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

More
05 Sep 2018 13:05 #117095 by andypugh
Looks about right, yes.
I don't think you need bitslice, unless that is for something else.
You also need to net m1 GB_2speed.0.message.1 => gear1.trigger (etc)

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

More
05 Sep 2018 13:19 #117097 by tecno
OK, so bitsclice is from your first code if not needed away it goes.

net like this?
# gearbox signals
# gearbox Hi/Lo
net high-gear-signal => GB_2speed.0.gear-high  <=  hm2_7i76e.0.7i76.0.0.input-14

# Motor High
setp motor-high-signal <= GB_2speed.0.motor-high
net motor-high-signal => hm2_7i76e.0.7i76.0.0.output-10

# gearbox A - B - C - D - E
net input-a-signal => GB_2speed.0.gear-A  <=  hm2_7i76e.0.7i76.0.0.input-09
net input-b-signal => GB_2speed.0.gear-B  <=  hm2_7i76e.0.7i76.0.0.input-10
net input-c-signal => GB_2speed.0.gear-C  <=  hm2_7i76e.0.7i76.0.0.input-11
net input-d-signal => GB_2speed.0.gear-D  <=  hm2_7i76e.0.7i76.0.0.input-12
net input-e-signal => GB_2speed.0.gear-E  <=  hm2_7i76e.0.7i76.0.0.input-13

net m1 GB_2speed.0.message.1 => gear1.trigger
net m2 GB_2speed.0.message.2 => gear2.trigger
net m3 GB_2speed.0.message.3 => gear3.trigger
net m4 GB_2speed.0.message.4 => gear4.trigger
net m5 GB_2speed.0.message.5 => gear5.trigger
net m6 GB_2speed.0.message.6 => gear6.trigger
net m7 GB_2speed.0.message.7 => gear7.trigger
net m8 GB_2speed.0.message.8 => gear8.trigger
net m9 GB_2speed.0.message.9 => gear9.trigger
net m10 GB_2speed.0.message.10 => gear10.trigger
net m11 GB_2speed.0.message.11 => gear11.trigger
net m12 GB_2speed.0.message.12 => gear12.trigger
net m13 GB_2speed.0.message.13 => gear13.trigger

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

More
05 Sep 2018 13:33 #117098 by andypugh
Looks nearly right, except that thecomp expects motor-high to be an _input_ as I don't like the idea of the comp changing motor speed with the VFD powered up.
(This is something to look at later, it might be possible to have a VFD disable pin to make this not an issue)

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

More
05 Sep 2018 13:37 #117099 by tecno
OK, will go down and do a test now after finishing a cup of black coffee.

So none of these can be used to disable VFD?
# ---Setup spindle at speed signals via GB_2speed.comp---
sets spindle-at-speed true

setp hm2_7i76e.0.7i76.0.0.spinout-scalemax 2400
setp hm2_7i76e.0.7i76.0.0.spinout-maxlim 2500

net spindle-enable => GB_2speed.0.spindle-enable-in
net spinenable => GB_2speed.0.spindle-enable-out => hm2_7i76e.0.7i76.0.0.spinena

net spindle-vel-cmd-rpm-abs => GB_2speed.0.motor-speed-in

net spindlespeed <= GB_2speed.0.motor-speed-out => hm2_7i76e.0.7i76.0.0.spinout

net spindle-ccw hm2_7i76e.0.7i76.0.0.spindir

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

More
05 Sep 2018 13:50 #117100 by tecno
Hmmm

HAL: ERROR: function 'GB_2speed.0' not found
./GB_2speed.hal:42: addf failed

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

More
05 Sep 2018 13:55 #117101 by andypugh
What is it called?

One way to find out, open a terminal

halrun
loadrt GB_2speed
show funct
exit

Maybe you need addf GB-2speed.0 ?

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

More
05 Sep 2018 14:02 #117102 by tecno
Will go up and open file in notepad++, maybe wrong line ending?

bengt@CombiMll ~ $ halrun
halcmd: loadrt GB_2speed
Note: Using POSIX realtime
halcmd: show funct
Exported Functions:
Owner CodeAddr Arg FP Users Name
00006 7f96920120d0 7f96938480d8 YES 0 GB-2speed.0

halcmd: exit
Note: Using POSIX realtime
bengt@CombiMll ~ $

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

More
05 Sep 2018 14:04 #117103 by andypugh
No, it is just that you need hyphen rather than underscore in the function name.

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

Moderators: cmorley
Time to create page: 0.181 seconds
Powered by Kunena Forum