nanogui: problems reading the buttons on the helio in VR Linux


Previous by date: 29 Dec 2000 14:51:36 -0000 Re: [Handhelds] Microwindows touch screen driver, Jordan Crouse
Next by date: 29 Dec 2000 14:51:36 -0000 Re: Question about microwindow resolution, Jordan Crouse
Previous in thread: 29 Dec 2000 14:51:36 -0000 problems reading the buttons on the helio in VR Linux, Robert Hartley
Next in thread: 29 Dec 2000 14:51:36 -0000 Re: problems reading the buttons on the helio in VR Linux, Robert Hartley

Subject: Re: problems reading the buttons on the helio in VR Linux
From: Jordan Crouse ####@####.####
Date: 29 Dec 2000 14:51:36 -0000
Message-Id: <3A4CB450.1FF9AFC4@censoft.com>

Robert -

Toss in a perror() function when the open fails, which will report the
error that was passed back from open(). 
That will tell you right away whats wrong.  

Jordan

Robert Hartley wrote:
> 
> Hello,
> 
> I whipped up the attached test file to try reading the button keys on
> the Helio running VR Linux from TVT. (pocketlinux)
> 
> It keeps telling me that it cannot open the file /dev/r39xxbuttons
> 
> I tested the same file by creating a named pipe using mknod called
> /dev/r39xxbuttons on a standard RH v6.2 Intel system that worked.
> 
> What am I doing wrong?
> 
> (Is there already a process that has this file open?)
> 
> thanks for your help,
> 
> Robert
> 
> --
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
> =  Robert Hartley                 Mail:         201 Broadway        =
> =  Central Region Systems Engineer              Cambridge, MA 02139 =
> =  Integrated Computer            Email:        ####@####.####    =
> =  Solutions, Inc.                Web Site:     www.ics.com         =
> =  Tech Support: ####@####.####  Phone:        800-800-4271        =
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
> 
> Visit the MotifZone (www.motifzone.org) for info on Motif!
> 
>   ------------------------------------------------------------------------
> /*
> Simple button test program built with the following two lines:
> mipsel-linux-gcc -static helio-test.c -o helio-test
> mipsel-linux-strip helio-test
> */
> #include <stdio.h>
> #include <fcntl.h>
> 
> char *button_fn = "/dev/r39xxbuttons";
> char ch;
> 
> int main(int argc, char *argv[])
> {
> int fd = open(button_fn, O_RDONLY);
> 
>     if(fd == -1)
>     {
>         fprintf(stderr, "Unable to open file: %s\n", button_fn);
>         exit(0);
>     }
> 
>     while(read(fd, &ch, 1) > 0)
>     {
>         fprintf(stderr, "ch = %c = (int) %d\n", ch, (int) ch);
>     }
> 
>     close(fd);
>     fprintf(stderr, "Finished reading.\n");
> 
> } /* main() */
> 
>   ------------------------------------------------------------------------
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ####@####.####
> For additional commands, e-mail: ####@####.####

Previous by date: 29 Dec 2000 14:51:36 -0000 Re: [Handhelds] Microwindows touch screen driver, Jordan Crouse
Next by date: 29 Dec 2000 14:51:36 -0000 Re: Question about microwindow resolution, Jordan Crouse
Previous in thread: 29 Dec 2000 14:51:36 -0000 problems reading the buttons on the helio in VR Linux, Robert Hartley
Next in thread: 29 Dec 2000 14:51:36 -0000 Re: problems reading the buttons on the helio in VR Linux, Robert Hartley


Powered by ezmlm-browse 0.20.