Page 1 of 1

Analog out for spindle speed control missing??

PostPosted: Tue Oct 04, 2016 2:07 am
by 1JUMPER10
Hello -

I am using a UC 400ETH and I was reading the software installation and user guide (manual version 1.0030) and under the IO set up tab it has settings for 2 Analog input Channels and 2, analog out channels. I am specifically interested in the Spindle PWM -> analog channel option. The manual says this "attaches the PWM spindle control PWM to the analog output." My spindle wants a 0-10v signal for speed control and this would work perfectly. However, in the current version of the software 1.2024, these options aren't there. Are they gone for good? Can they be unlocked? If not, can you recommend a capacitor and resistor value and a PWM frequency to convert the PWM signal to a 0-10v input for my spindle? Thank you.

Re: Analog out for spindle speed control missing??

PostPosted: Tue Oct 04, 2016 3:01 am
by cncdrive
The UC400ETH hardware does not have any analog output channels, this is why there is no analog option for it in the UCCNC.
The only controllers which have analog outputs and analog inputs are the UC300 and UC300ETH and the UCCNC has analog settings for them.

You can't convert a TTL 0/5V digital signal to 0-10Volts with resistors and capacitors.
What you can do with resistors and capacitors is you can low pass filter the signal to smooth the PWM out to an analog signal, but the signal range will be still 0-5Volts.

How you can convert a 0-5V signal to 0-10V is to gain the signal and for that you could do one of the followings:

1.) Use an operational amplifier circuit, e.g. in the non-inverting configuration: http://www.electronics-tutorials.ws/opamp/opamp_3.html
2.) Use an optocoupler with Open-collector output and pull the output above 10Volts, so the output PWM amplitude will be that power supply voltage.
3.) Use a transistor or mosfet to amplify the PWM.
4.) You can use a breakout board which has one of these circuits built in.
5.) Most VFDs have settings option to accept 0/5Volts input voltage range instead of the default 0/10Volts, it is just setting a register if it has this setting.

Re: Analog out for spindle speed control missing??

PostPosted: Tue Oct 04, 2016 3:24 am
by 1JUMPER10
No analog outputs on the UC400 ETH??? Well, thats unfortunate. But thank you for the helpful suggestions. My VFD can be set to use a 0-5v input but a 10v range would be better I think.

One other question. Can the UC400ETH accept a 24v signal as an input? I wanted to power my limit sensors with my 24v source but this will feed 24v directly into the board input all the time since its a NC proximity sensor. I've ordered a converter to drop the sensor voltage to 5v. But I thought I'd ask if the UC400 ETH board can tolerate a 24v input voltage.

Re: Analog out for spindle speed control missing??

PostPosted: Tue Oct 04, 2016 11:01 am
by ger21
1JUMPER10 wrote:
One other question. Can the UC400ETH accept a 24v signal as an input?


You can use a breakout board like the CNC4PC C62, which can use 24V inputs, and also provides the 0-10V spindle control you want. Not cheap, though.

Re: Analog out for spindle speed control missing??

PostPosted: Tue Oct 04, 2016 2:04 pm
by 1JUMPER10

Re: Analog out for spindle speed control missing??

PostPosted: Thu Oct 06, 2016 7:30 am
by cncdrive
1JUMPER10 wrote:No analog outputs on the UC400 ETH??? Well, thats unfortunate. But thank you for the helpful suggestions. My VFD can be set to use a 0-5v input but a 10v range would be better I think.

One other question. Can the UC400ETH accept a 24v signal as an input? I wanted to power my limit sensors with my 24v source but this will feed 24v directly into the board input all the time since its a NC proximity sensor. I've ordered a converter to drop the sensor voltage to 5v. But I thought I'd ask if the UC400 ETH board can tolerate a 24v input voltage.


No, it can't accept 24Volts on the inputs. The UC400ETH inputs should be treated like if they were inputs in a printer (LPT) port.
The easiest converter for a 24Volts signal is an optocoupler which contains an LED and a photo transistor in a single plastic package packed as an IC.
You can drive the LED of the optocoupler with virtually any Voltage above the LEDs forward voltage (1.5-2Volts), because the LED is a current driven device you have to use a series resistor to control the current to a safe level which the LED can dissipate without overheating. For different Voltages the required resistor value is different, but one resistor value can work for a relativley wide range of voltages.
To select the series resistor you can calculate the input current to the LED to be 5-10mAmps (Depends on the otocoupler model) at the voltage you use for input.

The output of the optocoupler is mostly a photo-transistor with the emitter and collector wired out. You can connect the emitter to the UC400ETH ground and the collector to the input pin of the device.
Since the UC400ETH inputs have the pullup resistors installed you do not need to add anything else, this simple connection will work.

Breakout boards mostly using the same technic to isolate the input signals and to allow a range of input voltages not only TTL levels.