Hello, I'm trying to set timeout_presence from the startup script (owserver.service) by passing it the argument --timeout_presence=2, but this is not taken into account and the default presence timeout of 120 seconds remains.
Is there any special precaution to be taken for this parameter?
Best Regards,
Benoît.
Please read /uncached instead of / to bypass the cache. This is much better than tweaking global settings. Please also note devices keep being accessible even when the timeout hits. You don't need to list them first.
View and moderate all "support-requests Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Support Requests (dead)"
Thanks for your reply. Actually, I'm using several EEPROM components (DS2431+) on the same bus and the presence/present function still shows them even if they are not on the bus anymore. I just wanted to shorten the delay of 120 seconds for my application, down to 10 or 5 seconds, which would be much more acceptable for our customer.
Which is the "present/presence" function for you? The .../present node in the device's directory? Forget about that, it doesn't work as people expect it to do and we have to leave it the old "broken" way for legacy applications. It's deprecated. If you have to test whether a known chip is present, read one of its values from /uncached/<chip.id>/<node>. That way OWFS tries to read from the chip, without consulting the cache (but updating it if the read succeeds). If the chip isn't on one of the the buses any more, you get an error message.
View and moderate all "support-requests Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Support Requests (dead)"
Got it. The 'present' function I was refering to is the one used by owpresent for example (from package ow-shell). I suppose it is also the function
int OW_present( const char * path )
from owcapi (See http://owfs.org/uploads/owcapi.1.html#sect10 )I'll code my application as you suggest and will report here about the result. Thanks for your help!
That one is even more tricky. It tries to find out the presence by accessing checking the cache with FS_parsedname(). That's stuff Paul Alfille did in his booth a long time ago. May or may not work.
View and moderate all "support-requests Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Support Requests (dead)"
I have nearly finished my application (Raspberry Pi-based SCADA gateway Modbus/TCP to 1-Wire EEPROMs), it works like a charm. Thanks for your support.