esp32-owb icon indicating copy to clipboard operation
esp32-owb copied to clipboard

RMT "Write 1" LOW duration too short

Open alemariusnexus opened this issue 2 years ago • 1 comments

I'm currently writing a bit-banged 1-Wire slave for PIC16/18, which forces me to look pretty closely at some of the 1-Wire timing. With esp32-owb as the master, the LOW pulse for a "write 1" is a bit short, which makes my slave not recognize it. This is what the code says:

https://github.com/DavidAntliff/esp32-owb/blob/60d977e7031f3fcb3900bce4f88befb159bfef4f/owb_rmt.c#L73

As far as I understand, 2us is actually too short. The Maxim guide recommends 6us (parameter A in the second table), and the worksheet below that table gives 5us as a minimum with default parameters.

While 2us seem to work with the official 1-Wire devices I have, I think it's better to use 6us (which is what the GPIO driver already does, btw) to comply with "the standard".

alemariusnexus avatar Mar 30 '22 02:03 alemariusnexus

Thanks for the feedback, seems like a good suggestion. I'll keep this issue open until I have time to look at it properly.

DavidAntliff avatar Mar 31 '22 01:03 DavidAntliff