Jump to content
IGNORED

Create ICSP Programmer for Embedded Micro Controller Chips


mytek

Recommended Posts

Michael,

OK, thanks for the confirmation.

 

The JOY2PIC-STIK will be an update for me.

 

The last PIC chip programmer I built was the P16PRO40 parallel port programmer I made in 1998. That one had 8, 18 and 40 pin DIP sockets instead of a ZIF socket to keep costs down. The P16 software was last updated in 2002 and doesn't support the PIC used on the SIO2MIDI interface.

Link to comment
Share on other sites

Keep in mind that the JOY2PIC is not a generic PIC programmer. Meaning that unlike a conventional programmer where you would load a hex file and then confirm that you wish to program a chip, this one is designed to flash a PIC from a specially compiled Atari ".com" file. I usually package that in an auto booting ATR, so all one has to do is load the file and follow the prompt to press START if you wish to flash that specific firmware. The guy behind this design created a program called PicProg that can be used to take a PIC hex file and convert it into the stand-alone flasher file like I just described. However for flashing the PICs I use in my projects, there is no need to use that program, since I have already done that, thus creating the firmware flashers for my projects, which can be downloaded from my website.

  • Like 2
Link to comment
Share on other sites

  • 2 weeks later...

I did a few Arduino AVR projects before I discovered Teensy and I'll never go back. Teensy 3.2 and 3.5 are 5V compatible 32-bit ARMs, perfect for retro projects.

https://www.pjrc.com/teensy/techspecs.html

Yep perfect if you don't mind the 20-30 times price tag vs buying an individual PIC chip. For instance the PIC used in the recent MIDI projects sells for around $0.79 last I looked. Not saying the Teensy isn't nice for people wishing to develop on, but it's not in the same category as developing an embedded board from scratch that can be cheaply reproduced.

 

As a result of this ICSP topic, an inexpensive programmer was created for use with the PIC based DIY boards I had developed such as the TK-II and the SIO2MIDI, and one that was far simpler to use then something that required installation of software in a PC. Thanks to AtariAge member dmsc, it became possible to create unique auto-booting PIC flashing files that could be run on any A8 to program the individual PIC firmware for the chips used on my projects. This made it simple to disseminate the firmware as a self booting ATR, with each one specific to a given project. Basically the process of updating the firmware became a no brainer for anyone that knows how to use an 8-bit Atari.

 

Never used or programmed a Teensy, so I can't say much in that regard as far as ease of getting setup to do so, but I would imagine there would be more steps required.

Link to comment
Share on other sites

Teensyduino installs over Arduino making for a simple IDE. PJRC takes great pains to convert Arduino libraries to Teensy. They also sell their own bootloader chip for use on custom PCBs. Worth a look.

 

When I found Great Cow Basic, which I started using on my last project, I essentially have in it a program development system that is very easy to write fast efficient code for either a PIC or AVR chip, while still be at a higher level then assembly. Really not much reason to change at this point for me, but I can see the attraction for others to go the Arduino/Teensy path for code development. Sometimes one has to say that's enough and stick with what they know and still works well for what they need to do.

 

BTW, how much does the bootloader chip sell for?

  • Like 2
Link to comment
Share on other sites

Truly these are good times we live in. I even had a ESP8266 development system set up that was based on the Arduino IDE when I needed some remote sensing over WiFi. Nice to be able to choose the right tool for the job depending on cost vs. capabilities. I've never met a micro i didn't like. :)

  • Like 1
Link to comment
Share on other sites

i think he was alluding to the built in graphics/display par of the chip, part of some of the conversations.... it all gets so mixed up and messy some times...

 

Sorry, sometimes I don't explain enough. I was meaning that if you had a chip that could produce data fast enough for video it would need to have a parallel connection to the bus. You can't do serial I/O fast enough on the Atari to keep up with ANTIC.

 

Example: Using a PIC or other chip to render video frames, etc. ...

  • Like 1
Link to comment
Share on other sites

  • 4 years later...

This is definitely a necro bump if I ever saw one...

 

So I have a new project that incorporates two PIC12F629 chips and I wanted to create a JOY2PIC flasher for both of them, as well as a firmware update for a specialized TK-II PIC16F1847 chip on a 576NUC+ (that one flashes no problem). So a while back I had added the PIC12F629 to the list of possibilities in the picprog program, and used it to create two flashing com files. I bumped up the version to v1.1 but it never officially got added to the Atari-picprog github which still sits at V1.0.

 

Anyway when I went to go flash the PIC12F629 chips for my NUCplus4 project via the JOY2PIC Atari Pic programmer I got the following error.

 

Screenshot.png.8931b9da9fe7b4031a90db819d2d2f2c.png

 

This kinda rang a bell in my head as being something I'd seen happen before when flashing these same chips for another project several years ago. I think it has to do with the calibration byte, but I'm not sure. Anyway I think @dmsc came up with a work around, but I forget what that was. Daniel I've been searching through this topic as well as my PMs but have yet to stumble upon our earlier conversation about this. Do you remember anything and/or the solution?

 

Here's some zipped folders containing picprog V1.1, as well as an ATR with what was going to be the released JOY2PIC flashers. I also included the original PIC hex files.

atari-picprog-1.1.zip

  • Like 2
Link to comment
Share on other sites

Hi @mytek!

 

Happy New 2024, hope it is great year for you!

 

16 hours ago, mytek said:

So I have a new project that incorporates two PIC12F629 chips and I wanted to create a JOY2PIC flasher for both of them, as well as a firmware update for a specialized TK-II PIC16F1847 chip on a 576NUC+ (that one flashes no problem). So a while back I had added the PIC12F629 to the list of possibilities in the picprog program, and used it to create two flashing com files. I bumped up the version to v1.1 but it never officially got added to the Atari-picprog github which still sits at V1.0.

 

Anyway when I went to go flash the PIC12F629 chips for my NUCplus4 project via the JOY2PIC Atari Pic programmer I got the following error.

 

This kinda rang a bell in my head as being something I'd seen happen before when flashing these same chips for another project several years ago. I think it has to do with the calibration byte, but I'm not sure. Anyway I think @dmsc came up with a work around, but I forget what that was. Daniel I've been searching through this topic as well as my PMs but have yet to stumble upon our earlier conversation about this. Do you remember anything and/or the solution?

 

The problem is not in the calibration byte, but in the configuration word. The datasheet says:

image.thumb.png.fe4334560e194cb5b9cafcf37db148dd.png

So, bits 9 to 11 should always be 0. But your HEX file (both TKNUCFN and TKNUCSD) have a value of 3FC4 specified. A simple fix is to edit the HEX file and in the line before to last, change the ":02400E00C43FAD" with ":02400E00C431BB", that should make the programming work.

 

The other fix is to see what generated your HEX file and put the wrong bits there.

 

Have Fun!

 

  • Like 2
  • Thanks 1
Link to comment
Share on other sites

3 hours ago, dmsc said:

The problem is not in the calibration byte, but in the configuration word. The datasheet says:

image.thumb.png.fe4334560e194cb5b9cafcf37db148dd.png

So, bits 9 to 11 should always be 0. But your HEX file (both TKNUCFN and TKNUCSD) have a value of 3FC4 specified. A simple fix is to edit the HEX file and in the line before to last, change the ":02400E00C43FAD" with ":02400E00C431BB", that should make the programming work.

Daniel thanks for the quick reply :)

 

I'll try this out a bit later today. Or maybe figure out what caused it to occur from my FlowCode compiler in the first place. Might be possible to edit the PIC definition file in that application instead, and then re-run the picprog READHEX.com program to regenerate the JOY2PIC flasher.

 

Thanks again, and Happy New Years to you as well 💥🎉

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...