Showing posts with label ATmega. Show all posts
Showing posts with label ATmega. Show all posts

Wednesday, October 29, 2014

Minima - User Options


On Mon, Oct 27, 2014 at 11:36 AM, John <****@*******> wrote:
Hello Eldon
I know that you said that you want to stop coding and get on with construction,  I was just about to upload BS02 again but with various options turned off to suit my way of operating , which is a bind, as I have to make the changes, upload again every time I make a small change,     So I was wondering if it would be possible to have some of the more popular options available on the menu like you have the 60m (yes /No), possibly     Tune 2500 khz,    CW beacon,    Scanning, they could all be Yes/No options
Would save a lot of trouble,   Just a suggestion !!!! get the minims going first
73
John


John,

I decide to respond to your questions via a blog post, and CC to the Minima email reflector, so my answers can be leverage by others.

Yes, I need to finish my Minima build.

And YES, most options could (or should) be added to the menu option.

Although, I wrote the menus as it is, in hast, as a trial to see if it was valuable. In hast, means that the menu system is very inefficient and requires much code space than it should. It needs to be rewritten with space, performance, and optimisation in mind.

In previous revisions of the Arduino IDE, my Minima Alternate Tuning Method (MATM) Sketch was running out of space and therefore user compile-time USER_OPTIONS was the only method available for allowing users to pick and choose their desired functions. As you know, with the NEWER Arduino IDE 1.5.8, the MATM uses much less of the available space and therefore most (if not all) current USER_OPTIONS will fit, at the same time.

John, I think you have said that you take your ATMEGA328P processor out of the Minima circuit and place it in an Arduino UNO to reprogram it. If so, yes, I can see how compile and modifications would be a pain - and therefore menus would be much better. First, I suggest that you upgrade and use a USB to Serial Converter connected to a four pin header on the edge of your controller board. There are NO components necessary to use this header. Although personally, I always put a 1nF cap on all processor pins that leave the processor board, especially when used in an RF environment. Downloading a Sketch and Restating the processor with this set up is automatic.

PropPlug and Four Pin Header
There are several USB-to-Serial Converters available from different manufactures, most are created using the same FTDI FT232R chip.  I use the "PropPlug" from Parallax. The required four header pins from the processor are; GND, TX, RX, and Reset. The PropPlug works very nicely with the Arduino IDE.

As most readers of my blog know, I like to build electronic project with the smallest parts that I can find (small is my thing). For example, for the Minima I did not use the ATMEGA328P-PU, I used the ATMEGA328P-MU which is a small MLF-32 package. The downside is, it can not be taken out of the circuit to be programmed, nor can it be easily replaced.

Top: ATMEGA328P-PU
Bottom: ATMEGA328P-MU

For me, using the original suggested large DB9 Serial connector for programming on the back of my project was a non-starter, but a simple four pin header is acceptable. Also, the original suggested level translation parts are not necessary with a FTDI interface.


So Yes, new revisions of my MATM software will include more menu items to make option selection easier. Note: "menus" will always be a compile time USER Option.



-- Home Page: https://WA0UWH.blogspot.com

Sunday, August 3, 2014

Minima - Good Progress

After a long late night working with Jeff - KO7M,  trying to fix my Minima Controller board, I finally gave up and went to bed.

About two hours of trying to sleep it dawned on me what was wrong, I got up and fixed the problem within a few minutes - Progress.

The initial problem was I had inadvertently ordered and installed the wrong Atmega328 part. The part that I installed is the "Atmega328-MU" and the desired part is the "Atmega328P-MU", the internal ID's were different, which confused me,  the Arduino IDE, and Avrdude. After modifying a few files, all worked as expected. I set "fuses", downloaded the bootloader, and downloaded the Minima Sketch. All is well.

The "P" in the product number indicate a "picopower" device, which is what all of the Minima builders are using. Actually, the builders are using the "Atmega328P-PU", the "P" in  "-PU" designates a Dual-Inline-Plastic package. Because I am building my Minima with very small parts, I am using the "-MU" package.

To avoid having a special configuration for my Minima build, I plan on ordering the correct "-MU" part.

Thanks to all those that have provided Comments, e-mails, and Assistance with this problem, a special thanks goes to Jeff for staying up very late at night on a Chat window.

Note: This morning, I also recovered my original damaged Minima Controller board, using the same strategy. Now I have two !!



UPDATE: Aug 3, 2014 22:26

