Close
0%
0%

pyLCI - Linux Control Interface

Makes Raspberry Pi accessible, portable and easily configurable.

Similar projects worth following
pyLCI is a simple control interface for your Raspberry Pi and other Linux devices. It's using cheap display&button shields to give you a simple yet powerful interface. Stop using all those shutdown buttons, displays showing your IP address and weird console commands - this is a solution to all your "control my Pi" problems!

No more searching for your Raspberry Pi on the network, trying to figure out what went wrong and reflashing SD cards all the time - pyLCI solves most basic problems once and for all so that you can finally focus on what's actually important, like doing whatever you wanted to do with a Pi in the first place. All you need is a 5$ shield. After that, install your software and IP/connect to networks/launch scripts/shutdown (and much more).

Oh, and pyLCI is a good interface for your projects as well! Intrigued? Read on!

Want to install pyLCI? Head here!

Don't know which shield to choose? Here's a hardware guide!

pyLCI is a Python app which runs on your Raspberry Pi and gives you an interface to many important functions and controls, saving your time and effort when you want to work with your Raspberry Pi, whatever your goal is. All you need is a display and some buttons, eliminating a need to SSH in your system or connect a monitor&keyboard in many cases.

pyLCI has proven itself in educational, commercial and hobbyist environments, saving time, developing costs and a lot of frustration for a first-time user. It's an important step in making Raspberry Pi computers accessible and removing many constructive problems that shouldn't be there in the first place.

Where can you use it?

  • Your Raspberry Pi desktop/learning setups - improving your learning and work experience
  • Your small projects - to make your development and painless
  • Your Raspberry Pi field setups - to control and configure them easily
  • Your Linux servers, development machines, workstations, commercial projects etc.
  • Your DIY wearables, phones, portable gaming setups, programmers and much more.

My goals:

  • Make it cheap. That means accessibility. Buying additional hardware is a roadblock, and hardware used by pyLCI is easy to get.
  • Make it universal. The cheapest hardware is usually the one we already have.
  • Make it simple. The simplest things are the things we can suit for different purposes easily.
  • Make it popular. In open-source, that's what simple things become.

Want to see a visual? Check out this video (it's old, but it's here till I make a new one, hopefully, soon):

Have some ideas about pyLCI? Suggestions for improvements? PM me or comment on this project!

