dsPIC_PWM_motor.tlc problem

Post Reply
Ebap
Posts: 1
Joined: Wed Jun 06, 2012 3:15 am

dsPIC_PWM_motor.tlc problem

Post by Ebap » Wed Jun 06, 2012 5:36 am

Hi Lubin,

I am trying to do a simple program with the dsPIC_PWM_motor block but when I try to generate the code from matlab, it give me this error ''The + operator only works on numeric arguments'' (In the dsPIC_PWM_motor.tlc) I attach the error file, the installation file and the .mdl.

Matlab 2011a
C30 compiler V3.3
Blockset V3.7c
Attachments
baja.mdl
(30.63 KiB) Downloaded 567 times
installation.txt
(13.56 KiB) Downloaded 595 times
error.txt
(3.87 KiB) Downloaded 557 times

LubinKerhuel
Site Admin - Expert
Posts: 616
Joined: Wed Mar 07, 2007 11:23 pm
Location: Bayonne- France
Contact:

Re: dsPIC_PWM_motor.tlc problem

Post by LubinKerhuel » Sun Jun 10, 2012 5:54 pm

Thanks for bug report,

Will be fixed in next release.
Lubin

welf
Posts: 5
Joined: Thu Aug 16, 2012 9:41 pm

Re: dsPIC_PWM_motor.tlc problem

Post by welf » Thu Aug 16, 2012 9:43 pm

I am also affected by this problem. Any progress on a fix or suggestions for a workaround?

Thanks

EDIT: the error does not seem to appear when compiling for certain chips (e.g. 33FJ218MC or 33FJ256MC series), but does for the chip that I am using (33FJ32MC204)

welf
Posts: 5
Joined: Thu Aug 16, 2012 9:41 pm

Re: dsPIC_PWM_motor.tlc problem

Post by welf » Mon Aug 20, 2012 1:41 pm

Actually I am able to compile the resulting code in MPLAB and run it even though the build (in Matlab) aborts with an error!

The MPLAB project is not created - but I can use a previous project file created without the PWM block in the system.
The file "dsPIC_OutputCompare_Interrupt.c" is not found but it is replaced with an object file.

welf
Posts: 5
Joined: Thu Aug 16, 2012 9:41 pm

Re: dsPIC_PWM_motor.tlc problem

Post by welf » Mon Sep 17, 2012 5:28 pm

Fixed in new version! :)

LubinKerhuel
Site Admin - Expert
Posts: 616
Joined: Wed Mar 07, 2007 11:23 pm
Location: Bayonne- France
Contact:

Re: dsPIC_PWM_motor.tlc problem

Post by LubinKerhuel » Tue Sep 18, 2012 5:05 pm

Ok, Thanks for your feedback,

(As I am not very responsive at that time !)
We're preparing a new blockset suporting newer chips at Microhcip...
Lubin

nasrullah
Posts: 2
Joined: Sun Dec 23, 2012 3:47 am

PWM DC Motor

Post by nasrullah » Tue Jan 01, 2013 9:47 am

Hi Lubin,

I am trying to do a simple program to active DC motor. But when I try to generate the code from matlab, it give me this error ''Error building Real-Time Workshop target for block diagram 'motor1'. MATLAB error message: Error(s) encountered while building model "motor1".I attach the motor1.mdl below. The motor driver frequency is 40Khz. Thanks.

Matlab 2009a
MPLAB IDE v8.88 compiler 32 V2.01
Blockset V3.7e
Attachments
motor1.mdl
(27.39 KiB) Downloaded 560 times

Post Reply

Who is online

Users browsing this forum: No registered users and 22 guests