📄 pmsm31.lst
字号:
802 ;>>>> FOC_TI_Run(&foc);
803 ;>>>> pwm.mfunc_c1 = foc.svgen.va;
804 ;>>>> pwm.mfunc_c2 = foc.svgen.vb;
805 ;>>>> pwm.mfunc_c3 = foc.svgen.vc;
806 ;>>>> pwm.update(&pwm);
807 ;>>>> ilg2.read(&ilg2);
808 ;>>>> foc.current_abc.a = ilg2.out_a;
809 ;>>>> foc.current_abc.b = ilg2.out_b;
810 ;>>>> foc.current_abc.c = -(ilg2.out_a+ilg2.out_b);
811 ;>>>> dac.update(&dac);
812 ;>>>> #endif /* BUILDLEVEL==LEVEL3 */
813 ;>>>> #if (BUILDLEVEL==LEVEL4)
TMS320C24xx COFF Assembler Version 7.02 Wed Apr 30 15:30:41 2003
Copyright (c) 1987-2002 Texas Instruments Incorporated
../temp/pmsm31.asm PAGE 18
814 ;>>>> #if TARGET==F243
815 ;>>>> EVIFRA=0x0ffff; /* Clear all Group A EV interrupt flags */
816 ;>>>> #elif TARGET==F2407
817 ;>>>> EVAIFRA=0x0ffff; /* Clear all EV1 Group A EV interrupt flags*/
818 ;>>>> #endif
819 ;>>>> drive.calc(&drive);
820 ;>>>> FOC_TI_Run(&foc);
821 ;>>>> pwm.mfunc_c1 = foc.svgen.va;
822 ;>>>> pwm.mfunc_c2 = foc.svgen.vb;
823 ;>>>> pwm.mfunc_c3 = foc.svgen.vc;
824 ;>>>> pwm.update(&pwm);
825 ;>>>> ilg2.read(&ilg2);
826 ;>>>> foc.current_abc.a = ilg2.out_a;
827 ;>>>> foc.current_abc.b = ilg2.out_b;
828 ;>>>> foc.current_abc.c = -(ilg2.out_a+ilg2.out_b);
829 ;>>>> qep.calc(&qep);
830 ;>>>> speed.theta_elec = qep.theta_elec;
831 ;>>>> speed.calc(&speed);
832 ;>>>> foc.Mea_spd = speed.speed_frq;
833 ;>>>> dac.update(&dac);
834 ;>>>> #endif /* BUILDLEVEL==LEVEL4 */
835 ;>>>> #if (BUILDLEVEL==LEVEL5)
836 ;>>>> #if TARGET==F243
837 ;>>>> EVIFRA=0x0ffff; /* Clear all Group A EV interrupt flags */
838 ;>>>> #elif TARGET==F2407
839 ;>>>> EVAIFRA=0x0ffff; /* Clear all EV1 Group A EV interrupt flags*/
840 ;>>>> #endif
841 ;>>>> drive.calc(&drive);
842 ;>>>> FOC_TI_Run(&foc);
843 ;>>>> pwm.mfunc_c1 = foc.svgen.va;
844 ;>>>> pwm.mfunc_c2 = foc.svgen.vb;
845 ;>>>> pwm.mfunc_c3 = foc.svgen.vc;
846 ;>>>> pwm.update(&pwm);
847 ;>>>> ilg2.read(&ilg2);
848 ;>>>> foc.current_abc.a = ilg2.out_a;
849 ;>>>> foc.current_abc.b = ilg2.out_b;
850 ;>>>> foc.current_abc.c = -(ilg2.out_a+ilg2.out_b);
851 ;>>>> qep.calc(&qep);
852 ;>>>> foc.shaft_theta_elec = qep.theta_elec;
853 ;>>>> foc.shaft_direction = qep.dir_QEP;
854 ;>>>> speed.theta_elec = qep.theta_elec;
855 ;>>>> speed.calc(&speed);
856 ;>>>> foc.Mea_spd = speed.speed_frq;
857 ;>>>> dac.update(&dac);
858 ;>>>> #endif /* BUILDLEVEL==LEVEL5 */
859 0066 bf80 LALK _dac+0
0067 0007-
860 0068 90a0 SACL *+
861 0069 bc00- LDPK _dac+5
862 006a 100c- LAC _dac+5
863 006b be30 CALA
864 006c 8b90 MAR *-
865 .line 275
866 ;>>>> foc.speed_ref_rpm = mul_q(foc.speed_ref,15,6000,0,0);
TMS320C24xx COFF Assembler Version 7.02 Wed Apr 30 15:30:41 2003
Copyright (c) 1987-2002 Texas Instruments Incorporated
../temp/pmsm31.asm PAGE 19
867 006d b900 LACK 0
868 006e 90a0 SACL *+
869 006f 90a0 SACL *+
870 0070 bf80 LACK 6000
0071 1770
871 0072 90a0 SACL *+
872 0073 b90f LACK 15
873 0074 90a0 SACL *+
874 0075 a8a0 BLKD _foc+3,*+
0076 0036-
875 0077 7a80 CALL _mul_q
0078 0000!
876 0079 7c05 SBRK 5
877 007a bc00- LDPK _foc+4
878 007b 9037- SACL _foc+4
879 .line 278
880 ;>>>> asm(" SETC XF ");
881 007c be4d SETC XF
882 007d EPI0_2:
883 .line 280
884 007d 7c01 SBRK 1
885 007e 7989 B I$$REST,AR1 ;and return
007f 0000!
886
887 .endfunc 776,000000000H,1
888
889 .sym _c_int04,_c_int04,32,2,0
890 .globl _c_int04
891
892 .func 786
893 ;>>>> void interrupt c_int04()
894 ******************************************************
895 * FUNCTION DEF : _c_int04
896 ******************************************************
897 0080 _c_int04:
898 0080 7a80 CALL I$$SAVE
0081 0000!
899 0082 8180 SAR AR1,*
900 0083 b001 LARK AR0,1
901 0084 00e0 LAR AR0,*0+
902
903 .line 9
904 ;>>>> qep.indexevent(&qep);
905 0085 bf80 LALK _qep+0
0086 0027-
906 0087 90a0 SACL *+
907 0088 bc00- LDPK _qep+11
908 0089 1032- LAC _qep+11
909 008a be30 CALA
910 008b 8b90 MAR *-
911 008c EPI0_3:
912 .line 11
913 008c 7c01 SBRK 1
914 008d 7989 B I$$REST,AR1 ;and return
TMS320C24xx COFF Assembler Version 7.02 Wed Apr 30 15:30:41 2003
Copyright (c) 1987-2002 Texas Instruments Incorporated
../temp/pmsm31.asm PAGE 20
008e 0000!
915
916 .endfunc 796,000000000H,1
917
918 .sym _RstSystem,_RstSystem,32,2,0
919 .globl _RstSystem
920
921 .func 799
922 ;>>>> void RstSystem(void)
923 ******************************************************
924 * FUNCTION DEF : _RstSystem
925 ******************************************************
926 008f _RstSystem:
927 008f 8aa0 POPD *+
928 0090 80a0 SAR AR0,*+
929 0091 8180 SAR AR1,*
930 0092 b001 LARK AR0,1
931 0093 00e8 LAR AR0,*0+,AR0
932
933 .line 8
934 ;>>>> WSGR=WAIT_STATES; /* Initialize Wait State Generator */
935 0094 b940 LACK 64
936 0095 9080 SACL *
937 0096 0c89 OUT * ,0ffffh,AR1
0097 ffff
938 .line 9
939 ;>>>> disable_ints(); /* Make sure the interrupts are disabled */
940 0098 7a80 CALL _disable_ints
0099 0000!
941 .line 10
942 ;>>>> wdog.disable(); /* Vccp/Wddis pin/bit must be high */
943 009a bc00- LDPK _wdog
944 009b 1002- LAC _wdog
945 009c be30 CALA
946 .line 11
947 ;>>>> IMR=0x0A; /* Set up interrupt mask to enable INT2
948 ;>>>> until an explicit enable. */
949 ;>>>> #if (TARGET==F243)
950 ;>>>> SCSR=0x40c0; /* Init SCSR */
951 ;>>>> EVIMRA=0x0201; /* Enable the timer 1 underflow/ CAP3 (index QEP) interrupts */
952 ;>>>> #endif
953 ;>>>> #if (TARGET==F2407)
954 009d b304 LARK AR3,4
955 009e b90a LACK 10
956 009f 8b8b MAR * ,AR3
957 00a0 9080 SACL *
958 .line 25
959 ;>>>> SCSR1=0xc; /* Init SCSR */
960 00a1 bf0c LARK AR4,28696
00a2 7018
961 00a3 7808 ADRK 8
962 00a4 8b8c MAR * ,AR4
963 00a5 838d SAR AR3,* ,AR5
964 .line 26
TMS320C24xx COFF Assembler Version 7.02 Wed Apr 30 15:30:41 2003
Copyright (c) 1987-2002 Texas Instruments Incorporated
../temp/pmsm31.asm PAGE 21
965 ;>>>> EVAIMRA=0x0201; /* Enable the timer 1 underflow/ CAP3 (index QEP) interrupts */
966 ;>>>> #endif
967 00a6 bf0d LARK AR5,29740
00a7 742c
968 00a8 ae89 SPLK #513,* ,AR1
00a9 0201
969 00aa EPI0_4:
970 .line 29
971 00aa 7c02 SBRK 2
972 00ab 0090 LAR AR0,*-
973 00ac 7680 PSHD *
974 00ad ef00 RET
975
976 .endfunc 827,000000000H,1
977
978 .sym _phantom,_phantom,32,2,0
979 .globl _phantom
980
981 .func 829
982 ;>>>> void interrupt phantom(void)
983 ;>>>> static int phantom_count;
984 ******************************************************
985 * FUNCTION DEF : _phantom
986 ******************************************************
987 00ae _phantom:
988 00ae 7a80 CALL I$$SAVE
00af 0000!
989 00b0 8180 SAR AR1,*
990 00b1 b001 LARK AR0,1
991 00b2 00e0 LAR AR0,*0+
992
993
994 .sym _phantom_count,_phantom_count$1,4,3,16
995 .line 5
996 ;>>>> phantom_count ++;
997 00b3 bc00- LDPK _phantom_count$1
998 00b4 1001- LAC _phantom_count$1
999 00b5 b801 ADDK 1
1000 00b6 9001- SACL _phantom_count$1
1001 00b7 EPI0_5:
1002 .line 14
1003 00b7 7c01 SBRK 1
1004 00b8 7989 B I$$REST,AR1 ;and return
00b9 0000!
1005
1006 .endfunc 842,000000000H,1
1007
1008 .sym _rtmon_init,_rtmon_init,32,2,0
1009 .globl _rtmon_init
1010
1011 .func 848
1012 ;>>>> void rtmon_init(void)
1013
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -