tag:blogger.com,1999:blog-3993498847203183398.post7743346626445351019..comments2024-03-28T09:19:27.451+00:00Comments on RevK<sup>®</sup>'s ramblings: Micro controller stuffRevKhttp://www.blogger.com/profile/12369263214193333422noreply@blogger.comBlogger8125tag:blogger.com,1999:blog-3993498847203183398.post-80065030213510440552016-03-20T16:45:48.535+00:002016-03-20T16:45:48.535+00:00There is another platform option you should consid...There is another platform option you should consider, the ESP8266. It was designed as a wifi-to-serial bridge but it's a microcontroller in its own right and being used for all sorts of things beyond its original purpose. I would confidently say that even for someone with lots of experience with PIC development, that you could get this particular project working faster on this platform, especially if you use a DS18b20 as suggested above.<br /><br />You can write in C on it or install a third party firmware called NodeMCU that lets you write in Lua. I believe you can code in assembly but if you WANT to do that, then you probably would be better off with the PIC.<br /><br />NodeMCU has a very functional OneWire module but, unlike the PIC, in-built modules for all sorts of other higher-level things too like HTTP, SNTP and MQTT.<br /><br />This would also appeal to your fondness for putting things on the internet (IPv6 support is sadly non-existent at the moment).<br /><br />I guess you would have to bit-bang the IR LED aspect but at the frequency you're talking about this shouldn't be any harder than it would be on the PIC. There are some limitations with monopolising the CPU by using timer delays since it needs to handle wifi / serial timing in addition to whatever code you're running.<br /><br />The cheapest version of the part is about $2.50, along with another $2 for a 3.3v usb-to-serial adapter needed to program it.<br /><br />It's also a rare example in the integrated circuit world of an original Chinese design, with the documentation to prove it. Have a google, I think it's the most interesting microcontroller development since the Arduino (which it's often used in combination with).Gavin Whttps://www.blogger.com/profile/11021101258601939374noreply@blogger.comtag:blogger.com,1999:blog-3993498847203183398.post-68006052158956854692016-03-17T05:40:15.963+00:002016-03-17T05:40:15.963+00:00Why do air conditioners have such a wide margin be...Why do air conditioners have such a wide margin between heating and cooling when in "auto" mode? If it is to prevent the unit from oscillating forth and back between heating and cooling, surely this could be eliminated with a basic algorithm that mandates a minimum time period (say 30 mins) between any flipping between heating and cooling.RSchuhttps://www.blogger.com/profile/06595169738713509573noreply@blogger.comtag:blogger.com,1999:blog-3993498847203183398.post-3231867935774935332016-03-16T17:12:55.462+00:002016-03-16T17:12:55.462+00:00Not exactly. I designed and built the drilling ma...Not exactly. I designed and built the drilling machine mostly out of old printer parts.<br />The original processing core was a 100MHz 486 running Damn Small Linux with a custom kernel. That PC has finally died so I'm revamping the machine as a USB peripheral with an FTDI USB->Serial converter talking to a PIC16F872.<br />The frontend is also getting a makeover with a brand new graphical interface written in C++/Qt4/5. I'll be putting the new schematics and firmware/software on my site when I'm finished:<br />https://baron.bologrew.net/Drillcon100.html<br /><br />With the expected speed increase, I'm hoping the routing mode will be a lot more useful for drawing component outlines on PCBs and there's a chance that my homemade laser cutter add-on will finally be usable which would let me cut masks for solder paste.<br />Bologrewhttps://www.blogger.com/profile/08022540338425449581noreply@blogger.comtag:blogger.com,1999:blog-3993498847203183398.post-83769305972387084782016-03-16T01:04:56.213+00:002016-03-16T01:04:56.213+00:00Surely with the cost of the mechanics for a CNC mi...Surely with the cost of the mechanics for a CNC milling machine, saving a few quid on the controller by using a PIC is pointless?Owen Smithhttps://www.blogger.com/profile/00890951742186614705noreply@blogger.comtag:blogger.com,1999:blog-3993498847203183398.post-82654896002667718532016-03-14T14:42:02.526+00:002016-03-14T14:42:02.526+00:00I've just finished programming a three-axis CN...I've just finished programming a three-axis CNC controller (i.e. three stepper motors and drill power on/off with three limit sensors) with drill and route modes on a PIC 16f872 using just 636 program words.<br />I used the Linux gpasm tools and ran it through simulation tests using the gpsim package.<br /><br />The chip only cost £2.87 plus £0.30 for a 20MHz crystal - less money than your temperature sensor alone. With its low power consumption and sleep modes, you could run such a beast for ages on a 9V battery (via a regulator of course).<br />If you haven't forgotten the PIC16C84 instruction set then programming any member of the PIC16 family is no problem as they all use the same one. Oh and the 16F872 has a built-in i2c port which would make interfacing with the ADT7420 much easier.<br /><br />Alternative sensors could be the DS18B20-PAR which is through-hole mounting if you don't want to get into surface mount components. It is a 12 bit device with 0.0625 degrees C precision and +/-0.5 degrees C accuracy and has a 1-Wire interface so you need only a single I/O line to talk to it. It also has programmable min and max temperature alarm limits that might be useful.Bologrewhttps://www.blogger.com/profile/08022540338425449581noreply@blogger.comtag:blogger.com,1999:blog-3993498847203183398.post-5147025012280974582016-03-14T09:48:38.545+00:002016-03-14T09:48:38.545+00:00Ah, devices that don't require weekly software...Ah, devices that don't require weekly software updates. There's something to be said for that. At times I feel like a slave to computers, constantly having to update the damned things.Owen Smithhttps://www.blogger.com/profile/00890951742186614705noreply@blogger.comtag:blogger.com,1999:blog-3993498847203183398.post-16899884586764997382016-03-14T08:06:44.432+00:002016-03-14T08:06:44.432+00:00I'd suggest Arm Cortex-M(3 or 4) like this dev...I'd suggest Arm Cortex-M(3 or 4) like this dev-board http://uk.farnell.com/stmicroelectronics/nucleo-f411re/dev-board-stm32f411re-cortex-m4/dp/2433469<br />and C/C++. You will probably find it is massivly overkill for the task, which is a good thing(feeling limited in a small run task means it takes longer to get it working or have to re-design the hardware, while it is usually easy to cost-down later if mass-producing, but you knew that... ).<br />Linaro provide a GCC tool-chain and libraries that are suitable, https://github.com/texane/stlink provides what is effectivly a GDB server for the on-board jtag interface, or OpenOCD works.<br />With the availability of good compilers on reasonable sized devices, there is no need to resort to writing the whole thing in assembler.<br />(Actually I'll add a rider on that, the M0, M0+ and M1 are arm6-m based, while the M3, M4 and M7 are arm7-m based. The arm7-m based units have a very nice new vector interrupt controller which only requires function pointers to extern "C" void func(void) functions, and thus requires no special magic to write interrupt handlers. I can't say if the arm6-m devices do the same thing or not.Anonymoushttps://www.blogger.com/profile/18158312606191961421noreply@blogger.comtag:blogger.com,1999:blog-3993498847203183398.post-58282375004223188552016-03-13T22:01:19.275+00:002016-03-13T22:01:19.275+00:00If you really want to write in assembler you shoul...If you really want to write in assembler you should still either use a PIC (probably not a 16C84) or an Atmel AVR (like an AVR tiny). The modern small processors have inbuilt oscillators which mean you may get away without a crystal, though I suspect for a reliable IR remote you may still need one. Both vendors produce reasonable IDEs with C compilers, though not sure what the non-Windows support looks like.<br /><br />ARM Cortex covers an enormous range of things, from Cortext-M1 which is supposed to compete with small 8-bit processor to the Cortex-Axx stuff which is in the smartphone territory.<br /><br />Surely you should be looking to use the Raspberry Pi Zero though...<br />Will Deanhttps://www.blogger.com/profile/15515078919433985452noreply@blogger.com