On 09/23/2016 08:02 AM, Sag ich Dir nich wrote:
while i read myself into creating python components, do you mean i
should put the resistor between the FET + output (which is going into
the pwm pin on the motor controller) and the extruder power input (p405)?

Generally, there are two types of outputs. One is called "open collector", the other "totem pole".

The output pin for an open collector goes to the collector of a transistor which is setup to pull the pin to ground.
https://en.wikipedia.org/wiki/Open_collector#MOSFET

The output has no built in power source that can drive the pin to a high state. On the other end the input generally has a high impedance, meaning it can only look at the state of the signal and not affect it. So far with this setup there is nothing that can bring the signal up to 5V or 3.3V or whatever. Adding a resistor between the signal line and a supply will pull the signal up to the supply voltage, then it up up to the output pin to pull the signal down overriding the pull up. Basically you are shorting the resistor to ground. The amount of current going through the resistor depends on the supply voltage and the value of the resistor.
V = I R, I = V/R, R = V/I
https://en.wikipedia.org/wiki/Pull-up_resistor


One problem is that the transistor in the output circuit can not tolerate much current. Many outputs are only good for a few milliamps. I think the BB outputs are usually good for 24ma. With that in mind:
R = V/I = 5/.024 = 208 Ohms

Anything greater than 208 Ohms should keep the transistor safe. The power supply will a maximum current rating too, but generally that is much higher.

Another consideration is that the high impedance input has some capacitance, which for a very short time is really a low impedance. The amount of time it takes to fill the capacitance and allow the signal to come up depends on the amount of current available from the pull up resistor. If the resistor has a very high value it may take too long for the signal to come up after the open collector output switches off.

So the pull up resistor needs to be greater than 208 Ohms to protect the output, but low enough to allow the signal to change quickly enough for the application.

Another common input type is an opto-isolator which has an LED input.
https://en.wikipedia.org/wiki/LED_circuit
https://en.wikipedia.org/wiki/Opto-isolator

The pull up needs to be low enough to turn the LED fully on. The often need about 3ma to turn on, but can not tolerate more than 20 or 30ma.
R = 5/.020 = 250 Ohms
R = 5/.003 = 1.6k Ohms

So any value between 250 and 1.6k should be appropriate.

In practice, there may be other components attached to the signal, so these will need to be considered. You may want a pull up resistor sized to protect the open collector output, then have a separate current limit resistor in series with the opto input that protects the LED. Often there is a regular LED in series with the opto input as an indicator, plus another regular diode in series to protect the opto from reverse voltages that can come about on long noisy cabling. The voltage drop across these series components will need to be subtracted from the supply voltage in order to do the calculations for the pull up or current limit resistance values.

It all depends on the components and design of the application.


--
Kirk Wallace
http://www.wallacecompany.com/machine_shop/
http://www.wallacecompany.com/E45/

--
website: http://www.machinekit.io blog: http://blog.machinekit.io github: 
https://github.com/machinekit
--- You received this message because you are subscribed to the Google Groups "Machinekit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to machinekit+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/machinekit.
For more options, visit https://groups.google.com/d/optout.

Reply via email to