Author Topic: Can you make the arduino do non miro controler things?  (Read 7972 times)

0 Members and 1 Guest are viewing this topic.

Offline raspberrypiTopic starter

  • Frequent Contributor
  • **
  • !
  • Posts: 358
  • Country: us
Can you make the arduino do non miro controler things?
« on: March 09, 2017, 08:33:38 pm »
Since it reads C could you make it do something like process an image (compress a .jpg to lower quality or anything that a computer would do when you program it in C)? Not necessarily to output the image in any usable way but just make it perform calculations or do something other then look at inputs and turn on outputs.

How complex is that chip; millions of transistors or is it pretty simple?
I'm legally blind so sometimes I ask obvious questions, but its because I can't see well.
 

Offline alsetalokin4017

  • Super Contributor
  • ***
  • Posts: 2055
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #1 on: March 09, 2017, 08:48:08 pm »
Well, the answer is basically "Yes".  You can perform calculations, you can store/read digital data, you can synthesize music, you can do all kinds of things in c++ but these ARE "microcontroller things" after all.  You can even have it store and serve an interactive web page wirelessly with the right "shield" plugin. A small webpage due to memory size limitations, of course.

There is nothing magic about Arduino. It is basically just the microcontroller chip itself, a regulated power supply, and a convenient set of connectors for the power and the mcu inputs and outputs. The software IDE (integrated development environment) is just an easy way to get your c++ program into the chip, and other programs like "processing" make it easy to get whatever kind of input/output you need to display on your computer.

Actually the chip itself doesn't "read c", the software IDE reads c and translates it into instructions that the chip can operate on. If you had the right IDE/compiler you could work in other high-level languages that would be translated into assembly language and fed to the chip.

How many transistors in an ATmel mcu? I don't know but it's more than I can count on my fingers and toes, for sure. "Pretty simple" it's not, from my perspective. But from the perspective of a CPU designer it probably is "pretty simple".
« Last Edit: March 09, 2017, 08:51:22 pm by alsetalokin4017 »
The easiest person to fool is yourself. -- Richard Feynman
 

Offline Nusa

  • Super Contributor
  • ***
  • Posts: 2416
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #2 on: March 09, 2017, 09:15:20 pm »
As for video processing, here's an old project that actually produces VGA output with nothing more than a handful of resistors besides the Arduino itself.
Quote
http://www.gammon.com.au/forum/?id=11608
 

The name Arduino refers to a family of devices, not a particular chip. Historically it uses one of the 8-bit Atmel AVR microcontrollers, but isn't restricted to those. If I had to guess what you bought to play with, you probably have http://www.microchip.com/wwwproducts/en/ATmega328p.
 

Offline raspberrypiTopic starter

  • Frequent Contributor
  • **
  • !
  • Posts: 358
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #3 on: March 09, 2017, 09:20:09 pm »
As for video processing, here's an old project that actually produces VGA output with nothing more than a handful of resistors besides the Arduino itself.
Quote
http://www.gammon.com.au/forum/?id=11608
 

The name Arduino refers to a family of devices, not a particular chip. Historically it uses one of the 8-bit Atmel AVR microcontrollers, but isn't restricted to those. If I had to guess what you bought to play with, you probably have http://www.microchip.com/wwwproducts/en/ATmega328p.

I had the atmega but took it back as I was told for simplicity stick with the original arduino.
I'm legally blind so sometimes I ask obvious questions, but its because I can't see well.
 

Offline suicidaleggroll

  • Super Contributor
  • ***
  • Posts: 1453
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #4 on: March 09, 2017, 09:20:43 pm »
Since it reads C could you make it do something like process an image (compress a .jpg to lower quality or anything that a computer would do when you program it in C)? Not necessarily to output the image in any usable way but just make it perform calculations or do something other then look at inputs and turn on outputs.
Yes of course, same with any other MCU.  Your limitations are code size and RAM size, as long as you fit within those requirements it'll run almost anything, it just might be slow, especially if floating point calculations are involved.
 

Offline Nusa

  • Super Contributor
  • ***
  • Posts: 2416
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #5 on: March 09, 2017, 09:33:06 pm »
As for video processing, here's an old project that actually produces VGA output with nothing more than a handful of resistors besides the Arduino itself.
Quote
http://www.gammon.com.au/forum/?id=11608
 

