pic16f1507dip20.py 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. """
  2. # TOP2049 Open Source programming suite
  3. #
  4. # Microchip PIC16F1507 DIP20
  5. #
  6. # Copyright (c) 2013 Pavel Stemberk <stemberk@gmail.com>
  7. #
  8. # This program is free software; you can redistribute it and/or modify
  9. # it under the terms of the GNU General Public License as published by
  10. # the Free Software Foundation; either version 2 of the License, or
  11. # (at your option) any later version.
  12. #
  13. # This program is distributed in the hope that it will be useful,
  14. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. # GNU General Public License for more details.
  17. #
  18. # You should have received a copy of the GNU General Public License along
  19. # with this program; if not, write to the Free Software Foundation, Inc.,
  20. # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  21. """
  22. from .microchip8_splittedPMarea_hasResetPC import *
  23. class Chip_Pic16F1507dip20(microchip8_splittedPMarea_hasResetPC):
  24. nLatches = 16
  25. rowSize = 16
  26. def __init__(self):
  27. microchip8_splittedPMarea_hasResetPC.__init__(self,
  28. chipPackage="DIP20",
  29. chipPinVCC=1,
  30. chipPinsVPP=4,
  31. chipPinGND=20,
  32. signature=b"\x80\x2D",
  33. flashPageSize=0x800,
  34. flashPages=1,
  35. eepromPageSize=256,
  36. eepromPages=0,
  37. fuseBytes=4
  38. )
  39. fuseDesc = (
  40. BitDescription(0, "FOSC[0], 0=LP, 00=INTOSC"),
  41. BitDescription(1, "FOSC[1]"),
  42. BitDescription(2, "Unused"),
  43. BitDescription(3, "WDTE[0], 00=WDT disabled, 11=WDT enabled"),
  44. BitDescription(4, "WDTE[1]"),
  45. BitDescription(5, "nPWRTE"),
  46. BitDescription(6, "MCLRE, 1=nMCLR/Vpp pin is nMCLR, weak pull-up enabled, ignored if LVP=1 "),
  47. BitDescription(7, "nCP 1=program memory code protection is disabled"),
  48. BitDescription(8, "Unused"),
  49. BitDescription(9, "BOREN[0], 00=BOR disabled"),
  50. BitDescription(10, "BOREN[1]"),
  51. BitDescription(11, "nCLKOUTEN, 0=CLKOUT is enabled on CLKOUT pin"),
  52. BitDescription(12, "Unused"),
  53. BitDescription(13, "Unused"),
  54. BitDescription(14, "NA"),
  55. BitDescription(15, "NA"),
  56. BitDescription(16, "WRT[0], 11=Write protection off"),
  57. BitDescription(17, "WRT[1]"),
  58. BitDescription(18, "Unused"),
  59. BitDescription(19, "Unused"),
  60. BitDescription(20, "Unused"),
  61. BitDescription(21, "Unused"),
  62. BitDescription(22, "Unused"),
  63. BitDescription(23, "Unused"),
  64. BitDescription(24, "Unused"),
  65. BitDescription(25, "STVREN, 1=Stack overflow or underflow will cause a reset"),
  66. BitDescription(26, "BORV"),
  67. BitDescription(27, "nLPBOR, 1=Low-Power BOR is disabled"),
  68. BitDescription(28, "Unused"),
  69. BitDescription(29, "LVP 1=Low-voltage programming enabled"),
  70. )
  71. ChipDescription(
  72. Chip_Pic16F1507dip20,
  73. bitfile="microchip01dip14dip20",
  74. chipID="pic16F1507dip20",
  75. runtimeID=(0xDE03, 0x01),
  76. chipVendors="Microchip",
  77. description="PIC16F1507, PIC16LF1507",
  78. packages=(("DIP20", ""),),
  79. fuseDesc=fuseDesc,
  80. maintainer="Pavel Stemberk <stemberk@gmail.com>",
  81. )