简体   繁体   English

错误:在Cloud9中找不到模块'bonescript'

[英]Error: Cannot find module 'bonescript' in Cloud9

I got the error in Cloud9 Error: Cannot find module 'bonescript' When the following code excuted by node.js 我在Cloud9错误中得到错误:无法找到模块'bonescript',当以下代码被node.js取代时

enter code here
var b = require('bonescript');
b.pinMode('USR0', b.OUTPUT);
b.pinMode('USR1', b.OUTPUT);
b.pinMode('USR2', b.OUTPUT);
b.pinMode('USR3', b.OUTPUT);
b.digitalWrite('USR0', b.HIGH);
b.digitalWrite('USR1', b.HIGH);
b.digitalWrite('USR2', b.HIGH);
b.digitalWrite('USR3', b.HIGH);
setTimeout(restore, 2000);

This code can be executed by command line: node blinkLed.js in the Debian Linus on BeagelBone Black without problem. 可以通过以下命令行执行此代码:BeagelBone Black上Debian Linus中的node blinkLed.js没问题。 It can also be run on the beaglebone.org web demo. 它也可以在beaglebone.org Web演示上运行。

Does anybody know how to solve this issue? 有人知道如何解决这个问题吗?

I had searched and try online solution for 6 hours, but not successful. 我已经搜索并尝试了6个小时的在线解决方案,但没有成功。 I thought it might be Cloud9 config issue. 我认为这可能是Cloud9配置问题。 I contact Cloud 9 support but get no solution. 我联系Cloud 9支持,但没有解决方案。

更新:需要通过192.168.7.2:3000在BeagleBone Black上使用Cloud9, https: //ide.c9.io上的Cloud9无法找到正确的骨骼脚本库

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

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