-
Improvements and plans - December 2016
12/31/2016 at 02:50 • 0 commentsWhat'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.I'm mainly working on #ICeeData and one more project of mine now, so things I implement are mainly for them. Also, fulfilling requests of the users from time to time =) Working on a project people use is a great way to finish a year for me.
-
Improvements and plans - November 2016
11/17/2016 at 21:32 • 0 commentsI 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
10/16/2016 at 14:12 • 4 commentsWorklogs:
- First day of refactoring&testing
- More refactoring, testing and new apps!
- A wireless app, Printer UI element, input system and docs!
- Yaaay, public docs!
- Release announcement!
- 20x4 displays tested, nested app folders and HW/SW plans
- Having a break, "App-a-day" approach and other ideas.
- App-a-day - added tvservice app
- New hardware support&a step closer to autoconfig!
- Docs for all apps + lsusb and script app!
- New UI element, GPIO hardware&fixes, clock&update apps
- Wearable assistant + hospital stay (very short log)
- Feature-a-day week? Systemctl and partition apps, Checkbox UI element
- Still not feeling well. Some thoughts about pyLCI.
- Current state, input UI elements and ideas
- Improvements and plans - October 2016
- Improvements and plans - November 2016
- Improvements and plans - December 2016
-
Improvements and plans - October 2016
10/10/2016 at 07:25 • 0 commentsImprovements 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?
I've decided that, for my project, code comments generally suck. You have to maintain them, they provide little to no value compared to proper documentation and clutter the view. I'm now trying to focus on better naming and deleting comments where they are not necessary to develop apps for pyLCI - that means comments on internal functions are going to disappear, IMO for the better.
A base class for all input drivers, yaay! It now will be easier to implement features like storing mappings in configs, hotplug etc. Would theoretically also be cool to have a common base class for UI elements, but I cannot imagine it right now - they're good so far. However, it's not in the main release yet - I'm still testing it.I should learn more of Git workflows and GitHub features - making proper releases etc. Should reduce chances of pushing things that break workflows etc - I generally should have stable branches. I can't yet imagine testing because everything's asynchronous and hardware-dependent. =(
There's a TODO list growing in my text editor. Here it is for now:
Finish and refactor path_picker- Add and test display backlight management to all output drivers
- Fix Adafruit shield display backlight management
- Clean comments in UI elements
- enable instead of select when adding a wireless network
- "format_for_screen" function for text
- Test and merge input refactoring
- Make a release system
- Changing UI elements to use threading.Event
- Backlight manager documentation
- Docs, docs, docs
- Video
- Move app manager to separate class
- App for pyLCI configuration
- Enabling/disabling apps
- Updating pyLCI (properly selecting releases etc.)
- Hold/pressed/released button states
- Input stream mode
- Number UI input element
- Device monitoring&restarting
- "TODO per day" app
- Proper PiFaceCAD support
- Menu contents refresh hook
It's kinda cryptic in some places, but I do know what's what.
Till next time! -
Current state, input UI elements and ideas
08/29/2016 at 16:35 • 0 commentsHi!
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.
05/29/2016 at 19:09 • 0 commentsHi! 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
05/18/2016 at 07:05 • 0 commentsSo, 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!
Naturally, any, even your /. (The first thing I did after I finished the app. mount -a doesn't quite help when there's no mount executable available, it seems. ) I'll add a dialog box for that one - as soon as I have dialog boxes.
Partition mount support is not there and I wonder if it will actually be. I've written a partition automount daemon before. Shit's complicated. However, currently the app supports lazy unmounting, ejects and even has timeouts on calling external command so that you're not stuck with screen saying "Unmounting" for 120 seconds or whatever the timeout was, or even longer in case of a hangup =) This feature will definitely need to be transferred into "Scripts" app. Also, I need to add viewing of current pending (and stuck) unmount process statuses, should be easy.
Now, I'm waiting until I get an Arduino shield like this one:
I've got one waiting at my post office but I'm in a hospital and can't collect shipments. Fortunately, I've arranged a local purchase - so I'll have one for the hospital stay, and one more just in case =)
My hospital stay in one picture
What now? I'm looking to collaborate with @Craig Hissett on his #Handheld Programmer this week, so today I'll probably write a file browser UI element. I'll look into integrating it into Scripts application. I'll probably write an app today, but I'm not sure. Maybe a sample Twitter app - but unfortunately, you need to get all those API keys nowadays just to view tweets in your software. Sucks for me, and for users. Also, there still aren't input UI elements. =( I'll look into tackling this issue this weekend. There's a day to be spent on #ICeeData, too, and I have paid projects to do. Time is an issue, indeed.
-
Wearable assistant + hospital stay (very short log)
05/16/2016 at 19:08 • 1 commentI'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?
04/24/2016 at 16:42 • 0 commentsHow can you use pyLCI in your projects?
- 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.
- 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.
- 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.
- 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.
- 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.
- 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.
- 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 to implement "expect" with some custom extensions. That STM shield could be hackable as well, given, for example, the analog buses those MCUs have and a Raspberry Pi lacks =) It's definitely going to have room for user-defined expect scripts, most likely an SD card slot.
- Second thing is developing more easy-to-use shields. Those Chinese shields are great (and cheap!), but if I could make a shield with just the right amount of features that pyLCI needs, that'd be even cooler. For example, 5 buttons is a nice constraint, but sometimes you just need at least one more.
- I also want to try out crowdfunding on a small project. I've read a lot about all the possible crowdfunding problems and, with the ideas I periodically work on, I know I'll encounter that challenge in the future. Therefore, I'd want to test it out with a comparably non-complicated hardware project first.
-
New UI element, GPIO hardware&fixes, clock&update apps
04/22/2016 at 02:27 • 0 commentsI 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.
Soo, yesterday I wrote:
Guess I'll go to sleep now.
Well, I kinda lied. I went to sleep, but couldn't fall asleep, so I wrote a new UI element that was necessary for some future apps. It's called Refresher and while it's on the screen, it refreshes it periodically. So, you can make a stopwatch, or maybe a clock:
Docs are not done though, forgot about them =( Will be soon, though.
See that 3x6 header? It's for jumpers so you can use either SPI pins or 40-header additional GPIOs for the display, so you can use spare GPIOs on B+ and have SPI available or free up SPI and use that on older Raspberries. Also, those lacking pins in 2x40 header make it possible to use IDC cables of older Raspberries on it - those are for ID EEPROM anyway, ain't using it =) I like this shield. There's plenty to add to it, and it can be pretty powerful. I guess it would be cool to make them, then sell them or something =)
The working day's over. Oh, BTW, I just added a clock app - using the Refresher UI element, of course! I plan on making it a world clock, but today was really full and, you know, it's something. I don't feel good about it because it's the simplest app I could make, but it's all I have time to do today =)
On a second thought, I also added "Update" app. All it does is "git pull". Greatly simplifies testing, actually, I just have a feeling it might not work sometimes... Found a couple of those "sometimes", fixed... Gosh, will I get to sleep any soon?
Ah, can't post anything. Hackaday.io is down. Fucking great. Guess this log goes to my Notepad++ until morning, then I can throw it together, add some photos and so on.
Oh wait, it got fixed!
pyLCI is becoming more and more self-sufficient. It's very cool. Until it becomes sentient, of course, but there's a lot of coding to be done for that ;-)
Good night!