1. Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.
    Dismiss Notice

Junebug help??

Discussion in 'Microcontrollers' started by MrDEB, Apr 8, 2009.

  1. MrDEB

    MrDEB Active Member

    Joined:
    Apr 16, 2007
    Messages:
    4,414
    Likes:
    23
    I think I am stupid or something
    I connected the junebug to the usb port
    have dip switches 1,2,3 =on all others off
    I get a yellow and green led light on=power and target power
    the 3rd red led (row of 6)(from the left) is only slightly on, very dim
    got mplab running but now what??
    get pickit2 not dected then it says ready?? see screen shot
    how do I see the leds blinking back and forth etc? or do the hello world thingy
    missing something in the directions or ??
     

    Attached Files:

  2. mvs sarma

    mvs sarma Well-Known Member

    Joined:
    Oct 29, 2006
    Messages:
    3,512
    Likes:
    76
    Location:
    Hyderabad, India.
    did you compile the sf basic file using sf SE compiler and you should get a hex file out
    but irrespective, when pickit 2 is initialized, it should turn on provided the main chip PIC18F2550 has the firmware. the three lamps at the top blink for few times and it would say pickit2 ready and device found 18F1320
     
  3. blueroomelectronics

    blueroomelectronics Well-Known Member

    Joined:
    Jan 21, 2007
    Messages:
    12,536
    Likes:
    170
    Location:
    Toronto, Canada
    Use the PICkit2 2.61 software first as this has troubleshooting, firmware update and target autodetect. If all is well it should see a 18F1320.
     
  4. dave

    Dave New Member

    Joined:
    Jan 12, 1997
    Messages:
    -
    Likes:
    0


     
  5. MrDEB

    MrDEB Active Member

    Joined:
    Apr 16, 2007
    Messages:
    4,414
    Likes:
    23

    well I think I am getting somewhere?

    I reinstalled pickit2.60
    then holding down the button under chip #3 I got the red busy led to start flashing
    then loaded the OS (it said to load an OS)
    ran a blinking led file and go one led blinking
    tried the hello world screen but no hello world like in the junebug manuel?
    tried several different things.
    am I supposed to clear memory first=did that then WRITE then checked the on box.
    I wish the directions were a step by step or maybe I just don't get it??
     
  6. 3v0

    3v0 Coop Build Coordinator Forum Supporter

    Joined:
    Jul 14, 2006
    Messages:
    9,404
    Likes:
    227
    Location:
    OKLAHOMA USA
    Too many people attempting to help can be bad.

    But I think you are not undertanding what bill ask you to do.

    Using the PICkit2 software. Under the tools menu. Click TROBLESHOOTING and follow the instructions.

    But that only works if the PICkit2 can find the junebug. If it does it will ID what chip is connected 18F1320.

    You should not be tring to blink LEDs yet.

    3v0
     
  7. blueroomelectronics

    blueroomelectronics Well-Known Member

    Joined:
    Jan 21, 2007
    Messages:
    12,536
    Likes:
    170
    Location:
    Toronto, Canada
    Does the Junebug see an 18F1320? Can you post a photo of your Junebug (some folks put the DIP switch in upside down so you have to flip the top 3 switches the opposite way)
     
  8. MrDEB

    MrDEB Active Member

    Joined:
    Apr 16, 2007
    Messages:
    4,414
    Likes:
    23
    It appears to work?

    maybe I am missing something?
    posted screen shots
    the one led blinks when I run the program, at least I think I am running the program
    what am I supposed to do to see the uart screen saying "hello world"
    I open the uart screen, 9600 baud, asc11 but then what??
    dip switches are in correct=the word tutor is under the right side of the dip switches and the 1,2,3 switches are to the right
    the 5 remaining switches are to the left
    am sure or pretty sure that I am missing something very simple
    like maybe moving a switch then reading the 18f1320 or ??
    it says the hex file loads successfully
     

    Attached Files:

  9. blueroomelectronics

    blueroomelectronics Well-Known Member

    Joined:
    Jan 21, 2007
    Messages:
    12,536
    Likes:
    170
    Location:
    Toronto, Canada
    DIP switch #1 will disconnect (when off) the MCLR/VPP control from the programmer. Try turning it off after you have programmed the 18F1320, this will put the chip in RUN mode but the programmer cannot see or control it in this mode. For the UART tool test program to work the TX & RX DIP switches should be ON and all others OFF, run the UART tool @9600 and you should see the hello world data on the terminal screen.
     
  10. MrDEB

    MrDEB Active Member

    Joined:
    Apr 16, 2007
    Messages:
    4,414
    Likes:
    23
    turned on 4-8 oups!

    I reread your post nd realized my mistake.
    all hell broke loose as the juney wouldn't even communicate with the pickit2
    going to try again tomorrow.
    juney wants a bedtime story
    something about the 3 little ic's and little miss pic eating the bowels of electrons and sleeping in dip sockets.


    LOL

    going to strat out fresh tomorrow morn
     
  11. MrDEB

    MrDEB Active Member

    Joined:
    Apr 16, 2007
    Messages:
    4,414
    Likes:
    23
    well Juney is working but??

    I typed in the prg from the assembly manuel and I get invalid program or module.
    suggestion to Blueroom = great unit but needs some tweeking as far as the user manual
    am curious about the CON5 output? can't wait to connect a speaker and program my deer chaser
    I plan on using this for my deer project
    the picture on page 2 shows a ribbon cable going from ??
    I assume from ICD #6 in pic to CON3 #7 in pic
    the HELLO WORLD should include a sentence explaining about switching dip sw1 to off and TX & RX on
    I am going to have fun with this little bug.
    just need to compute the language syntax , spaces and capitalization
    on the back n forth led prg I wonder if just incrementing the port address instead of (LED b '00000001' etc. the hex numbers are the port address?
    chopping at the bit in Idaho
     

    Attached Files:

  12. blueroomelectronics

    blueroomelectronics Well-Known Member

    Joined:
    Jan 21, 2007
    Messages:
    12,536
    Likes:
    170
    Location:
    Toronto, Canada
    I'm always looking for improvements to the manual. Or new project for JPUG.

    I'll try to add a DIP switch guide that's clear to understand.

    The ribbon cable is the external ICD/ICP cable. The Mongoose photo on my homepage shows the Junebug programming the Mongoose 18F2525.
     
  13. MrDEB

    MrDEB Active Member

    Joined:
    Apr 16, 2007
    Messages:
    4,414
    Likes:
    23
    Really like your sketchup drawings

    I use sketch up from time to time.
    have tried using the jpeg of an expresspcb silkscreen layer then trying to use the push pull to draw a 2D of the board.
    not much success but trying different things.
    this should work?
    are your sketch up models to scale?
    would love to try hand at doing some Junebug models showing set up of dips etc.
    I noticed your pic of a Junebug connected to a robot? but the tutor dips 1-3 are all on Is this right?
    Another question is when I want to program a pic, do I insert in place of the tutor chip or can I program in circuit?
    I tried copy n paste the back n forth led prg but get improper module error (see above post of screen shot.)
    I know I am getting ahead of myself but learning along the way such as attempting to build a program that has a random number gen (found snippet) then include different output sound frequencies (using the code that be80be posted.
     
  14. blueroomelectronics

    blueroomelectronics Well-Known Member

    Joined:
    Jan 21, 2007
    Messages:
    12,536
    Likes:
    170
    Location:
    Toronto, Canada
    When the ribbon cable is connected DIP SW 1,2,3 = OFF
     
  15. MrDEB

    MrDEB Active Member

    Joined:
    Apr 16, 2007
    Messages:
    4,414
    Likes:
    23
    what about the led program?

    I copied/pasted from the assembly manual and still get errors??
    maybe a mis-type??
     
  16. 3v0

    3v0 Coop Build Coordinator Forum Supporter

    Joined:
    Jul 14, 2006
    Messages:
    9,404
    Likes:
    227
    Location:
    OKLAHOMA USA
    Please output with the errors. If it is asm a good bet is that
    you typed it in with opcodes in collumn 1 which is reserved for labels.
     
  17. blueroomelectronics

    blueroomelectronics Well-Known Member

    Joined:
    Jan 21, 2007
    Messages:
    12,536
    Likes:
    170
    Location:
    Toronto, Canada
    Attach the .ask file (zip it) and we can take a look.
     
  18. 3v0

    3v0 Coop Build Coordinator Forum Supporter

    Joined:
    Jul 14, 2006
    Messages:
    9,404
    Likes:
    227
    Location:
    OKLAHOMA USA
    Bill,

    It may be a good idea to provide the asm code for download.

    3v0
     
  19. MrDEB

    MrDEB Active Member

    Joined:
    Apr 16, 2007
    Messages:
    4,414
    Likes:
    23
    ask file??

    all I see are bas and sfp files??
    need to zip to upload??
     
  20. MrDEB

    MrDEB Active Member

    Joined:
    Apr 16, 2007
    Messages:
    4,414
    Likes:
    23
    lets see if this works

    hopfully I compressed the one file
    there are two listed
    one is bas and sfp
     

    Attached Files:

  21. blueroomelectronics

    blueroomelectronics Well-Known Member

    Joined:
    Jan 21, 2007
    Messages:
    12,536
    Likes:
    170
    Location:
    Toronto, Canada
    Blinky.asm

    Here's the .asm file. Copy and paste from the PDF did strip the formatting so put it back in.
    You can post .asm without zipping it first.
     

    Attached Files:

Share This Page