I can email you the project if you are interested in seeing my approach. I do not have the time to do this testing (nor the variety of crystals).
ONE WIRE LIBRARY SERIAL
While I can measure the latencies of pin changes, I am not sure that my scale factors would be suffuciently accurate without testing on a LARGE number of different speeds. The 1-wire bus is a serial bus that uses just a single wire for communication (in addition to wires for ground and power). Device Description D:UsersXXXDocumentsArduinolibrariesOneWireutil/. The diode used in the simplified version should be fast and has a low forwarding voltage. Resistors can vary from 200ohm to 20kohm. My goal had been to write code that is able to adjust the delays so that you can change the crystal to a higher/lower speed and still have the same timing. Created 3 months ago in PaulStoffregen/OneWire with 2 comments. This project is based on Maxim’s application note: Using a UART to Implement a 1-Wire Bus Master. This translation will change the timing in small but significant ways sufficiently that I do not think it will be all that useful for you. I have some low level code that I wrote for the OM128, which uses some device specific code to reference the physical pins by location rather than AVR port/pin. Then if you have an oscilloscope available, watch the high and low signals as you repetetively read and write bits and bytes. I then timed the number of clocks between high and low signals, and start and end points. (Inherited from Object. Equals(Object) Determines whether the specified Object is equal to the current Object. Methods Name Description AcquireEx: Attempts to acquire the OneWire net. Constructors Name Description OneWire: Initializes a new instance of the OneWire class. I took a shot at writing the code, then ran it in simulator with a timer running (acting like a stopwatch). The OneWire type exposes the following members. Youll have to scroll down a bit to find the right one.
ONE WIRE LIBRARY INSTALL
Open up the Arduino library manager Search for the OneWire library and install it. Most of the timing is reasonably flexible, but one of them needs to be rather precise. You can download the OneWire library from the Arduino library manager. I went back to the Dallas example and then wrote my own. I had looked around and found several sources of code, but all of them did not suit me.