Do you know Mnemosyne? It's an excellent tool for learning flash cards. The only problem is that the computer is an evil distraction machine. So you might decide one day, that you want you print your flashcards to learn them the old school way, which means double sided printing questions and answers out on paper.
Unfortunately Mnemosyne does not have the ability to print flash cards with the question on the front and the answer on the back in double sided print. However flash cards can be exported to xml which can be converted to printable html with the following script. The Python script is a bit shaky and you might have to adapt it for your own needs, but it did the job for me.
This blog is supposed to be a collection of random, unrelated, little ideas, thoughts, and discoveries, which I assume to be helpful to a negligible part of the world's population and wish to share out of pure altruism. If posts appear really weird, maybe you have the wrong kind of humor. Many of the posts are science/technology related. If you are opposed to that, stop reading here! Comments, criticism, corrections, amendments, questions are always welcome.
2011-08-23
Mnemosyne Print Flash Cards on Dead Wood
2011-08-20
Python Constant Madness
Somehow Python does and does not have constants. The following examples, which can be tried out on the interactive interpreter, are of not much practical use, but interesting however:
Even the built-in constants True and False can be overwritten with arbitrary content. This flexibility is probably rarely required and if this happens by accident, the logic of the following program is most likely screwed.
Type "help", "copyright", "credits" or "license" for more information. >>> temp_true = True >>> temp_false = False >>> True = temp_false >>> False = temp_true >>> True False >>> False True
Even the built-in constants True and False can be overwritten with arbitrary content. This flexibility is probably rarely required and if this happens by accident, the logic of the following program is most likely screwed.
>>> True = "hello world" >>> True 'hello world'Ruby does have a little advantage here, since it does not allow assigning new values to true and false.
2011-08-18
SVN Version Control with Xilinx ISE Projects
Maybe you have had the pleasure to work with Xilinx ISE already. A serious problem of ISE (version 13.2 at the time of this posting) is, that it has no support for version control like SVN. The project folder is a mess of generated scripts, reports and many other relatively useless files, which should not go into version control. However just adding all .vhd and .ucf files is not a good solution, because Wizards for IP generation cannot be used anymore. The 'Clean Project' Function within ISE is only an incomplete way to get rid of all unnecessary files.
A decent but working solution was to experiment a little which files are necessary and which ones aren't and use this information to create simple scripts which add necessary files to version control and set the svn ignore property to ignore the junk files. Albeit simple, these scripts have shown to be quite handy.
A decent but working solution was to experiment a little which files are necessary and which ones aren't and use this information to create simple scripts which add necessary files to version control and set the svn ignore property to ignore the junk files. Albeit simple, these scripts have shown to be quite handy.
2011-08-09
Using the Xfig Library in Inkscape
Maybe you have used Inkscape before. It's a remarkable tool for creating vector graphics.
Sometimes it would be helpful to have a library with predefined images for all kinds of purposes (eg. arrows, symbols for schematics, fighter aircrafts, origami folding,...). An older program that is less frequently used to today, but comes with a nice library is Xfig.
Xfig has it's own file format which is a little unhandy. The following script can be used to convert the entire Xfig clipart library to .svg files. It works under Ubuntu. The package transfig is required for the conversion.
Sometimes it would be helpful to have a library with predefined images for all kinds of purposes (eg. arrows, symbols for schematics, fighter aircrafts, origami folding,...). An older program that is less frequently used to today, but comes with a nice library is Xfig.
Xfig has it's own file format which is a little unhandy. The following script can be used to convert the entire Xfig clipart library to .svg files. It works under Ubuntu. The package transfig is required for the conversion.
Subscribe to:
Posts (Atom)