[En-Nut-Discussion] PHAT example code ?

Kroum Vassilev vassilev at itln.de
Wed Jan 25 08:20:49 CET 2006


Yes, there is.
please check the app ftpdphat!

Alex


Jesper Hansen wrote:

> Does any testcode or examples for the PHAT filesystem and MMC
> on the Nut 3.0d exist ?
> I've spent hours here to try get it working without any luck.
>
> The MMC seems to be okay, card status is alive, but I can't
> get it to speak with PHAT.
> The documentation is not very clear on this, even contradicting
> in a few places.
>
>
> Here's my simple test code snippet :
>
>
> NutRegisterDevice(&devNplMmc0, 0, 0);
> NutRegisterDevice(&devPhat0, 0, 0);
> _open("MMC0:", _O_RDWR | _O_BINARY);
> {
>     DIR *d = opendir("/");
>     if (d == NULL) {
>         printf("failed to open dir\n");
>     }else {
>         struct dirent* ent;
>         while ((ent = readdir(d)) != NULL) {
>             printf("%s\n",ent->d_name);
>         }
>         printf("done\n");
>     }
> }
>
> But this always fail to open the directory.
>
>
> /Jesper
>
> _______________________________________________
> En-Nut-Discussion mailing list
> En-Nut-Discussion at egnite.de
> http://www.egnite.de/mailman/listinfo.cgi/en-nut-discussion
>



More information about the En-Nut-Discussion mailing list