Theo Verelst Local Diary Page 17


The same holds as for my tripod and other diary pages: nothing on this page may be copied or changed and distributed except that the page as a whole may be printed or otherwise transfered in unchanged form,  mentioning the original URL and global page reference, and that holds for everyone on the globe and beyond, including so called 'christians' and self-appointed 'Secret Services'.


Home
(alt)   Tripod Home   Local
Diary list (Secure)   Tripod Diary List   Previous Diary

Sun Feb 29 2004; 14:59:42

The above is standard notice since my family and some who I until a certain point considered friends were not exactly trustworthy in dealing with me and what I stand for, if you don't feel addressed, it means in normal language that people can't feel free to impersonate me or motherf* others into believing they represent my opinions and my life, and do so without finding my opinion against them. In public. And worldwide, I might add. At least some correction.

I felt like writing another diary page after I visited FOSDEM conference in Brussels, and after I did some programming with Gnu/Open Step Objective-C based Framework and IDE, and linked an example program with Tcl/Tk.

I put on some more stuff as I went along, and don't forget the daily (or hourly) fortune:

   God is real, unless declared integer.

Fosdem lectures

I did a Tcl/Tk BWise (1 hour) and short string simulator lecture in Belgium, which was at least fun enough, see the page above for content.

Open software, available for free for everybody, if that isn't a good production good! At least one can have nowadays a fairly decent enough unix-like os, X and a window manager most normal computer tools like openoffice and gnome/kde desktops, and now we have also freely distributable NeXTStep clones including window manager, objective-C (gnu) Project Manager, Gorm Interface Designer, and example code.

Below, I'll go into that, I guess it is good example to describe what works, and at least good for thinking.

Fairly sized conference, I don't know how many people, but more than a few hundred, atmosphere a bit what one could expect on a open source conference: programmers or wannabees through profis through hobbiists or something. A scientist here and there, core programmers here and there, weight enough.

What if microsoft would run that way: free conference, everybody free to do as they please, lots of public lectures, most about relevant subjects. Not bad.

Are the great greengrocers of software that dissatisfactory? Why would one not pay $50 or 50 euros for some package of software? Well, for one thing, if one doesn't feel free of big brother deciding on how that works, and how it fails. If one doesn't like to sign non-disclosure forms before anything. Stuff like that.

Why pay when the free stuffis also open? People still pay for courses, and I'm sure ertain software would spread just fine if it wasn't for free. But free is nicer, and open source important. How are you getting ' sobig' of your windows machine? Antu virus, fine, commercial ? What when things realy go wrong? Any serious warranty? Download the next security patch? Gmpf.

Suppose microsoft would sell groceries world wide, they would be a pretty strange bunch. And realy, with so much (ex-unix) linux stuff around for free, how many researchers, programmers, translators, package designers, salespeople and web maintainers are needed for the next XP? And how much should that all cost?

Well, when those people must all live, their wages should be paid, which until last times would be quite serious wages. But as it is?

I just found an interesting link in the context. Picture the windows guys, tied to the microsoft moloch, knowing their little or big part of mce courses (which buttons to push?), hoping to (like of course many companies) generate depence of the customers on their position and knowledge, defending themselves against major forces present in free software like linux. Well paid unix courses (I gave them myself 15 years ago...) probably teach you about some essential things more than much of the ms stuff, so how do you defend yourself? microsoft is less expensive. ... Really...

So the linux wizards, programmers, Knowledgeable Persons, or even average installers and maintainers are too well paid or something? Or linux just ins't as powerfull as ms software-wise. That would not be about much subject, I guess.

GnuStep

A decade ago, no, a bit longer I guess, the world saw the advent of a actually new computer system, with enough innovation and thought in it to at least make it interesting and fun, and it also happened to look good: the NeXT.

On it, while running a flavour of unix, the well known NeXTSTEP graphical environment for windows, standard programs, printing, etc.

Anno 2004 (a dutchism, I'm sure), parts of that environment are available as open source, and you can have it, too...

It seems to run on Linux (like I have tried) on windows (maybe X is required), on Mac OS-X, and probably on Unix. It isn't perfect, parts aren't into ß-test even yet, and some major apps like OpenWrite must be borrowed from linux burels like openstep, but it's at least fun to see again.

For some time already I had the chance to run the GNUstep desktop manager, which I like better then the kde and gnome ones, in general, though they are programmed/installed to do some things better, but that isn't the same without what I tried now:

   GWorkspace file manager and other utils like image viewing
   ProjectManager for managing compilation and source files
   Gorm a interactive interface designer

It's worth recording what is possible, first check out www.gnustep.org for getting the 4 parts of the gnustep environment, make sure you have all libraries (ffi on redhat isn't a good idea, try callff (or whatsitsname) instead) installed, than ./configure and make install the whole bunch (minutes a piece or so). If you don't have gnustep yet, you might want to get that one, and install it, or use one of the alternative step style window managers mentioned.

I'll describe the little proto application I made, assuming you have all things up and running enough, make the example 'Convertor' from the tutorial page which describes the use of project manager and gorm to make a converter window with three entries and a button, built it, an run it to see it works. Making the connections is a fun part of the idea, but a bit tricky to get right, at least it is when you use a networked X windows connection (where shm extension was missing).

Next, get the examples from one of the gnu links which makes network library demo of a echo server, which should compile fine without the manager, and test the result by either some terminal emulator allowing a socket connection or maybe even netscape (telnet://localhost:portnr) or pcom (as I use), which is a tcl/tk script I made quite some time ago, which can be instucted to connect to a certain port, which must be set to the port the echoserver prints on its standard output when started.

It should give a welcome message when connected, and than echo each incoming line. Thus far, all this can be downloaded and is existing.

My interest was in the combination of Tcl/Tk and the Objective-C compiled step interfaces, and a IDE isn't bad either, and I guess I liked the look and feel of NeXTStep from long ago, so here we go.


          The GWorkspace file manager showing the 'Convertor and net' project

The Nextstep-like file selector and shelf, with neat but limited icons in action. This thing is also available as Objective-C class for inclusion in applications, and it seems nowadays the latest MacIntosh OS-X aqua and stuff use even the same (basically) gnu compiler and object library. Lots of nifty icons and styles added, of course...

Double clicking the .pcproj project file starts the project center, where files can be addited, maintained in a project, built, and executed, where the makefile is automatically generated.

One of the examples from the GNUstep site is the converter, which can be made and compiled when you have the important step-stuff running, see this page.

       
               The converter result in action

 It's a bit of a hassle with Gorm to get the connections right, and the process is far from self-explanatory for a beginner, but it does all work, and in principle at least is worth it.

The other example I'm interested in is the netclasses echo server, which can also be downloaded via one of the Gnustep links, which should compile out of the gzipped tar (tar -xzf filename , ./configure , make install) easily, assuming you've got the right libs available, and which can be tested with pcom by adjusting the port number to what the echo tool prints at startup.

An interesting link is to combine the gorm and project center based program with the network part, to make an interactive link between tcl/tk and gnustep Objective-C programs, which is possible by adding the net files to the project, omiting main, and editing the Convertor main to include the startup code of the net main.

After some work, and including also the netlib file, the combined project (make copies by cp -R Oldproc/ Newproj/ when you want, project file defs are stored relative to main dir) compiles, and can be tested. The net and UI parts both work, but independently!

To test interaction between the UI and the socket interface to Tcl/Tk (in my test Pcom), I made the convert: method from the ConvertorManager classes only instance  set a global variable to the ID of the object (...) to be able to can conver: from the netlib method which gets called when socket data is being read.

The result? one can update the GUI under tcl control.



              The combined server / converter UI connected with pcom on top of the Project Center


To make something more real life, it would be better to know more about the GUI objectsrhan in this example, especially the instance id of the convertor manager class, which is hidden at startup.

Both gorm and project manager  may crash at times, so save regularly....

Serious stuff.



My previous university section

Apart from some of my earlier pages, for instance on tripod, I recently had another look at what is going on in the electrical engineering department and section I studied and worked.

From this section presentation (a new ordering of some old sections centered around some old persons) a picture



taken from the general internet site. I don't make this up, check for yourself.

The content? Well, 15 years ago, the main lines were hot stuff, that's when I entered then network theory section. As any layman should and any half expert would see straight away: nothing much of relevance or interest is left. Not for technical or normal university studying.

Delft was known for its fundamental angles (for instance the havierst mathematical first year foundation, esp. for EE), but it has stranded in politicized (not to mention fascist) islands-while-great-control-aspirations without the technical and fundamental foundations.

Guys claiming dsp stuff who don't know a microcontroller from an adder, let alone a neural network from a memory chip, mathematical semi-talk without ever going essential or realy making something that anyone would ever be realy interested in, probably because some 'forces' in charge know that difference, too, and the traffic control is set up to never make big-Roma lose...

Seriously, a decent, fundamental, nice even, and capable electrical engineer is supposed to know about fundamental mathematics, mathematical network theory, physics, advanced computer simulation programming, electromagnetical field theory, electronics (jeez), and of course touch on various contemporary issues.

Not that I don't assume those topics are taught, but seriously, most of the presented research stuff (which should precede education) is dead before you'd start with it, depressing.

My recent Bwise presentation and work for instance includes fairly low complexity nets for for instance basic memory cells, which is completely essential theory, which I think wouldn't even make across the threshold. Staats-feindische kunst. Yeah, right.

They should verify their EE-appropriateness against a simple, unadvaced (in that game) look at a contemporary electronics company, which makes the stuff they drag on theoretically about, like analog or another, to see what the real ee world also looks like. They wouldn't make it over THAT threshold, certainly not certain persons claiming 'professor' positions which suggest a much more elevated field of interest. Realy.

Lets say we look at http://www.analog.com just to make sure we take an ordinairy, completely common, worldwide visible, unsecret, succesfull (...) fairly big, electronics company as comparison, to have a look at what I'm talking about. What would a student graduating from 'circuits and system' or whatever name they nowadays have get from the stuf presented there, and is that ok ?

I'm sure that depending on the non-precooked curriculum choices wouldn't understand one f* (sorry about the language) of that site, almost. Let alone of even one, relatively harmless datasheet, lets say of the fundamental building block of an opamp. Or, even worse, a AD converter. You know, the stuff which is supposed to make all those 'modern' antenna arrays tick, at some point.

When I was a electronics practicum assistent (asked about, and allowed in much earlier than officially permitted after I applied), I as a sort of joke made a (imo) simple AM radio receiver with some simple enough parts (say no more than a dozen), of course not using chips, which was fun, but I don't think I could explain to some circuits-and-systems graduate what that sort of design would be about. Seriously. I don't think they'd know how to do any signal processing of such real world electronics even.

Is that because I left and supposedly didn't make it? No. I left because I started to suspect that at least some of the people were seriously bad, and didn't want to work with them, and on the other hand my project was (for me) financially killed for no good reasons (others got decently refinananced, and they sucked bad, which all my official stuff worked and was even on schedule). And in fact was was sort of destined or proposed to become a professor at some point, which was at least being communicated about, and of course I had (and have) sufficient content to proof myself badly for that, except a pile of senseless, unread publications (or peer steals) to satisfy the civil servant publication counters and desk drawers with, but hey, some people come in as wine salesman.

I don't have the ambition for aforementioned reasons to even much proof myself there, but I do have ambition enough to be taken seriously as very solid, theoretically founded, multidisciplinary, practically capable, seriously leadership capable elctrical engineer, and don't intent to allow others to take my place as a dead man in there. I hardly had competition, even though I broke every inch of my own way, and even can claim to be quite a bit of a theoretical physicist, to mention another area. I don't give my personal and professional credits away, and have never conceded to let that be tried in that dreadfull environment people may need at times to graduate and get references from.

And luckily, none of these guys (and galls ?) would know a voodoo card if it hit them in the face.

Egyptian art via IBM



I was looking around the ibm website, saw a little movie on their fully automated chip facilities and a 1/3 billion sony chip request on cell microprocessors on silicon-on-insulator technology, and came across ancient egyptian images in HUGE digital format, which looks good. You'd better have some bandwidth to download these...

Used without explicit permission...

The above is very downscaled with GIMP .

March 3 2004, 12:25

String simulator on DSP

I am working on my string simulator, and luckily have the chance to try it out on a modern digital signal processor (DSP), in this case from Analog Devices the BF533 stamp sized over 600 MHz with double ALU and MAC-like units, 16 bits memory interface (32 bit intern) and a risc-like instruction set. It's got programmable clock rate and core voltage, advanced enough interupt and DMA interfaces and a serial interface and of course timers/pwm units.

This is the board it happens to be on, which has a lot more than just the DSP and supply, in this case more than enough for profi audio development:.


   
                       BF533-HARDWARE EZ-KIT Lite™

It has 4 in and 6 out audio connectiona with 24 bit converter and 3 video in and out channels, usb developer connection, and serial and proprietary connectors, and a sort of bus connector on the back. The optical connectors I never saw in practice. The size is about a medium sigar box.

Also it has a number of pushbuttons and LEDs (lights), and it comes with a developer environemnt, wich is a fairly powerfull, except in this case the target object code is memory size limited to 20kB.

I've tried the examples, and made some more, for instance I turned the board into a echo/delay unit, and also made it startup by itself in such a way, so that it when given supply voltage in a fraction of a second would start acting as a audio delay, starting up automatically from it's 2MB flash memory, making use of the fairly large 32 Megabytes SDRAM.

Of course I played around with the switches and the leds, and I made monophone sample player which I fed with self generates sine samples (C libraries are available on the dsp!) and externally made drum sound samples.

Satisfied enough with the IDE and compiler and the audio (which sounds definately high quality on quite high standard system) as it appeared (video examples are limited), I thought I'd try the step of porting my string simulator to the DSP, which basically makes this novel physical model oriented synthesis method into a machine, possibly even a standalone unit.

The simularor, which is in prototying and research phase on cygwin (windows) and possibly linux (no sound or midi driver at the moment), is written in C, so it is worth while trying a direct port, except for the interrupt routine handling, and possible midi (which isn't at this moment present with the DSP). The DA converter can be driven via an interrupt routine, which can be supplied in C, but of course in a different way than the PAlib for the windows version, though easily comparable.

The advantage of this approach is that there is just one sample delay for the 24 bits, up to 6 channel data to arrive at the DA converter, so when the string simulator works, it can be driven with very small delay.

After trimming certain memory consuming parts down (which can be put in SDRAM or hard-coded ram positions later), porting the interrupt sound driver, this is an example of the Integrated Development Interface:




And it compiles without errors, after not much work. Even within space boundaries, and including mathematical functions in the code.

I didn't include the midi part, and first wanted to make the string simulation core and initialization work.and I included code for the dsp I prepared before to gated and triggered mode read the buttons, and also to issue a test sine note at the press of one button.

Finally, after compilation and initialisation of all the code worked, and the reading back of tables in the devenv proved correct, I linked a gated button with the simulation code as part of the interrupt routine, that is when the button is pressed the string update routine gets activated as part of the DA converter once-per-soundsample update routine, and the string computation engine is left alone when the button is unpressed.

Another button triggers a one time initialisation of a string when pressed, by calling the string initialization routine once, as part of the sound interrupt routine.

And the results? Taking a relatively short string, it works !

Pressing the the trigger button while keeping the simulator button down makes a string sound, and when the board is switched into run mode by the devenv, 2 strngs sound. When reasonable string lenths are being used, the current program is to slow, which becomes clear because the test note becomes llower, because interupts are skipped...

I didn't look into the initialisation code much, I took an formerly adapted example as frame, so it might be the clock frequency is not optimal. The clock for the dsp is made by a PLL from an input clock, and the feedback division of the phase locked loop can be given a divider which is adjustable tomake the dsp run effectively up to over 600 MHz, at 1200 MACS. The string simulator does take quite some processing power, on a recent pentium, it takes a few hunderd megaherz for a single fair length string.

Looking at the mixed C-source/assembly listing, which nicely puts the corresponding assembly under each C statement, I'd say its pretty sure that apart from more rigurous optimalisations, a serious factor of speedup should be possible in array access, much of the string simulator update sweep routine consists of additions and divide by two's while the assembly listing showed a lot of statements.

The risc dsp core, I think even with 2 MAC units should be able to do a lot in a few clock tics.


Basic electronic circuits

For me, this was for when I was 12, and very interested in what makes up all kinds of audio and other equipment. I made various audio signal mixers at the time, the better one survived way into the CD player time, and was always interested how electronical circuits were designed and made.

Assuming one knows about battery/light circuits, and Ohms law, an important circuit, as electrical engineering students get presented in all kinds of forms, too, is a basic amplification circuit. Not immedeately suitable as audio power amplifier, but just as signal amplifier for line level signals, like from a CD player, maybe a microphone or guitar, a radio, a tape deck, etc.

Most mixer circuits damp the signals they mix together, so an active mixer is often called for, which can be made in various ways, as I experimented with in lets say '78. I had this philips EE2003 electronics kit which had a way to put electronical circuits together with springs on a board, and supplied a lot of example circuit diagrams. Everybody with an electronics hobby should know the main categories: measument circuits, oscilators, amplifiers, filter, multivibrators, radios, etc.

A basic medium impedance normal audio line signal level amplifier circuit in electronics is as follows:


          Basic voltage amplifier circuit

The transistor, T1, in normal approximation multiplies the current which runs over the base/emittor (left --> right below) by a factor of ß which is in the range of 30 ... 1000 usually to run from collector to emittor (top right, botton right). Furthermore, under most realistic rest currents, the currents running through the transistors emitter when no signal is present, the voltage difference between emittor and base is about 0.6 ... 0.7 Volts. That is sufficient information to compute as realistic voltage amplifier circuit part values when for instance the rest current is supposed to be 5 milli amperes.

The signal which comes in is decoupled through a capacitor, which basically filters out the DC voltage difference between the input signal (normally no DC offset) and the base of the transistor, which is given by the voltage divider formed by R1 and R2 and the rest current through the base of the transistor. The signal will change the voltage a the base slightly, which will result in a different voltage over R4 (assuming the base emittor voltage drop remains more or less constant), and therefore in a different emittor current. The current through emittor and collector are almost the same, so the changed current also changes the voltage over the collector resistor, R3.

When we take the ratio of R3/R4 larger than one, this effect will cause voltage amplification, with an accuracy depending on the transistors current amplication factor ß, which takes part in the inherent feedback of the circuit.

The input rest voltage current divider is made with impedance in mind, we want as high as possible impedance of the input circuit to make it not load the input signal, while still giving a reliable, part variation insensitive voltage, which follows from the desired voltage at the emittor + 0.7 volt. The desired voltage at the collector is about halfway the emittor and the supply voltage V1, so that the output voltage has maximum swing.

The capacitors must be chosen to make sure the lowest frequency (20 Hz for audio) is not yet damped, while the switch on or connect transient must damp away quickly enough.