Friday, 19 August 2011
CompTIA Network+
Monday, 1 August 2011
R118 — R122: own string literals
Slow slow progress! I'm in the middle of a sequence of marketing improvement courses (CompTIA A+, Network+, ITIL, Windows 7, and Windows Server 2003/2008), so the progress at sternons mkmap is proceeding very slowly. I like learning courses, so there's no real trouble, but I also would like to develop my private astronomy book plans requiring star maps, and similar. Maybe also I'll be lucky enough to get a job that contains a little C programming beside the PC-administration or networking jobs I'm preparing for.
The releases r118 to r120 slowly continued the novel dynamical object system produced by "carving plaster" – let's call it the plaster object system – but then I realized how tedious it is lacking string literals for pure 32 bit int wide strings.
Lacking those, I hacked a converter (neither a parser nor scanner – more like an oversimplistic preprocessor) that scans a file, collects strings with the syntax u"example string"
perusing
an initial nonstandard u"
as a string marker for my own string literals. Now the function ustring_to_attrib
in file pointobj.uc
is converted as follows
source pointobj.uc | target pointobj.c |
---|---|
int ustring_to_attrib(uchar *ustr) { |
int ustring_to_attrib(uchar *ustr) { |
All such 32 bits wide string constants are then collected into the file allstrings.h
, containing (among others):
static uchar _UC_R_2E_A_2E_[] = {'R','.','A','.',0}; /* R.A. */ static uchar _UC_RA[] = {'R','A',0}; /* RA */ static uchar _UC__3B1_[] = {0x3B1,0}; /* α */
The releases in chronorder:
- R118 (May 25, 2011): "More plaster carving towards dynamical classes" experimental refactorings directed from static defines to dynamic allocation
- R119 (Jun 13, 2011): "In the middle of refactoring" more mature refactorings in the same direction
- R120 (Jun 13, 2011): "More object class refactorings" more refactorings – removing a conceptual flaw: the object type identifier must (!) be stored at the same position in all objects, minor other code fixes
- R121 (Jul 22, 2011): "Further walking around Windows wide C-string limitations" novel invention – half-way wide string literal converter implemented: demo conversion seems OK
- R122 (Aug 1, 2011): "String literal converter - ucliterals" the above wide string literal converter implemented and perused in code generation
Friday, 22 July 2011
Wednesday, 20 July 2011
SVG in XHTML??
Since Blogger peruses XHTML 1.0, the following shall display as graphics if your web browser supports XHTML and SVG natively. ERROR, ERROR! However I layout the XHTML headings, Blogger adds <meta>
tags into my heading that are violating XML. The reason that the following displays a figure in gecko based browsers is that it nicely interpret the code as HTML5 containing embedded SVG:
It should look like this:

Preliminary tests indicate that it works well in Mozilla Firefox (6.0) but not in browsers using Webkit, f.ex. Epiphany and uzbl.
Mozilla Firefox 6.0β | Gecko/20100101 | YES! |
uzbl | Webkit | yes? |
IE 10 | Trident | YES! actually and surprisingly! |
epiphany 2.30.6 | Webkit | yes, but only if served as file.xhtml |
konqueror 4.4.5 | KHTML | no |
It seems my troubles are due to the immaturity of most browsers, and their general unwillingness to adapt to web standards. It also seems that Blogger serves a lot of <link>
tags that are invalid according to XML, making it impossible to adapt this blog for inclusion of SVG insets. It's just sheer luck that it works with Firefox.
The points of this experiment are
- that Blogger shrinks the pixmap images that are downloaded under the assumptions that they're photos, not instruction figures (see dynamic classes for how instruction figures becomes), embedded SVG may remedy this
- embedded SVG/MathML is the best part of the confused future HTML5 standard, and the only real advantage of HTML5, however deficient in comparison to XML embedding.
Saturday, 16 July 2011
CompTIA A+
This week I managed to take a CompTIA A+ exam. It was tough. During the course preceeding it I got the following negative reflections about it:
- the system with English learning books and English examinations in Sweden counteracts the Swedish immigrants integration into the Swedish society — Swedish examinations should be in Swedish,
- the so called computer terminology (jargon) is the worst linguistic mess imaginable, where brands are confused with technology solutions, and there's no distinctions between adapters, adapted wires/connections, or technology, everything termed with three letter abbreviations,
- one cannot explain problems to the customers using the "established" computer jargon — there's a very distinct need to educate computer professionals in presentation techniques for customers and end users.
The course itself then? Well, pretty different from university courses. I learnt a lot about the basics that is important for a computer professional. The coverage was PC and basic Windows from a problem solving perspective, but not so much about the fundamental workings of the computer and the operating system. There was nothing about Linux – that's another cram course.
Tuesday, 14 June 2011
MinGW
MinGW is a free gcc for Windows, not using the Cygwin.dll Posix compatibility layer. For the sternons tools, MinGW is to be preferred (or a purely Windows based compiler), since it is to mainly be designed to not contain any Unix or Posix related calls.
I tested to install MinGW on a VMware XP copy of mine, and compile sternons mkmap. I generated SVG:s and the result was successful. Thus: mkmap compilable under a Unix gcc, Cygwin and MinGW.
Monday, 13 June 2011
Wednesday, 25 May 2011
Sunday, 22 May 2011
Rursus, etc.
Epsilon Coronae Borealis:
154 | Quæ hanc rurſus comitatur | 13.32 ♏ | 46. 9ſb | 4 | 1 | corb | 106 |
Modern latin text:
Quae hanc rursus comitatur
I also registered on vulkan.se in order to prepare for writing an astronomy book in Swedish... L8R!
Monday, 16 May 2011
Dynamic classes
The dynamic classes are implemented as per above:
- class table: the class descriptor is just an attribute indexed (type, RA, RAΔ, etc.) array with indexes pointing out to the relative offset of the attribute in question.
- all the attributes within the class table, their names and numbers, must either be hard-coded or loaded to be known at the time when the class arrays are allocated, since each class array must be indexed by all known attributes,
- object layout: objects are allocated to contain exactly what the class array allows, and just nothing more ¹).
¹) | with the natural exception for pointers to memchunks representing objects in a quite different way |
R113 — R117: carving plaster
The latest functionality adding revision was R112 adding labels to make navigable constellations. The following revisions (currently R113 — R117) have the general intention to refactor the celestial objects in order to allow dynamical class creation to be perused in the mkmap language; the redevelopment was originally slow, actually I didn't know what class model to use.
For celestial objects, it is necessary to be able to define the classes in runtime. Therefore I'll prepare a class system with inheritance, where the class tables list what attributes are available, what types those attributes have, and in what bytes they are stored within an object of that class.
For map projections, it will suffice with hard coded projections defined in the mkmap code. I'll therefore peruse structs containing a pointer to the virtual table containing pointers to the function performing the projection on a position ⟨α, δ⟩ given certain projection parameters.
I'll document the implementations in better detail elsewhere.
The releases in chronorder:
- R113 (Mar 26, 2011): "REFACTORINGS: ..." is a self-glorifying name for: "I didn't do very much, except shuffle around the code arbitrarily"
- R114 (Apr 2, 2011): same thing also this revision
- R115 (Apr 14, 2011): added a Knobel list of star descriptors (≈ names) never used in West, but listed in Al Achsasi's calendar from 1534¹) as stars along the ecliptic, not very important
- R116 (May 7, 2011): "intermediary code chaos revision", the star struct partially replaced by plain allocated memory, working on Linux only.
- R117 (May 16, 2011): "Carving plaster" the star struct now fully replaced by plain allocated memory, working on Linux and Windows; the object types (classes) won't be readable as structs in the code.
"Carving plaster" means that I'm working outside the PL abstractions (f.ex. structs) to be compared with the furniture of the room, and working with the computer raw material "the walls": bits-n-bytes. Now the task at hand is to be directed towards documenting and coding so that I (and code readers) get a grip on how it is implemented.
¹) | Western star names are generally some kind of pronunciations of Arabic star names, f.ex. Rigel (α Orionis) is from Rijl Arabic for "foot", but those names were generally transcribed in the wake of the First Western Renaissance of circa 1100–1347, presumably from the newly conquered library of Toledo in the Reconquista where Spanish Christian powers conquered the islamic Al-Andalus step by step. Many transcriptions were severely obfuscated by misread Arabic letters. |
Saturday, 7 May 2011
Thursday, 14 April 2011
Saturday, 2 April 2011
Saturday, 26 March 2011
Monday, 14 March 2011
R112: Labels

- synergic mergers of similar structures according to C object orientation techniques – perusing similarities in struct declarations using a type tag and perhaps a virtual table implementation providing real dynamic method dispatch, such as generally invisible in C++
- thereafter program loading and map setup.
Saturday, 5 March 2011
R111: Delporte 1930 area

A note on Streaming theory – r87: that theory is dead and buried — mkmap cannot use streams because loaded data is reused again and again, and some loaded data peruses earlier loaded data. No streams, but instead database like queries.
Thursday, 3 March 2011
R107 — R110: Constellations and asterisms
The maps that were exhibited in posting "Example maps" were generated from R110 adding Constellation bounds. Revisions from R106:
- R107 (Feb 8, 2011): ripout of star struct into star.[ch],
- R108 (Feb 17, 2011): microscopic struct attribute and function renames,
- R109 (Feb 26, 2011): adding asterism line drawing,
- R110 (Mar 3, 2011): adding code for loading and drawing constellations' bounds.
¹) | Willingly: it's my church, just not the nearest church. |
²) | Capitalism sucks, truly: any system that refuses to employ a well educated healty computer engineer with full working capacity under a hot boom when there's a shortage of computer engineers, is a sociopathic system (I'm hereby mild and reconsiling). |