The name Arduino refers to a family of devices, not a particular chip. Historically it uses one of the 8-bit Atmel AVR microcontrollers, but isn't restricted to those. If I had to guess what you bought to play with, you probably have http://www.microchip.com/wwwproducts/en/ATmega328p.

I had the atmega but took it back as I was told for simplicity stick with the original arduino.

You're confusing the chip designation and the product name. Look at the labeling on the CPU chip on your Aruduion. Odds are it says ATmega328. The Arduino Mega uses http://www.microchip.com/wwwproducts/en/atmega2560, which has more i/o ports, timers and memory, but otherwise performs about the same.
 

Offline pitagoras

  • Regular Contributor
  • *
  • Posts: 116
  • Country: fr
 

Offline Ian.M

  • Super Contributor
  • ***
  • Posts: 12860
Re: Can you make the arduino do non miro controler things?
« Reply #7 on: March 10, 2017, 12:01:16 am »
An Arduino is Turing Complete, subject to the limitations of available memory, so given enough external storage, it can do *anything* that isn't time critical, as long as there's enough time to complete the task before the Arduino dies of old age. (e.g. from charge leaking away in FLASH memory cells, electromigration in the metallisation layer of the various chips, or the electrolytic caps drying up and failing)

Here's an 8 bit ATmega emulating a PXA255 SoC (ARMv5TE. core) running Ubuntu Linux.

http://dmitry.gr/index.php?r=05.Projects&proj=07.%20Linux%20on%208bit

Its not actually an Arduino as such, but the Atmega1284P it uses in the same family of chips as the Atmel based Ardunos, and there are third party board packages for using a '1284P from the Arduino IDE.

The emulator could be ported to run on an Arduino Mega 2560 + a protoshield for the SIMM and the SD card with a moderate amount of effort, but as its overclocking the '1284P at 24MHz and the Mega 2560 is only clocked at 16MHz with half the RAM of the '1284P, it would be a lot slower - approximately half the speed or maybe worse.  Also it uses the 'raw' AVR GCC toolchain, not the novice-friendly Arduino IDE, (although the Arduino installation does install the AVR GCC toolchain) so it would be a steep learning curve if you only had previous 'Arduino-land' experience.
 

Online ataradov

  • Super Contributor
  • ***
  • Posts: 11260
  • Country: us
    • Personal site
Re: Can you make the arduino do non miro controler things?
« Reply #8 on: March 10, 2017, 03:40:33 am »
millions of transistors or is it pretty simple?
Number of transistors means absolutely nothing as far as performed tasks go.
Alex
 

Offline raspberrypiTopic starter

  • Frequent Contributor
  • **
  • !
  • Posts: 358
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #9 on: March 10, 2017, 03:54:44 am »
So is this where most ICs are headed? I have a really cool clock that uses needle dial "VU" meters to show the hours, minutes, and seconds. The instructions say you can program it to do anything you want like changing out different dials or use different displays entirely. You can tell its "smart" by the way you set the time with a rotary encoder. So in the future or right now maybe, you get a micro controller whos only limits are speed and memory and you just program it to do what ever you want instead of purpose built ICs that only do one thing and only have one type of output that works? I'm noticing it in products that have USB connections...
I'm legally blind so sometimes I ask obvious questions, but its because I can't see well.
 

Online ataradov

  • Super Contributor
  • ***
  • Posts: 11260
  • Country: us
    • Personal site
Re: Can you make the arduino do non miro controler things?
« Reply #10 on: March 10, 2017, 03:58:11 am »
So in the future or right now maybe, you get a micro controller whos only limits are speed and memory and you just program it to do what ever you want
You can do that right now. High end microcontrollers run at 300+ MHz and have 512 KB of RAM (and can use external SDRAM, if needed). This is plenty of computing power.

And then your nickname is pretty powerful for its price.

instead of purpose built ICs
Depends on the "purpose". Some things are just impractical to do in software. Sometimes you care about the price and purpose-build ICs are cheaper.
Alex
 

Offline raspberrypiTopic starter

  • Frequent Contributor
  • **
  • !
  • Posts: 358
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #11 on: March 10, 2017, 04:00:48 am »
millions of transistors or is it pretty simple?
Number of transistors means absolutely nothing as far as performed tasks go.

