Updating pncconf for 7i95t

  • bigmactx
  • bigmactx's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
13 Apr 2025 00:13 #326201 by bigmactx
Updating pncconf for 7i95t was created by bigmactx
Sorry so slow but massive interruptions and a few train wrecks to clean up...

I have the 7i95t working completly now and would like to share what I've learned about getting this board to work with linuxcnc 2.10pre. MesaCT tool 2.1.7 doesn't currently support the 7i95t and neither does pncconf as compilied with 2.10pre however using the information in the file Under ADDING_A_MESA_CARD.md along with lots of searching and some trial and error I managed to create a good working entry for the private_data.py file. Pnccconf can now use this information to create a working configuration. I've attached this information in "pncconf for 7i95t".

I didn't include the P1 expansion connector as the 7i95t has sufficient resources for all my needs. It would be very easy to add however if you need it.

Now when you run pncconf you can select the 7i95t and properly configure it as required however the ~/linuxcnc/configs/<config name>.hal file needs a minor tweak before linuxcnc can use it. It seems pncconf translates inmux to inm and that needs to be fixed (thanks to user merongi on the forum). To do this I simply created a one line script since this must be fixed everytime you run pncconf. Basicly you need:
sed -i 's/inm.00/inmux.00/g' ~/linuxcnc/configs/<config name>/<config name>.hal 

Now you can run linuxcnc.

I also wanted to add a joystick for X & Y axis that will provide the same function as the Up/Down. Left/Right arrow keys of the keyboard. While HAL overall and creating the necessary entries is well documented finding the right inputs took me a lot of study/trial and error with halshow to find the right signals. First assign inputs to each switch using the drop down selection Axis Rapid -> Jog xx in pncconf as appropriate. Pncconf will create the necessary entry in your <config name>.hal. To connect these inputs you need to map them appropriately. Here's the custom.hal contents I created to accomplish this (this implies X is joint 0 and Y is 1):

setp halui.joint.jog-speed 6500
net jog-x-neg => halui.joint.0.minus
net jog-x-pos => halui.joint.0.plus
net jog-y-neg => halui.joint.1.minus
net jog-y-pos => halui.joint.1.plus

The last item I spent time on was getting clarity on proper setup to eliminate Following Errors. Following some comments from andypugh and PCW I was able to clean this up. Here's a quick recap of the knowlege shared:
base period max velocity > stepgen max velocity > machine max velocity
Each step requires headroom (say 5-25% each)

My interpertation is in the Screen section of pncconf you set Min linear velocity and Max linear velocity. They become in the <config name>.ini file:
[TRAJ]
...
DEFAULT_LINEAR_VELOCITY = xx
MAX_LINEAR_VELOCITY = xx        which is machine max velocity in the equation above

Under each Axis you set Max Velocity which becomes MAX_VELOCITY in the <config name>.ini file. STEPGEN_MAXVEL is automatically calculated by pncconf at 125% of the MAX_VELOCITY (which is required also).

If I'm correct, the base period max velocity can be computed by ACTUAL SERVO PERIOD / highest STEPGEN_MAXVEL used by any motor. You need to allow head room here so I multiply it by 0.75.

Now you have all three components which allows you to avoid following errors, or at least it works for me. While not clearly stated, the max jitter value could also be a factor. If it's excessively high you will likely need more than 25% headroom.

Comments and corrections always welcome.

Mike
Attachments:

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

More
13 Apr 2025 00:34 #326203 by PCW
Replied by PCW on topic Updating pncconf for 7i95t
A couple of comments

There is no base period.

The maximum velocity is not dependent on the servo thread period.

You should get no latency dependent following errors unless"

1. The latency is so bad that a whole servo cycle is skipped

2. The DPLL does not have enough headroom to account for
linux's baseline timing drift (fix by setting the timer to a larger
negative number say -200)

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

Time to create page: 0.290 seconds
Powered by Kunena Forum