Here are my worklogs if you want to get development and design insights.

  • Improvements and plans - December 2016

    Arsenijs12/31/2016 at 02:50 0 comments

    What's new?

    • Autoscrolling of long menu entries in Menu UI element
    • Custom sorting of elements in app menus (actually, just finished it 20 minutes ago)
    • Started working on graphical displays (not yet available, since it's a hack I've put together for a device I'm developing, yet to be cleaned up and refactored)

    What's on the schedule?

    • An alarm app, possibly, some productivity apps
    • A website or at least a big blog post - got a ton of promotional materials now
    • Support for graphical displays - maybe even with a C extension for a speedup

    pyLCI is getting more and more popular. I receive e-mails from people developing their own apps or just asking questions, which 1) is uplifting 2) gives insights into where the documentation is lacking ;-) The post I recently wrote on the biggest Russian IT-related blog definitely didn't hurt, and I have more and more ideas about promotional materials and efforts. I really do believe that this project can make things easier if you're tinkering with single-board computers or even developing things for them.

    Read more »

  • Improvements and plans - November 2016

    Arsenijs11/17/2016 at 21:32 0 comments

    I work on this from time to time, adding features as they become necessary.

    Items from TODO list that are done:

    • Finish and refactor path_picker
    • Fix Adafruit shield display backlight management
    • enable instead of select when adding a wireless network
    • "format_for_screen" function for text
    • Changing UI elements to use threading.Event
    • Move app manager to separate class
    • Menu contents refresh hook

    Not much, but I'm not spending too much time either. Unplanned but added/fixed things:

    • Added arbitrary script and command launching to Scripts app
    • Added a Pomodoro tracker app (works with PomodoroD daemon)
    • Added backspace function to CharArrowKeyInput

    Next up - writing better documentation. I've started to get questions about writing new apps, so the docs have to be there, and they lack some important details. Some UI elements haven't yet been described, and there should be more examples for the existing ones. last but not least, I should finally fix PiFaceCAD or at least say that it doesn't work because it definitely doesn't now.

  • Worklog with worklogs

    Arsenijs10/16/2016 at 14:12 4 comments
  • Improvements and plans - October 2016

    Arsenijs10/10/2016 at 07:25 0 comments

    Improvements gradually come, depends on my free time and features I want to implement. Check out this cool IR temperature sensor app! Wrote it in half an hour and now I can measure temperature by just connecting a MLX90614 sensor to my wearable PC.

    Also, check out this lecture helper app! It has a counter to show how many minutes are left from your chosen time interval, and you can load a document with lecture tips to scroll through them and see what is it you've gotta talk about now.

    Wireless connection app got some improvements. You can now see status in a Refresher, meaning you don't have to wait or scroll through menus until you get your IP address - it'll appear on the screen by itself. (old verbose menu is still there - just click ENTER in the refresher!) Also, you can now manage networks that are already added. Oh, and the config is now saved automatically after each change.

    You can now make backlight turn on and off after a time interval automatically. It's not there by default due to some corrections needed to the code, but it'll get there eventually.

    There's a dialog box UI element now! How cool is that?

    Read more »

  • Current state, input UI elements and ideas

    Arsenijs08/29/2016 at 16:35 0 comments

    Hi!


    I've been working on pyLCI from time to time. What's new?
    • The display's only refreshed when it needs to be refreshed. If only some characters change, those get replaced instead of clearing the display and printing the whole string. That makes pyLCI work much more quickly. Also, I added and tested a custom character enter function.
    • I've added an UI element to adjust integer values with arrow keys. Should have called it IntegerAdjustInput, shame I've only thought of this now.
    • I've added an UI element for character input using arrow keys. Now you can enter WiFi passwords!
    • I've added the RPC API files for usage in projects (no examples though =( )
    • I've added a Listbox UI element - for the occasions where you just need to select a single element. I've also improved the volume control app with it - now you can select channels to be adjusted, as well as change adjustment values and type (dB, percent and HW value)

    I'm mainly moving pyLCI forward because my projects need it. For example, input UI element was necessary for #ICeeData, and it in turn needed the "eliminate refreshes" patch. Number adjust UI element, custom chars and RPC API were for a project a local company ordered from me (sadly, not open-source). Listbox and volume control app are for #Wearable Raspberry Pi personal assistant - first thing I want to set up on it is listening to music, so that's necessary.

    To sum up - pyLCI is a good base for my projects. I improve it while working on my them, and as long as I have other projects, this will stay the same way.

  • Still not feeling well. Some thoughts about pyLCI.

    Arsenijs05/29/2016 at 19:09 0 comments

    Hi! I've been working on #Wearable Raspberry Pi personal assistant this week. Mainly, 3D printing things. I also organised a lecture on Raspberry Pi computers used with Python (I organise those with my local hackerspace), to tell and show all. It's about a week since I've been out of the hospital, and I have had planned to include some cool features... But instead, I didn't feel consistently well through the week, which screwed up some of my plans. On top of that, the lecture I've organised was not successful. I had screwed up the first stage, and pyLCI might have saved my ass.

    I had planned the lecture to accomodate around 10 people, and for everybody to interact with the hardware directly - that is, everybody has a Pi and uses it to blink LEDs, read buttons and so on. I have found 9 Raspberry Pi boards and asked others to bring theirs. That wasn't a problem. Connecting them all up and starting work turned out to be *the* problem. I had prepared an image with network settings configured in to work automagically, but it just didn't work somehow - some Raspberries wouldn't connect, some did. For those which did, finding out the IP address was a problem. I included UART adapters in the course because I had foreseen this but most of them didn't even work with the computers, and for some reason one of them burned up, apparently, bringing oh-so-sensitive miniUART on my one and only Raspberry Pi 3 with it. It was a disaster, and the stress appeared to be too much for me, causing my second attack of acute pancreatitis later that evening. Long story short, it ruined my weekend plans. At least I have a doctor appointment for tomorrow, hopefully that clears things up.

    Funnily enough, all the problems I had on that lecture were solvable by pyLCI. Thus, I need more cheap shields and I've acted on my own hardware buying guide:

    I'll buy some more soon, to make sure our customs do not freak out when receiving multiple packages of same shields at once. The lecture was ruined though, being dependent on hardware very much - I spent about 2 hours trying to make it work and it was too much. I hope to repeat lecture in 2 weeks, with better preparation and better results. As for now, I'm in my bed most of the time. It still hurts, and one of the symptoms is body weakness, which makes it hard to even type this blog entry. Also, I'm hungry because I can't eat anything now to make sure inflammation goes away =) Fortunately, I've got enough motivation to continue writing.

    One more use case of pyLCI is clear - it's education. I'm currently working on the "wearable" use case with my wearable personal assistant. For example, I need a notification system, but it's not yet clear to me how to go on implementing it. However, I hope to have that finished by the end of the summer. A separate display would be nice though, and consistent with what some people expect from pyLCI - for example, some want to have a separate display for, say, a music player, which would be active at all times, regardless of the application currently on the main screen.

    I've been finally featured on Hackaday! Couldn't wait for that, it's been 7 weeks since the Tip Line actually. It didn't give me much insights into what's expected from users though, doesn't seem to be that popular of an idea. However, I'll be using the project a lot and thus it lives at least as much as I do =) There are goals to be reached, and I hope a user base will sooner or later appear to make sure this system gains popularity.

  • Feature-a-day week? Systemctl and partition apps, Checkbox UI element

    Arsenijs05/18/2016 at 07:05 0 comments

    So, I'm in a hospital. Long story short, I have 2 pyLCI-enabled devices with me and I'm coding whatever is on the roadmap. Just right now I was disappointed by the news that I'm not going to be let out today. Well, this is very disappointing, but in the end it's not like I don't have enough things to implement =)

    Systemctl app is one of the most important apps I had to write. Now, you can restart stuck services, as well as start/stop/enable/disable/reload them. It also has a filter-by-type feature because systemd has just enough units to make you sick of scrolling. For that, I had to implement checkboxes, so the app wasn't there until Checkbox UI element appeared, otherwise this app would simply be a "checkbox app" - "See! We have a systemctl app! Not saying it's easy to use...". I could limit loading to services, but I can easily imagine me needing to restart graphical.target once again to restart X. But then, I can't really see the status of services... Guess that's a fix incoming soon.

    Partition app was quite an important app, too. Unmounting a drive is one of the things you often could do either much easier or even automatically, though it's hard for me to imagine the latter. So, you can use pyLCI to scroll through your mounted partitions and unmount any partitions!

    Read more »

  • Wearable assistant + hospital stay (very short log)

    Arsenijs05/16/2016 at 19:08 1 comment

    I've been in a hospital for a week now. For about 2 weeks before that, I was building my wearable personal assistant - #Wearable Raspberry Pi personal assistant. So that's about it. I'm building a systemctl app for rebooting your services, see you soon with news about that one!

  • How can you use pyLCI in your projects? Why am I submitting it for the Hackaday Prize?

    Arsenijs04/24/2016 at 16:42 0 comments

      How can you use pyLCI in your projects?

      1. pyLCI is a control interface completely independent from any network connections. Thus, it's very useful for networking-enabled projects where you have to use an independent configuration channel.
      2. pyLCI is independent of any GUI interfaces. Thus, you can use it as an addition to them, for example, in media centers, music playing boxes and radios.
      3. pyLCI is hackable. Adding a custom application for your project is quite easy, since there are examples, documentation pages and existing applications which you can read to understand the principles and best practices.
      4. pyLCI is cheap to add to your project. You can assemble GPIO hardware for 3-4$ in Chinese parts, or buy a shield for 6$ and it'll work great with pyLCI, providing you with a simple interface to offload some basic tasks to.
      5. pyLCI solves chicken-and-egg problems. If your Pi doesn't automatically connect to a wireless network, you'd have to use some complicated methods to do that. With pyLCI, the idea is that you just connect to it. Same with shutdown, by the way - you just shutdown your Pi, avoiding SD-card corruption.
      6. pyLCI adds opportunities you never thought of before. It allows you to dynamically change many of your project's settings on the fly, making your projects much more flexible.

      Why Hackaday Prize?

      As an interface, pyLCI aims to change the world by making our projects capable of achieving their tasks more efficiently. With Raspberry Pi and other Linux SBCs being a quite popular base for Hackaday Prize projects, it can shorten the development time for many people and increase the capabilities of their projects by not wasting their time on implementing the basic interfacing from scratch, as well as giving many functions for free. It also lowers the effort to make a project configurable automatically - autoconfiguration doesn't matter as much when you have a powerful interface to reconfigure things in case something goes wrong. Not only that, but it also increases repeatability of the projects - with many different ways you can connect the hardware necessary for pyLCI, details such as LCD&button connections become more and more flexible and there's less possibility you need to buy that particular interface shield to make that particular project work, as it happened to me a couple of times. Last but not least, it's very cheap - and the components are easy to get in most places of the world.

      On the other side, it's accessible. Let's just face it - web interfaces aren't as easy to reach. They require a network connection, another device capable of connecting to it, as well as rendering the interface correctly, not to mention knowing the network address. Graphical interfaces require a display connected, which reduces repeatability of the projects, as well as requires having some input devices, too - and the efficiency of configuration with a GUI isn't that good for many applications. pyLCI is an interface that has neither of those problems. It's right there in your project, stacked on top of your Raspberry Pi as a shield, or maybe embedded in your project's case, or even built as a detachable console. You don't need neither expensive displays nor one more computer to configure everything.

      I expect to launch an Indiegogo campaign for both gaining popularity among makers and for developing some ideas I have thought of since the start of the project.

        1. First of all, I still want to lower the complexity of getting started with pyLCI. Thus, I've developed an idea of autoconfiguration shield. It'd have the character screen and buttons usable by pyLCI, as well as use the UART-accessible console of a Raspberry Pi to configure the network, install pyLCI and configure it to use the shield. It's no job for a simple Arduino, given all the command-line output parsing that has to happen and all the errors possible. I'll probably make that with MicroPython on a suitable STM chip, given that STMs have less constraints for my task in general - I'll need...
    Read more »

  • New UI element, GPIO hardware&fixes, clock&update apps

    Arsenijs04/22/2016 at 02:27 0 comments

    I assembled a little board with a display header and some buttons. It's for me to test GPIO drivers, as well as use for Arduino driver development and, afterwards, for my home automation Raspberry Pi. A 4-row screen goes well with it, and, since it's GPIO, the plate works pretty fast even on a Raspberry Pi 1B.

    I remember hesitating about assembling it, thinking "what could have gone wrong from when I last tested GPIO?" Well, I was mistaken:

    I wonder how the hell it worked before, LOL. Conclusion? Unless you have hardware for testing accessible, guesses are, well, guesses. Anyway, I have one more piece of pyLCI hardware - 5 Raspberries running pyLCI now! Aaaand... I have one more Raspberry Pi free, so I can easily make it 6 =) Guess that sixth will be the "Arduino driver" one.

    Read more »

