Using the Padauk programmer to program the 8 pin SO PMS154C micro and flash a LED on a breadboard.
Forum: http://www.eevblog.com/forum/blog/eevblog-1141-padauk-3-cent-micro-programmer/'>http://www.eevblog.com/forum/blog/eevblog-1141-padauk-3-cent-micro-programmer/
EEVblog Main Web Site: http://www.eevblog.com
The 2nd EEVblog Channel: http://www.youtube.com/EEVblog2
Support the EEVblog through Patreon!
http://www.patreon.com/eevblog
AliExpress Affiliate: http://s.click.aliexpress.com/e/c2LRpe8g
Buy anything through that link and Dave gets a commission at no cost to you.
Stuff I recommend:
https://kit.com/EEVblog/
Donate With Bitcoin & Other Crypto Currencies!
https://www.eevblog.com/crypto-currency/
T-Shirts: http://teespring.com/stores/eevblog
Likecoin โ Coins for Likes: https://likecoin.pro/ @eevblog/dil9/hcq3
Forum: http://www.eevblog.com/forum/blog/eevblog-1141-padauk-3-cent-micro-programmer/'>http://www.eevblog.com/forum/blog/eevblog-1141-padauk-3-cent-micro-programmer/
EEVblog Main Web Site: http://www.eevblog.com
The 2nd EEVblog Channel: http://www.youtube.com/EEVblog2
Support the EEVblog through Patreon!
http://www.patreon.com/eevblog
AliExpress Affiliate: http://s.click.aliexpress.com/e/c2LRpe8g
Buy anything through that link and Dave gets a commission at no cost to you.
Stuff I recommend:
https://kit.com/EEVblog/
Donate With Bitcoin & Other Crypto Currencies!
https://www.eevblog.com/crypto-currency/
T-Shirts: http://teespring.com/stores/eevblog
Likecoin โ Coins for Likes: https://likecoin.pro/ @eevblog/dil9/hcq3
Hi! In a previous video, we took a look at this Paducah in-circuit emulator for these three cent microcontrollers. So I thought we'd now have a look at and we've got a program running on our three cent micro controller. but it was actually on the in-circuit emulator which is close enough. but it wasn't actually the real deal.
So I Thought we'd now try the programmer and see if we can actually program a chip. What we're going to do is we're going to program the PMS one, Five four. See, this is actually not a three cent micro. It's actually about five cents or maybe a bit under in volume because it's the bigger cousin to the PMS 150.
It's the same series, but it's got twice the memory in it. It's also got three eleven bit PWM modules which is fantastic. plus 8 to 8 bit timers as well. So this little SOA chip for 5 cents or less has I believe 5 PWM modules in a Fantastic! It's got a couple of other things: I think a comparator and a LCDR bias generator so you can generate a bias if you're driving like a little tiny little custom LCD display or something like that's.
not a full on LCD module, but it's got it a little DC bias generator. Cool! Anyway, so we're going to program one of these on a real chip using the produc programmer which they kindly sent to us. So updates from the previous video are that yes, you can actually get these chips pre-programmed at the matter, you can't do it at the from directly from Paducah but they're official. While suppliers which are linked in on their website they're all Chinese supplies so may not be the easiest side place to deal with, but they will actually program these for like I believe it's a like point two cents each or something like that.
So the will program and LCSC have kindly offered for a limited time I believe to program them for free for people. Not sure the minimum volume you're going to have to contact them and all that sort of stuff, but I believe that they will program. They've extended the offer they've offered pre-program them in bulk for me, and they've also extended that offer to my audience as well. So I'm not sure how long that's going to anyway.
You can get these things programs. So obviously you know the whole value proposition of a three cent microcontroller. Sub three cent microcontroller is that you don't program with one of these. you need to get them programmed from the factory, in the tubes or on the reels or whatever, and then you populate them pick-and-place straight on to your projects because these are one-time programmable so you wouldn't build in like it connected.
To program them onto your board or even pads or anything to programming onto your board, you get them programmed in the tube. As I said in previous video, it's really easy to validate and qualify like a small microcontroller for a specific niche application like this. You know you can test it over voltage and temperature and you can test and inspect the code line by line. and you can ensure that there's no bugs and stuff like that so you can be pretty confident and getting like a whole reel of these. You know, many thousands of these actually programmed and it doesn't cost much at all, even if you do goof it? Well what's it going to cost you? You know, 50 or 100 bucks or something for a whole reel of these things. Now the other thing is a lot of people are questioned of course the the 3 cent micro with the 60 US dollar or a hundred US dollar depending where you buy it from programmer and the match in 60 or $100 in circuit emulated. Now of course if you've got a develop with these chips, get the in-circuit emulator. It's an incredible value and it's you know it's super valuable to do that, but of course you wouldn't.
You know for like small one-off stuff yeah get the program I think it's good value but a lot of people questioned ok it's a bit expensive for these 3 cent micros and fair enough So a lot of people asked well can we actually reverse engineer this and like open source the whole thing and maybe program it with an Arduino You know everyone's got one of those so they can just hook the chips up and stuff like that And I asked Baduk and they said look, there's a lot of complex algorithms in there, a lot of not just digital thing. There's lots of analog voltage level stuff. there's lots of compensation that they do another timing type stuff and they said sorry we're not going to release the programming information for the chips so that's a bit of a bummer. But hey, I can understand that They recommend that you use the proper programmer or the programming services of their official suppliers because they've got the big automated machines that take all the chips and and unchoose them and unreal them and then end of like program them in a bulk thing and then they'll reel them or reach up them for you ready to put populate onto your boards.
So I'll leave that as a separate video today. we're just going to program a real chip and we'll put it onto a breadboard and will flash a real lead on a real chip. No, this in-circuit emulator rubbish. So thankfully I've gone through all this before so this will be a summary right.
What I've done is I've changed the project from the last video. it is now using the 1/5 4c chip and the software is actually quite smart. If you want to change the chip that you're actually using, just go to your dot APRI file here and you actually just like literally change it from 150 to 150 4 That's what I use the 150 last time using the 154 now and it automatically detects that you've actually changed that and it actually chooses the new include file when you next. When you go to build the thing, it actually changes the include file for you.
It's actually very smart and a lot of people were very impressed by this Paducah software and I continue to be very impressed. And the programmer software is actually pretty good as well. It's a bit quirky, but the documentation is usable and and it's quite nicely integrated for the single 3 Meg executable for this that their handles. it's a separate executable for the program as we'll see, but it's really nicely integrated anyway. that's all we had to do. There was a difference I'll show you right now. actually if we have the 3 volt low voltage drop out like we did last time and then we actually compile that, you'll see that it gives us an error. Lvr error: Lvr must be greater than 3 point 5 volts for sis clock onto Ihr C onto clock source that we're using.
So that's interesting that there's a difference in that between the 150 and the 154, which is exactly the same family chip, except that it's got like double the memory of the few issue features. So yeah, that's interesting. So we just changed that to 5 for the 3.5 there and we just build it again. And Bob's your uncle look at Fantastic! So there's all our it's compiled, everything's happy.
This chip has twice the memory than what we got in the previous one Hex 7 E 897 hex of that 751 hex. free convert that to decimal for you decimal fanboys and we've got double the amount of RAM in here. We've only used four bytes out of our hundred and twenty eight byte ram, so I've got double the RAM of the 64 in the 150 series and a lot of people talked about this in the comments to the and on the forum to the previous video, a lot of people mentioned, well it like a GCC might be a solution you write a GCC version of you know to support the Paduka architecture and well, that should be okay. But a lot of people pointed out that the GCC compiler isn't really optimized for the really small memory architectures on these real low-end microcontrollers.
and they've given examples of other 805, one, and eight other pic stuff. People have tried to target with the GCC compiler before and it's done a pretty terrible job of it. There are other compilers and stuff like that for it, but basically yeah, like you could probably do it, but because it's a small amount of memory, limited stack size and stuff like that. So if you're getting in a compiler C compiler that's not optimized for these really low memory amount of SRAM architectures like this, it's not about code size, it could be about SRAM So you know if you've got a lot of stack and stuff like that little routines that need to push stuff onto the stack you're gonna.
You could chew up your memory quite fast if you compile. It's not optimized for it, so it's probably better to use the Paduka Mini C as they call it all the Paduka Assembler, but the Mini C seems to work just fine. I Don't think you're actually going to get a much, if anything like code optimization for going for the assembler over the Mini C here, but hey, we haven't actually evaluated that yet. So we've got exactly the same code as last time and we're just gonna flash a let. So we've compiled our thing for our 1:5 for C Target. So there you go. We've got the 154 CS O 8 chips. We've targeted those in here and it's all compiled now.
What we can do now is pull up the programmer so we'll turn on our program here. Initializes: Everything's like a shift will go into all the shift stuff in a minute. We'll plug it into our USB port, did a little bit and test project dot PDK I Think it's already stored in there? It could be non-volatile stored in there from our previous attempt, my previous attempt at this. Anyway, we can go in here.
We go to the Opt Writer so we've built our project. It saves that there's a dot PDK file so it's not Intel, hex or anything like that. So if we have a look at the dot PDK file it produces here. it is like a binary file.
It contains all the stuff. It contains the information on the chip and everything used so it doesn't look like A and Intel like hex equivalent format. Anyway, this is what it the writer uses. So if we go into our Opt Writer here, let's load it up Tada and let's have look now we can.
Let's let's actually load our file in here. Test Project PDK So open it up and we're in. It's verified, it's talking to the unit, everything's hunky-dory and it actually shows you on there that it's the PMS 1, 5, 4, C so already knows you don't have to select it in the software. it's all embedded in the file, gives you the checksum and all that sort of stuff.
and I see shift. For a 14 pin, it's 1. Now let's talk about this I see shift thing. Now what it is is that it says check jumper here.
So the this S 16 that's an Esso or Dip 16. Basically what it means is put, put it in JP 2. Now if we have a look at the back of this thing, this is JP 2 in here. It's telling us to use GP 2.
This is actually a jumper actually provided like it shorts out all the pins it was originally on this one over here, so it tells you for this particular chip moving over to JP 2 here. so you've just got to reconfigure it. It basically just reconfigures the pins for the zero insertion force the zip or text tool socket. Now because we've got different types of chips that we could potentially program here.
a 16 one, a 14, P NSO a 10 pin, M sub package or an 8 p NSO which were got here or even a SOT 23 6 which I've also got but I don't have the right adapter yet I can budge one up. So we're doing the So8 so we have to shift. Here's our little adapter. Focus your bastard.
Alright, here's our little adapter. If you haven't seen these before there, there are zero insertion force socket and they've just got the pins in there. You can see those move in and out like that and that allows you to get your little just dropped an Esso chip. It's gone into the carpet.
Luckily, I've got a few so let's just get another one. I Just wasted another four and a half cents or whatever. Anyway, the little So8 chip will then go inside our nice zero insertion force socket there. Lovely. So there's our chip inside our socket there. and this is what it means by shifting. because they're different pin outs on the chip. We have to.
Actually, it says shift four so we need to go to the fifth pin down for this So1. So there we go. We're now in the fifth pin down like that. So that's what it means by shift on that instruction there.
Okay, so now we've put our file in there. Now we've got other stuff. Here's the date. here's the sis clocks.
All this stuff was imported in that PDK file. So the integration between the programmer software and the IDE interface is really quite nice. Like per talked have done an awesome effort. A lot of people were impressed by the IDE and rightly so.
and the integration with the programmer software, whilst a little bit quirky, is really quite good. And they do have English documentation for the programmer which is you know it is really just fine. So as this clock 16 megahertz on tooth we don't have our write-protect or anything like that and Llv RS 3 point 5 volts like we changed before. So let's just do blank check now shall we? Will it work? Pass IC blank.
There you go. No problems whatsoever. Are the Ng on? They're the one ng I Accidentally press the button ng is no, no good. Now we've got a rolling code system here which allows you to put a serial number in to embed into the chip.
I'll show you this in the documentation in a second, but it's not supported because we haven't enabled it in the IDE. So if we have a look at our programmer manual here which has still got some mock Chinese stuff in it, but it's still. it's pretty good. This seems to be a discrete location of software in here the engineering type and simple type and stuff like that, but it's pretty comprehensive.
I Like it, so it's pretty impressive rolling code. Here it is, so we can start the relevant settings about rolling code. so and there three locations in memory there 3 FC through the three FA and presumably your program can read those back if you need to, but it can put a basically a three byte rolling serial number code in there as you program. so each chip can get a unique ID So that's a real nice little feature.
and here we go. They explain the jumpers and stuff like that, how you have to shift them and then shift it down by one if you've got the 14 pins. So if you got the 16 pin package, you don't shift anything. If you've got a 40 MPA keys, you shift down by one.
if you've got the 10 pin one, you shift down by two and if you've got the 8 pin like one like actually shift down by four or something like that, so it is. It is pretty comprehensive I Like it now. like the fact that they got a 10 pin M sub package as well cuz that you know if you need an extra 2 pins but you don't want to go to the you know, the full 14 or 16 pin version that could be. That could be very handy indeed, but look like it's nice. It's got nice drawings of how everything goes up so it's all about like the PA There's like four programing pins on the paduka chips so they've got kind of a common pin configuration, but you do need to shift them in the programmer which is fine. So and check this out, you can get what's called a customer package. You can add your own package to these things, so that's why if you go convert PDK here to package, you can actually generate a well. yeah, I haven't actually done it yet, but it is in the software here which shows that you can actually define your own package.
So if you wanted to have like custom header on a board or something like that if you really wanted to defeats the purpose of the three cent Micro. but anyone because the connector cost more than the micro does anyway, you could define your own package or do whatever and it looks very powerful so you know that's that's really quite impressive and that they've gone to the effort to, you know, do customized packages and things like that. They're really, you know, they've really thought about this stuff. So there you go.
There's the in circuit programming thing that hooks up to Pa3, Pa6 and Pa5 there, so the menu is pretty good. Like hats off to that. Anyway, here we go so we can now program auto program our chip. Here we go verifying.
Boom OTP Done like that cuz it's only like it's only 2k worth of program memory. and what does it say? I See Okay and one has passed. So yep, one one okay and of course we can. Can we just push the program button I don't want to do it again, don't want to try and write over it anyway.
You can just push the program button or we can verify as well, but you probably can't verify after you set the security bit. So the secure weird, but our security the protect bit is turned off in this particular case. But there you go, we know we know. Chicken dinner.
Let's try now. flush our lead on our breadboard. Okay so what I've got here is just a little little so8 adapter board like this. so just got power and ground hooked it up to the lead.
and yes, the power and ground pin eight is the ground so it's back to front. just watch that Trevor Young players Yes an update. By the way, this bloody LCD is still going with their DC bias after what nine months? How long's it been? People have been asking for an update on that bastard. Won't fail so.
but that doesn't mean the theory is not wrong, it's just that means that this seemed be large segmented LCD is it's working a tree anyway? Oh I wish my chip not easy to lose I couldn't be bothered soldering on this I'll have to line it up and I'm gonna press on it. Here we go Blinky hey you guys that's you know I like this case five cent micro but it will say the three cent micro-programmed without a problem and flashing a lead so that is need soapy talk. Have done an amazing job with this with the whole thing and like it's not new they've been around for quite some time and whilst there is you know some Chinglish type stuff like the Help is very comprehensive in English, the manuals in English for the programmer and it's all pretty much it didn't take me long to figure out this at all. Et phone arm feel a bit silly holding this chip up like this, but anyway, um there you go. This is quite impressive I Like it. We've programmed our three cent micro no problems whatsoever and you can't actually get these not programmed at the factory? we were praying. Program for practically free. Really? you know, but like don't ask them to go and program one or ten or even a hundred.
Maybe you know you've got to order like thousands and then they'll be happy to our program them for you I'm sure. So there you go, hope you found that interesting and in a future video I will hook up a scope and logic analyzer to all the pins on this programmer and we'll see if we can start getting some data for this and potentially reverse engineer this so that we can like get it into like an Arduino like program or oil. You know any like low-cost open-source like open the whole thing up so that we can do that won't be as simple as just hooking these up towards some pins on Arduino because they said it's different voltage levels and stuff like that. but hey, we could have.
maybe have a little board that plugs on top. make it all open-source and then you know, a 3-cent micro. A lot more people can use these things. They're amazing.
Anyway, if you liked the video, please give it a big finger up. And as always discussed down below, catch you next time you.
Unfortunately not available in India
The comment in the FPPA0 routine – 125,000 / 125 = 1,000, rather than 125
I have a case where all I need is a chip that turns off another chip when the AA battery is below 1v. The key is it is very low power, i'm using a attiny85 which will work, buts its $1.50, adding it to a $5 setup is a bit much, but I don't know of any other solution..I'm sure someone EE could do some analog solution, but it would be more than a single component to hand solder, so one of these that just reads voltage, turns on a pin if below, and go back to sleep, this would be great for that.
They now have a MTP chip (multiple time programmer, 1000 times only) which would be great for hobby, if an arduino could program it.
"Reverse-engineer"… Now Padauk regrets sending you the programmer.
So! When do we get it to boot Linux?
You have talked so much about how impressed you are about the quality provided by Padauk. But then in the last minute you go on saying you want to try to reverse engineer it and maybe make it open source. I find that fairly disrespectful. Just pay the 50 bucks for the programmer/emulator and let the pros at Padauk do the integration. Open-sourcing that will just dilute the quality.
While Padauk may sounds esoteric to DIYers, it is very well known among mcu hardware professionals in China and SEA. Billions of chips made by Padauk are used in toys and small consumer electronics, where power consumption and cost are primary concerns. Some devices may contain more than one such MCUs.
cool
Real life Shenzhen-IO
Great video
this programmer also calibrates internal rc oscillator when uploading the code.
Is there anything similar that is open source?
I'm imagining this reading I2C and outputting servo PWM control so you could reduce wiring in more complex RC devices by just running busses.
This chip is not programmable with Arduino, so what is actually the cheapest chip that is?
you can easily swallow them, nice
Did you know ET actually says, "ET home phone"? One of the classic quotes that is generally done wrong!
If they expect people to use their software to compile/program the chips, do they at least have a linux version of everything (or run it all flawlessly under wine)? 2020 is coming and I expect a surge in Windows exodus by the holdouts when Win7 hits EoL.
Can we program it using ardriuno
Ok Dave was the solder worth more than a chip? Y I know the adapter was lol where was this when I started. EPROMS were a pain lol