PIC18F1320 HPWM on 2 pins


Closed Thread
Results 1 to 22 of 22

Hybrid View

  1. #1
    Join Date
    Jan 2008
    Location
    Selm, Germany
    Posts
    116


    Did you find this post helpful? Yes | No

    Lightbulb Re: PIC18F1320 HPWM on 2 pins

    Hello Richard,

    by using the right PIC you may think of something like this:

    http://www.microchip.com/wwwproducts/en/PIC16F15323

    I donīt believe PBP supports that one or similar new ones.

    Iīm shure with 10 (or 30) more IQ points I could program an older one thats supported by PBP

    but Iīm stuck to my own miserable brain.


    regards
    Mugel

  2. #2
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default Re: PIC18F1320 HPWM on 2 pins

    Actually Mugel, PBP3.1 does support the PIC16F15323. At the cost of a few extra pins might I suggest something like the PIC18F26K22. It has 2 USART ports and can run @64Hhz.
    Dave Purola,
    N8NTA
    EN82fn

  3. #3
    Join Date
    Jan 2008
    Location
    Selm, Germany
    Posts
    116


    Did you find this post helpful? Yes | No

    Default Re: PIC18F1320 HPWM on 2 pins

    ahhh,

    you are trying to talk me weak for buying PBP3?

    may work......

  4. #4
    Join Date
    Jan 2008
    Location
    Selm, Germany
    Posts
    116


    Did you find this post helpful? Yes | No

    Default Re: PIC18F1320 HPWM on 2 pins

    Hello Richard,

    i tried your example and i get compilation error "DEBUG " bad expression or "SERIN2 bad expression"

    I even used a PBP example that was delivered with my software and I get the same "HSERIN bad expression" compilation error.
    So I have a software problem but I donīt know where to search.

  5. #5
    Join Date
    May 2013
    Location
    australia
    Posts
    2,644


    Did you find this post helpful? Yes | No

    Default Re: PIC18F1320 HPWM on 2 pins

    i tried your example and i get compilation error "DEBUG " bad expression or "SERIN2 bad expression"

    a totally meaningless statement


    you need to post the complete code you are trying , also state the version of pbp you are using
    Warning I'm not a teacher

  6. #6
    Join Date
    Jan 2008
    Location
    Selm, Germany
    Posts
    116


    Did you find this post helpful? Yes | No

    Default Re: PIC18F1320 HPWM on 2 pins

    Hello Richard,

    Iīm using an old PC that runs XP Professional.
    MPLAB IDE v 7.61
    Microcode Studio 3.0.0.5
    Compiler Picbasic Pro 2.50C
    Programmer PICKIT2 and 3


    Complete Code:


    '************************************************* ***************
    '* Name : AnalogDEBUG *
    '* Author : [Davidpower] *
    '* [select VIEW...EDITOR OPTIONS] *
    '* : All Rights Reserved *
    '* Date : 05.12.2017 *
    '* Version : 1.0 *
    '* Notes : 16F88 no LCD *
    '* : Portb.7 analog IN 0-5V *
    '************************************************* ***************


    Include "modedefs.bas"

    Define OSC 4
    Define ADC_BITS 4 ' Set number of bits in result
    Define ADC_CLOCK 3 ' Set clock source (3=rc)
    Define ADC_SAMPLEUS 50 ' Set sampling time in uSec
    DEFINE DEBUG_REG PORTB
    DEFINE DEBUG_BIT 2
    DEFINE DEBUG_BAUD 9600
    DEFINE DEBUG_Mode 0
    DEFINE DEBUG_PACING 1000



    CMCON = 7 ' Disable analog comparator
    ANSEL = %01000000 ' set AN6 (RB7) as analog, others to digital
    ADCON1.7 = 1 '

    GLCDBM VAR WORD


    PAUSE 1000 ' lcd settle time
    DEBUG 10,13

    loop:
    ADCIN 6,GLCDBM ' Read channel 6 (RB7)

    DEBUG "*.*",DEC5 GLCDBM,13,10


    Goto loop

    End


    The DEBUG line gives the compiling error "bad expression"

    If I use for example :

    DEBUG GLCDBM

    then no compiling error shows up. Doesnīt mean that it works.

  7. #7
    Join Date
    Jan 2008
    Location
    Selm, Germany
    Posts
    116


    Did you find this post helpful? Yes | No

    Default Re: PIC18F1320 HPWM on 2 pins

    Hello Richard,

    to be shure I ordered PBP3 Gold and Microcode studio 5.0 today. Will see if that helps. One question: What Computer do I need for that software?

    Regards

    Mugel

Similar Threads

  1. PIC18F1320 Config Help
    By iw2fvo in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 8th June 2013, 06:31
  2. Timer 3 config for HPWM using remappable pins
    By jimbostlawrence in forum General
    Replies: 1
    Last Post: - 5th December 2012, 14:26
  3. PIC - 8 Pins - 6 Output Pins ?
    By DanPBP in forum Off Topic
    Replies: 0
    Last Post: - 22nd October 2007, 00:23
  4. Setting up 5 HPWM pins on 18F4680
    By tcbcats in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 2nd August 2006, 05:54
  5. Compiling error with PIC18F1320
    By mazlan in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 26th November 2004, 01:01

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts