PyCharm

This is going to sound like a commercial but I’m so impressed with a new Python editor I learned about while listening to the Talk Python podcast. Wow, PyCharm is very impressive. And I’ve only just started using it. I use to use print statements and the pdb debugger to debug programs. Not to blow Microsoft’s horn but I haven’t seen anything even approaching their interactive debugging…until PyCharm. Much like MS you just click on a statement to cause a breakpoint. Then a window opens with all variables and their values is shown.

xLights

xLights [v4.2.25 Beta] working great…except Effects icon very tiny under the Sequencer tab. Posted problem in the xLights Forum under Bugs. Turns out there is a “Tool icon size” setting under the the Settings tab that fixed this. So technically it wasn’t a bug, however I can’t imagine the Small setting being useful for anyone.

I really want to get into the whole “Christmas light Show” thing which can also be used for OTHER holidays/things such as 4th of July, Halloween, New Years, announcements. My personal desired project is to create a Matrix/Grid such as 16X50 or 16 strings of 50 pixels

ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo
ooooooooooooooooooooooooooooooooooooooooooooooooo

This Matrix/Grid could be used for many things, not just a Megatree which is only for Christmas. Basically for a Mega tree you just turn this Landscape grid to Portrait mode and fan the bottom out from the top. And now I feel I have a couple of very important pieces of the puzzle. A dedicated computer running the Light show…Raspberry Pi running FPP and xLights running on Linux. However the remaining pieces are pretty expensive. At the very least I need a pixel controller at around $180 assembled, 16 strands of pixel lights at around $18-$25 a string and a power supply or supplies for the Lights. So $180 + (16x$20) + ~$40 so $540…rather steep for me. Plus I really need a board to attach the strings to. Will have to recheck prices AFTER the holidays!

Christmas Light Shows

Have been getting interested in creating Christmas Light Shows [lights or individually programmable pixels synchronized to music] recently…tis the season. Spent a couple hours just watching FPP and xLights/Nutcracker videos. I have a Pi and find this Christmas light Show technology very interesting. Especially Linux only solutions using Raspberry Pi running the FPP [Falcon Pi Player]. However it requires sequence files created by xLights. All of the videos that I watched used Windows/Mac PCs to run xLights to create the required sequence files for the FPP. I want Linux only! Created a Linux Mint VM to use to get xLights working. Binaries exist for Windows and Mac only…I think. Had to manually download source and compile on Linux. Used the “README.linux” file on gethub to do this. Got it running…apparently. Will test more tomorrow.

judoplaces

Rewrote judoplaces from MS-Access to SQLite/Python. Wow my brain really atrophied from lack of programming. It took me forever to find a simple error that Python was complaining about. Turned out it was a “if” statement case problem mispelled as “If”. Python was pointing to the variable name…not the “If”. However the code editor had pointed this out by not color coding the statement…but I didn’t notice. Next it I was convinced that the SQLite module was skipping records. Once again it was my problem of having an extra fetch statement within the loop. I should code more often. I’m sure in my case it’s a more satisfying brain exercise than anything else.

PostgreSQL security

Disappointed on how seemingly difficult PostgreSQL security is. Read several places that you do something like:

create database mydb;

then…

create user bill with password ‘password’;

grant all on database mydb to bill;

but after logging on by

psql -d mydb -U bill

then attempting to do a simple select on a table I created…I get this:

Many questions/solutions from Google about the following error

mydb=> select * from customer limit 10;

ERROR: permission denied for relation customer

WTH? It seems straight forward

Googling leads to further confusion

Many different solutions, including:

GRANT ALL ON TABLE customer to bill;

Which BTW…why should that work? If I previously granted myself all privs to the database, wouldn’t I now have all privs to tables within that DB? Evidently not, seems kind of like root creating a file in my home directory…I can’t access because root owns it. So… grant all on database, dosen’t really mean grant all, but grant most or grant all unless you didn’t create the table. Me not being able to access every file in my Linux home account isn’t as confusing because I understand the concept of permissions and ownership, but the command grant all is misleading.

So…while describing the problem I figured out the solution. The problem…at least MY problem was that I created the table within that database from postgre. Solution was to [after creating database and user within postgre] was to logon to mydb from user bill then create the table.

I believe I followed an example somewhere that showed creating a database and Role from psql under the postgre account then creating a table. I don’t think it was made clear that you should create the table from the user NOT postgre. Yes you can create the databases, user’s and table’s from postgre however evidently postgre will own those tables regardless of the fact that you granted all privs to the database to the user. For the purpose of learning commands, yes you can do everything within postgre. Perhaps “GRANT ALL ON TABLE customer to bill;” would have fixed the problem also. So for learning PostgreSQL all the commands work from postgre, however I think it should have been made cleaner that once the database and user were created that database operations on that table should be done from the user granted access to that database.

Lazarus/GAMBAS

09/20 – Really want Lazarus working. Also have a big curiosity [probably because I’ve used MS-Visual Basic] about Gambas [see farther down below]. So I feel some changes in Mint 18 along the way may have caused the problem. So I decided to Clonezilla what I have, then reinstall Mint 18. Lazarus still seemed to have problems. So installed Lazarus from Software Manager. It did install FPC but not sources.

BTW WTH do you choose? Lazarus or Lazarus IDE or Lazarus 1.6. They all say 27MB download which is way less than 3 deb files.

Having a Lazarus IDE implies that you already have FPC already installed, but why is the install size the same as a complete Lazarus install?

Warning

Without the proper FPC sources code browsing and completion will be very limited

Directory: /home/bill/Mystuff/Pascal/Lazarus/

I don’t want a crippled install. So I installed the sources from Software Manager. Which fixed that problem, however when trying to edit an existing Lazarus project…I got

Warning: directory lcl not found

Very skeptical about Software Manager’s Lazarus install

So tried to uninstall using the Software Manager which said it did it, however…the fpc compiler wasn’t uninstalled. So it really didn’t uninstall everything it installed!

What was/wasn’t installed/uninstalled?

The 3 .deb file downloads[fpc, fpc sources, lazarus] are 126.3MB which was much larger than Software Manager’s Lazarus reported install size.

So glad I cloned fresh Mint install, will restore and try installing from the .deb’s.

While installing FPC 3.0 & Lazarus 1.6 deb…

A later version is available in a software channel

You are strongly advised to install the version from the software channel, since it is usually better supported.

So…restored latest Mint clone…Installed from 3 deb files [in this order FPC, FPC sources, Lazarus

And, finally, drum roll please….It WORKED!!!

config error messages when starting IDE. My existing Lazarus Scoreboard program opened fine.

bill@bill-desktop ~ $ fpc

Free Pascal Compiler version 3.0.0 [2015/12/05] for x86_64

Lazarus 1.6 2-15-2016

Of course AFTER I let the Update Manager, update FPC & Lazarus which it wanted to do…drum roll please….It DIDN’T WORK!

So I’ve decided to restore clone and most of my other software before installing Lazarus. Since I feel I now know how to get and keep it running…install from .debs & don’t update with Update Manager.

Installing most of my other software 1st cuts down on time when I have problems with bigger, more complicated software, because some of the other software still aren’t just a simple install.

For example the Keepass Firefox plugin requires a complete mono install and a plugin placed in ‘/usr/lib/keepass2’ and sometimes a Firefox option change telling where Keepass2 is.

Truecrypt, Veracrypt, Opera and Google Chrome not are not installed by Software Manager.

G A M B A S

Because of my familiarity with Visual Basic, I have a fascination with GAMBAS, however I really haven’t used it much. It does seem like very nice project and it’s been around a long time.

I install it with Software Manager then tried to remove with the Software Manager, because I could install the latest version via a PPA but it got some status code near the end…maybe because I hadn’t closed the Software Manager. It showed in the menu but wouldn’t start. So I installed it by a PPA.

Restored clone again [maybe not the best/fastest way, but since I’ll be on this release a long time…I want my system very clean.

Install Linux Mint 18 KDE from a DVD

On a whim, I tried to install Linux Mint 18 KDE from a DVD instead of USB. Despite a few problems…it worked. Didn’t mess up my grub menu, rendering my computer un-bootable!
Want to try out Plasma…KDE 5. I had stability problems in the past, but so far so good.
Perhaps this would have worked for Antegros also!

Installed Linux Mint 18 Cinnamon also. ffmpeg is back!