Info

La pregunta está cerrada. Vuélvala a abrir para editarla o responderla.

Bus assignment block automatically converts input data type

1 visualización (últimos 30 días)
Suraj Lal Putta Mothilal
Suraj Lal Putta Mothilal el 28 de Nov. de 2019
Cerrada: MATLAB Answer Bot el 20 de Ag. de 2021
Hello,
I am using bus assignment block to replace one of the signal in a bus. The input port of the bus assignment block is connected to switch block where the data type of the switch block output is set to uint8. But the bus assignement block converts it automatically to double. This causes a problem because later in the model a uint8 signal is expected. I don't know how to prevent this.
BusAssignmentError.png
Best Regards
Suraj

Respuestas (1)

Mark McBroom
Mark McBroom el 2 de Dic. de 2019
What is the data type of RX_Error in the bus when the bus is created? It is probably double. You will need to make the signal used for RX_Error when you create the bus to be uint8.

Etiquetas

Productos


Versión

R2017a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by