热门标签 | HotTags
当前位置:  开发笔记 > 编程语言 > 正文

如何使用RaspberryPi和便宜的显示器构建壁挂式家庭日历和仪表板

Ilovedashboards.IloveRaspberryPis(tiny$35computersthesizeofasetofplayingcards).AndImcheapf
Glanceable Dashboard

I love dashboards. I love Raspberry Pis (tiny $35 computers the size of a set of playing cards). And I'm cheap frugal. I found a 24" old LCD at Goodwill (a local thrift shop) and bought it but it's been sitting unused in my garage.

我喜欢仪表板。 我喜欢Raspberry Pis(35美元的微型计算机,只有一套纸牌)。 我很便宜的节俭。 我在Goodwill(一家当地的旧货店)发现了一台24英寸旧的LCD显示器,并购买了它,但是它一直闲置在我的车库中。

Then I stumbled on DakBoard. The idea is simple - A wifi connected wall display for your photos, calendar, news, weather and to-do.

然后我偶然发现了DakBoard 。 这个想法很简单-使用wifi连接的墙面显示器,用于存放您的照片,日历,新闻,天气和待办事项。

The implementation is simple genius. It's a browser that starts up full screen (kiosk mode) and just sits there and updates occasionally. DakBoard provides the private webpage and tools to make that happen. You can certainly build this yourself with any number of open source tools. I chose DakBoard because it was simple, beautiful, and I was able to get the whole thing done in less than an hour. I'm sure I'll spend many hours tweaking it through. There's also the very popular MagicMIrror platform, so lots of choice and power in this space!

实现是简单的天才。 它是一种浏览器,可以全屏(信息亭模式)启动,只是坐在那里偶尔更新。 DakBoard提供了专用网页和工具来实现这一目标。 您当然可以使用任何数量的开源工具自己构建它。 我选择DakBoard是因为它简单,美观,而且我能够在不到一个小时的时间内完成整个工作。 我确定我会花很多时间来调整它。 还有非常流行的MagicMIrror平台,因此在这个领域有很多选择和强大功能!

What are some considerations?

有哪些注意事项?

  • You may want to turn it off on a scheduled to save power and the screen

    您可能希望按计划将其关闭以节省电源和屏幕

    • cronjob - turn it off on a schedule

      cronjob-按计划将其关闭
    • sensor - turn it on when something (your alarm, nest, thermostat motion detector attached to GPIO, etc) detects your presence)

      传感器-当某物(您的警报,嵌套,连接到GPIO的恒温器运动检测器等)检测到您的存在时将其打开
  • It has to act like an appliance. If you are messing with it to keep it alive, it's not an appliance, it's another computer to manage.

    它必须像设备一样工作。 如果您为了使它保持活动状态而烦恼,它不是设备,而是要管理的另一台计算机。
  • It has to just work. If my Spouse doesn't like the idea or find its not reliable, the SAF (Spouse Acceptance Factor) will be low and they'll want to get rid of it. All it takes is one "why isn't this working" and I'm dead in the water.

    它必须工作。 如果我的配偶不喜欢这个主意或发现它不可靠,那么SAF(配偶接受因子)将很低,他们将希望摆脱它。 只需要一个“为什么这不起作用”,我就死定了。
  • Finally - What do you want to show?

    最后-您想展示什么?

Someone asked me - "What would I want to put on my dashboard other than a calendar? I don't see why this is useful."

有人问我:“除了日历之外,我还想在仪表板上放什么?我不明白为什么这样做有用。”

您会在Glance-able显示器上放什么? (What would you put on a Glance-eable Display?)

Family Calendar(s), movie times, temperature, news, my blood sugar, disk free on my NAS, TV schedule, family photos, commute traffic, album releases, homework due soon, family events, trips, flight status, music playing now, literally anything you want as a glance-able display. 

