(I accidentally sent this from the wrong address the first time, and now I'm
re-sending it from the address that's actually subscribed to this list. My
apologies if it ends up going out to the list twice anyway.)
Hi Paul,
I've taken another look at it and it seems like the write actually is
working. Before, I had an Arduino sketch loaded that was also poking at the
DS2404. Now, with a different sketch that doesn't touch the DS2404, writing
via owfs seems to work.
The reading is still not quite right... a read of any page shows that page
and everything after it, and then some garbage beyond the last page.
Here's what I did, and what I got back from it:
I wrote "1234567890123456789012345678901" to each page (0-15).
When I cat page.0 I see all 16 copies of that string, followed by what is
probably the 30 timekeeping registers, followed by all FF bytes, for a total
of 4096 bytes returned.
When I cat page.15 I see 1 copy of that string, followed by the 30
timekeeping registers, followed by all FF bytes, again for a total of 4096
bytes.
page.ALL seems to work... I see all 16 pages and nothing more.
When I cat "memory" I see the same behavior as with page.0.
I'll be using owperl eventually, so I guess I should be all set with reading
ranges or individual bytes of memory.
Let me know if you want me to try out a fix.
Thanks
-Ben
On Wed, Sep 24, 2008 at 5:05 PM, Paul Alfille <[EMAIL PROTECTED]>wrote:
> The DS2404 has never really been tested. I'll work with you to see if we
> can make it work.
>
> As for accessing just parts of memory, it's not really possible via the
> shell. The underlying libow API supports writes (and reads) with offsets and
> a length. owcapi supports this. owperl supports this.
>
> Paul Alfille
>
> On Wed, Sep 24, 2008 at 4:57 PM, Ben Griffith <[EMAIL PROTECTED]>wrote:
>
>> Hi,
>>
>> I've got a few DS2404 chips and I'm playing around with them and an
>> Arduino. I've got the Arduino connected to the 3-wire port and my laptop
>> connected via a USB dongle to the 1-wire port. The DS2404 is getting +5V
>> and ground from the Arduino board. My laptop is running Gentoo with owfs
>> 2.7-p4. For starters I'd like to just write to memory via one port and see
>> the result via the other. I'm having trouble writing to memory via owfs and
>> seeing the result also via owfs. I've never played around with a 1-wire
>> memory device before, only temperature and switch devices, so maybe I'm
>> doing something wrong. I tried "cat pages/page.0" and get what seems like a
>> whole lot more than 32 bytes worth of garbage characters. If I then "echo
>> 1234567890 > pages/page.0" and do "cat pages/page.0" again I get the
>> expected (to me anyway) "1234567890". But then if I cat the same thing
>> again a minute later it's back to the same garbage characters as before.
>> I'm guessing that the 1234567890 I see is just cached from the attempted
>> write.
>>
>> Also, it looks like the only way to access the memory is a page at a time
>> or all at once. Is there any way to access a byte at a time, or a range of
>> bytes other than a whole page?
>>
>> Has anyone else tried using this device? I know it's been discontinued by
>> Maxim, but I have a few I'd like to try out in a project.
>>
>> Thanks,
>> Ben
>>
>> -------------------------------------------------------------------------
>> This SF.Net email is sponsored by the Moblin Your Move Developer's
>> challenge
>> Build the coolest Linux based applications with Moblin SDK & win great
>> prizes
>> Grand prize is a trip for two to an Open Source event anywhere in the
>> world
>> http://moblin-contest.org/redirect.php?banner_id=100&url=/
>> _______________________________________________
>> Owfs-developers mailing list
>> Owfs-developers@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>>
>>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Owfs-developers mailing list
> Owfs-developers@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>
>
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Owfs-developers mailing list
Owfs-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/owfs-developers