网页资讯视频图片知道文库贴吧地图采购
进入贴吧全吧搜索

 
 
 
日一二三四五六
       
       
       
       
       
       

签到排名:今日本吧第个签到,

本吧因你更精彩,明天继续来努力!

本吧签到人数:0

一键签到
成为超级会员,使用一键签到
一键签到
本月漏签0次!
0
成为超级会员,赠送8张补签卡
如何使用?
点击日历上漏签日期,即可进行补签。
连续签到:天  累计签到:天
0
超级会员单次开通12个月以上,赠送连续签到卡3张
使用连续签到卡
01月02日漏签0天
beaglebone吧 关注:269贴子:382
  • 看贴

  • 图片

  • 吧主推荐

  • 游戏

  • 3回复贴,共1页
<<返回beaglebone吧
>0< 加载中...

Using the user leds 点亮用户灯

  • 只看楼主
  • 收藏

  • 回复
  • btiger
  • 贡士
    6
该楼层疑似违规已被系统折叠 隐藏此楼查看此楼
The BeagleBone has 4 user leds located on the main board close to the Ethernet port.They typically won't be visible if you put the BeagleBone in an enclosure, but they can be good for debugging and visually seeing the status.
The user leads are accessible from user land on the file system at this location:
/sys/devices/platform/leds-gpio/leds/There is one directly per user led, named:
/sys/devices/platform/leds-gpio/leds/beaglebone::usr0/
/sys/devices/platform/leds-gpio/leds/beaglebone::usr1/
/sys/devices/platform/leds-gpio/leds/beaglebone::usr2/
/sys/devices/platform/leds-gpio/leds/beaglebone::usr3/Inside each directory, there is a file names "brightness". If you write a "0" or a "1" to this file, then you can control the status of that led.
Here is a sample command to turn on user led 1:
echo 1 > /sys/devices/platform/leds-gpio/leds/beaglebone\:\:usr1/brightness
Note that user led 0 is already in use to indicate Ethernet activity, so you should use the user leds 1,2 and 3 for you projects.
For reference, this is the mapping to GPIO pins the user leds are mapped to:
USER LED GPIO PIN
User led 0 GPIO1_21
User led 1 GPIO1_22
User led 2 GPIO1_23
User led 3 GPIO1_24
http://beaglebone.cameon.net/home/using-the-user-leds


  • btiger
  • 贡士
    6
该楼层疑似违规已被系统折叠 隐藏此楼查看此楼
这么好的帖子怎么没人支持呢?看来还是改日我自己改写一套中文教程吧。
看看大家有什么反应。


2026-01-02 03:21:32
广告
不感兴趣
开通SVIP免广告
  • Rocky_Zou_Root
  • 白丁
    1
该楼层疑似违规已被系统折叠 隐藏此楼查看此楼
这个 很简单的啦


  • btiger
  • 贡士
    6
该楼层疑似违规已被系统折叠 隐藏此楼查看此楼
欢迎大家来讨论 BeagleBone的学习资料,这里人气好少啊。


登录百度账号

扫二维码下载贴吧客户端

下载贴吧APP
看高清直播、视频!
  • 贴吧页面意见反馈
  • 违规贴吧举报反馈通道
  • 贴吧违规信息处理公示
  • 3回复贴,共1页
<<返回beaglebone吧
分享到:
©2026 Baidu贴吧协议|隐私政策|吧主制度|意见反馈|网络谣言警示