ts-7000
[Top] [All Lists]

[ts-7000] Re: Webserver access to /dev/mem

To:
Subject: [ts-7000] Re: Webserver access to /dev/mem
From: "Keith Gilman" <>
Date: Wed, 05 Oct 2005 01:46:04 -0000
It is actually the httpd running the script as a cgi task which is 
running as nobody. I'm pretty sure this is not the best way to do 
this but I need to do more research to determine the best way. I was 
just anxious to get the server up and doing something "interesting".

Thanks
-Keith


--- In  Andrew Bealing <> wrote:
> Is your app running as root?  I think it needs to be to have 
O_RDWR access
> to the memory space.
> 
> 
> 
>                                                                    
                                                                     
       
>                       "Keith 
Gilman"                                                              
                                             
>                       <        To:       ts-
                                                 
              
>                       o.com>                   
cc:                                                                  
                           
>                       Sent by:                 Subject:  [ts-7000] 
Webserver access 
to /dev/mem                                                
>                       ts-
                                                       
                                                 
>                       
ps.com                                                               
                                                    
>                                                                    
                                                                     
       
>                                                                    
                                                                     
       
>                       04/10/2005 
05:27                                                                
                                         
>                       
p.m.                                                                 
                                                    
>                       Please respond 
to                                                                   
                                     
>                       ts-
7000                                                                 
                                                 
>                                                                    
                                                                     
       
>                                                                    
                                                                     
       
> 
> 
> 
> 
> Newbie to Linux trying to set up a webserver with the TS7250. I 
have
> the server up but I want to be able to read the onboard 
temperature.
> I'm using the test-cgi script that shipped with the board with the
> following two lines added:
> 
> echo UPTIME=`uptime`
> echo TEMP=`./tempSensor' #tempSensor.c downloaded from the TS 
website
> 
> The uptime works as expected but the tempSensor logs the following
> error to the apache error logger:
> 
> tempSensor.c:42 main:Assertion 'fd != -1' failed.
> 
> The source is:
> 
>              int fd = open("/dev/mem", O_RDWR);
>              assert(fd != -1);
> 
> Thanks in advance for any advice
> -Keith
> 
> 
> 
> 
> 
> 
> 
> 
> 
> Yahoo! Groups Links
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
#####################################################################
######
> This e-mail is confidential and may contain information subject to 
legal 
> privilege.  If you are not the intended recipient please advise us 
of our
> error by return e-mail then delete this e-mail and any attached 
files.  
> You may not copy, disclose or use the contents in any way.  
> 
> The views expressed in this e-mail may not be those of Gallagher 
Group 
> Ltd or subsidiary companies thereof.
> 
#####################################################################
######








------------------------ Yahoo! Groups Sponsor --------------------~--> 
Most low income households are not online. Help bridge the digital divide today!
http://us.click.yahoo.com/cd_AJB/QnQLAA/TtwFAA/CFFolB/TM
--------------------------------------------------------------------~-> 

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ts-7000/

<*> To unsubscribe from this group, send an email to:
    

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


<Prev in Thread] Current Thread [Next in Thread>
Admin

Disclaimer: Neither Andrew Taylor nor the University of NSW School of Computer and Engineering take any responsibility for the contents of this archive. It is purely a compilation of material sent by many people to the birding-aus mailing list. It has not been checked for accuracy nor its content verified in any way. If you wish to get material removed from the archive or have other queries about the archive e-mail Andrew Taylor at this address: andrewt@cse.unsw.EDU.AU