PnCConf with RPI 4 and Mesa 7C81

  • smogol
  • smogol's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
17 Nov 2020 20:30 #189615 by smogol
PnCConf with RPI 4 and Mesa 7C81 was created by smogol
Hello every one,
I am quite new with LinuxCNC, I managed once to setup linuxcnc 2.5.5 on an old PC running ubuntu 10.04 with a parallel port.
My goal is to replace this old lady with a raspberry pi 4 and a MESA 7C81.
Until now, the installation of linucCNC was a success thank to the post :
forum.linuxcnc.org/9-installing-linuxcnc...it-linuxcnc?start=10

I also could manage to compile the mesaflash and can "talk" to the 7C81 over the command:
mesaflash --spi --addr /dev/spidev0.0 --device 7c81 --readhmid

My next step is to configure the MESA 7C81 over th PnCConf utility.
Unfortunately, I'm blocked with the warning "You have no hostmot2 firmware downloaded in folder:
/lib/firmware/hm2/"

I guess I have to install hostmot2, in some sort, but I don't find any further information.

Any help is welcome
Best regards

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

More
17 Nov 2020 20:50 #189620 by tommylight
Replied by tommylight on topic PnCConf with RPI 4 and Mesa 7C81


My next step is to configure the MESA 7C81 over th PnCConf utility.
Unfortunately, I'm blocked with the warning "You have no hostmot2 firmware downloaded in folder:
/lib/firmware/hm2/"

That is pertaining to firmware for some other/older Mesa boards that required uploading the firmware at LinuxCNC start, new ones have that on board so you can safely ignore that and move on.

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

More
18 Nov 2020 13:11 #189658 by andypugh
Replied by andypugh on topic PnCConf with RPI 4 and Mesa 7C81
If it refuses to continue without the firmware package:

sudo apt-get install hostmot2-firmware

Though I am not 100% sure that PnCConf knows about the 7C81.

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

More
18 Nov 2020 13:31 - 18 Nov 2020 19:39 #189661 by PCW
Replied by PCW on topic PnCConf with RPI 4 and Mesa 7C81
PNCConf does not support the 7C81.
The easiest path to creating a working hal/ini file for the 7C81 is probably:

1. Run pncconf and select 5I25/G540 firmware
2. Edit the created hal file and replace hm2_pci with hm2_rpspi
3. Replace all instances of "5i25" in the hal/ini files with "7c81" **
4. GPIO used for inputs and outputs will need to be hand edited in the hal file.

** if you select "Use INI substitution for Mesa board names." in pncconf
there will be just on instance of the board name in the ini file. If you do not
select this option, the board name will appear throughout the main hal file.
Last edit: 18 Nov 2020 19:39 by PCW.
The following user(s) said Thank You: smogol

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

More
18 Nov 2020 13:32 - 18 Nov 2020 14:11 #189662 by PCW
Replied by PCW on topic PnCConf with RPI 4 and Mesa 7C81
Sorry for double post...
Last edit: 18 Nov 2020 14:11 by PCW.

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

  • smogol
  • smogol's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
18 Nov 2020 19:36 #189716 by smogol
Replied by smogol on topic PnCConf with RPI 4 and Mesa 7C81
Thanks andypugh for your advice,
unfortunately, the RPI 4 does not have this package.

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

  • smogol
  • smogol's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
18 Nov 2020 20:11 #189721 by smogol
Replied by smogol on topic PnCConf with RPI 4 and Mesa 7C81
Thanks PCW,
I'll give it a try and get back with the results:
BTW: when I run the mesafirmware command, I get the following configuration :
unable to set bpw32, fallback to bpw8  <-- this is ok, found a post covering it..... :-)
Configuration Name: HOSTMOT2 
My need is to hook my Chinese CNC. I downloaded the configs from the MESA site. Is there a better configuration to apply?
This is my actual DB25 pinout for my machine (extract out of my working .hal file):
net estop-out => parport.0.pin-01-out
net ystep => parport.0.pin-02-out
setp parport.0.pin-02-out-reset 1
net ydir => parport.0.pin-03-out
net xstep => parport.0.pin-04-out
setp parport.0.pin-04-out-reset 1
setp parport.0.pin-05-out-invert 1
net xdir => parport.0.pin-05-out
net zstep => parport.0.pin-06-out
setp parport.0.pin-06-out-reset 1
net zdir => parport.0.pin-07-out
net astep => parport.0.pin-08-out
setp parport.0.pin-08-out-reset 1
net adir => parport.0.pin-09-out
net xenable => parport.0.pin-14-out
net xenable => parport.0.pin-16-out
net xenable => parport.0.pin-17-out

net all-limit-home <= parport.0.pin-11-in-not
net probe-in <= parport.0.pin-15-in-not

I am aware that I need to read and understand the documentation ;-) but a little help from the community will surely help me to get quickly to a running system and then I can enhance it in a second step.

Regards

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

More
18 Nov 2020 20:48 #189726 by PCW
Replied by PCW on topic PnCConf with RPI 4 and Mesa 7C81
Look like the 7C81 G540 or 5ABOB configs are close
You have X,Y swapped from the normal pins, but if you
assign XYZ stepgens in pncconf:
0 Y
1 X
2 Z
pncconf will create the correct hal connections

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

  • smogol
  • smogol's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
22 Nov 2020 10:40 - 22 Nov 2020 10:41 #190033 by smogol
Replied by smogol on topic [SOLVED] PnCConf with RPI 4 and Mesa 7C81
I followed the instructions as mentioned in the upper post from PCW, renaming manually the reference to 7C81 and hm2_rspi and that worked well.
I can use the PnCConf to re-edit some gpios and redo the replacements.
My next step is to configure my HB04 to my rasberry pi as I could notice that the configuration has changed slignthly from the older version.

Change the subject ot solved
Last edit: 22 Nov 2020 10:41 by smogol.

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

More
21 Dec 2023 06:47 - 21 Dec 2023 06:55 #288733 by Mehta_123
Replied by Mehta_123 on topic PnCConf with RPI 4 and Mesa 7C81
how to hand edit input output (GPIO) in hal and ini? 
please give me one example.
Thanks!!!!!
Last edit: 21 Dec 2023 06:55 by Mehta_123.

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

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