Remora - ethernet NVEM / EC300 / EC500 cnc board

More
2 years 2 months ago #307649 by AlessandroEmm
Any idea about the pin out for spindle 0-10v output? PWM I noticed in your config/other pinouts but voltage based seems to be missing.

Thanks again
Alessandro

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

More
2 years 2 months ago #307652 by cakeslob
I dont have the hardware for the rt1052, but most units arent directly controlling an analog voltage, but rather sending a PWM to an opamp which makes 0-10v. When this is the case, the PWM signal is out of 100, so PWM 100 = 10v = max spindle speed. From the configs Ive seen for the RT1052 I will assume its the same, but I cannot find an example that says otherwise.
The following user(s) said Thank You: AlessandroEmm

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

More
2 years 2 months ago #307666 by AlessandroEmm
Can confirm this portion actually controlled voltage up to 10v on NVEMs (MX1052) output

net spindle-cw remora.output.09
loadrt pwmgen output_type=1
loadrt scale count=1
loadrt lowpass count=1
loadrt abs count=1
addf scale.0 servo-thread
addf lowpass.0 servo-thread
addf abs.0 servo-thread
setp scale.0.gain 0.00416666667
net spindle-cmd-rpm spindle.0.speed-out => scale.0.in
net spindle-cmd-rpm-abs scale.0.out => abs.0.in
net spindle-speed-DAC abs.0.out => remora.SP.0
net spindle-cw <= spindle.0.forward


 

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

More
2 years 2 months ago - 2 years 2 months ago #308238 by aDm1N
Hello

I have an NVEM v5. The stlink is to be delivered tomorrow. I think after everything I've read here, I'll be able to flash the firmware. I am currently building a small lathe into CNC. The spindle drive becomes an AC servo. I still have to see that I get it connected with step/dir, should be feasible. Then the machine gets another MPG, no problem either. But I still have an encoder only with a/b without index. Do I have any connections left for this? Does thread cutting work with it?

Encoder:
de.aliexpress.com/item/1005006363767037....gatewayAdapt=glo2deu

Servo:
de.aliexpress.com/item/1005006659782702....gatewayAdapt=glo2deu
 
Last edit: 2 years 2 months ago by aDm1N.

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

More
2 years 2 months ago - 2 years 2 months ago #308434 by cakeslob
Code:
// calculate the output value vel_cmd = pgain * error + data->cmd_d[i] * ff1gain;


Hey Scott, sorry to bother you with this, but can you explain this a bit more? Im wondering how we can just do a math to figure it out. Ive been bruteforcing pid stuff for a few days but i cant get my overshoot down to less than 5 steps, but this question comes up on discord a bunch also.

using a 1mm distance for the example to make it easier(?)

ff1 * cmd_d + error * pgain = velcmd

ff1 = number in ini file
cmd_d = old pos - new data? this is the D ?
error = ?
pgain = ini number

edit, holy shit it my issue was a typo this whole time.

my issue is typo related, but the question still stands, is there a math way to figure it out?
Last edit: 2 years 2 months ago by cakeslob.

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

More
2 years 2 months ago #308501 by scotta
Hi Cakeslob,

The stepgen "PID" was adopted from the PID component. There is some auto tuning code in there but I've not looked closely at it.

github.com/LinuxCNC/linuxcnc/blob/master...hal/components/pid.c
The following user(s) said Thank You: cakeslob

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

Time to create page: 0.855 seconds
Powered by Kunena Forum