简体   繁体   English

无法管理更新树莓派,gpio-header html文件

[英]Can't manage to update raspberry pi, gpio-header html file

I'm very new to programming with webiopi and very new to the raspberry pi in general. 我对使用webiopi进行编程非常陌生,而对树莓派来说则非常陌生。 Me and my brother are planning to build a robot running on a raspbery pi. 我和我的兄弟正计划建造一个在树莓派上运行的机器人。 We're planning to build a camera on the robot. 我们正计划在机器人上构建摄像头。 We would stream the camera through our raspberry pi and controll the robot, both through the same website. 我们将通过树莓派流式传输相机,并通过同一网站控制机器人。

However, here's my problem: I downloaded and installed webiopi for my raspberry pi. 但是,这是我的问题:我为树莓派下载并安装了webiopi。 And with that webiopi comes an example code which he will execute. 伴随着该webiopi,他将执行一个示例代码。 These are simple html files. 这些是简单的html文件。 If i make any change to them the raspberry pi just shows the original file. 如果我对它们进行任何更改,树莓派将仅显示原始文件。

Here's the first original: 这是第一个原件:

    <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> 
<html> 
<head>
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
            <meta name="viewport" content = "width = 420, user-scalable = no" />
            <title>Webiopi</title>
            <script type="text/javascript" src="/webiopi.js"></script>
            <script type="text/javascript">
            webiopi().ready(function() {
                    webiopi().RPiHeader().createTable("content");
                    w().refreshGPIO(true);
            });
            </script> 
</head> 
<body>
<div id="content" align="center"></div> 
    </body>
    </html>

Here is the version I want to upload(for a test): 这是我要上传的版本(用于测试):

              <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">  
     <html>  
     <head>
             <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
             <meta name="viewport" content = "width = 420, user-scalable = no" />
             <title>Webiopi</title>
             <script type="text/javascript" src="/webiopi.js"></script>
             <script type="text/javascript">
             webiopi().ready(function() {
                     webiopi().RPiHeader().createTable("content");
                     w().refreshGPIO(true);
             });
             </script> 
     </head> 
     <body>

     <P>Testesttestest</p> 
     <div id="content" align="center">   
     <img width="300" height="240" src="http://raspberrypi:8080/?action=strem"><br/>

     </div> 
     </body>
     </html>

I don't know if any of you guys ever had this problem. 我不知道你们是否有过这个问题。 But I can't continue my project if i can't update my webpage. 但是,如果我无法更新网页,则无法继续我的项目。

Thanks for u're help 谢谢你的帮助

Justin 贾斯汀

I think you're not editing the right files. 我认为您没有在编辑正确的文件。
Webiopi installs a server on your Raspi. Webiopi在您的Raspi上安装服务器。 From a fresh install, files are stored in /usr/share/webiopi/htdocs/ . 全新安装后,文件存储在/usr/share/webiopi/htdocs/
Also, you should check this page about configuration file in order to modify the default folder the files are stored in, and other usefull config features. 另外,您应该检查有关配置文件的页面,以便修改文件存储在其中的默认文件夹以及其他有用的配置功能。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM