DC Second Semester

DC theory course

If you are a student of the Energy department at AAU, you are going to attend a course at the second semester called “Introduction to Electrical Engineering” also referred to as “DC”. This is a basic course on different direct current electrical components, how they act and which rules apply to them. While I was studying for my exams in this course, I came across a website called Electronics tutorials. The website contains tutorials on many different elements within the electronics world. I can highly recommend it for use as a supplement to the DC course at AAU.

Data Homer Matlab P2

Importing time series to Homer

For our P2 project we are currently working towards a goal of obtaining the most efficient household setup of PV solar, hybrid inverter and storage batteries. This setup is of course connected to the grid.

Using the Homer software to run simulations is very useful in obtaining our main goals in the project, but it also feel pretty useful to have knowledge working with it when returning to work in the industries after receiving our masters.

Anyhow. The timeseries load profile we wanted to use in our project originated from my own personel load profile from a local electricity supplier formerly known as “SE” which know goes by the name “Norlys”. Unfortunately the only way to get one year of hourly usage on your laptop is by manually clicking 3 times each time you download a file, bear in mind that each file only hourly data for one day, so this proces has to be repeated 365 times to download data for a complete year.

Finally with the data downloaded and trying to import it to Homer, it would not work. Homer simply does not recognize the format supplied by Norlys.

I turned to my trusted friend Matlab, and by writing a script suitable for our situation Matlab easily digested through all of the files trimmed and compiled the load data into a single .csv file which then could be easily imported to Homer.

The hardest thing for me was to find out what sort of format Homer would accept. There is little help to find on their website here, but that did not help me all to much, mainly because I don’t know too much about formatting .csv files. (I know it is comma separated ūüôā ) What I did find out eventually was that if I just simply use a one column csv format Homer would recognize it and put all my data in the right spot. So this was what i did, i simply created a single .csv file containing all the hourly load data, and from this data Homer accepted it and added it to the respective dates with no problems whatsoever.

Not sure how well you can use my matlab code for this project, but I will put it up here just in case. I have the script placed in main folder, and “jan”,”feb”…etc. are all subfolders containing the downloaded time series from Norlys. When I refer to the 3rd column, it is simply because this is the place of the load data in the downloaded file, the tweaking must be up to you guys ūüėČ

% Matlab Script
% Creating suitable time series load profile for Homer Pro Grid Software
% Created by Esben Uth
% Energy Department
% Aalborg University Esbjerg
%clean up
%output script start to command line
disp('Conversion started');
%create empty matrix to hold all load data
M = zeros(1,1);
%run through all subfolders
sf = {'jan', 'feb', 'mar', 'apr', 'maj', 'jun', 'jul', 'aug', 'sep', 'okt', 'nov', 'dec'};
for k = 1:12
    %define folder
    myDir = sf{k}; %gets directory
    % count number of files in folder
    myFiles = dir(fullfile(myDir,'*.csv')); %gets all csv files in subfolder
    % start the for loop, extracting data from all the files in the folder.
    for i = 1:length(myFiles)
        %construct file name
        baseFileName = myFiles(i).name;
        fullFileName = fullfile(myDir, baseFileName);
        %read file and move data from .csv file to the T variable
        T = readtable(fullFileName, 'Delimiter', ';', 'PreserveVariableNames', true);
        %convert table to cell
        T = T{:,:};
        %read data from the file
        load_data = T(1:24,3);
        date_data = T(1:24,1);
        %trim data before appending them to the matrix
        load_data = strrep(load_data,',', '.');
        load_data = str2double(load_data);
        date_data = strrep(date_data,'-', '/');
        date_data = str2double(date_data);
        %create temporary matrix
        temp_data = [load_data];
        %append new data to the matrix
        M = [M;temp_data];
        %output part done to command line
        disp(fprintf('File %d of %.0f in %s converted.', i, n_files, sf{k}));
%delete first row of matrix
M(1,:) = [];
%write load data into .csv file
%output script end to command line
disp('Conversion complete');
Data Matlab P1 Project

