PIC Vietnam

Go Back   PIC Vietnam > Microchip PIC > Chương trình dịch & các công cụ mô phỏng

Tài trợ cho PIC Vietnam
Trang chủ Đăng Kí Hỏi/Ðáp Thành Viên Lịch Bài Trong Ngày Vi điều khiển

Chương trình dịch & các công cụ mô phỏng Khu vực này chỉ có thành viên diễn đàn mới được vào

 
 
Ðiều Chỉnh Xếp Bài
Prev Previous Post   Next Post Next
Old 10-04-2008, 05:18 PM   #1
dtv
Nhập môn đệ tử
 
dtv's Avatar
 
Tham gia ngày: Apr 2008
Bài gửi: 4
:
cách thiết lập phần "Edit component" cho PIC18F4331 trong proteus 6.9??

chào các bạn,
trong proteus 6.9, trong phần "edit component" của pic18f4331, các thiết lập phải viết dưới dạng text. Mình thử mô phỏng tắt sáng led trên chân RB7, mô phỏng trong proteus không chạy, báo lỗi. Mạch thực tế thì chạy tốt. Vậy phải giải quết ra sao ( trong phần "Edit component"

Đoạn code như sau:

#include <18F4331.h>
#fuses HS,NOWDT,NOPROTECT,NOLVP
#use delay(clock=20000000)


void main(){
set_tris_b(0);
port_b_pullups(FALSE);
setup_power_pwm_pins(PWM_OFF, PWM_OFF, PWM_OFF, PWM_OFF);
delay_ms(1);
output_B(0xff);
while(1){
delay_ms(1000);
output_toggle(PIN_B7);
}
}


mình thiết lập cho 18f4331 như sau:
{PACKAGE=DIL40}
{PRIMITIVE=DIGITAL,PIC18F4331}
{MODDLL=PIC18}
{MODDATA=256,255}
{ITFMOD=PIC}
{PROGRAM=sangled.HEX}
{CLOCK=20MHz}
{CFGWORD=0x3FFB}
{DBG_RANDOM_PMEM=0}
{DBG_RANDOM_DMEM=0}
{DBG_DUMP_CFGWORD=0}
{DBG_STARTUP_DELAY=0}
{DBG_WAKEUP_DELAY=0}
{DBG_ADC_BREAK=0}
{DBG_STACK=1}
{DBG_UNIMPLEMENTED_MEMORY=1}



Lỗi như sau:

SIMULATION LOG
==============
Design: C:\Documents and Settings\DAI HOC BACH KHOA\My Documents\vinh\thu nghiem 13\DK2DCDC.DSN
Doc. no.: <NONE>
Revision: <NONE>
Author: <NONE>
Created: 04/09/08
Modified: 10/04/08

Compiling source files...
Build completed OK.
Compiling netlist...
Linking netlist...
Partition analysis...

Simulating partition 1 [6F8D47F5]...
PROSPICE Release 6.9 SP5 (C) Labcenter Electronics 1993-2006.
SPICE Kernel Version 3f5. (C) Berkeley University ERL.

Reading netlist...
ERROR: [U1] PIC18.DLL failed to create MIXED model for primitive type 'PIC18F4331'.
Reading SPICE models...
Building circuit...
Warning: Net #00000 has no DC path to ground.
Check pins: U1-RA0/AN0, X015996AC#0-*
Warning: Net #00001 has no DC path to ground.
Check pins: U1-RA1/AN1, X015996AC#1-*
Warning: Net #00002 has no DC path to ground.
Check pins: U1-RA2/AN2/VREF-/CAP1/INDX, X015996AC#2-*
Warning: Net #00003 has no DC path to ground.
Check pins: U1-RA3/AN3/VREF+/CAP2/QEA, X015996AC#3-*
Warning: Net #00004 has no DC path to ground.
Check pins: U1-RA4/AN4/CAP3/QEB, X015996AC#4-*
Warning: Net #00005 has no DC path to ground.
Check pins: U1-RA5/AN5/LVDIN, X015996AC#5-*
Warning: Net #00006 has no DC path to ground.
Check pins: U1-RA6/OSC2/CLKO, X015996AC#6-*
Warning: Net #00007 has no DC path to ground.
Check pins: U1-RA7/OSC1/CLKI, X015996AC#7-*
Warning: Net #00008 has no DC path to ground.
Check pins: U1-RB0/PWM0, X015996AC#8-*
Warning: Net #00009 has no DC path to ground.
Check pins: U1-RB1/PWM1, X015996AC#9-*
Warning: Net #00010 has no DC path to ground.
Check pins: U1-RB2/PWM2, X015996AC#10-*
Warning: Net #00011 has no DC path to ground.
Check pins: U1-RB3/PWM3, X015996AC#11-*
Warning: Net #00012 has no DC path to ground.
Check pins: U1-RB4/PWM5/KBI0, X015996AC#12-*
Warning: Net #00013 has no DC path to ground.
Check pins: U1-RB5/PWM4/KBI1/PGM, X015996AC#13-*
Warning: Net #00014 has no DC path to ground.
Check pins: U1-RB6/KBI2/PGC, X015996AC#14-*
Warning: Net #00015 has no DC path to ground.
Check pins: U1-RC0/T1OSO/T1CKI, X015996AC#16-*
Warning: Net #00016 has no DC path to ground.
Check pins: U1-RC1/T1OSI/CCP2/$FLTA$, X015996AC#17-*
Warning: Net #00017 has no DC path to ground.
Check pins: U1-RC2/CCP1/$FLTB$, X015996AC#18-*
Warning: Net #00018 has no DC path to ground.
Check pins: U1-RC3/T0CKI/T5CLKI, X015996AC#19-*
Warning: Net #00019 has no DC path to ground.
Check pins: U1-RC4/INT1/SDI/SDA, X015996AC#20-*
Warning: Net #00020 has no DC path to ground.
Check pins: U1-RC5/INT2/SCK/SCL, X015996AC#21-*
Warning: Net #00021 has no DC path to ground.
Check pins: U1-RC6/TX/CK/$SS$, X015996AC#22-*
Warning: Net #00022 has no DC path to ground.
Check pins: U1-RC7/RX/TD/SDO, X015996AC#23-*
Warning: Net #00023 has no DC path to ground.
Check pins: U1-RD0/T0CKI/T5CKI, X015996AC#24-*
Warning: Net #00024 has no DC path to ground.
Check pins: U1-RD1/SDO, X015996AC#25-*
Warning: Net #00025 has no DC path to ground.
Check pins: U1-RD2/SDI/SDA, X015996AC#26-*
Warning: Net #00026 has no DC path to ground.
Check pins: U1-RD3/SCK/SCL, X015996AC#27-*
Warning: Net #00027 has no DC path to ground.
Check pins: U1-RD4/$FLTA$, X015996AC#28-*
Warning: Net #00028 has no DC path to ground.
Check pins: U1-RD5/PWM4, X015996AC#29-*
Warning: Net #00029 has no DC path to ground.
Check pins: U1-RD6/PWM6, X015996AC#30-*
Warning: Net #00030 has no DC path to ground.
Check pins: U1-RD7/PWM7, X015996AC#31-*
Warning: Net #00031 has no DC path to ground.
Check pins: U1-RE0/AN6, X015996AC#32-*
Warning: Net #00032 has no DC path to ground.
Check pins: U1-RE1/AN7, X015996AC#33-*
Warning: Net #00033 has no DC path to ground.
Check pins: U1-RE2/AN8, X015996AC#34-*
Warning: Net #00034 has no DC path to ground.
Check pins: U1-RE3/$MCLR$/VPP, X015996AC#35-*
Warning: Net #00037 has no DC path to ground.
Check pins: U1-AVDD
Warning: Net #00038 has no DC path to ground.
Check pins: U1-AVSS
Instantiating SPICE models...
Real Time Simulation failed to start
Totaliters=0, Totalsteps=0, Goodsteps=0, Badsteps=0


Simulation FAILED due to fatal simulator errors.
Hình Kèm Theo
File Type: jpg mach mo phong.jpg (44.0 KB, 77 lần tải)
File Type: jpg thiet lap mo phong.jpg (37.4 KB, 76 lần tải)
File Kèm Theo
File Type: rar 18f4331.rar (13.4 KB, 24 lần tải)

thay đổi nội dung bởi: namqn, 10-04-2008 lúc 07:09 PM.
dtv vẫn chưa có mặt trong diễn đàn   Trả Lời Với Trích Dẫn
 


Quyền Sử Dụng Ở Diễn Ðàn
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is Mở
Smilies đang Mở
[IMG] đang Mở
HTML đang Tắt

Chuyển đến


Múi giờ GMT. Hiện tại là 10:33 PM.


Được sáng lập bởi Đoàn Hiệp
Powered by vBulletin®
Page copy protected against web site content infringement by Copyscape
Copyright © PIC Vietnam