家庭日历,电影时间,温度,新闻,我的血糖,NAS上可用的磁盘,电视时间表,家庭照片,通勤交通,专辑发行,即将到期的家庭作业,家庭事件,旅行,航班状态,正在播放音乐,几乎任何您想要作为浏览显示的内容。

Glanceable Dashboard

哲学 (Philosophy)

You'll want to ask yourself, is this just an iPad on the wall? I'd propose not. In fact, I'd say this is a Wall Mounted Glanceable Display - a personal dashboard - not an interactive thing. I want the family and kids to just stop by, note important information and move on.

您将要问自己,这只是墙上的iPad吗? 我不建议。 实际上,我会说这是壁挂式可视显示器-个人仪表板-而非交互式的东西。 我希望家人和孩子们停下来,注意重要信息并继续前进。

It's also worth pointing out the a horizontal monitor on the wall looks like, well, a monitor on the wall. But somehow when it's Portrait it's dramatic. It's not something we are (yet) used to seeing. I may try this out in a few ways, or even make a few of these displays!

还值得指出的是,墙上的水平监视器看起来就像墙上的监视器。 但是不知何故,当它是肖像时,它是戏剧性的。 这不是我们(现在)已经习惯的东西。 我可能会以几种方式进行尝试,甚至做一些这样的展示!

如何构建基于Raspberry Pi的家庭日历 (How to Build a Raspberry Pi-based Family Calendar)

UPDATE - I wrote how to do this with a Raspberry Pi Zero W (smaller and cheaper) and a readonly filesystem (advanced)

更新-我编写了如何使用Raspberry Pi Zero W(更小更便宜)和只读文件系统(高级)执行此操作

It's pretty easy! I used the DakBoard Blog but I had most of the stuff already.

很简单! 我使用了DakBoard博客,但我已经掌握了大多数东西。

  • Get a $35 Raspberry Pi 3. The 3 is fast and includes Wifi so you don't need an extra adapter.

    获得35美元的Raspberry Pi 3 。 3速度很快,并包含Wifi,因此您不需要额外的适配器。

  • I like a 2.5A powersupply but some folks say you can run the Raspberry Pi off the monitor's USB power - IF that power can put out at least 1A. 500mA will likely cause instability. It depends on if you want to try to get the whole thing down to one power cable.

    我喜欢2.5A的电源,但有些人说您可以在显示器的USB电源上运行Raspberry Pi,前提是该电源至少可以输出1A。 500mA可能会导致不稳定。 这取决于您是否要尝试将整个事情分解为一根电源线。

  • Cheap Micro SD Card - 8 gigs is fine, but get whatever works for you. This doesn't need to be awesome.

    便宜的Micro SD卡-8个演出就可以了,但是可以为您提供一切。 这不必太棒了。

  • A 1 foot HDMI cable. You're gonna mount the Raspberry Pi to the back of the monitor and hide it so you want the cable to be as small as possible.

    1英尺的HDMI电缆。 您将把Raspberry Pi安装到显示器的背面并隐藏起来,以便您使电缆尽可能的小。

    • You might need a 90 degree or 270 degree adapter to avoid HDMI cables from sticking out or a short cable with this built in.

      您可能需要一个90度或270度的适配器,以防止HDMI电缆伸出或内置的电缆短路。

    A 1 foot HDMI cable. You're gonna mount the Raspberry Pi to the back of the monitor and hide it so you want the cable to be as small as possible.

    1英尺的HDMI电缆。 您将把Raspberry Pi安装到显示器的背面并隐藏起来,以便您使电缆尽可能的小。

  • And finally - a 24" ish (smaller is fine) LCD (IPS is nice) monitor with smallish bezels and HDMI inputs that go out to the side (NOT directly out the back) as you want this flush on the wall.

    最后-一台24英寸(较小的显示器)的LCD(IPS很好)显示器,带有较小的边框和HDMI输入,当您要在墙上齐平时,它可以向侧面(而不是直接从背面)出来。

    • Think about how you'll mount it. You can take the back off the monitor and use hanging wire OR use a flush VESA mount.

      考虑一下如何安装它。 您可以从显示器上取下后盖,并使用吊线或使用齐平的VESA支架。

    And finally - a 24" ish (smaller is fine) LCD (IPS is nice) monitor with smallish bezels and HDMI inputs that go out to the side (NOT directly out the back) as you want this flush on the wall.

    最后-一台24英寸(较小的显示器)的LCD(IPS很好)显示器,带有较小的边框和HDMI输入,当您要在墙上齐平时,它可以向侧面(而不是直接从背面)出来。

Install Raspbian on the Raspberry Pi. I use Noobs to bootstrap my install as it's super fast and easy. Go through the standard setup. Make sure you've set up:

在Raspberry Pi上安装Raspbian。 我使用Noobs引导安装,因为它非常快捷,简便。 通过标准设置。 确保您已设置:

  • Wifi login

    WiFi登录
  • Timezone

    时区
  • Boot to Desktop automatically

    自动启动到桌面
  • install chromium via "sudo apt-get install -y rpi-chromium-mods"

    通过“ sudo apt-get install -y rpi-chromium-mods”安装Chrome

Then you make sure that Chromium starts up full screen, the mouse is hidden, and we're looking at the dashboard! It's super important you don't have to touch it. It's an appliance, right?

然后,确保Chromium可以全屏启动,鼠标被隐藏,并且我们正在看仪表板! 您不必触摸它,这非常重要。 是电器,对不对?

sudo nano ~/.config/lxsession/LXDE-pi/autostart
@xset s off
@xset -dpms
@xset s noblank
@chromium-browser --noerrdialogs --incognito --kiosk http://dakboard.com/app/?p=YOUR_PRIVATE_URL

Then you can set up a cronjob if you want to turn the Pi's screen on and off on a schedule. Using rpi-hdmi.sh you can make a crontab -e that looks like this:

然后,如果您想按计划打开和关闭Pi的屏幕,则可以设置cronjob。 使用rpi-hdmi.sh可以创建一个crontab -e,如下所示:

# Turn HDMI Off (22:00/10:00pm)
0 22 * * * /home/pi/rpi-hdmi.sh off# Turn HDMI On (7:00/7:00am)
0 7 * * * /home/pi/rpi-hdmi.sh on

My family uses Google Calendar (GSuite) to manage hanselman.com, but I use Outlook at work. I also have a lot of business/work crap in my calendar that the family doesn't need to see. So I have two problems here, filtering, and appointment movement between Work and Home.

我的家人使用Google日历(GSuite)管理hanselman.com,但我在工作中使用Outlook。 我的日历中也有很多家庭不需要看的商务/工作垃圾。 所以我在这里有两个问题,过滤和工作与家庭之间的约会移动。

My wife and kids use Google Calendar and it's their authoritative source. My work calendar is MY authoritative source, so I want to sync Outlook->Google but ONLY including Personal/Podcasts/Travel categories. I categorize in Outlook at work, and then those appointments that are appropriate for the family calendar get moved over. Then the Family Calendar dashboard includes color coordinated items for Mom, Dad, Kid1, Kid2. The kids include homework that's due as appointments.

我的妻子和孩子使用Google日历,这是他们的权威资料。 我的工作日历是我的权威来源,因此我想同步Outlook-> Google,但仅包括个人/播客/旅行类别。 我在工作中对Outlook进行了分类,然后适合家庭日历的那些约会被移了。 然后,“家庭日历”仪表板包括用于妈妈,爸爸,Kid1,Kid2的颜色协调项。 孩子们包括应交的作业。

I use the Outlook Google Calendar Sync open source project to do this calendar movement for me. It does require Outlook and is a client solution so if you have a better idea let me know.

我使用Outlook Google Calendar Sync开源项目为我完成日历移动。 它确实需要Outlook,并且是一种客户端解决方案,所以如果您有更好的主意,请告诉我。

GOTCHA: I have been using Google Calendar for YEARS. I have also been using sync tools like this for years. As such, I was noticing that sometimes DakBoard would timeout asking for my Google Calendar's ICS file. It would take minutes. So I requested it myself and it was 26 megs. It's clear that Google calendar doesn't care deeply about iCal and that's disappointing. This could easily be solved if they'd support some kind of OData like URL-based query for fromdate=, todate=. In this case, the DakBoard was getting 26 megs over and over to just show a few weeks of appointments. I literally had appointments from 2005 in the calendar. I decided that since I'd declared Outlook my authoritative source for my calendar that I'd take an archive (one time snapshot) of my iCal and then delete all my calendar items from Google Calendar and re-sync, one way, from the authoritative source, going back 1 year. I'm likely a rare case but it's worth noting in case you bump into this.

GOTCHA:我一直在使用Google Calendar for YEARS。 多年来,我一直在使用类似的同步工具。 因此,我注意到DakBoard有时会超时,要求我的Google Calendar的ICS文件。 这需要几分钟。 所以我自己问了一下,那是26兆。 显然,Google日历并不十分关心iCal,这令人失望。 如果他们支持某种OData,例如fromdate =,todate =的基于URL的查询,则可以轻松解决。 在这种情况下,DakBoard一遍又一遍地获得了26兆的能量,仅显示了几个星期的约会。 从字面上看,我的约会时间是2005年。 我决定,由于已将Outlook声明为我的日历的权威来源,因此我将对iCal进行存档(一次快照),然后从Google日历中删除所有日历项,然后从一种方式重新同步权威来源,可以追溯到1年以前。 我可能是一种罕见的情况,但值得注意的是,如果您遇到这种情况。

All in all, this can easily be done in a short few hours if you have a Pi and a monitor. The time will be spent making it "sanitary." Making the cables perfect, hanging it on the wall, hiding the cables, then tweaking the screen to be perfect.

总而言之,如果您拥有Pi和显示器,则可以在短短几个小时内轻松完成此操作。 时间将花费在使其变得“卫生”上。 使电缆完美,将其挂在墙上,隐藏电缆,然后调整屏幕使其成为完美。

Editing screens on DakBoard

DakBoard has a free option that works great, or a Premium subscription that gives you even more control. Again, it depends on your web/art ability, and your patience. This is a fun new world that I'm excited to get involved with and my family is already stoked about this new display as we enter the holiday season.

DakBoard有一个效果很好的免费选项,或者是Premium订阅,它使您拥有更多控制权。 同样,这取决于您的网络/艺术能力和耐心。 这是一个有趣的新世界,我很高兴能参与其中,当我们进入假期时,我的家人已经对这种新的展示感到高兴。

Sponsor: Preview the latest JetBrains Rider with its Assembly Explorer, Git Submodules, SQL language injections, integrated performance profiler and more advanced Unity support.

赞助商:预览最新的JetBrains Rider,包括其Assembly Explorer,Git子模块,SQL语言注入,集成的性能分析器以及更高级的Unity支持。

翻译自: https://www.hanselman.com/blog/how-to-build-a-wall-mounted-family-calendar-and-dashboard-with-a-raspberry-pi-and-cheap-monitor




