This week, I had to work on the algorithm part, especially I was supposed to test the algorithms given by the firm and to compile them in C to see if we can put the auto generated code directly in the embedded system.
Above all, I had to domesticate Simulink so that now, I know how to use it and I learnt a lot about the firm work. However, their algorithms weren’t really appropriate for our project so I tried to modify them to fit with our expectations. Once I did it, we had some data on which we could try out, unfortunately, Laurent told us that the files he gave us weren’t really adapted so on Saturday, he brought new data base. Yet, all the new data are already filtered so we can’t try out our algorithm on its… So this part is delayed by the acquisition part, indeed I must wait until Benoit and Alexandre get some interesting curves I can try to filter.
In theory, we are able to filter the 50Hz from our signal and to separate the ECG(ElectroCardioGram) and the parasternal EMG (ElectroMyoGram). I also wrote a small C code in order to count the number of beating heart cycle in an ECG and give the cardiac cycle.
Furthermore, all the filtering chain is written in Simulink so I looked after the auto-generated C code from our Simulink work. But I faced two main problems: the first one of course is the illegibility of the auto-generated code and the second one is that it’s very heavy and not really optimized. For example, our filter take a file as entry and in auto-generated C, this file is hard coding, which is not really useful because this file should change with time. Thus, if we want to use it we will need for sure to modify what is auto-generated which means that if we have to modify something on Simulink, every time we will need to modify the auto-generated C code. As a consequence, I think I will rewrite all the filtering algorithms in C but before I want to be sure that the algorithms are really efficient so again, I need to wait some acquisitions to be really sure…
To sum up, for this next week, I must try out filtering algorithm on our acquisition, to translate Simulink in C and begin with the PCB.
Benjamin for BreathUp 😉