DRO values not zero on startup

More
14 Sep 2013 05:22 #38805 by spangledboy
Ok. It's taken me a while, but I think I've found the source of the problem:

In the .hal file for each axis there is a statement similar to the following:

net x-pos-rawcounts <= hm2_5i25.0.encoder.00.rawcounts

I can see that it's taking the raw encoder counts from the MESA card and sending that to a signal called X-pos-rawcounts, which is fair enough. However, I don't know what it's actually intended for, if anything other than diagnosing the hardware using Halscope etc.

Can anyone shed any light on why that command might be causing my DROs to start up with odd values? When I comment out the commands, they start at zero. I haven't tried running the machine yet so I don't know if there are any other side effects - they were created by PcCConf originally, so I don't know what their purpose is.

Thanks

Ben

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

More
14 Sep 2013 10:33 #38811 by PCW
Replied by PCW on topic DRO values not zero on startup
Can you post your hal file here to see where net x-pos-rawcounts is used?

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

More
14 Sep 2013 15:21 #38816 by spangledboy
Sure, the command is in there for each axis - I can't find any other reference to x-pos-rawcounts in the hal file though.

Thanks

Ben
Attachments:

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

More
14 Sep 2013 21:40 - 14 Sep 2013 22:28 #38821 by PCW
Replied by PCW on topic DRO values not zero on startup
If they are not connected, it may be a hm2 driver / linuxcnc / hal
bug of some kind

It is a pretty strange configuration, using both a 7I76 and a 7I77

Can you add some signals to some encoder rawcounts pins in the
hm2-sample config to see if this is a driver or hal bug?

A side issue is that the config line is rather suboptimal as well, enabling lots
hardware that is unused (the 5 unused stepgens, 7 encoder counters with only 4 used).
This should not cause a problem but will waste CPU I/O cycles.

Also with a 7I76/7I77 its better to use the 7I76/7I77s built in MPG support
than a normal encoder especially if you have a 100 count MPG Since the normal
encoder input does not support a 1X mode
Last edit: 14 Sep 2013 22:28 by PCW.

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

More
14 Sep 2013 23:46 #38824 by spangledboy
I tried entering the line into the sample config that you provided and yes, the problem happens there too. It doesn't matter what the name of the signal is, if I link a signal to the rawcounts output , the DRO is messed up on startup.

Agreed, I have an unusual setup - I only have the 7i76 in there due to my lack of understanding of all the machine control concepts when I was starting out and the encoder on it proved useful for the MPG. I have a plan to add rotary encoders for each axis to improve the machines accuracy, which would use the remaining three encoders on the 7i77, so I decided to use the additional encoder on the 7i76.

I will modify the config line - it was created by PnCConf and I only really noticed what it was doing when I went through the HAL and ini files in more detail looking for this problem last night.

How is the MPG connection configured using the built in support? I see it mentioned on your website, but can't find anything about it in the manual. If I can get things configured correctly and take the 7i76 out of this machine then I may well use it in something else in future.

In case you hadn't noticed, this is still very much a work in progress, with me gradually climbing the learning curve!

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

More
14 Sep 2013 23:57 #38825 by spangledboy
Ah - I've just taken a look at the latest version of the manual and found the part about the MPG connection - it's not in the version of the manual I was using.

Is this a new feature of the 7i77/7i76 - was it there all the time, or is it enabled with a firmware update?

Thanks

Ben

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

More
15 Sep 2013 00:44 - 15 Sep 2013 00:53 #38826 by PCW
Replied by PCW on topic DRO values not zero on startup
Its relatively new (say last year or so)
It needs to be enabled by setting the sserial mode
to the mode listed in the manual
Last edit: 15 Sep 2013 00:53 by PCW.

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

More
15 Sep 2013 00:56 #38827 by spangledboy
Yes, I see that it has to be in Mode 3 - is this supported on my older 7i77, as the older manual (v1.5) only list modes 0-2?

Ben

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

More
15 Sep 2013 01:11 - 15 Sep 2013 01:12 #38829 by PCW
Replied by PCW on topic DRO values not zero on startup
Not sure. With linuxcnc 2.5.x you would just have to try.
If you run LinuxCNC master, it will display all the available
modes in the kernel log (dmesg)

I should add that with master, you can upgrade the sserial remote
firmware to the latest
Last edit: 15 Sep 2013 01:12 by PCW.

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

More
15 Sep 2013 01:48 #38832 by spangledboy
Ah - now that sounds useful - especially as I already have Master installed for testing with Gmoccapy.

Could you point me in the right direction for the instructions on how to set the sserial mode and how to update the firmware?

Thanks

Ben

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

Time to create page: 0.208 seconds
Powered by Kunena Forum