Converting code to be Arduino (ATMEGA328 IC) compatible

Go To Last Post
35 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi,

I need to convert this code to be compatible for the arduino however I am very new to the Arduino and am not sure how to start. I read up on some forums and online sites that the arduino doesnt require a "main". Secondly i was having problem with my interrupts, using sei(); instead of #asm("sei") didnt really help me.

Please tell me how and where i should start. I would really be grateful!!!

Thanks
Confy

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Your code is written for the Codevision compiler.

And I have never heard of a system file called

As far as I know, the Arduino is just some hardware with a bootloader and serial link.

So any program written in any language for a mega168 target should run ok. You just compile it in the regular way. Any i/o must match the Arduino port pins.

However if you want to conform to the Arduino 'way of doing things', you should use the Arduino syntax and conventions.

You need to reveal the contents of "WProgram.h"
The first step would be to use regular C that can be compiled by avr-gcc.

Then with a few well chosen macros, you can 'Arduino-ise' it.

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

Any i/o must match the Arduino port pins.

So knowing the pinout of the 168/328 board will probably help:

http://arduino.cc/en/Hacking/Atm...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi David,

Thank you for your reply. I am using the Atmega328. I tried compiling this but there were a plethora of errors.

This was initially coded for the ATmel Mega 32 chip in which the Mega32.h library was added. I replaced that with WProgram.h in order to try to avoid some of the errors i found since WProgram.h is the main header for the wiring library. ( I was sort of clutching at a straw)

I realise that for the arduino i would need to remove the int main() and add the void setup() and void loop() parts.. but apart from that i think i'm really lost as to how to code the interrupt part to be compatible. The compiler keeps throwing the error "TIM0_COMP" was not declared in this (global) scope"

Thanks again
Confy

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi clawson,

Thanks for the link. Yes i will be ensuring that the I/O pins are properly connected.

Confy

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

But why do you think you need to convert the code to Arduino syntax (setup(), loop(), digitaWrite(), digitalRead(), etc., etc.) just because you want to run the program on an Arduino board. Nothing says they can only run Arduino "sketches". Just build this code (modified for 328) using normal C so that it generates a .hex file then the only "clever" bit is how you get that .hex file programmed into the Arduino chip. In fact, because the Arduino bootloader uses a completely standard protocol, the way you do this is using a PC program that can communicate using that protocol. The program to use is called "avrdude" and there are many references on the net showing exactly how to use with with Arduino (one of the best is Workshop article 10 on this page: www.smileymicros.com )

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I converted the mega32 code to mega328P code. i.e. changed register names.

Then converted the sfr.# syntax to standard C.
And used the avr-gcc ISR() convention.

So you get an avr-gcc compile.
And it should compile with CodeVision too.

I have no idea what your program does, you will have to edit for correct hardware pins etc.

David.

Sed script to convert for m328p and avr-gcc.
You will still have two hand-edits.
You will also need to use floating point printf() library

# convert sfr.# syntax
# Note that structure.member is pefectly valid syntax too.
# IDENTCONTINUER [A-Za-z_0-9]*
# bit assignments and logical comparisons

s/\([A-Za-z_][A-Za-z_0-9]*\)[.]\([0-7]\)[ 	]*=[ 	]*1/\1 |= (1 << \2)/
s/\([A-Za-z_][A-Za-z_0-9]*\)[.]\([0-7]\)[ 	]*=[ 	]*0/\1 \&= ~(1 << \2)/
s/\([A-Za-z_][A-Za-z_0-9]*\)[.]\([0-7]\)[ 	]*==[ 	]*1/((\1 \& (1 << \2)) != 0)/g
s/\([A-Za-z_][A-Za-z_0-9]*\)[.]\([0-7]\)[ 	]*==[ 	]*0/((\1 \& (1 << \2)) == 0)/g
# any other refs in expressions unless expression assignment
/[A-Za-z_][A-Za-z_0-9]*[.][0-7][ 	]*=[ 	]/!{
	s/\([A-Za-z_][A-Za-z_0-9]*\)[.]\([0-7]\)/(\1 \& (1 << \2))/g
}

