Rod Maker - 5/24/2018 08:12 I have been contemplating a fuse/breaker when interfacing the outside world. Do you have any thoughts on that? It should all be high impedance but not sure. If you truly want it isolated use of an optocoupler in this situation would be of benefit. For what you are doing that would be a great option on the output. There are shields, breakout boards, etc. to fit those needs easily and for relatively low cost. High impedance works until you get static, stray voltage, etc. Then your $15 microcontroller is toast and potentially anything hooked up. An optocoupler could work on the input side depending on how your output of the weight sensor is designed. If it's a PWM out then you can take that and run it into the opto and get the same "signal" on the back side. The plus of this is if you have a 12v system on one side and 5 v on the other it will be roughly proportional. The ATMEGA328P has a 10 bit analog in so that's 0-1023. 5v= 1023 on the arduino side and if it's a 12v system on the other then 12v would equal 1023. I hope that makes sense?.? If the sensor is truly analog output or If you don't use an opto and choose to do it with resistors I would still highly suggest protecting the input pin of the arduino with a zener diode in the case of overvoltage. A 5.1v diode would be satisfactory. If the voltage exceeds 5.1v then it will "open up" and let current pass to ground. Or, you could drop a few bucks and purchase a device such as a ruggeduino that would have most of the protection built in. It sounded like you were going for a low cost route so if you could use an opto I would. |