Skip to main content

Messages

This section allows you to view all Messages made by this member. Note that you can only see Messages made in areas you currently have access to.

Messages - Fezoj

1
Bus Pirate Development / Re: Homemade Bus Pirate
[quote author="BrentBXR"]I setup the pins adjustable in shared.h and added the 'standard' setbit clear bit defines and used those to set the clear the pins for readability.[/quote]

I like your changes. Can I upload them to git repository? Also, I was thinking that we could enhance a communication protocol a bit to enable user to assign Port and Pins directly in application in addition to communication parameters. What do you think?
3
Bus Pirate Development / Re: Homemade Bus Pirate
Since few people have found programmer useful, I decided to update it a bit. According to responses in this thread, UI was enhanced so that it feels more intuitive.

There are some known issues waiting for solution:
- does not export flash memory to a hex file
- does not check memory range yet. Assumption is that user loads correct hex file for PIC device.
- several ToDo(s) in source code

If you find a bug, please let me know or fix it :)
Snapshot:
4
Bus Pirate Development / Re: Homemade Bus Pirate
[quote author="ricros"]I can erase, read the pic ID (0x4207)[/quote]
I have checked PIC24FJXXGAXXX programming specification and it does not contain device with id 0x4207...
My BusPirate reports 0x0447 this means that it contains PIC24FJ64GA002 device. Did you write wrong device id by mistake?

Please check http://ww1.microchip.com/downloads/en/D ... 39768d.pdf page 64. In addition to that, different devices have different configuration word address. Hex file and device must match.
5
Bus Pirate Development / Re: Homemade Bus Pirate
Hi Ricros

[quote author="ricros"]I got those "poll poll done", I can erase, read the pic ID (0x4207)...[/quote]

If you can read DeviceId and those "Writing 64 instructions at XY poll poll done." strings everything works as expected. So it looks like you are burning wrong hex file into device. The hex file shall contain configuration words at the end. For example, if you are trying to burn in BusPirate, you have to burn in bootloader hex instead of firmware hex because only bootloader hex file contains configuration words at the end. After that you can load firmware via bootloader.
6
Bus Pirate Development / Re: Homemade Bus Pirate
[quote author="kehribar"]
I'm quite busy right now for writing a Processing library for Little-Wire but as soon as possible, i'll try to port this to Little-Wire![/quote]
That would be fantastic. I'll add an extension point to simplify this work.

[quote author="ricros"] I tried to open it with visual studio express with no success[/quote]
What version of VS do you have? VS 2010 Express should work.
7
Bus Pirate Support / Intel hex file generation
Hello,

I am going to enhance my AVR based PIC programmer I posted in other thread to enable user to export instructions from a PIC to hex file. The problem is that I am not sure how to generate proper hex file. I know how to parse a hex file but what I do not know is:
1.) how long data records shall application create?
2.) linker usually generates 16 and 8 byte data records. Is it mandatory?  Does anyone know why and when linker creates 8byte long records instead of 16bytes? Would it be ok to create 1byte long data record?
3.) Is it safe to skip some addresses i.e. leave hole when some code area is not programmed?

Thanks.
9
Bus Pirate Support / Re: Re: Self test results
Hi Ian,
Thanks for your answer.
I soldered BusPirate v3.5a SOIC by myself. I have no problem to replace anything :) The problem is that I do not see any pullup resistor on MOSI. The MOSI is connected via 2k resistor to IC3 - 4066 cell: A. I am not sure how this pullup was meant to work. I double checked schematics and I found that pin 13 of 4066 is not connected anywhere. Is it a bug? Shall I connect it to pullup resistor?

Thank you.
10
Bus Pirate Support / Re: Self test results
Hello,

the BusPirate reports 1 error. Do you have any idea what could go wrong?
Did I screw something up?

Code: [Select]
Disconnect any devices
Connect (Vpu to +5V) and (ADC to +3.3V)
Space to continue
Ctrl
AUX OK
MODE LED OK
PULLUP H OK
PULLUP L OK
VREG OK
ADC and supply
5V(4.99) OK
VPU(4.98) OK
3.3V(3.27) OK
ADC(3.27) OK
Bus high
MOSI OK
CLK OK
MISO OK
CS OK
Bus Hi-Z 0
MOSI OK
CLK OK
MISO OK
CS OK
Bus Hi-Z 1
MOSI FAIL
CLK OK
MISO OK
CS OK
MODE and VREG LEDs should be on!
Any key to exit
Found 1 errors.

Thanks
11
Bus Pirate Development / Re: Homemade Bus Pirate
Hello,
it is good to hear that code may be useful for someone else.

ATmega8A should work stable at 16MHz/3,3V.
Nevertheless 16MHz is not mandatory. I used it because it was the first crystal I found... Feel free to use any other frequency just do not forget to match baudrate tolerance. When you go for lower frequency than 10MHz, you can safely remove all nop() instructions from code.

I am going to create a connection configuration dialog as I realized that other people may naturally use it :)
12
Bus Pirate Development / Re: Homemade Bus Pirate
Hello,
I updated my post with circuit schematic. Please check.

Here are some answers:
1. ATMEGA operates from 2,7V to 5,5V so everything is powered from 3,3V supply.
2. Yes, it is a standard reset button - reset circuit is optional. Second pin of button is connected to Vcc via 10K resistor.
3. you are correct, this wire does not play any role here. I did not notice it somehow.
4. correct. Capacitors are 22pF but 18pF would be ok as well I guess.
5. Actually it is 1k. I use it because PGD pin changes to output state from time to time. Direct connection may lead to short circuit.
13
Bus Pirate Development / Re: Homemade Bus Pirate
Hello,

I uploaded firmware for ATMEGA8 and software at github: https://github.com/JoKr2/ApProg
I created this programmer according to following spec. http://ww1.microchip.com/downloads/en/D ... 39768d.pdf
My goal was to burn in bootloader into my homemade BusPirate. I never worked with PICs before so all I can tell is that programmer works for PIC24FJXXXGAXXX devices.

The PCB is not necessary - I used just few wires on BreadBoard:


Note that MCLR wire is hidden under the BusPirate PCB. This wire is connected to PORTB pin 2.

I created a schematics because circuit is not clear from above picture:


Enjoy :)
14
Bus Pirate Development / Re: Homemade Bus Pirate
I finished a simple AVR based PIC24FJ programmer. If anybody has a same problem like I had feel free to ping me. I will upload firmware, application incl. sources somewhere.
15
Bus Pirate Development / Re: Homemade Bus Pirate
Actually I have found an old Max232 and ATMega8 chip among my spare parts and I still do have access to the COM port so I changed my mind a bit. Now i have a crazy idea. I am going to build a one shot programmer on breadboard because I only want to upload a bootloader to my BusPirate.

I saw that some people are working on PIC programmer application for the Bus Pirate. Unfortunately the code is not documented very well so I think that it will be faster if I learn the PIC24F programming specification and create another one.

Regards,
Jozef