/WProgram.h/{
	s/WProgram.h/avr\/io.h/
	a\
	#include 
}
s/ADCSR/ADCSRA/g
s/TIM0_COMP/TIMER0_COMPA_vect/
s/TIMSK/TIMSK0/
s/TCCR0/TCCR0B/
s/OCR0/OCR0A/
s/UCSRB/UCSR0B/
s/UDR/UDR0/
s/UBRRL/UBRR0L/
s/USART_RXC/USART_RX_vect/
s/USART_DRE/USART_UDRE_vect/
s/interrupt[ 	]*\[\([^]]*\)\].*{/ISR(\1) {/
s/interrupt[ 	]*\[\([^]]*\)\].*$/ISR(\1)/
s/\#asm/asm/
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

@David - would you mind sending me the version you compiled? (unless i misunderstood and you're guiding me on how to convert it? which i also appreciate very much.. thank you)

Also, i'm sorry for bothering you but i dont understand the code that you pasted above..

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Way cool. I'd pay for a bat file that converts gcc->imagecraft, and I bet there are people that would like a gcc->cv converter too. (Probably no one would want to go the other way......)

Imagecraft compiler user

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Bob,

It is just a question of suitable sed scripts. This can automate most of the edits. However it is always wise to 'diff' the input and output to check for wierdos.

You will also have some hand-edits anyway.
Then you use a single "compiler.h" that copes conditionally with macros / includes specific to your compiler.

David.

Bob,

I already have fairly portable macros that cope quite well with Atmel app notes. I am sure that they have been posted here before.

You will never automate code written by avr-gcc diehards that use every non-portable construct possible.

Confy,

You are already using avr-gcc. It comes with 'sed' the stream editor. So you just need to copy and paste my script to a file called "conf.sed". Then say:

sed -f confy.sed code.txt >code.c

A feature of gnu sed is that it does not like in a script file. So when you capture from a post, you must make sure it only has
between each line.

If you have a problem, I will email you the sed output.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

A feature of gnu sed is that it does not like in a script file. So when you capture from a post, you must make sure it only has
between each line.

Dare I suggest you could sed the sed script? ;-)

I often use this as a sed reference:

http://sed.sourceforge.net/sed1l...

Suitable converters are under "TEXT CONVERSION AND SUBSTITUTION".

I think I'd go with:

sed 's/\x0D$//'

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Cliff,

That is useful. My own sed ignores . And since Windoze likes to have I just use my version rather than the gnu 'sed'.

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

@Clawson - The smileymicros link is very useful and interesting and I am learning a lot. Thanks =)

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

@David - You're very kind, I am trying it out now.

@Bob - Checking out your link.. thanks for helping.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The big question is what do you mean by "compatible for the Arduino"?

Note: I'll state up front that I'm not an arduino fan but I'll try to be open and objective in describing it.

IMHO the arduino team has taken a horrible misstep in their attempt to brand "Arduino".

In their minds "Arduino" is a "way of life".
It means you use an "Arduino" board,
you use the "Arduino" IDE to write code in the "Arduino" programming language,
which uses the "Arduino" s/w libraries, and then use the IDE to talk to an "Arduino" bootloader to flash the code into the AVR.

The problem with all this "Arduino" stuff is that there are many separate components and they literally don't have proper terminology to refer to the separate components as they expect you to use all of them other wise you are not "Arduino".

In reality you can separate out many of the separate pieces.

That is why you see all kinds of "duino" names. Freeduino, Sanguino, Teensyduino, boarduino, etc...

I will say that one really good thing that the Arduino s/w provides is a 1 stop shop for downloading the s/w. It is also a single install which gives you all you need.
This is definitely not the case with the standard avr s/w tools like WinAVR and Avrstudio.

So if you look at each piece:

Arduino h/w:
It is a hardware platform with well defined connectors. There nothing requiring this to use any other Arduino component.
The arduino team prefers that the name "Arduino" only be used if it matches their hardware design. But even then, there are many different designs of "Arduino".
Some have rs-232, some have ttl serial, and some have a ftdi to USB chip on them to provide the serial interface to the Host.
In general when the name "Arduino" is used, the board will have the "arduino" connectors on it, but there is no guarantee how it interfaces to the host or how it is powered.

Arduino IDE:
This is a java based IDE that compiles the "Arduino programming language" file and downloads it to the Arduino hardware.
It also includes a serial terminal monitor
as well as the ability to allow the user to pull in "libraries" and many provided "canned" example "sketches".

Arduino Programming Language:
The arduino programming language really isn't a language at all but simply some library functions used in C++.
Essentially, main() is trapped by their code
and then they call a function in the user sketch called setup() and when that returns
they then call a function loop() in an endless loop.
So the users code consists of setup() and loop().
It depends on lots of support from the IDE
as it attempts to not require that users know much programming or require them to write proper C++ code.
So the IDE will take your sketch (.pde file)
and parse through it to convert it proper C++.
Quite a bit of magic going on here as it has to locate all your functions and create prototypes for you. The is part of the arduino s/w libraries.
This is slammed into your code as part of the process of converting your .pde file to a .cpp file.
It sets up a few macros but mainly includes the header for their low level "wiring" library functions.
The IDE also has some magic in it to locate what they call "libraries" which are not libraries at all but an organized directory of sources. If the users "includes" a "library" by using the IDE "import library" option, it will then compile that "library" source and add that librarie's directory to the C++ include path when compiling the users .pde/.cpp file.

One of the big philosophical items for arduino is "soft" configuration.
This allows everything to be configured runtime. So the i/o pins to be used have the ability to be assigned at runtime.

Arduino Software Libraries
Even this is not well defined.
There is a core set of functions that provide low level functions such as
digitalWrite(), pinMode(), digitalRead(), timers, pwm, attach/detach from interrupts, hardware serial functions, etc..
Those are the core arduino supplied library.
That is in fact a real library that is built as a library.
The other "libraries" add support for periphals like LCDs, servos, stepper motors etc... and are not built as libraries.
The IDE has support for including these libraries and there is lots of code in the IDE to support the building of these "libraries" based on the location in the arduino tree.
The IDE will build an included "library"
for the user. But the library writer has no ability to alter/control the way the code is built or its compile options.

Bootloader:
Pretty much an AVRISP bootloader.
The IDE uses avrdude under the hood for actual downloading.
Recent "arduino" packages now have the ability to allow user supplied downloaders. This is what the teensy boards use for their downloading.

---------------------------

So back to your original question/dilemma.
How to be compatible with "Arduino".

It comes down to what does that mean to you?

Does it mean converting your code to use the Arduino i/o library and be a "true" arduino sketch that uses all the arduino i/o facilities rather than direct port i/o?

OR

Does it merely mean tweaking the code to be able to use the Arduino IDE to compile it and download it to the users board?

I have seen people that have done the latter.
They write standard C code (replace their main() with loop()) and simply use the Arduino IDE as an easy way to allow users to compile it and download it to their boards.
While the code would not be considered to be an "Arduino" sketch, it can be done this way.

================
Now for some commentary on some of the "ugly" stuff under the hood in Arduino.

It appears to me that
the Arduino team really doesn't like commandline stuff. They really haven't ever had support for building outside the IDE.
Yes they had a Makefile but it didn't work until you tweaked it and even then it didn't support any of the "libraries". It only supported the core wiring library.
And now in the recent 0018 release they have removed the makefile entirely from their tree.

Since the IDE is trying to implement the "Arduino programming language" rather than be a simple wrapper on top of standard C/C++ tools, it is doing TONs of parsing.
Sometimes this parsing will break on perfectly legal code.

The IDE does not use or take advantage of make
or anything rule or script based.
As a result all sources are built every time.
They have all the build rules as well as all the compiler and linker options hardcoded in the java code.
Need to change a compiler option?, go rebuild your IDE.
(which normal users will never be able to do)

The have a "verify" and an "upload" button in the IDE GUI.
The verify button compiles the code but in a temporary directory. The upload button rebuilds everything just like the "verify" button but in a directory underneath the source location, and then downloads it to the board.

The low level wiring routines are a pig.
They are table driven. So when you want to turn on say pin#1 table lookups have to be done in order to map that pin to a AVR port address and then to the proper bit within that port.

These lookups are not only slow but can't take advantage of SBI/CBI instructions because they have to go indirect off a port address.

What is worse is that since their code is not using atomic instructions to set/clear i/o bits the operation is interruptable and they don't mask interrupts during the i/o port update. So as result their digitalWrite() functions are not interrupt safe.
As a result foreground code can clobber an interrupt routine's i/o pins if the foreground and interrupt routine share pins on the same AVR port.
This has been reported to the Arduino team with a proposed fix but is not even being accepted as issue that needs to be resolved.

The sad part of their i/o lookup method is that it could have been done better. Their method does not take advantage of knowing the processor type at compile time which means part of the lookup could have been avoided/optimized knowing this knowledge.

Compounding all this arduino i/o is that the i/o functions do more than merely set or clear the i/o bits. They also configure the port bits and will detach other AVR functions from the bit/pin when necessary.

To make the i/o code really fast, this additional logic needs to be removed from the runtime path. Or at least have a layered set of calls like say digitalWrite() vs _digitalWrite() to provide both options.

The discussions over altering this behavior were a bit spirited.

Paul Stoffregen over at http://www.pjrc.com as well as several others
battled with the Arduino team over trying to redo the i/o routines to make them faster and provide the ability to get CBI/SBI instructions when the arguments are all constants.

If you use his teensy boards, the i/o will be much faster and will use SBI/CBI instructions when arguments to the ardunino functions are all constants. This makes them about 40-50 times faster than the standard arduino i/o routines as well as being interrupt safe.

Paul also has defined a set of defines & macros that allow you to specify raw AVR pins when using the arduino api functions. So to set PORT D pin 0 you would use writePin(PIN_D0, 1)

If you look at the time sensitive "arduino" h/w libraries, they won't be using the Arduino wiring library API calls. The wiring API calls are simply to slow for some applications. This shows that when time is critical you have to step outside the "Arduino" i/o world and use native i/o access methods, which totally breaks the Arduino idea of having fully portable code.

The biggest thing Arduino does well is allow a non technical person to download and install the software and make an led blink.
That an any number of other "canned" programs.
Once you step outside that world of "canned" programs, arduino can start to get fuzzy and then when you get into anything realime, you pretty much have to jump outside the Arduino APIs.

And at least from my perspective, using the Arduino IDE and its environment is very frustrating to a person that is familiar with programming and standard build tools.

Anyway, hopefully people will find that information useful.

--- bill

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Bill,

Your information is really good and I'd like to see this all discussed piece by piece in specific threads. On the one hand Arduino is the greatest thing since sliced bread, on the other hand it is a nightmare. I agree with both these statements. The real problem is exactly the kind of issue that started this thread. The OP takes some complex code from a Cornell student, tries to modify it for the Arduino, since after all the Arduino is easy - right? Then he hits a wall and comes to AVRFreaks and many folks here just don't know what to make of the situation. I'm one of those people. How do you address folks who are getting seduced by the ease of the Arduino, then run into the real world of embedded systems? I spent an hour already on this thread trying to figure out a proper approach because this very issue of copying complex code, messing with it, then posting it here to get input on how to fix it for the Arduino has occurred many times in that past several months. At the moment it is imponderable.

BTW, I've been a fan of Paul since the day's of Paulmon. I nearly stayed with the 8051 just because of his work. His new work with the AVR is brilliant, but I guess that is another topic.

Anyway, I'm going to mark and reread your comments because I think they deserve several new threads on their own.

Can you think of a polite title/topic for a thread on how we should address the Arduino newbies who come here after shooting themselves in the foot?

In the meantime I'm not sure how to address the OP since this isn't either a complete newbies who needs to be told to learn how to blink and LED and call me in the morning, nor is it someone with the transitional skills to port code from 'the real world' to Arduino. I'm in the middle at the moment and I don't know how to proceed without risking alienating one crowd or the other. I'm also babbling so bye bye.

Smiley

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

We have drifted off topic but in my mind with respect to Arduino on the avrfreaks site is
that if you look at the subject of each of the established forums on avrfreaks,there is no real place for "arduino" threads.

Arduino discussions aren't really AVR, and it sure isn't GCC or AVRstudio, so where should they go?

Hardcore AVR folks, gcc folks and experienced embedded people typically won't have much desire to deal with arduino.

And the arduino folks, including the top level Arduino team don't want to bend their environment
to make it friendlier to experienced embedded programmers and other build tools. If anything they are pushing
further away by doing things the "Arduino" way.

And that *is* the problem in my view.

Both sides have their views and are they are not compatible.

Currently, the arduino guys have their own forums and the non arduino guys come to avrfreaks.

And since there seems to not be many folks
that know both, getting help to bridge between them going either direction is spotty at best.

So by default avrfreaks is currently not really a place for getting any sort of arduino support.

The bigger question would be?
Should avrfreaks be a place that supports "arduino"?

I'm not sure that the answer to that questions is yes.

-- bill

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

So back to the OPs topic.
The big question is what is the goal?
To create an "Arduino" sketch by fully porting to the code the arduino environment
or to merely use the arduino s/w tool set to compile and download a piece of code?

For a piece of code like this, the latter
will be much easier.

I have seen projects and kits for sale where this is done.
Here is a great example of non arduino code using the Arduino IDE to compile and build the code:

http://www.evilmadscientist.com/article.php/bulbdialkit

(Scroll down and take a look at the "standard firmware")

While somewhat perverse and total blasphemy to both arduino and avr-gcc/AVRstudio users,
it does allow people to have access to the source code and a simple GUI IDE tool to build the code and update the AVR chip on Windows, MAC, and Linux.

And while I'm no Arduino fan,
there is no other way to easily provide this capability on all those OS platforms.

Arduino is great for providing an environment to build "canned" AVR s/w stuff like this kit and allowing users to make minor tweaks and tinker with it if they want to.

--- bill

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

There is nothing special about the situation:

Someone "finds" code written in language A on platform X, but wants to have it in language B on platform Y.

So how to get from A/X to B/Y?

Simple. You need to be good enough with A/X to understand the finer details of the existing implementation. And you need to be good enough with B/Y to recreate the implementation.

Now, if your desire to get A/X ported to B/Y is because you don't understand A/X very well, then your porting activities are doomed. Then your hope is not porting, but going back to the underlying algorithms (if you have a description of them), to understand them, and to freshly implement them on B/Y.

If A is close to B and/or X close to Y then things are likely easier, but still you first have to understand A/X or the algorithms well. Otherwise you need to be lucky.

If you don't understand your target platform B/Y you have a problem whether you port the code or re-implement the algorithms.

So the first question would be WHY? If it is because you want to avoid language A or platform X, then well, see above. You need to know enough of A/X to port the software. So porting is not a valid strategy to completely avoid A/X.

You then can have a look at how different A/X and B/Y are, to estimate how difficult the porting would be.

In case of the Arduino you find that the Arduino inventors complicate porting by venting their spleen to name everything different and going with their own baby-talk terminology. Even if there are well established names for things. So someone knowing all the special B/Y terminology has to learn the standard terminology for A/X, too. With having their own terminology they actually did a disservice to their users. And it doesn't matter if they sell it as a way of life. The result is plain and simple language/platform lock-in.

Stealing Proteus doesn't make you an engineer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Gents, if you want me to cut out the interesting generic "is Arduino a bit crap" discussion from the middle of this thread I can select individual posts. Just tell me which ones, what you want the new thread called (whoever "owns" the top post will be able to change this anyway) and where you want it.

(BTW I don't agree with Bill, AVR Forum *is* relevant to Arduino, in fact Arduino is one of the most signnificant thinks to happen to AVR in the last few years and I imagine it's probably attracted more new AVR users than the traditional routes have with their slow drip-drip-drip)

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Yes..I'm very new to programming and I'm just picking up interesting projects to work on... I have compiled code in C but i'm not very strong.

I am indeed just trying to compile this code so that i can download it onto the arduino so that i can export the results elsewhere and then my main aim would be to work on these results.

So just before i start anything in haste. Could i perhaps write a code in C and then just download that into the arduino?

i have played around with the 16f877 chip and am familiar with it... would it be a good idea to perhaps code the same functionality in C and then check proper functionality using my 16f877 chip and then make a few changes to the code (ports etc) and then download that to the arduino?...would that work?

I use IAR EwPic to compile and WinPic800 to download the program to the PIC.. will this work on the arduino?

Sorry for being so basic.. Just thought giving this project a shot would be fun and I would get to learn a lot

Thanks again for your patience.
Confy

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Taking a large and complex program such as the one you got from the Cornell website and trying to port it to other compilers or boards is NOT the best way to get started IMHO.

You cannot simply export any old C program to an Arduino and have it work. Once you understand how the Arduino works, then you can test bits and pieces of the program, but you are still asking for a lot of trouble since this program relies on stuff that isn't supported by Arduino at the top level.

Trying to test this code on a PIC to me makes even less sense because you just compound the porting issues that have already stopped you.

If you want to implement this programs functions on the Arduino, first learn to use the Arduino by working through the examples and reading the tutorial materials available on their website. Then break the program into logical units and implement each in the Arduino. Eventually you'll be able to put all the working pieces into a program that works like the one from Cornell.

If you want to use the Cornell program more or less as is, then get the compiler and board the students used.

You said:

Quote:
I am indeed just trying to compile this code so that i can download it onto the arduino so that i can export the results elsewhere and then my main aim would be to work on these results.
It is usually a very bad idea to be so prescriptive when you are just starting out. It seems from your statment that the Arduino does nothing but confuse the issue. If you goal is 'export the results elsewhere' then why wouldn't you start with this mysterious 'elsewhere' instead of chucking an Arduino in the middle?

Smiley

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You can indeed write C code that will run on different targets. However you need to organise your code very carefully in layers. The top layers will be bog standard C.