推荐阅读
  • 本文介绍了iOS数据库Sqlite的SQL语句分类和常见约束关键字。SQL语句分为DDL、DML和DQL三种类型,其中DDL语句用于定义、删除和修改数据表,关键字包括create、drop和alter。常见约束关键字包括if not exists、if exists、primary key、autoincrement、not null和default。此外,还介绍了常见的数据库数据类型,包括integer、text和real。 ... [详细]
  • 【shell】网络处理:判断IP是否在网段、两个ip是否同网段、IP地址范围、网段包含关系
    本文介绍了使用shell脚本判断IP是否在同一网段、判断IP地址是否在某个范围内、计算IP地址范围、判断网段之间的包含关系的方法和原理。通过对IP和掩码进行与计算,可以判断两个IP是否在同一网段。同时,还提供了一段用于验证IP地址的正则表达式和判断特殊IP地址的方法。 ... [详细]
  • 解决github访问慢的问题的方法集锦
    本文总结了国内用户在访问github网站时可能遇到的加载慢的问题,并提供了解决方法,其中包括修改hosts文件来加速访问。 ... [详细]
  • IOS开发之短信发送与拨打电话的方法详解
    本文详细介绍了在IOS开发中实现短信发送和拨打电话的两种方式,一种是使用系统底层发送,虽然无法自定义短信内容和返回原应用,但是简单方便;另一种是使用第三方框架发送,需要导入MessageUI头文件,并遵守MFMessageComposeViewControllerDelegate协议,可以实现自定义短信内容和返回原应用的功能。 ... [详细]
  • macOS Big Sur全新设计大版本更新,10+个值得关注的新功能
    本文介绍了Apple发布的新一代操作系统macOS Big Sur,该系统采用全新的界面设计,包括图标、应用界面、程序坞和菜单栏等方面的变化。新系统还增加了通知中心、桌面小组件、强化的Safari浏览器以及隐私保护等多项功能。文章指出,macOS Big Sur的设计与iPadOS越来越接近,结合了去年iPadOS对鼠标的完善等功能。 ... [详细]
  • linux进阶50——无锁CAS
    1.概念比较并交换(compareandswap,CAS),是原⼦操作的⼀种,可⽤于在多线程编程中实现不被打断的数据交换操作࿰ ... [详细]
  • 1Lock与ReadWriteLock1.1LockpublicinterfaceLock{voidlock();voidlockInterruptibl ... [详细]
  • 本文介绍了利用ARMA模型对平稳非白噪声序列进行建模的步骤及代码实现。首先对观察值序列进行样本自相关系数和样本偏自相关系数的计算,然后根据这些系数的性质选择适当的ARMA模型进行拟合,并估计模型中的位置参数。接着进行模型的有效性检验,如果不通过则重新选择模型再拟合,如果通过则进行模型优化。最后利用拟合模型预测序列的未来走势。文章还介绍了绘制时序图、平稳性检验、白噪声检验、确定ARMA阶数和预测未来走势的代码实现。 ... [详细]
  • Mono为何能跨平台
    概念JIT编译(JITcompilation),运行时需要代码时,将Microsoft中间语言(MSIL)转换为机器码的编译。CLR(CommonLa ... [详细]
  • 初识java关于JDK、JRE、JVM 了解一下 ... [详细]
  • WebDAV之葫芦儿·派盘+天悦日记
    天悦日记支持webdav方式连接葫芦儿派盘。是一款清爽简约的日记记录工具,通过天悦日记app随时随地快速写日记,更有智能数据统计分析报表,多端同步多种备份,本地备份和基于Web ... [详细]
  • 我一直都有记录信息的习惯,不知是从什么时候开始,大约是在工作后不久。如今还真有点庆幸从那时开始记了点东西,当然是电子版的,写 ... [详细]
  • uboot与linux驱动1.uboot本身是裸机程序(1)在裸机中本来是没有驱动概念的(狭义的驱动概念是指在操作系统中用来具体操控硬 ... [详细]
  • VScode格式化文档换行或不换行的设置方法
    本文介绍了在VScode中设置格式化文档换行或不换行的方法,包括使用插件和修改settings.json文件的内容。详细步骤为:找到settings.json文件,将其中的代码替换为指定的代码。 ... [详细]
  • 在说Hibernate映射前,我们先来了解下对象关系映射ORM。ORM的实现思想就是将关系数据库中表的数据映射成对象,以对象的形式展现。这样开发人员就可以把对数据库的操作转化为对 ... [详细]
author-avatar
寻路灬鸿
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有