View all 21 project logs

  • 1

    Get a Linux device

  • 2

    Add buttons

  • 3

    Add a screen

View all 5 instructions

Enjoy this project?

Share

Discussions

K Johansen wrote 12/30/2016 at 21:29 point

hi, dumb question.  In one of your logs you mention 'ordering of the apps' using __init.py__.  Did you ever implement that?  I can't see how you're doing it, as those files will either be empty or have the menu name in them

  Are you sure? yes | no

Arsenijs wrote 12/30/2016 at 21:47 point

Hi! Yes, indeed, I haven't yet implemented it. I have a feeling this is a feature request - will be a nice brain teaser for today's night =) (I'll need this for my project quite soon, too.)

  Are you sure? yes | no

K Johansen wrote 12/30/2016 at 21:57 point

thanks, at least now I know I should stop looking for it, and going crazy in the process.  Just getting back to my project now, thanks for the quick reply.  Happy New year to you.

Ke

  Are you sure? yes | no

Arsenijs wrote 12/30/2016 at 21:59 point

Just for you to know - I have a TODO list where I list features that are yet to be implemented but are on the schedule =) http://pylci.readthedocs.io/en/latest/plans.html

  Are you sure? yes | no

Arsenijs wrote 12/31/2016 at 02:31 point

It's implemented now - as an example, I've sorted the main directory (look in the apps/__init__.py). Do a "git pull" and check it out, and notify me if you encounter any problems =) 

