TL866 Writing to Atmega 328P - Page 1
Forum section: electronics / beginners

author: Electro Fan
author_rank: Super Contributor
timestamp: August 31, 2023, 07:06:50 am
content: edit - SOLVED THIS FIRST PARTI have a couple Atmega 328P chips that were programmed in an Uno from a PC with the IDE. I can remove them from the Uno socket and put them in a TL866 programmer and the MiniPro software reads what is on each 328P. For each chip I made a new project using MiniPro and I think saved what was on each chip into a MiniPro project file. I can erase the 328Ps and I can then open either project file and write the project file to the 328P with the TL866 - with MiniPro doing the normal confirmations that the write was successful; after which time I can search using the MiniPro software while the 328P is still in the TL866 programmer and I can find the newly written info (that was written from a previously saved project file).However, if I exit the MiniPro app and restart MiniPro when I look at the 328P still sitting in the TL866 it shows the 328P is blank (no data). Maybe some setting in MiniPro is preventing me from truly writing to the 328P and I'm just seeing the project file while it's still sitting in RAM after what I thought was a successful write "program" command?Under File Load Options are choices for Code Memory (which seems to be the default), Data Memory, and CONFIG - maybe I should be using Data Memory or CONFIG? There are some other fields - so far I'm just taking the defaults.Thx! for any guidance.2ND ITEM:Now I can successfully read, store data in a project file, erase a chip, re-program (write from a previously saved project file), exit, read, etc etc.However, something now has the data locked down. I was previously able to search (using ASCII), find the text and simply edit the text, then save the changed text. Now the edit function (which used to turn an edited character red) doesn't seem to be functioning. If it isn't one thing it's another..... Thx

author: Electro Fan
author_rank: Super Contributor
timestamp: August 31, 2023, 08:22:26 am
content: PROBLEMS SOLVED. Just a matter of getting used to the intended process.Seems like it's pretty repeatable to copy chips and/or make edits. Knock on wood.If anyone has a preferred chip extractor that would be good to find. Or maybe it's just a small screw driver and some learned dexterity?

author: liaifat85
author_rank: Regular Contributor
timestamp: September 03, 2023, 11:12:38 am
content: Good to know that it worked finally.

author: Infraviolet
author_rank: Super Contributor
timestamp: September 03, 2023, 06:47:32 pm
content: Electro fan, ideally two small flat bladed screwdrivers, one to go at each end. There are special chip pulling tools, but I've never tried one, nor had many people I know working in electronics when, many years ago, I asked the same question. I guess you'd only use apulling tool if you were doing an awful lot of swapping chips betwe sockets. If you have made a programing jig then look at ZIF (Zero Insertion Force) sockets instead, you load the chip and psh down a lever to hold it in while programming, lift the lever to release. 3M makes them for 28pin DIP ICs for about £20 each sold on major electronics distriburtor websites, but you can get them on amazon for more like £2 for clones from chinese sources which should be adequate except for long-term highly repeated brutally clumsy use cases.P.S. your second item, I don't know the details of your situation but this sounds like a problem entirely inside your software tool. What about copying to another text editor, editing as you please, then flashing your edited code to chips using the avrdude command line tool (or using the "upload with programmer" option available in the arduino IDE).If your whole problem is just the process of flashing your programs to atmega328p chips, I'd make a ZIF jig which you could wire to an arduino uno and use that uno as an "arduino as ISP", very quick easy way of writing to the chip and bypassing any need for the arduino bootloader. This jig and arduino as ISP setup can also be used with the avrdude command line tool to extract code from an atmega328p, but you'd need to decompile it afterwards.

author: Electro Fan
author_rank: Super Contributor
timestamp: September 04, 2023, 12:51:12 am
content: Hi Infraviolet,Thanks for the help.I hadn't used the TL866 and the Minipro software in a couple years or more, so I think it was mostly a PEBCAK error. After I erased the existing program from the 328P I then loaded a new program from the MiniPro "Project" directory and the data from newly loaded project file appeared as expected. When I exited MiniPro (while leaving the 328P installed in the TL866) I expected that when I relaunched MiniPro I woud see the data on the 328P and was surprised to see MiniPro showed the 328P was blank - but that was just my user error - at that point I just needed to hit the Read command in MiniPro, and the data was there on the 328P as expected. For some reason I was thinking that when you launch the MiniPro app it would bring up the most recent state connection with the TL866 but that's not how it works - when launching the app I just needed to hit Read. Net, net: I confused myself but then I managed to unconfuse myself. Occasionally I get lucky that way but I posted my question before I figured it out.As for changing out the 328P in Arduinos, I don't do it often but sometimes I have a need to move chips from one board to another, and with the TL866 I can make backups and restores plus do some simple edits. It's all a fun learning process.For anyone reading this, I saw another thread and a particular link that might be a step up from my first semester 100 issues/questions:https://www.eevblog.com/forum/beginners/what-is-self-programming-and-what-is-it-used-for/msg5042050/#msg5042050.https://www.electronicshub.org/types-of-memory-on-arduino/As for chip pullers, until now I have used a basic chip extractor but I found that the tongs driven by the diagonal parts go out of alignment and even when they are in alignment the tongs don't fit and catch well under both ends of the chip, especially when it's snug to the socket. After overcoming this week's software user error I decided to try the Jonard and it works better but the real winner is the WIHA 26810 - it does the job well, consistently. If someone only occasionally extracts a chip a small flathead screwdriver will get the job done.

author: BillyO
author_rank: Super Contributor
timestamp: September 04, 2023, 01:48:39 am
content: This extractor is only for PLCC packages and should not be used on others.

author: Electro Fan
author_rank: Super Contributor
timestamp: September 04, 2023, 02:42:32 am
content: Well that would explain why it doesn’t work well on an Atmega 328.Thanks!