Precix CNC Router that has the Sensoray 626 pci card and pwm Servos need help

More
8 years 10 months ago #103192 by EMFab01
The cnc router works and I have used the 626 demo program to find out the inputs for the encoders and the limit switch's. I just really don't know how to do the programming from the linuxcnc to the pci card.

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

More
8 years 10 months ago #103202 by andypugh
You need a HAL driver.

This is one that I wrote for a vaguely similar card:
github.com/LinuxCNC/linuxcnc/blob/master.../drivers/pcl720.comp

If you look through it (ignore the "reset" function for now) You will see a header block that defines the HAL pins, and then, written in C, a "read" and a "write" function that convert HAL signals into register values abd vice/versa and then send/get them with inb() and outb() instructions.

You would need something very similar, but would need a bit more complexity to set up the PWM signals (which I assume are generated on the board?)
The following user(s) said Thank You: EMFab01

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

More
8 years 10 months ago #103419 by mcheffe
I took a look at the pcl720.comp file to try and see how to adapt this to the Sensoray 626 card mentioned by EMFab01. This .comp file appears to be a mix of C code and other declarations used by Linuxcnc to figure out how to talk to the hardware. Is there some documentation somewhere that explains the syntax used in the .comp file? Specifically, the definition of the pins vs usage of the pins in the C read/write functions?

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

More
More
8 years 10 months ago #103906 by EMFab01
what do you do if you can't get the "base address" of the 626 card?

router@Router:~$ lspci -v -b -d 1131:7146
01:02.0 Multimedia controller: Philips Semiconductors SAA7146 (rev 01)
Subsystem: Device 6000:0272
Flags: bus master, medium devsel, latency 32, IRQ 3
Memory at f7c00000 (32-bit, non-prefetchable)
Kernel driver in use: S626

router@Router:~$

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

More
8 years 9 months ago #103973 by andypugh
You seem to have a driver loaded. Do you know anything about that?

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

Time to create page: 0.066 seconds
Powered by Kunena Forum