Happy New Year to you too, and hope this helps in whatever you're making!

  Are you sure? yes | no

K Johansen wrote 12/31/2016 at 10:38 point

wow, that was fast.  I'll let you know how I make out.

Ummm, can we add 'cold fusion reactor' to your to-do list while we're at it?😉

  Are you sure? yes | no

Arsenijs wrote 01/01/2017 at 05:57 point

Unfortunately, no, I suck at physics (though I'd love me some fusion batteries to replace those 18650!) However, if it's pyLCI-related, do not hesitate =)

  Are you sure? yes | no

K Johansen wrote 11/17/2016 at 20:43 point

hi, thanks for the reply.  I've started playing with the example apps, and seeing how it works with ./update.sh.  I'm amazed at how well it works, and how elegant the solution is (at least in my experience).  The documentation is very good as well, you've obviously put in a lot of work there (into the code as well).  

As for the home automation, I'm willing to share what I do if you're interested  I'm new to python, so it will probably look a bit rough around the edges.  The pi is intended to be my central controller, with arduinos around the house for various jobs.  This is where piLCI comes in: it's a perfect jumping off point.

Thanks again

  Are you sure? yes | no

Arsenijs wrote 11/17/2016 at 21:17 point

Hi! I've just written a lot of shit code, this is my attempt to learn something from what I've written before =) I'll try to improve documentation about writing your own apps this weekend - today, I've been improving the Scripts app, you can now run arbitrary commands using the arrow key input.  

I've had some experience making a similar automation setup, though it was for an escape room. Will be very interested to see how it turns out and if we could made an app that could be included in pyLCI! Oh, and don't forget to join #Hacker Channel - if you ever have problems, there are people ready to help =)

  Are you sure? yes | no

K Johansen wrote 11/13/2016 at 22:32 point

great project.  I got it up and running in a couple of days (had to make my own version of the adafruit shield - I'll see abou posting a picture).  I'll be very interested in what you do with openHAB, as I've considered using that for my home automation project.

https://hackaday.io/page/2505-my-pylci-implementation

Looking forward to implementing my own apps.

Thanks,

Ken

  Are you sure? yes | no

Arsenijs wrote 11/17/2016 at 15:45 point

Hi! 

An awesome implementation! Nice to see what a hacker can do with enough motivation and skill =) Drop me a message here or to crimier at yandex dot ru if you ever need help with writing apps or resolving any problems. I've just received some feedback about documentation and am now working on making it bette, specifically, I'll work on UI element documentation.

About OpenHAB - that's planned to be about a project of mine which is still in the queue. Therefore, it'll take me some time working on current projects before I'll be able to take on home automation, especially when I have less need in that now, barely even visiting home =) I'll be happy to help with that, though. 

Hope I still will get to making my home automation controller - I've started building parts of the hardware, but I lack time as I have to work on another projects =(

  Are you sure? yes | no

ZaidPirwani wrote 05/29/2016 at 12:33 point

AWESOME, I was just planning to make something similar, but I want to use those NOKIA MONOCHROME LCD Screens..

  Are you sure? yes | no

Arsenijs wrote 07/28/2016 at 23:30 point

Hi! I'm very surprised Hackaday didn't notify me of this comment =( It'd be simple to make a basic pyLCI driver for those screens. You still interested?

  Are you sure? yes | no

ZaidPirwani wrote 07/29/2016 at 04:02 point

yes - YES I am - made a little PiHAT of my own recently for doing stuff like this.

  Are you sure? yes | no

Laurent B wrote 04/24/2016 at 16:53 point

Good job ! I am anxious to try :)

  Are you sure? yes | no

Arsenijs wrote 04/24/2016 at 16:57 point

You already can, it's in working and installable, all you need is proper hardware =) There's already plenty of information about supported hardware on pyLCI documentation page, so feel free to get started. Also, my inner perfectionist tells me I'll make a very simple hardware buying/building guide in a couple of days =)

  Are you sure? yes | no

Arsenijs wrote 04/25/2016 at 13:49 point

Hi! Check out my hardware guide I just made: http://pylci.readthedocs.org/en/latest/hardware.html

This describes which hardware you can use to get it up and running. If you have something else, PM me and I'll likely be able to make a driver for that - I'm interested in making my system support more input/output devices =)

  Are you sure? yes | no

Arsenijs wrote 04/18/2016 at 15:52 point

Oh wow, I actually did! Wonderful! 

  Are you sure? yes | no

Craig Hissett wrote 03/31/2016 at 10:16 point

Ha ha, good man!

I can't wait to see it when it is released; I've been looking at your Github and it is is looking great. It is much bigger than any Python project I have done, but it is just about making sense to me. I love how modular it is - you could just write new apps and drop them in there, and the interface will load them without any coding changes to the main script.

It is this type of coding that I need to learn in order to make my Box Office/PoS system expandable!

  Are you sure? yes | no

Arsenijs wrote 03/31/2016 at 10:47 point

Well, I wrote a lot of shitty projects before =D And I'm not even implying this one is good in terms of code, something definitely could have been done better. However, I got plenty of experience from those previous projects. Hope the things I'll document will help you learn!
Oh, and it couldn't have happened if Python weren't that good of a language ;-)

  Are you sure? yes | no

Craig Hissett wrote 03/31/2016 at 09:29 point

I have just rewatched your video.

This is definitely something I am going to use, both to use for my in-car PI, but also for a Pi-based Box Office/PoS system I'm planning. This would handle customer feedback (displaying prices and things) brilliantly.

I love the PI/Screen enclosure you've made too!

  Are you sure? yes | no

Arsenijs wrote 03/31/2016 at 09:33 point

Hi! And here I am, doing before-release things =) I've actually made one more video, check it out! I'll need to put it on the page today, as well as make plenty of changes - I'm also making the documentation now.

  Are you sure? yes | no

Craig Hissett wrote 03/31/2016 at 09:54 point

You need to get that video posted ASAP!

The ability to control the Pi completely from the buttons and screen makes this a very, VERY useful project - it makes the Raspberry Pi more accessible and easier to use for so many uses!

You need to treat yourself to one of these:

http://www.aliexpress.com/item/1pcs-Raspberry-pi-1602-LCD-screen-RGB-LED-button-expansion-module-I2C-1602-LCD/32464219474.html?spm=2114.01010208.3.10.fZuoeZ&ws_ab_test=searchweb201556_7,searchweb201602_5_10036_10035_10034_507_10032_10020_10017_10005_10006_...

One of these i2c LCD/button shields on a Pi A+/Zero will make for a really small handy package!

  Are you sure? yes | no

Arsenijs wrote 03/31/2016 at 10:04 point

Heh, I already bought one of those, along with 20x4 screen, 16x4 screen and some more things =) When I get this thing, I'll write a driver for it. Possibly, even before that - if somebody appears and says he has one of those and it'd be useful =)
I just finished unifying output drivers under one HD44780 library so that it's easy to write output drivers, then I'll make a GPIO-controlled LCD and go after documentation.
I'm cautious about releasing it prematurely. See, I want to at least have installation instructions, some basic UI elements and a guide on configuring it. That is, I'll announce it big - I've found plenty of places to make posts about it on, and I'm writing announcement texts when I have some spare time. However, I'll be damned if I release it and it doesn't install ;-)

  Are you sure? yes | no

Craig Hissett wrote 03/20/2016 at 01:18 point

jackpot! :)

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates