Поиск сообщества
Показаны результаты для тегов 'pickit3'.
Найдено: 4 результата
-
Здравствуйте. Есть два программатора Pickit3. Один из них китайский клон, другой оригинал от Microchip. Китаец стирает калибровочную константу Pic12f629, а оригинал прошивает и проблем нет. Подскажите причину стирания константы?
-
Здравствуйте. Собрал простую схему мигания светодиодом, использую pickit3 и flowcode7 триал версию, в симуляции светодиод мигает. pic18f4550 определяется в MPLAB IPE v4.05 и прошивается, но не могу понять если запитывать от ПК и программатора схему, откуда в этом случае идет земля , где схема в этом случае замыкается. Спасибо. Target folder: C:\Users\Public\DOCUME~1 Source name: C:\Users\Public\Documents\Flowcode1.fcfx Title: Description: Device: PIC.18F.18F4550 Generated by: Flowcode v7.2.1.4 Date: Monday, November 20, 2017 14:30:34 Users: 1 Registered to: Launching the compiler... C:\Program Files\Microchip\MPLABX\v4.05\mplab_ipe\ipecmd.exe /P18F4550 /F"C:\Users\Public\DOCUME~1\Flowcode1.hex" /TPPK3 /M /OL /W3.3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ***************************************************** Connecting to MPLAB PICkit 3... Currently loaded firmware on PICkit 3 Firmware Suite Version.....01.51.06 Firmware type..............PIC18F . . Programmer to target power is enabled - VDD = 3,250000 volts. Target device PIC18F4550 found. Device ID Revision = 7 . . . . . Device Erased... Programming... The following memory area(s) will be programmed: program memory: start address = 0x0, end address = 0xff configuration memory program memory Address: e Expected Value: 44 Received Value: 40 Failed to program device Programming Target Failed. . . . . . C:\Program Files\Microchip\MPLABX\v4.05\mplab_ipe\ipecmd.exe reported error code 7 FINISHED
-
Я новичок в программировании PIC. Я создал тестовую программу, чтобы проверить, все ли работает нормально, но светодиод не мигает. Программатор: Pickit3. Микроконтроллер: PIC16F628A Возможно, я что-то неправильно делаю в разделе кода: #include <stdio.h> #include <stdlib.h> #include <pic16f628a.h> void delay_ms(int); int main() { TRISA2 = 0; //RB0 as Output PIN while(1) { RA2 = 0xFF; delay_ms(1000); RA2 = 0x00; delay_ms(1000); } return 0; } //General short delay void delay_ms(int x) { int y, z; for ( ; x > 0 ; x--) for ( y = 0 ; y < 4 ; y++) for ( z = 0 ; z < 176 ; z++); }
-
Всем привет ! Да, вот так вот. Опять светодиод и опять не запускается. В чём косяк ? Питание - от автозарядки для мобилки ( 12В -> 5В ). Среда разработки ( IDE ): MPLAB X v3.35 Linux, компилятор C18. Программатор: PICKit3 Прошивка, по-моему - нормальная. Сконфигурирован - нормально. ( Или нет ? ) Элементы все рабочие. В наличие есть кварц: 4, 8, 10 МГц. Фотка со схемкой - в атаче. Осциллографа под рукой - нет . Исходник прошивки: #include "config_bits.h" #include <stdio.h> #include <stdlib.h> void main (void) { int i = 0; TRISA = 0x00; PORTA = 0x00; TRISB = 0x00; PORTB = 0xFF; TRISC = 0x00; PORTC = 0x00; TRISD = 0x00; PORTD = 0x00; TRISE = 0x00; PORTE = 0x00; while (1) { for ( i = 0; i < 1000000; i++) { PORTB = !PORTB; } } } Файл "config_bits.h": // PIC18F452 Configuration Bit Settings // 'C' source line config statements #include <p18f452.h> // CONFIG1H #pragma config OSC = HS // Oscillator Selection bits (HS oscillator) #pragma config OSCS = OFF // Oscillator System Clock Switch Enable bit (Oscillator system clock switch option is disabled (main oscillator is source)) // CONFIG2L #pragma config PWRT = OFF // Power-up Timer Enable bit (PWRT disabled) #pragma config BOR = ON // Brown-out Reset Enable bit (Brown-out Reset enabled) #pragma config BORV = 20 // Brown-out Reset Voltage bits (VBOR set to 2.0V) // CONFIG2H #pragma config WDT = OFF // Watchdog Timer Enable bit (WDT disabled (control is placed on the SWDTEN bit)) #pragma config WDTPS = 128 // Watchdog Timer Postscale Select bits (1:128) // CONFIG3H #pragma config CCP2MUX = ON // CCP2 Mux bit (CCP2 input/output is multiplexed with RC1) // CONFIG4L #pragma config STVR = ON // Stack Full/Underflow Reset Enable bit (Stack Full/Underflow will cause RESET) #pragma config LVP = OFF // Low Voltage ICSP Enable bit (Low Voltage ICSP disabled) // CONFIG5L #pragma config CP0 = OFF // Code Protection bit (Block 0 (000200-001FFFh) not code protected) #pragma config CP1 = OFF // Code Protection bit (Block 1 (002000-003FFFh) not code protected) #pragma config CP2 = OFF // Code Protection bit (Block 2 (004000-005FFFh) not code protected) #pragma config CP3 = OFF // Code Protection bit (Block 3 (006000-007FFFh) not code protected) // CONFIG5H #pragma config CPB = OFF // Boot Block Code Protection bit (Boot Block (000000-0001FFh) not code protected) #pragma config CPD = OFF // Data EEPROM Code Protection bit (Data EEPROM not code protected) // CONFIG6L #pragma config WRT0 = OFF // Write Protection bit (Block 0 (000200-001FFFh) not write protected) #pragma config WRT1 = OFF // Write Protection bit (Block 1 (002000-003FFFh) not write protected) #pragma config WRT2 = OFF // Write Protection bit (Block 2 (004000-005FFFh) not write protected) #pragma config WRT3 = OFF // Write Protection bit (Block 3 (006000-007FFFh) not write protected) // CONFIG6H #pragma config WRTC = OFF // Configuration Register Write Protection bit (Configuration registers (300000-3000FFh) not write protected) #pragma config WRTB = OFF // Boot Block Write Protection bit (Boot Block (000000-0001FFh) not write protected) #pragma config WRTD = OFF // Data EEPROM Write Protection bit (Data EEPROM not write protected) // CONFIG7L #pragma config EBTR0 = OFF // Table Read Protection bit (Block 0 (000200-001FFFh) not protected from Table Reads executed in other blocks) #pragma config EBTR1 = OFF // Table Read Protection bit (Block 1 (002000-003FFFh) not protected from Table Reads executed in other blocks) #pragma config EBTR2 = OFF // Table Read Protection bit (Block 2 (004000-005FFFh) not protected from Table Reads executed in other blocks) #pragma config EBTR3 = OFF // Table Read Protection bit (Block 3 (006000-007FFFh) not protected from Table Reads executed in other blocks) // CONFIG7H #pragma config EBTRB = OFF // Boot Block Table Read Protection bit (Boot Block (000000-0001FFh) not protected from Table Reads executed in other blocks) Проблема: Он то ли не запускается, то ли ещё что-то. Светодиод на 30 ножке ( PORTBbits.RB0 ( B0 ) ) просто горит. А ведь в программе я прописал, чтоб весь блок B периодически переключался на противоположенное значение, но этого не происходит. Менял значения цикла от 1000000 до 10 - 0 по цельсию. Вопрос, что может быть. Может минус плохой и на монтажных схемках такого рода ( как на фотке ) собирать схемы на МК - плохая идея ? Аля нужно паять ?! Спасибо !!!