I often speak in generalizations. Such as I thought this power supply I was building (when I started it I had no idea what I was doing, or rather some knowledge but no working use of it) had some fancy MOSFET in it because it looked like one. It was an LM317 that doesn't have one transistor in it but probably 50. I had no idea that integrated circuits came in this package with only three pins. So when I say "number or transistors" I'm asking about general complexity of the device. Like a core I7 has ~10 billion transistors.
I'm legally blind so sometimes I ask obvious questions, but its because I can't see well.
 

Offline Ian.M

  • Super Contributor
  • ***
  • Posts: 12860
Re: Can you make the arduino do non miro controler things?
« Reply #12 on: March 10, 2017, 04:05:14 am »
If its digital, or mostly digital, is more than can be done with one off-the-shelf logic chip, and it doesn't need to be screamingly fast, the tendency is to use a MCU.  If its pure digital and it does need to be screamingly fast, there's a tendency to use a FPGA. 

Many special purpose chips for more complex tasks are actually custom programmed MCUs - sometimes the only difference is the pre-loaded program and the part number, or it may be more 'hidden' e.g a MCU core on a multipurpose custom chip with extra peripherals and/or interfaces that can be factory programmed as a range of different chips for similar applications.
 

Online ataradov

  • Super Contributor
  • ***
  • Posts: 11260
  • Country: us
    • Personal site
Re: Can you make the arduino do non miro controler things?
« Reply #13 on: March 10, 2017, 04:09:06 am »
I'm asking about general complexity of the device. Like a core I7 has ~10 billion transistors.
The reason such numbers are not readily publicized, is that they are pretty much useless for anything. Intel likes to brag about this stuff because there is not much else to say.

I'd estimate that mega328 has 500K-1M transistors (excluding on-chip memories). But this says absolutely nothing about actual chip performance.
Alex
 

Offline jonovid

  • Super Contributor
  • ***
  • Posts: 1437
  • Country: au
    • JONOVID
Re: Can you make the arduino do non miro controler things?
« Reply #14 on: March 10, 2017, 04:10:38 am »
be interested to know if this is possible  :o
do like the old Arduino Atmel  its the  Z80 of our time.
if someone can squeeze more out of it , then Good, let us know .  :-+
Hobbyist with a basic knowledge of electronics
 

Offline Ian.M

  • Super Contributor
  • ***
  • Posts: 12860
Re: Can you make the arduino do non miro controler things?
« Reply #15 on: March 10, 2017, 04:28:09 am »
From comp.arch.embedded: Transistor count of common uCs? (11 May 2004)
Quote
IIRC, The AVR core is 12,000 gates, and the megaAVR core is 20,000 gates
Each gate is 4 transistors. The chip is considerably larger since the memory
uses quite a lot.
The ATmega128 is probably somewhere between 600k-1M transistors.

For comparision:
The AT91R40008 ARM7 micro is probably 2 M transistors.
The ultimate CISC microprocessor, the NS32016 was but 60,000 transistors.



--
Best Regards,
Ulf Samuelsson   ulf@********.com
This is a personal view which may or may not be
share by my Employer Atmel Nordic AB
 

Offline TNorthover

  • Contributor
  • Posts: 42
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #16 on: March 10, 2017, 04:43:08 am »
Quote from: Ian.M
The AT91R40008 ARM7 micro is probably 2 M transistors.

This looks incongruous, I think he's mixing counts of different things (including the RAM for the ARM?). The Cortex-M0 apparently has about 12000 gates and while it's optimised for transistor count, I don't believe it's 50 times better than the earlier equivalents.
« Last Edit: March 10, 2017, 04:46:51 am by TNorthover »
 

Offline Ian.M

  • Super Contributor
  • ***
  • Posts: 12860
Re: Can you make the arduino do non micro controller things?
« Reply #17 on: March 10, 2017, 04:52:12 am »
Yes, it does look like Ulf mixed up the comparisons.  However his numbers for the AVRs are probably good. - For those who don't know of him, he was well respected Atmel 'insider' who helped a lot of people with AVR queries on comp.arch.embedded and related technical USENET groups.
« Last Edit: March 10, 2017, 04:54:20 am by Ian.M »
 

Online ataradov

  • Super Contributor
  • ***
  • Posts: 11260
  • Country: us
    • Personal site
Re: Can you make the arduino do non miro controler things?
« Reply #18 on: March 10, 2017, 04:52:23 am »
The Cortex-M0 apparently has about 12000 gates and while it's optimised for transistor count, I don't believe it's 50 times better than the earlier equivalents.
Cortex-M0 from Design Start package in Cyclone V takes exactly 841 registers and ~4000 LUTs. This is just the core, no memories, no peripherals.
Alex
 

Offline TNorthover

  • Contributor
  • Posts: 42
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #19 on: March 10, 2017, 05:09:39 am »
Cortex-M0 from Design Start package in Cyclone V takes exactly 841 registers and ~4000 LUTs. This is just the core, no memories, no peripherals.

You don't happen to have the Cortex-M1 numbers handy too, do you? I'd heard that one was optimized for FPGAs but never actually saw the numbers and would be interested in what the difference is when tuning for different targets like that.
 

Online ataradov

  • Super Contributor
  • ***
  • Posts: 11260
  • Country: us
    • Personal site
Re: Can you make the arduino do non miro controler things?
« Reply #20 on: March 10, 2017, 05:14:06 am »
You don't happen to have the Cortex-M1 numbers handy too, do you?
Nope. But M1 numbers should be available from ARM. I think I saw some numbers on their site or in some promotional PDF.

I'd expect them to be a bit more heavy on the register side. As far as number of registers goes, DS M0 is definitely optimized for that, at expense of a lot of logic. And that's no the best for FPGA.
Alex
 

Offline Richard Crowley

  • Super Contributor
  • ***
  • Posts: 4317
  • Country: us
  • KJ7YLK
Re: Can you make the arduino do non miro controler things?
« Reply #21 on: March 10, 2017, 05:16:43 am »
Since it reads C
There is a C compiler for the machine code.  That is no indicator of capability.

Quote
could you make it do something like process an image (compress a .jpg to lower quality or anything that a computer would do when you program it in C)?

Could a lower-end Atmel microcontroller do the computations necessary to transform an image into a compressed codec?  Yes, but for a couple of limitations which are likely show-stoppers:
1) Speed.  The amount of time it would take to process a large array of pixel data may be much longer than you expect.
2) Memory. Unless you are talking about really tiny images, it seems quite possible that the Atmel microcontroller can't access enough memory to perform such a task.

Quote
Not necessarily to output the image in any usable way but just make it perform calculations or do something other then look at inputs and turn on outputs.
You are vastly under-estimating the amount of "horsepower" it takes to do sophisticated image manipulation and/or analysis.

Quote
How complex is that chip; millions of transistors or is it pretty simple?
Complexity of the CPU has no correlation with its ability to process a large amount of data quickly.
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #22 on: March 10, 2017, 06:09:15 am »
The only thing that "reads" C code is the compiler. C was developed in the early 70s and you can code in C for just about anything, even 8 bit microcomputers from the 80s. Technically there's no reason you couldn't do image processing or even transcode video with an AVR or even a 6502 if you were extremely patient. To put that into perspective, I remember when .jpg compression was first showing up I had a 40MHz 386 with a 640x480 VGA screen. It could open a jpg file for viewing but it took about 30 seconds to paint it on the screen. That had a lot more processing power and memory than an Arduino.
 

Offline Rick Law

  • Super Contributor
  • ***
  • Posts: 3442
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #23 on: March 10, 2017, 07:06:19 am »
be interested to know if this is possible  :o
do like the old Arduino Atmel  its the  Z80 of our time.
if someone can squeeze more out of it , then Good, let us know .  :-+

Wikipedia has "As of 2016, 10 nm devices are still under commercial development. Commercial release is confirmed for 2017 by Samsung." and on the side bar, 5nm in 2020.
https://en.wikipedia.org/wiki/10_nanometer

5nm is the width of about 50 atoms abreast.  They are nearing/entering a domain where quantum mechanics starts to dominate.  I am eager to see in 2020, if and how they begin to deal with that.

I actually would not think 5nm is possible, but perhaps it is.  Question remains is can it be commercially produced and with operational reliability.  There is a floor >0.1nm.  You can't have a node smaller than an atom.

So, no matter what, the end of Moore's Law is in the near future.
 

Offline westfw

  • Super Contributor
  • ***
  • Posts: 4199
  • Country: us
Re: Can you make the arduino do non miro controler things?
« Reply #24 on: March 10, 2017, 09:35:48 am »
See also https://en.wikipedia.org/wiki/Transistor_count  (alas, it does not include many microcontrollers.)
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf