I found piklab could be a good replacement for my usual text editor for my Microchip projects with Jalv2 and SDCC.
I am wondering if I can myself add new device deffinitions to enhance this great too to comply to my needs.
For other things, I found that I can add custom compiler and programmer settings and is working great
with jalv2 and jallib and with SDCC, but for project there are limited device definitions.
Of course, if I set the proper parameter for command line is working, but I think I also can help with this.
Thank you very much,
Mihai
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
which device do you want to add? It is pretty simple if you can compile from source. In directory piklab/src/devices/pic/xml_data, there are xml files that describe all supported devices. You can find the closest supported device to the one want to add. Copy the xml file and edit it to match the datasheet.
When you are done, just recompile the project and the device should appear.
Don't hesitate to ask me if you have any problem following these steps.
Regards,
Nicolas
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
hi azhyd. i followed ur instructions and compiled piklab. ./configure works fine. make stops at certain point.
Parsing XML file "cmacros/cmacros_16X.xml"…
Warning : Different number of config names (1 != 0) for WRT/0000:0FFF
Warning : Different number of config names (1 != 0) for WRT/0000:07FF
Warning : Different number of config names (1 != 0) for WRT/0000:00FF
Warning : Different first config name _WRT_OFF for WRT/Off
Fatal : stop
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
thanks for the quick reply. i found piklab 0.15.9(ubuntu ) and 16f727 is supported in it. but i dont know how to compile it under debian using cmake. there is no config file. so i simply tried cd into the source and
../piklab_path$cmake
but cmake prints a long list of options. pls advice how to compile. i am using debian lenny.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The current version of piklab is available on Debian Squeeze, However they who must be obeyed have decided to drop piklab on wheezy when released as it uses qt3.
If you are using wheezy, (testing), enable the squeeze repos and download piklab, It works without a problem.
No need to compile.
HTH
Richard
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
hey guys. now compilation works. i just added a path infront of cmake. all the manulas simply mentioned cmake. now i have piklab 0.15.9_1 installed in debian lenny.
$cmake;pwd
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Well you can bug the SDCC developper to suppotr this device or you can use another compiler (for example there is a lite version of the picc compiler).
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have successfully created / updated PIC16F1509, PIC16F1508, PIC16F707 device information file and compiled the piklab source code including them. I have just added these xml files in the "./piklab-0.16.2/src/devices/pic/xml_data/ " directory
compiled with the instruction <cmake .> and then <make>
However neede to install few more qt and kde development packages before successful compilation.
Here I have added the code for 16F1509.xml
<?xml version="1.0" encoding="UTF-8"?><!--************************************************************************--><!--* Copyright (C) 2011 Gal Zsolt *--><!--* Updated by Abhijit Biswas *--><!--*! *--><!--* This program is free software; you can redistribute it and/or modify *--><!--* it under the terms of the GNU General Public License as published by *--><!--* the Free Software Foundation; either version 2 of the License, or *--><!--* (at your option) any later version. *--><!--************************************************************************--><devicename="16F1509"status="IP"memory_technology="FLASH"self_write="yes"architecture="emidrange"id="0x2D40"id_low_power="0x2E00"xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'xsi:noNamespaceSchemaLocation='pic.xsd'><!--* Documents ************************************************************--><documentswebpage="553474"datasheet="41609"progsheet="41573"erratas="80536"/><!--* Checksums ************************************************************--><!--* Operating characteristics ********************************************--><frequency_rangename="extended"><frequencystart="0"end="16"vdd_min="2.3"vdd_max="5.5"/><frequencystart="16"end="32"vdd_min="2.5"vdd_max="5.5"/></frequency_range><frequency_rangename="extended"special="low_power"><frequencystart="0"end="16"vdd_min="1.8"vdd_max="3.6"/><frequencystart="16"end="32"vdd_min="2.5"vdd_max="3.6"/></frequency_range><voltagesname="vpp"min="8.0"max="9.0"nominal="9.0"/><voltagesname="vdd_prog"min="2.7"max="5.5"nominal="5.0"/><voltagesname="vdd_prog_write"min="2.7"max="5.5"nominal="5.0"/><!--* Memory ***************************************************************--><memoryname="code"start="0x0000"end="0x17FF"/><memoryname="user_ids"start="0x8000"end="0x8003"rmask="0x3FFF"/><memoryname="debug_vector"start="0x8004"end="0x8004"/><memoryname="device_id"start="0x8006"end="0x8006"/><memoryname="config"start="0x8007"end="0x8008"/><memoryname="calibration"start="0x8009"end="0x800A"cal_opmask="0x0000"cal_opcode="0x0000"/><!--* Configuration bits ***************************************************--><configoffset="0x0"name="CONFIG1"wmask="0x3FFF"bvalue="0x3FFF"><maskname="FOSC"value="0x0007"><valuevalue="0x0000"name="LP"def="_FOSC_LP"/><valuevalue="0x0001"name="XT"def="_FOSC_XT"/><valuevalue="0x0002"name="HS"def="_FOSC_HS"/><valuevalue="0x0003"name="EXTRC"def="_FOSC_EXTRC"/><valuevalue="0x0004"name="INTRC"def="_FOSC_INTOSC"/><valuevalue="0x0005"name="EC"def="_FOSC_ECL"/><valuevalue="0x0006"name="EC"def="_FOSC_ECM"/><valuevalue="0x0007"name="EC"def="_FOSC_ECH"/></mask><maskname="WDT"value="0x0018"><valuevalue="0x0000"name="Off"def="_WDTE_OFF"/><valuevalue="0x0008"name="Software"def="_WDTE_SWDTEN"/><valuevalue="0x0010"name="On_run"def="_WDTE_NSLEEP"/><valuevalue="0x0018"name="On"def="_WDTE_ON"/></mask><maskname="PWRTE"value="0x0020"><valuevalue="0x0000"name="On"def="_PWRTE_ON"/><valuevalue="0x0020"name="Off"def="_PWRTE_OFF"/></mask><maskname="MCLRE"value="0x0040"><valuevalue="0x0000"name="Internal"def="_MCLRE_OFF"/><valuevalue="0x0040"name="External"def="_MCLRE_ON"/></mask><maskname="CP"value="0x0080"><valuevalue="0x0000"name="All"def="_CP_ON"/><valuevalue="0x0080"name="Off"def="_CP_OFF"/></mask><maskname="BODEN"value="0x0600"><valuevalue="0x0000"name="Off"def="_BOREN_OFF"/><valuevalue="0x0200"name="Software"def="_BOREN_SBODEN"/><valuevalue="0x0400"name="On_run"def="_BOREN_NSLEEP"/><valuevalue="0x0600"name="On"def="_BOREN_ON"/></mask><maskname="CLKOUTEN"value="0x0800"><valuevalue="0x0000"name="On"def="_CLKOUTEN_ON"/><valuevalue="0x0800"name="Off"def="_CLKOUTEN_OFF"/></mask><maskname="IESO"value="0x1000"><valuevalue="0x0000"name="Off"def="_IESO_OFF"/><valuevalue="0x1000"name="On"def="_IESO_ON"/></mask><maskname="FCMEN"value="0x2000"><valuevalue="0x0000"name="Off"def="_FCMEN_OFF"/><valuevalue="0x2000"name="On"def="_FCMEN_ON"/></mask></config><configoffset="0x1"name="CONFIG2"wmask="0x3FFF"bvalue="0x2E03"><maskname="WRT"value="0x0003"><valuevalue="0x0000"name="0000:07FF"def="_WRT_ALL"/><valuevalue="0x0001"name="0000:03FF"def="_WRT_HALF"/><valuevalue="0x0002"name="0000:01FF"def="_WRT_BOOT"/><valuevalue="0x0003"name="Off"def="_WRT_OFF"/></mask><maskname="STVREN"value="0x0200"><valuevalue="0x0000"name="Off"def="_STVREN_OFF"/><valuevalue="0x0200"name="On"def="_STVREN_ON"/></mask><maskname="BORV"value="0x0400"><valuevalue="0x0000"name="2.5"def="_BORV_HI"/><valuevalue="0x0400"name="1.9"def="_BORV_LO"/></mask><maskname="LPBOR"value="0x0800"><valuevalue="0x0000"name="On"def="_LPBOR_ON"/><valuevalue="0x0800"name="Off"def="_LPBOR_OFF"/></mask><maskname="DEBUG"value="0x1000"><valuevalue="0x0000"name="On"def="_DEBUG_ON"/><valuevalue="0x1000"name="Off"def="_DEBUG_OFF"/></mask><maskname="LVP"value="0x2000"><valuevalue="0x0000"name="Off"def="_LVP_OFF"/><valuevalue="0x2000"name="On"def="_LVP_ON"/></mask></config><!--* Packages *************************************************************--><packagetypes="pdip ssop soic"nb_pins="20"><pinindex="1"name="VDD"/><pinindex="2"name="RA5/SOSCI/T1CKI/NCO1CLK/IOC5/IPU5/CLKIN/OSC1"/><pinindex="3"name="RA4/AN3/SOSCO/T1G(1)/IOC4/IPU4/CLKOUT/OSC2"/><pinindex="4"name="RA3/MCLR/VPP/T1G/SS/CLC1IN0/IOC3/IPU3"/><pinindex="5"name="RC5/CWG1A/CLC1(2)/PWM1"/><pinindex="6"name="RC4/C2OUT/CWG1B/CLC4/CLC2IN1"/><pinindex="7"name="RC3/AN7/C1IN3-/CLC2IN0/PWM2"/><pinindex="8"name="RC6/AN8/SS(1)/NCO1(2)/CLC3IN1"/><pinindex="9"name="RC7/AN9/CLC1IN1/SDO"/><pinindex="10"name="RB7/TX/CLC3/IOC9/IPU9"/><pinindex="11"name="RB6/SCL/SCK/IOC8/IPU8"/><pinindex="12"name="RB5/AN11/RX/DT/CLC4IN0/IOC7/IPU7"/><pinindex="13"name="RB4/AN10/SDA/SDI/CLC3IN0/IOC6/IPU6"/><pinindex="14"name="RC2/AN6/C1IN2-/C2IN2-"/><pinindex="15"name="RC1/AN5/C1IN1-/C2IN1-/NCO1/PWM4"/><pinindex="16"name="RC0/AN4/C2IN+/CLC2"/><pinindex="17"name="RA2/AN2/DACOUT2/C1OUT/T0CKI/CWG1FLT/CLC1(1)/PWM3/INT/IOC2/IPU2"/><pinindex="18"name="RA1/AN1/VREF+/C1IN0-/C2IN0-/CLC4IN1/IOC1/IPU1/ICSPCLK/ICDCLK"/><pinindex="19"name="RA0/AN0/DACOUT1/C1IN+/IOC0/IPU0/ICSPDAT/ICDDAT"/><pinindex="20"name="VSS"/></package><packagetypes="qfn"nb_pins="20"><pinindex="1"name="RA3/MCLR/VPP/T1G/SS/CLC1IN0/IOC3/IPU3"/><pinindex="2"name="RC5/CWG1A/CLC1(2)/PWM1"/><pinindex="3"name="RC4/C2OUT/CWG1B/CLC4/CLC2IN1"/><pinindex="4"name="RC3/AN7/C1IN3-/CLC2IN0/PWM2"/><pinindex="5"name="RC6/AN8/SS(1)/NCO1(2)/CLC3IN1"/><pinindex="6"name="RC7/AN9/CLC1IN1/SDO"/><pinindex="7"name="RB7/TX/CLC3/IOC9/IPU9"/><pinindex="8"name="RB6/SCL/SCK/IOC8/IPU8"/><pinindex="9"name="RB5/AN11/RX/DT/CLC4IN0/IOC7/IPU7"/><pinindex="10"name="RB4/AN10/SDA/SDI/CLC3IN0/IOC6/IPU6"/><pinindex="11"name="RC2/AN6/C1IN2-/C2IN2-"/><pinindex="12"name="RC1/AN5/C1IN1-/C2IN1-/NCO1/PWM4"/><pinindex="13"name="RC0/AN4/C2IN+/CLC2"/><pinindex="14"name="RA2/AN2/DACOUT2/C1OUT/T0CKI/CWG1FLT/CLC1(1)/PWM3/INT/IOC2/IPU2"/><pinindex="15"name="RA1/AN1/VREF+/C1IN0-/C2IN0-/CLC4IN1/IOC1/IPU1/ICSPCLK/ICDCLK"/><pinindex="16"name="RA0/AN0/DACOUT1/C1IN+/IOC0/IPU0/ICSPDAT/ICDDAT"/><pinindex="17"name="VSS"/><pinindex="18"name="VDD"/><pinindex="19"name="RA5/SOSCI/T1CKI/NCO1CLK/IOC5/IPU5/CLKIN/OSC1"/><pinindex="20"name="RA4/AN3/SOSCO/T1G(1)/IOC4/IPU4/CLKOUT/OSC2"/></package></device>
Thanks.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi all.
I succesfully compiled piklab-0.16.2 on debian stretch after the addition of a PIC12F1840 device using the hints posted above.
both SDCC and gputils compile code for the new added device correctly. The only matter I have is a message in the command window after the compilation ends:
*** Success ***
Parsing COFF file: /home/rok/src/PIC/bip_step/bip_step_c/bip_step_c.cof
Could not determine processor (0x1840).
I'm pretty shure the message comes from src/coff/base/coff_object.cpp at row 576 but I have no clue on what to do to avoid the condition which lead to the message.
Anyone is able to explain what is the problem and how to address for it?
Thank You
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello,
I found piklab could be a good replacement for my usual text editor for my Microchip projects with Jalv2 and SDCC.
I am wondering if I can myself add new device deffinitions to enhance this great too to comply to my needs.
For other things, I found that I can add custom compiler and programmer settings and is working great
with jalv2 and jallib and with SDCC, but for project there are limited device definitions.
Of course, if I set the proper parameter for command line is working, but I think I also can help with this.
Thank you very much,
Mihai
Hi Mihai,
which device do you want to add? It is pretty simple if you can compile from source. In directory piklab/src/devices/pic/xml_data, there are xml files that describe all supported devices. You can find the closest supported device to the one want to add. Copy the xml file and edit it to match the datasheet.
When you are done, just recompile the project and the device should appear.
Don't hesitate to ask me if you have any problem following these steps.
Regards,
Nicolas
hi azhyd. i followed ur instructions and compiled piklab. ./configure works fine. make stops at certain point.
Parsing XML file "cmacros/cmacros_16X.xml"…
Warning : Different number of config names (1 != 0) for WRT/0000:0FFF
Warning : Different number of config names (1 != 0) for WRT/0000:07FF
Warning : Different number of config names (1 != 0) for WRT/0000:00FF
Warning : Different first config name _WRT_OFF for WRT/Off
Fatal : stop
Hi,
support for 16F727 was added to Piklab at version 0.15.9 released June 2010. You should upgrade Piklab to a more recent version.
Regards,
Nicolas
thanks for the quick reply. i found piklab 0.15.9(ubuntu ) and 16f727 is supported in it. but i dont know how to compile it under debian using cmake. there is no config file. so i simply tried cd into the source and
../piklab_path$cmake
but cmake prints a long list of options. pls advice how to compile. i am using debian lenny.
I would think you have a binary ubuntu package. If it is indeed a binary package you can probably install it using the following intructions:
http://it.dennyhalim.com/2008/11/install-ubuntu-apps-on-debian.html
To compile from source, you should follow instructions from:
https://sourceforge.net/apps/mediawiki/piklab/index.php?title=Compilation_for_Linux
The current version of piklab is available on Debian Squeeze, However they who must be obeyed have decided to drop piklab on wheezy when released as it uses qt3.
If you are using wheezy, (testing), enable the squeeze repos and download piklab, It works without a problem.
No need to compile.
HTH
Richard
hey guys. now compilation works. i just added a path infront of cmake. all the manulas simply mentioned cmake. now i have piklab 0.15.9_1 installed in debian lenny.
$cmake;pwd
but sdcc doesnt support pic16f727. any idea how to do this
Well you can bug the SDCC developper to suppotr this device or you can use another compiler (for example there is a lite version of the picc compiler).
Hi,
I have successfully created / updated PIC16F1509, PIC16F1508, PIC16F707 device information file and compiled the piklab source code including them. I have just added these xml files in the "./piklab-0.16.2/src/devices/pic/xml_data/ " directory
compiled with the instruction <cmake .> and then <make>
However neede to install few more qt and kde development packages before successful compilation.
Here I have added the code for 16F1509.xml
Thanks.
Hi,
The code for PIC16F1508 require a bit of modification on 16F1509.xml
code for PIC16F707 can be created by modifying the 16F727.xml file
Hi all.
I succesfully compiled piklab-0.16.2 on debian stretch after the addition of a PIC12F1840 device using the hints posted above.
both SDCC and gputils compile code for the new added device correctly. The only matter I have is a message in the command window after the compilation ends:
I'm pretty shure the message comes from src/coff/base/coff_object.cpp at row 576 but I have no clue on what to do to avoid the condition which lead to the message.
Anyone is able to explain what is the problem and how to address for it?
Thank You