Maker Pro
Maker Pro

Cottage industry microcontrollers

woodchips

Feb 8, 2013
43
Joined
Feb 8, 2013
Messages
43
Hi, an interesting forum only found by some now unknown search. Now to pick some brains.

I manufacture measuring instruments and use the PIC 16C73 microcontroller. Time to update the design and it would be nice to use a somewhat more elegant microcontroller. The PIC has worked perfectly for the 20 years I have used it, once programmed then no problems at all.

I define elegant as a processor with an 8 or 16 bit size, signed and unsigned branches, useful addressing modes, something like the 6809 or 68000. The gotcha is that my manufacturing is a cottage industry, pin spacing less than 0.050", SOIC, is simply not possible to solder, reliably, by hand. The other requirement is that it also needs to be 5V to work with all the thousands of previous products out in the market.

All I can come up with is the PIC, possibilities like the 6811/12 or MSP430 just don't work on 5V and have a SOIC package. No doubt there are are possibilities in the 8048 type architecture but I really not keen on Intel processors.

And the final requirement is an assembler, yes, that is correct, no C code, bit twiddling in Brief, or Wordstar.

Ok, so using assembler is just my way of working, a HLL is much quicker, usually, to program. But does no one else use small quantities of microcontrollers in products where reliably soldering something with lead pitch of 0.25mm, or less, is simply impossible. Like using lead free solder, guarantees dry joints.

Any comments or thoughts? Not just the specific questions I ask but in a wider context of low level manufacture.

Bob
 

pwdixon

Oct 14, 2012
52
Joined
Oct 14, 2012
Messages
52
I regularly hand solder smd chips with less than 0.05" pitch eg. PIC32 so while I think I wouldn't want to do large scale production at that level it can easily be done.

Why are you stuck on assembler? If it's running speed you can always insert chunks of assembler into c code and get the best of both worlds. If it's cost then there are low cost/free compilers available.
 

woodchips

Feb 8, 2013
43
Joined
Feb 8, 2013
Messages
43
Even with a headband magnifier I can't really see such small pitch connections. I have the reflow hotplate, syringes of solder etc but it is the word 'reliably' that hits the buffers.

C is fine, but with the new Windows based software which has every bell, whistle and chime added then it is so long between using it that I can't remember how. DOS based editor, assembler and programmer is actually quicker than these fancy environments, for a casual user. Added to that much of the code is low level sensor interfacing, bit twiddling and 40 bit maths then C loses its appeal.

Bob
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
Jan 21, 2010
25,510
Joined
Jan 21, 2010
Messages
25,510
If I were you, I'd simply update to a newer PIC. You'll be familiar with the instruction set and your existing code may run with only minor changes.

It's possible to combine C and assembler. I would recommend that you limit the assembler (especially if you change processors) to those parts requiring you hand tuned assembler, and do the rest in C.

You might even try the speed stuff in C because there have been a lot of advances in compilers and you may find it generates faster code than you do -- especially if you are new to the architecture. Faster clock speeds may render also render the need for assembler moot.

You probably want to pick a processor that comes in DIP and/or SOIC if smaller pitch is an issue for you. Definitely keep away from TSSOP! :D

Have you investigated reflowing your boards? << I was thinking reflow oven with control over temperature profile.
 

poor mystic

Apr 8, 2011
1,074
Joined
Apr 8, 2011
Messages
1,074
:)
You could consider voltage-converting chips, which are capable of taking a supplied 5V and converting it to almost any useful voltage, using only a small area of the circuit board.
Your choice of processor need not be limited to 5V-working chips, if you could accept the voltage converter option.
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
Jan 21, 2010
25,510
Joined
Jan 21, 2010
Messages
25,510
Added to that much of the code is low level sensor interfacing, bit twiddling and 40 bit maths then C loses its appeal.