Read data from KeySight 34450A Digital Multimeter

My group just finished off an experiment in which we had to read data from the log of a KeySight 34450A Digital Multimeter.

I tried to read the data using different approaches. The KeySight bundle did not work with the instruments on AAU Esbjerg because apparently they are bought without a license.

I found out that you can connect the instrument to Matlab, and read the data this way. Unfortunately I didn’t get all of the data using this method, so I found another way.

First you have to download and install this piece of software.

Next you start the newly installed “Keysight connection Expert 2019

KeySight Connection Expert 2019 Overview
As you can see in this example my instrument are no longer connected, therefore it is marked with a red X

In here you’ll find a tab on the left side, showing new and former connected instruments. If you have one instrument connected it should have a green mark on it.

Click the instrument and then in the right tab click “Interactive IO“.


A new windows opens where there is a textfield for writing commands. In this field you write the command: “DATA:DATA? NVMEM” and click “Send and read“.

The instrument will now write out all data saved in the log, you can now copy this into a file or program of your choice. Personally I saved the data into a .csv file, since the data the instrument spits out are already comma-seperated for each log-input.

Matlab handles these files pretty well, but this will be a post for another time.


AK slut

S√• n√•ede jeg i m√•l med mit f√łrste √•r p√• Aalborg Universitet. Nu er Adgangskurset til Ingeni√łr uddannelserne overst√•et, og jeg gl√¶der mig meget til at starte til September p√• Energi ingeni√łr studiet. Det har v√¶ret et meget kr√¶vende √•r det kan slet ikke diskuteres, men samtidigt har det ogs√• v√¶ret et utroligt l√¶rerigt √•r. Man form√•r virkeligt at finde ud af hvor meget viden man kan presse ind p√• utrolig kort tid, og jeg er vildt imponeret over ikke bare mig selv, men ogs√• alle mine studiekammerater. Det er noget af en kamp vi har v√¶ret igennem, og vi kan alle v√¶re stolte af hvad vi har opn√•et! Nu skal der holdes sommerferie og slappes af. S√• ser vi hvad jeg vender tilbage med til September.

God sommer til jer alle derude ūüôā


Office 365 og iCloud

Siden jeg k√łbte en ny pc i stedet for min mac til studiet, har jeg haft k√¶mpe problemer med, at f√• min iCloud mail og kalender synkroniseret med outlook. I aftes lykkedes det endelig.

Jeg har installeret iCloud p√• min pc, og hver gang jeg pr√łver at koble den til mit outlook kommer f√łlgende besked: ‚ÄúIndstillingen kan ikke forts√¶tte, fordi Outlook ikke er konfigureret til en standardbeskrivelse. Kontroller Outlook-indstillingerne og pr√łv igen.‚ÄĚ Jeg har pr√łvet mange forskellige ting. Men f√łlgende guide virkede for mig og det tog ikke specielt lang tid. Det kr√¶ver lidt kommandoer i windows powershell, men guiden forklarer meget godt, hvad der skal g√łres. (hint: powershell f√•s frem ved at h√łjreklikke p√• windows ikonet i nederste venstre hj√łrne.)

Adgangskursus Dansk Posts

Idehistorie i Dansk på AAU AK

P√• adgangskurset til at blive ingeni√łr p√• AAU, vil i, i dansk g√łre brug af Idehistorie del. 1 og 2. B√łgerne omhandler den vest-europ√¶iske filosofi historie og kan udover at v√¶re sp√¶ndende l√¶sning, godt virke lidt tungt i starten.

Et godt supplement til teksterne (om det er s√• er for at f√• en bedre forst√•else, eller fordi man bare ikke kan f√• nok af filosofien) kan v√¶re DR’s podcast omkring selvsamme emne. Podcasten er opdelt i 12 dele, der f√łlger meget godt i takt med de emner og personer der bliver behandlet i Idehistorie. Samtidig viser den ogs√• mange af emnerne fra sider der ikke oplyses i Idehistorie. Podcasten findes p√• f√łlgende link: