So, yesterday was productive. I stocked up on Cola&potato chips, played some games to unwind and started working on a wireless connectivity application.
I've been using wicd suite for my Linux devices, a lot. It sucked here and there, but it wasn't something extraordinary. Now I've moved on to wpa_cli because that's the option Raspbian currently ships with and I can assure you: Wicd sucks.
Now, DBus is cool. Daemons are cool, too. Python is cool. What's not cool:
- Crashes I was experiencing once in a while, with wicd-curses in particular. Shame, shame.
- Lack of documented DBus API - I needed to read through wicd_cli to get an example together, and it ain't as easy as it sounds.
- Its inability to work before somebody has logged in on the system - which is exactly the case for pyLCI on many occasions. Users don't notice that, but it's critical for my system. Has that got something to do with DBus, I wonder?
- Its inability to work with different wireless interfaces it wasn't set up to work with.
There are more, I won't go further. I'm waiting for 2.0 because, hey, the idea is still cool, but I wonder if the implementation is going to be good.
What else? Wpa_supplicant is great. It's great for scripting, too. Unlike bluetoothctl, say - that's why there's no Bluetooth app in pyLCI yet, doesn't seem to be easy to do it properly!
Wpa_cli is wonderful for scripting. It was also easy to parse through its output. I had a library for it in, like, a couple of hours. This library can even act as a standalone Python-based wpa_cli interface. I think my favourite part was writing that library in 250 lines, then shrinking those to 180 much more beautiful lines while adding plenty of things =) When I got finished having fun, I wrote a pyLCS wrapper application. Now there's a wrapper (pyLCS) around a wrapper (my library) around a wrapper (wpa_cli) around a wrapper(wpa_supplicant) around a wrapper(wireless driver) around a wrapper(ioctls and stuff)... Sorry, couldn't resist. Maybe wrappers are all operating systems are around. (Nevermind, they also help calculate things sometimes... Or do they wrap around CPU capabilities?)
Now is time for last minute changes that I won't be able to do after v1.0 - such as changing init arguments for things, or finally changing the project's name. It's pyLCI now, you can see that, and if you see something else somewhere, do notify me =) I changed arguments for Menu to more intuitive input, output, instead of output, input - you know, that's not how I'm used to recount these.
...
Right now I'm opening input.py file. I'm quite excited. I've still got a video to complete and stuff, but this is also necessary. Or it isn't, whatever. I have to get rid of it as soon as possible, the sooner, the better.
nano input.py
...
Good news. It was easy and rewarding. Bad news. There's a loop somewhere in new input system which is a CPU hog. ... Actually, never mind. I understood the reason while I was writing this sentence and fixed it.
Also, I cleaned up the output.py file. I didn't refactor it, just deleted a lot of code I planned to use that I'm sure I won't. This code is long implemented in v2.0 and already planned to be refactored =)
I added a Printer UI element. Capable of both printing strings and lists of strings, it's quite valuable. You can also skip something by pressing Enter on your input device =)
I started my documentation with Sphinx and autodoc. It was easy and I'm now writing docstrings, a lot of them =) Already documented existing input modules and UI elements.
Sorry, I just finished documenting input modules and understood I'm feeling sick and terribly sleepy. I'll go to sleep, right now. Making this log more verbose, testing code and pushing to GitHub is first thing when I wake up =)
Woke up. Feeling better, so I can continue working =) Talking about documentation, it's complicated. My main modules don't depend on any custom Python libraries, but my input modules, for example, do. The problem is that I'm using autodoc for these, and planning to push everything to ReadTheDocs so that, you know, the documentation is actually available to others. ReadTheDoc builds my docs on its own, however, so it won't be able to import all kinds of Python modules I'm using since many of them are using C libraries - such as evdev. That might take more time than I have, I'm afraid. Will se how this can be worked around.
I don't remember anything else worth recording in the log. Not that the things described before aren't enough. It seems I didn't take any pictures. (Of me typing on my keyboard?) I did, however, make a first promotional video for my system and will start processing files from the camera right now =)
Starting the next day and the next build log. What's now? Well, video. Also, I have to document output devices and possibly make a HD44780 lib of some sorts for them where I can describe init sequences and commands. Not to mention I need GPIO-connected LCD driver made!
Also, I need an ability to set custom key mappings to input devices - will probably make a base class of some sort and make an "mapping_file" argument so that you can have multiple driver instances running for different devices and combine all of their key in your application =) Then, maybe some simple apps (not Bluetooth though, that needs at least a spare day, I don't think that'll be released till 1st.). For example, I can write an app to manage systemd units and services, wouldn't that be good? If I have enough time today, I'll also make 'evdev' input devices and test my system fully on an another Raspberry with PiFaceCAD, as well as with MCP23008 output driver.
I have no extra days left. There seems to be more and more to be done before launch, I just don't know. On top of that, I still need to write promotional materials. Sucks. Hope I manage to do it in time.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.