My code at work makes extensive use of 24 and 40 bit integers. I have defined libraries for 24, 40, 48, and 56 bit integers (the architecture already supports 8, 16, 32, and 64 bit integers.

With C++, these become datatypes and I can manipulate them just as easily as I can manipulate bytes, short integers, or anything else.

I use them mainly for data storage optimization (imagine having a few billion of them in a data structure) but I can recode them in assembler if I wish for extra performance. (If I could beat the C compiler, that is).

My job once involved converting routines to assembler to eek out more performance from applications, so I'm not exactly inexperienced in this area.
 

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
Hi woodchips,

If you haven't looked at the AVR, you should. It's not too bad, as 8-bit architectures go. But I'm not sure why you feel the need to change. If the PIC is still doing what you want, what's not to like?

Of course moving to a newer device could probably enable you to eliminate some components from your design; perhaps even eliminate a whole ADC or DAC, maybe speed up SPI using a built-in peripheral, that sort of thing. And with larger memory and better speed you could improve performance and add features. If there's any real incentive to do so...

There certainly are a lot of architectures and manufacturers to choose from. Some devices include programmable logic blocks, or configurable analogue blocks, on the chip. Most support features that offer practical advantages, such as in-circuit reprogrammability and even software-driven reprogrammability.

Here's a large survey of embedded devices. It will at least enable you to find the names of all current manufacturers of embedded MCUs.

http://www.embeddedinsights.com/directory.php
 

CocaCola

Apr 7, 2012
3,635
Joined
Apr 7, 2012
Messages
3,635
Can I assume you are at least using the revision A or B revision of the chip? If so I'm of the idea that until Microchip decides to mark it end of life, don't try to fix something that isn't broken...

But if you must, there are so many Microchip PICs out there right now that if you know your design requirements it should be easy to narrow do to a dozen chips that will suit your purposes, and possibly shave a few dollars off the per chip price... Porting the software might be a little irritating but if you stick to the PICs it will minimize the porting headaches vs jumping into a different architecture like Atmels...
 

woodchips

Feb 8, 2013
43
Joined
Feb 8, 2013
Messages
43
Many thanks for all the responses, it does seem that sticking with the PIC is the easiest option.

As to C, there is no doubt that for coding a user interface, high level control and similar then it is the way to go. My user interface is an LED display and a few switches, all clearly labelled with their function. But at the low bit twiddling level then there isn't any real advantage, assembler is possibly only 2 to 4 instructions per statement. The trouble with C is that it is regarded as a self documenting language, assembler isn't. So the 'what is being done' is easy to document, the 'why it is being done' and the 'how it is being done' don't get a look in. I remember writing in PDP11 assembler using the macro facility. Once it was grasped what it could do then it was almost a high level language. A similar situation can be attempted with the PIC.

My comment about coming back to programming after a gap of years hasn't been picked up on. As a product developer then the software is a small part of the product. The electronics and PCB need designing, with the mechanical arrangements sorting out, and they are all interconnected. And when all is done the product needs making and selling. All this is done by me. I bought what looked like a good CAD package years ago, but the learning curve to re-remember how to use it after a couple of years was far longer than using Lotus Freelance. Ok, Freelance produces rubbish CAD drawings, but the metal bashers had no problems, or mistakes, in using them. Similarly I don't have a Windows computer, I have my wife's cast off Macs. Finding any product design software for the Mac is hard.

What it comes down to is that the efficiency of using my 20+ year old computer and tools is greater than the cost and delays of buying new. I am also rather appalled that you can buy some software and a few years later the OS is end of lifed and it won't run anymore. DOS doesn't have this problem. I know I can go back and use it at any time, no learning curve. I updated my PCB design package to Windows but it suddenly gained features of no importance, 16 layers, copper fill etc etc but all of a sudden the menus were layers deep.

Developing a product is just a small step on the road, the manufacturing and selling are of far greater importance, and occupied time. I am supporting items from 20 years ago, and expect to carry on doing fro another 20. A position sensor isn't something that can change, the position display can have lots of features but no one uses them. It is like an oscilloscope. A 465 has a fully parallel user interface, everything it can do is always there in front of the user. A DSO is exactly the opposite, it has two wobbly cursor controls and one button, plus 53 and counting menu levels. The 465 is much the better instrument.

So I am out of date? Good! I will cater for the 30% of the population that have never gone online and experienced the joys and pleasures of a software update.

Bob


ps, a typical example of software wasting time and effort, I have just been logged out whilst typing this reply, why???? Never used to happen with DOS!
 

CocaCola

Apr 7, 2012
3,635
Joined
Apr 7, 2012
Messages
3,635
ps, a typical example of software wasting time and effort, I have just been logged out whilst typing this reply, why???? Never used to happen with DOS!

Because you didn't click the 'stay logged in' box when you logged in. this is not an OS feature simply a feature of the forum software, your browsers cookie timed out and thus you were logged out...

You appear to want to blame the OS for the software drawbacks, bloating and what not of the software, is not an OS issue it's just bad or a chosen programming direction... In the end there is well written Windows software and there is garbage DOS software, and the reverse is true as well...

I am also rather appalled that you can buy some software and a few years later the OS is end of lifed and it won't run anymore.

Can't say I have ever experienced this issue, most Windows software has been pretty universally written from 95 to Windows 8, there are exceptions but a dual boot computer can fix that if it's an absolute concern that is if you can't get it to run at all in say a virtual overlay... Even Windows 3.x and DOS software will still run on current Windows machines, if not natively in a virtual machine overlay...

Now if you use a Apple computer, well yeah you won't get the backwards compatibility, but backwards compatibility was never a selling point of MAC OS, and they totally destroyed compatibility when Apple switched to the x86 architecture...
 

woodchips

Feb 8, 2013
43
Joined
Feb 8, 2013
Messages
43
Ah ha, thanks for that, might be able to cope now.

Dragging the discussion away from moans about Windows.

Are there no other people who design, make and sell small products in low quantities? Small enough to make subcontracting the assembly one cost too many, so have to try and solder these minute packages.

The internet provides the ultimate in advertising media, worldwide, free, no size or other constraints, amazing. Of course you ideas can get borrowed just as easily, it is a trade off. What do others do?

Bob
 
Top