▷ Practice 5B #TSCLAB: Activation of Transistor 1 and 2, also Temperature sensor 1 and 2 reading

 ⭐⭐⭐⭐⭐ Practice 5B #TSCLAB: Activation of Transistor 1 and 2, also Temperature sensor 1 and 2 reading

Objetivo general:

  • Visualizar los datos resultantes empleando código de Matlab.

Materiales:

  • Programa Cool Term
  • PCB de Temperature Control Lab (TSC-Lab)

Procedimiento:

  1. Ir al siguiente repositorio: https://github.com/vasanza/TSC-Lab/tree/main/Practice5b
  2. En el repositorio encontrará la carpeta completa que usaremos en Matlab, donde se incluyen funcionalidades.
  3. Para fines explicativos, a continuación solo detallamos el código main que usted encontrará en el repositorio.
  4. Luego de ejecutar el código de Matlab, podemo realizar las prácticas 13 y 14.

TEMPERATURE AND SPEED CONTROL LAB (TSC-LAB)

Práctica 5: Activation of Transistor 1 and 2, also Reading of temperature sensor 1 and 2

Raw dataset preparation

clear;clc;%clear all
addpath(genpath('./src'))%functions folders
datapath = fullfile('./data/');%data folder

Raw dataset preprocessing

filenames = FindCSV(datapath);%List All CSV files
data=readtable(fullfile(datapath,filenames(1).name));%Select i CSV file
data=table2array(data);
DataNorm = fNormalization(data(:,1:2));%Normalization
DataFeatures = [max(DataNorm) min(DataNorm) mean(DataNorm)...
median(DataNorm) rms(DataNorm) std(DataNorm) ];%Feature extraction

Plot Raw TSC-LAB dataset

figure
plot(data);xlabel('Samples');ylabel('°C');
title('Temperature');
legend('Temp1','Temp2','PWM1','PWM2');

Plot Normalization EOG dataset

figure
plot(DataNorm);xlabel('Samples');ylabel('Normalized Values');
title('Normalized EOG data graph');
legend('Temp1','Temp2');

Select a case

num = input('Enter a case: ');
switch num
case 1 %Temp1
IN=data(:,end-1);%temp1
OUT=data(:,1);%PWM1
case 2 %Temp2
IN=data(:,end);%temp1
OUT=data(:,2);%PWM1
case 3 %Temp1 and Temp2
IN=[(data(:,end) + data(:,end-1))/2];%temp1
OUT=data(:,1);%PWM1
end
figure
plot(OUT)
title('OUT');

System Identification

ident
Warning: The "ident" command is obsolete and may be removed in a future release of MATLAB. Use the "systemIdentification" command instead.
Type HELP MIDPREFS if you want to move this file.
Created preference file C:\Users\vasan\Documents\MATLAB\idprefs.mat.

Open the Classification Learner

%regressionLearner
%classificationLearner

Read related topics

Comentarios

Popular Posts

▷ Especificaciones del módulo ESP32

▷ #ESP32 - REAL-TIME CLOCK #RTC INTERNO

▷ #ESP32 - SINCRONIZAR RTC INTERNO CON SERVIDOR NTP

▷ #ESP32 - Display OLED 128x64

▷ #ESP32 - Over-The-Air programming #OTA

▷ #ESP32 - #MQTT (Introducción)

▷ PROTEUS PCB DESIGN

▷ DISEÑO DE SISTEMAS DIGITALES, PROYECTOS PROPUESTOS (2019 2do Término)

▷ SISTEMAS EMBEBIDOS, PROYECTOS PROPUESTOS (2021 PAO1)

▷ #ESP32 - INSTALAR LIBRERIAS DESDE GESTOR LIBRERIAS ARDUINO