Community Profile

photo

Michael


Northern Arizona University

Last seen: 3일 전 2013년부터 활동

Programming Languages:
MATLAB

Statistics

  • Thankful Level 4
  • 3 Month Streak
  • Knowledgeable Level 2
  • Revival Level 2
  • First Answer

배지 보기

Content Feed

보기 기준

질문


ROS2 Subscriber Callback Function Arguments for Code Generation
I need to pass additional variables to my ROS2 subscriber callback function. I am trying to follow the help file explicity, whic...

18일 전 | 답변 수: 1 | 0

1

답변

질문


ROS2 Message Received Callback for Code Generation
The Question I'm trying to receive messages on a ROS2 network and exectute a callback function when messages are received. I ne...

20일 전 | 답변 수: 1 | 0

1

답변

질문


Using coder.ceval to getcwd()
I am trying to get the current working directory in generated C++ code. I think it is possible using coder.ceval() by calling th...

29일 전 | 답변 수: 1 | 0

1

답변

답변 있음
mean square error (MSE) between two graphs
Interp them so they are on the same grid and then do the regulare MSE calc? xLED_vermelho_K_INTERP = interp1(ss,xLED_vermelho_...

약 1달 전 | 0

질문


Coder RuntimeChecks Error Line Numbers
If I turn on RuntimeChecks in my coder config for C or C++ code generation (cfg.RuntimeChecks = true; codegen my_function -args ...

약 1달 전 | 답변 수: 1 | 0

1

답변

질문


ros2genmsg Error when updating to R2022b
I was able to generate/use custom ROS2 messages with R2022a, but I just upgraded to 2022b and I am not getting an error when I ...

약 1달 전 | 답변 수: 1 | 0

1

답변

질문


Coder ROS2 Build Error (colcon) with Custom ROS2 Message
I have a custom ROS2 message that am integrating into a Matlab function that is getting deployed on a remote Linux maching using...

약 1달 전 | 답변 수: 1 | 0

1

답변

답변 있음
Changing plot line colour with multiple data sets
Create a color map and then give each one a distinct color. figure; thecolors = parula(9); for i = 1:9 plot(rand(5,1),r...

3달 전 | 0

| 수락됨

답변 있음
How to write an if-else statement for a function
if n>1 f = sqrt(1 + f(n-1)); elseif n == 1 f=2; else f = NaN; end

3달 전 | 0

답변 있음
How can i make an Audio File loop continuously?
Have you read this article? <https://www.mathworks.com/help/audio/gs/real-time-audio-in-matlab.html Real-Time Audio in MATLAB> ...

3달 전 | 0

| 수락됨

답변 있음
Why do I receive this error while using a MATLAB help example?
This ran fine on my machine. See below. What version of Matlab are you using? Maybe an older version that doesn't support struct...

3달 전 | 1

질문


Code Generation Handle Object Not Defined for All Execution Paths
I have a problem where I am using a custom handle class that is allocated within an infinite while loop. At the end of each iter...

3달 전 | 답변 수: 1 | 0

1

답변

답변 있음
Convert striaght lines to smooth curves
It looks like your sample rate was too low. I'd recollect the data at a higher sample rate. You could try doing a cubic spline...

3달 전 | 1

| 수락됨

답변 있음
I need help with Matlab - FFT - getting pairs of peaks-freq in array - urgently need help
I think you need to specify the x locations (frequency in your case) in the findpeaks function, otherwise it just gives you the ...

3달 전 | 0

| 수락됨

질문


Best Ways to Save Objects with Coder Support
I have a couple of custom classes I've made for my project and I am using Coder to run my code as an executable. I am processing...

3달 전 | 답변 수: 1 | 0

1

답변

질문


Typecast a hex string to single
I have strings of hex values that I need to typecast to single precision values. I don't actually care about the actual single p...

4달 전 | 답변 수: 1 | 0

1

답변

답변 있음
undefined function error for builtin toolbox function
Did you install that toolbox when you installed Matlab? If not, run the 2021b installer again and only select the Image Processi...

5달 전 | 0

| 수락됨

답변 있음
When I try to generate C++ code for generalizedInverseKinematics I get the following error Dimension 2 is fixed on the left-hand side but varies on the right ([1 x 8] ~= [1 x
@Aravindh Deiva G, I looks like you are trying to save the output of the validatestring function over the entries in value,...

5달 전 | 0

질문


Deploying ROS2 Node with Custom Messages
I have Matlab code that includes a ROS2 node/publisher. I want to publish custom messages. This works when I run it natively in ...

5달 전 | 답변 수: 1 | 0

1

답변

답변 있음
Find matching small matrix in larger matrix
An admittedly brute force approach, but Matlab doesn't have a built in method for finding patterns in an array/matrix (at least ...

5달 전 | 0

| 수락됨

답변 있음
Vectorize comparing a column vector in a matrix to all other vectors in the matrix.
You can use repmat.m to make a matrix of the same size. a = A.a - repmat(A.a(:,1),1,size(A.a,2)) b = A.b - repmat(A.b(:,1),1,s...

5달 전 | 0

답변 있음
Filter design to remove noise
Are you talking about the high frequency stuff? Try lowpass.m

5달 전 | 0

답변 있음
Error in 'udp/UDP Receive': Received a fractional-length packet for the specified data type.
I've had this issue before and it was related to the port already being used by another process. You may want to change you port...

5달 전 | 0

질문


Current Directory for Generated Code
pwd Doesn't seem to be supported for code generation. How might one get the current directory when deploying code with code gene...

5달 전 | 답변 수: 1 | 0

1

답변

답변 있음
How can I set up unequal bin widths in a histogram?
Check out the 'BinEdges' argument. blah = randi(20,1000,1); histogram(blah,"Normalization","probability","DisplayStyle","bar"...

5달 전 | 1

| 수락됨

질문


Properly Disconnect from ROS2 Network with Generated Code
The Matlab ROS2 publish/subscribe documentation suggests using clear to remove the sample nodes, publishers and subscribers from...

5달 전 | 답변 수: 1 | 0

1

답변

질문


How to Flush Input Buffer for dsp.UDPReceiver
I am using dsp.UDPReceiver objects in my code. There are times when I put my code into an idle state. When I transition back to ...

6달 전 | 답변 수: 0 | 0

0

답변

답변 있음
How do I pre-allocate memory for a structure?
Repmat offers another solution for preallocating structures: https://www.mathworks.com/help/simulink/ug/defining-arrays-of-stru...

6달 전 | 0

답변 있음
Object Arrays in Code Generation
The answer is that it does not support object arrays. Here is the workaround https://www.mathworks.com/help/coder/ug/resolve-er...

6달 전 | 0

| 수락됨

질문


Object Arrays in Code Generation
Does code generation support arrays of custom objects? Here is a simple class. classdef MyClass properties value...

6달 전 | 답변 수: 1 | 0

1

답변

더 보기