The lowest layer is very dependent on the underlying hardware. Yes, you can write one version for a 18F877 and another for a ATmega328P. But you will probably need a bit more experience to succeed.

And you will be limited to the lowest common denominator. Thus you will lose some good features of either controller.

Returning to your original post.

Have you successfully compiled and run that code on the Arduino platform?

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Ok yes as a beginner i believe i'm oversimplifying things... and yes i have found some really educative tutorials on how to use the arduino (Clawson suggested your website (workshop 9 / 10) and i found that very educative for me)..

I need actual results in order for me to use these results and then work on them. I figured using the arduino i could also then build on this to export my results wirelessly by connecting up an xbee module to the board.

But ure right.. i need to go back to basics and build the program and test it in parts carefully.

Thank you.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Arduino isn't even original. It seems to be a rehash and simplified version of 'wiring'.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

kscharf wrote:
Arduino isn't even original. It seems to be a rehash and simplified version of 'wiring'.
First page of the Arduino website:
Quote:
The microcontroller on the board is programmed using the Arduino programming language (based on Wiring)

Smiley

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Exactly.
And there are some that think wiring boards are better.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Back to:

kscharf wrote:
Arduino isn't even original. It seems to be a rehash and simplified version of 'wiring'.
Maybe I'm picking up subtext that wasn't intended, But wiring was started by Hernando Barragon while a student of Massimo Banzi (his thesis adviser). Banzi later and with other students came up with Arduino as a less expensive alternative (priced to compete with a pizza dinner). Wiring was built on Processing created by a couple of guys from MIT, one of whom was also a thesis adviser on the Wiring project. These guys all know each other and probably have all eaten pizza together and I doubt any of them would say 'isn't even original' or 'rehash and simplified' to describe the relation of with system.

Smiley

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

It's amazing how people can have such strong opinions about things they don't know anything about :)

thanks smiley

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

It is amazing that people who invented baby-talk programming for pothead have such strong opinions about people they don't know anything about.

Stealing Proteus doesn't make you an engineer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I think the two post above show the issue.
The two camps are so far apart ideologically that they can't even talk to each other.
It does seem a bit odd though that a principal in "Arduino" which is totally wrapped around the AVR,
hadn't ever posted to the AVR freaks site in the 6.5 years since joining the forum.

--- bill

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

clawson wrote:

(BTW I don't agree with Bill, AVR Forum *is* relevant to Arduino, in fact Arduino is one of the most signnificant thinks to happen to AVR in the last few years and I imagine it's probably attracted more new AVR users than the traditional routes have with their slow drip-drip-drip)

I didn't say AVR Freaks was not relevant to Arduino. I said I wasn't sure if AVR freaks was currently the appropriate place for "Arduino" support.

And I do agree agree that Arduino has been an enormous success in creating market interest in around AVR chips.

That said, I think Arduino users will typically be less technical and will often be asking Arduino specific questions related to the IDE, language, or Arduino library.
They will not be asking "AVR" type questions.
Since there is not currently a place for such Arduino specific discussions on AVR freaks and Arduino already provides Arduino specific forums setup for such discussions and support, I was questioning if AVR freaks was the appropriate place for such discussions.
(IMHO, I think AVR freaks is currently not a good place to go to get Arduino help/support)

So my view is that if AVR Freaks really wants to welcome Arduino disussions, then I think the most appropriate thing would be to have a dedicated "Arduino" forum, just like there are currently gcc, avr and AVRstudio forums.
That way all the Arduino specific discussions which may not involve anything to do with AVR, gcc, or AVRstudio have a real home.

Moderators could recognize Arduino specific content/questions and move them to the arduino forum the same as is done today with other topics.

--- bill

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

how to change the code in microPro C into arduino software..Please help me...here are my code::

 

here my email:  ravin_ath@yahoo.com

Attachment(s): 

Last Edited: Sun. Mar 8, 2015 - 08:26 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Why should we have all the fun?
Our job is to assist you, not to do your work.
At a guess, the code reads a RTC chip and displays the time on a lcd. I dare say someone has done that already and has posted the codes. Google the rtc chip name and arduino
Eg google ds1307 arduino
I'd expect you should find your answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I have no intention of reading a RTF file.     I suspect most other members would be the same.

 

I suggest that you post a TXT file or a PDF file.   Or even a ZIP file.

 

I have not heard of "microPro"

There are certainly Arduino examples for doing almost everything.   Google is your friend.

 

David.