For future reference, I used the following to "jump start" my new raw Atmega328-MU:
  • I changed the ID for the m328p to "m328" in the "/etc/avrdude.conf" file
  • avrdude -F -b 19200 -c usbtiny -p m328 -v -e -U efuse:w:0x05:m -U hfuse:w:0xDE:m -U lfuse:w:0xFF:m
  • See: http://www.codingwithcody.com/2011/04/arduino-default-fuse-settings/
  • Used Arduino IDE to download the UNO bootloader
  • Changed the ID for the m328 in the "avrdude.conf" file, back to the original
  • Used the Arduion IDE to download a Sketch
  • Note: Arduino IDE does not use /etc/avrdude.conf, it uses its own conf file.
--

Tuesday, April 29, 2014

Minima FN - Troubleshooting

I am still testing my Minima CPU Module, for some reason the FUNCTION (FN) switch will not work. The microscope was used for inspection, looking for shorts or open circuits.
This is the ATmega328 Processor
and Crystal Circuit
Note: I have mounted the 0805 bypass capacitors on edge so that they will fit on the 0605 pads. For this module space reduction was not really necessary, but  I generally use this technique by default.
ATmega328 - 32QFP
So far, nothing found that would cause the malfunction. Resistance and switch operations appear normal. The other switches and functions work as expected.

This is not considered to be the "Ugly Style" of Homebrew hobby construction. But, under a high power microscope everything is "Ugly", especially after it has been setting around for a while. It is a wonder that any modern high density electronic devices work at all, with all of the accumulated contamination that everything collects.

More circuit review, software program review, and testing is required.


UPDATE: Apr 30, 2014 15:09
Success, I got my FN switch problem solved. There were two problems.

The first, was a missing via on my board that should have provided a ground path for the FN switch.

The second, I have been working on the frequency Display and the associated Human Interface within the Sketch. My new modifications had not been properly integrated with the rest of the Sketch.

Now,  all is working as expected.

--

Tuesday, April 22, 2014

Minima - CPU Module Mods - PLus

After chatting with my friend, Jeff - KO7M, I decided to again modify the next Revision of my Minima Controller. Jeff has pointed out that a new raw ATmega328 processor does not have a bootloader.

I guess I knew that already, but I thought that I could use the TxRx pins to download a bootloader similar to downloading an Arduino Sketch. I was wrong.

More research is/was obviously needed.

REV04 of my Minima Control Module
The Backside
The latest addition to my Minima Module Mods is a JTAG connector, which will be used to download the Arduino Bootloader, or other raw mode programs (or sketches). The JTAG connector is under the "locally" mounted LCD display (left of center), but the display will be un-plugged during the JTAG use, because the JTAG and the LCD uses some of the same processor pins. I will have to check that the JTAG connector pins will not interfere with the mounted LCD board.

Once the ATmega328 programmed with the bootloader, the display will be re-installed, and then normal sketch programming will be done via the Prop-Plug TxRx header (lower right).

My previous modifications included; Consolidation of several individual headers into a single AUX-CTL header (lower left), Remove the Minima schematic programming components which will be replaced with a Prop-Plug header. I have also added my own version of EMI suppression by adding 1nF caps to each board edge header pins.

This board is getting complex enough that I am considering having it professionally manufacture, it is about 6.6 square inches and will cost a few bucks, but it now has about 65 via's (which are not exactly fun to do on a Homebrew board). I may still create a prototype board via Toner Transfer, but it will take some time/work.

The goal for this board is to be compatible (but more flexible) with the Farhan Minima Transceiver Project. I also plan to use this board with/for other Test LAB projects.

More project info to follow .  .  .

--

Thursday, April 17, 2014

Mimima - Minimal Progress

As stated in a previous post, I have started layout of the separate Audio Modules for my experimental Minima Transceiver. I think I have four of the five modules in semi-final form, but I get "bored" working on Audio circuits.

And therefore, I have temporary turned my attention to the ATmega328P Processor Module layout. The original Minima circuits uses an ATmega328P-PU 28-pin DIP package, which is easy to use, and easy to solder on a through-hole PCB, or mounted "Dead Bug" or "Ugly Style". But, I enjoy building my own PCB's.

As with all of my projects, my goal is to make them as small as my eyes, nerves, an abilities will allow, and therefore I will use the ATmega328P-MU which is a small 5x5mm 32-TQFP package on a Homebrew PCB. The pin numbers and layout are a little different, but the functions are the same.

First DRAFT
Minima - CPU Module
The above is the first Draft of the proposed layout, the planned Homebrew Double-Sided board will be 1.4x3.0 inches with only 13 via's. The PCB will be created using the Toner Transfer Method.

The ATmega328P-MU will be mounted on the small diamond shaped pad in the center. The power +5V Power Regulator is on the left, the CPU programming circuit is on the right. The upper long header is for connection to the LCD Display.

I am still considering modifying the layout to use a single combined edge connector for connection to the planned Audio Modules.

This is work in progress, there is still more layout work to be done.

--