PIC or AVR? noobie question(s)

Mike, I can see your really just dead set on being a jerk about this (great attitude toward someone coming here looking to for help/direction)

As I explained the Open Source/Saber Project is about putting the chip use toward a SPECIFIC TASK/PROJECT where were share things on that front.. like the PCB schematic for the LED driver portion that is there.. or the PCB layout for the other components we'll need once a 'program' has been written to do all the things we wanted it to do.. I doubt he would give away his HEX/SOURCE code for how he did the Orion Chip. Or have a parts list/Number for every component need to get the LED driver and other stuff

As for the sticker.. "I" put that on there to know what chip(s) are what.. (the stupidest things you focus on to dry about....really? I sticker on the chip to identify it in a bad og blanks or other flashed chips?) (sigh)

Googling the name produced what 'secret' wasnt mentioned for you?

To be specific its a PIC24FJ64GA02 I believe.

Noone asked if it was 'big overhead' for an embedded system.. its a good idea IMHO.. to let the end users get the most out of their chips..and makes it very versatile.

Thats NOT how the Arduino works..as far as a I can tell.. maybe you can show me how you claim it works the same? Dont you have to write some code..and flash it to the chip? (period) Then it does what its supposed to?

I dont mind changing my mind 'once I know more'.. thats why I came here.. to find out more.. but your attitude is just KAKA.. And you cant seem to focus enough to answer the questions..just BASH other things.
(should have known when you answered in this thread...from other threads saying oh well your 'grumpy' as an excuse to be a jerk in other posts.)

Your link to the SD card stuff...doesnt show or teach me anything, because Im in experienced...but it looks to be ANOTHER daughter board of some type.. hardly as 'tidy/easy' as the ReplicantFX where you just directly add wires to the SD pins on the chip.... or am I missing something?

so to summarize.. maybe you need a hug..cause your attitude sucks.

Instead of teaching or trying to educate..all you did was BASH form the jump.. and point the finger. (wow..cool) :cry:

AWOL-

I too thought the ReplicantFX was/is very clever..and agree the documentation wasnt the best... and Im saddened that there is no support/further development on it currently..

which is why I am here to look for an alternative.. but with people like "Grumpy_Mike".. Im doubting the Arduino is that answer unfortunately..

Its a shame.. I thought the code examples I saw were very straight forward..and easy to get a hold on too.

@xl97

I really think you're mis-reading Mike - he's one of the most helpful and knowledgable members here, and name-calling is really not the way to endear yourself to other members here either.

Someone has invested a lot of time in the replicant device, but it just isn't mainstream enough to attract the kind of community the Arduino has.

or am I missing something?

Quite a lot, it would seem.

Don't let Mike put you off Arduino. He means well and has known to be helpful if you don't mind dealing with someone that is so grumpy he uses it as a handle :wink:

Leaving aside the interpreter, I think the only functional thing that may be difficult for an arduino without external hardware is the wav file support. Does the orion board actually play 8 bit audio wav files or does it read 8 bit files but produce single bit output? I did not think the PIC24FJ64G had inbuilt ability for true analog.

I knwo he is a knowledagable memebers.. I have read some of his other posts... IMHO..doesnt excuse an attitude.. I have done NOTHING wrong, yet I all I got was attitude.. what for is what Im asking? Just a bunch of basjing another chip that isnt AVR/Arduino is what I gather.

I simple came to seek help/advice.. and used the ReplicantFX as a base of my needs and ease of learning curve...

and asked if the Arduino can fill that void.

nothing about stickers or Open Source (fakeness).. which "HE" mis-interpreted... the COMPLETE/OVERALL project was to be OPEN SOURCE..not the CHIP's SOURCE CODE..

I have been polite everytime..trying to get back on focus of the Arduino..but his focus was bashing the RFX project.

I know the RFX isnt 'mainstream'... I dont understand what that means? I was never trying to say it was BETTER.. Im looking for a replacement.

I stated my goals.. and the things Id like to do....and how the RFX does it..can the Arduino do the same? With as much ease?

Mike himself in other posts has been harsh in comments..and then just hey... thats why Im 'Grumpy' so I dont think its a surprise as to how he acts.. I just feel it was warrented when I came with legit questions..

Did I offend him or get 'snarky' in ANY post besides my last? He made assumptions and ran with them (like the sticker thing for example..or the Open Saber Project).. he didnt even bother to ask before bashing any/everything.

I mean is this really what the Arduino community is all about? I had no clue?

Before you start bashing me.. what is it Im missing? Arduino experience? Im here to get some.

No, really.
You've read the device ID off the replicant chip, and you're as capable as I am of going to the Microchip website and reading the device datasheet.
It told you that the device has 64K FLASH, 8K RAM, a faster A/D than the AVR, yadda yadda.

So what's your beef?

You're faced with a choice - a superior spec device with an obscure proprietary API and no support (it says as much in big red letters), OR a marginally lower specced device with open source standard 'C'/C++ and a great deal of (free) support.

I have been polite everytime..

On my planet, calling someone a "jerk" does not count as "polite".

mem-

thanks for the reply..

unfortunately.. I dont know enough to answer correctly..
All I can tell you is that it has 2 'channels' that can play 8-it .wav files..
1 at a time or layered/mixed together (playing both at same time)

I dont know if it can play the 8-bit files..or if it reads them and plays as single output..

I just know I turn on the PIN SND1 (or SND2) and use either PLAY1 or PLAY2 function to play the wav file form the SD card.. (sorry).. wish I knew more to answer better.

AWOL-

whats my beef? with what? "MIKE" asked for the CHIP type..so I told him.

There is no choice really.. Im looking for an alternative (like Ive stated previously).. the ReplicantFX project is dead for now.. until the owner comes back from Military duty.. but that doesnt mean I want to stop 'learning/playing/developing' my goals..

I was told the Arduino may be an alternative to look into.. so I came here seeking advice/answers on how things interface. Whats not to get about that? Im not sure how much more clear I can state things..

The things I asked about..that I cant seem to get straight answered with out attitude is:

can I use an Arduino starter kit to test code.and then just burn/flash what Ive done to a chip..and use it as the 'brain' in my overall/big picture layout/project?

it is similar to the RFX chip where you have dedicated PINS for ADC, SOUND, PWM? like I can just set those PINS (turn them on) and directly connect a device to those pins

LIKE can I just set PINS 0-2 as ADC pins..hook up an accelerometer to them and start tracking my X, Y & Z values?

Can I just turn a SOUND pin on..and hook up a speaker to it?...etc

or there is more hardware involved?

etc..

looking back what i got was a bunch of non-sense talking about what OPEN SOURCE MEANS...and PUTTING STICKERS on PIC CHIPS...

not alot of direct help/answers..

but as stated..thats just his nature...(as he himself admits in other posts)..

I also stated I was POLITE before my last post... JERK didnt come out until the end.. until he got way off topic..

I dont know..maybe were you come from Mikes 'reaction & attitude' is considered 'cool' & 'polite'.. but not me.

As for the (free) support.. like the help I got from Mike? ::slight_smile:

Im going to try and move forward..and see if I can get the help/advice that will clear things up..as maybe if I 'can' get the right answers.. the Arduino still may be a viable solution.

Thanks

Question you posed in original post:-

I was then told that I can just use the Arduino to 'test' my stuff out..and then burn the code I write to an Atmel chip.. true? (and if so..does it mater what one I use?)

answer I gave in first post:-

Yes you can program it up and move the chip to an other circuit board. However, you don't even have to be that complex just build it into your project and add a header and program it in situe.

Question you posed in post 14:-

The things I asked about..that I cant seem to get straight answered with out attitude is:
can I use an Arduino starter kit to test code.and then just burn/flash what Ive done to a chip..and use it as the 'brain' in my overall/big picture layout/project?

Who has the attitude? I just give as good as I get. :stuck_out_tongue:

lol...ok touche` :stuck_out_tongue:

I was being a little 'thick' at times..but hardly attitude (ever).. I have been very keen to thank you for your replies, until the end.

I did read that I can burn to the chip and place it into my over all/big scheme project.. I guess I was just trying to summarize what I came here seeking help/answers on.

but Im still unsure about all the sound, SD card, accelerometer stuff.

does this require extra hardware, daughter boards..etc

or is it similar to the ReplicantFX set-up where I just solder/connect (whatever) to the correct PIN?

and then just (in the code) write routine that constantly checks for these X, Y & Z values and if above a certain threshold..(for an accelerometer)

in the end the project would an on-board audio-amp..that leads to some solder pads.. can I just hook the amp up to the pin in the Arduino pin and be done with it? or more work involved? extra hardware?

there was mention of Interface Shields... but I dont think (or I missed it) anyone explained to me what they were? Just that they make things easier?

there was mention of Interface Shields... but I dont think (or I missed it) anyone explained to me what they were? Just that they make things easier?

Shields are boards that can be plugged on top of the Arduino PCB extending its capabilities. See: http://www.arduino.cc/en/Main/ArduinoShields

but Im still unsure about all the sound, SD card, accelerometer stuff.
does this require extra hardware, daughter boards..etc

I answered this in my post #10:
“Leaving aside the interpreter, I think the only functional thing that may be difficult for an arduino without external hardware is the wav file support.”

Mike was right about what Open Source is.

Having a lot of ideas, but understanding each of them only enough to have a short (and if you wish - heated) conversation over a glass of beer gets you in the parliament.

there are schematics in the open source section there..
he just chose to focus on the open source-ness of the RFX chip source code only. everything else has been open source..and talked about freely.. why it was Open SABER project, focusing on the WHOLE board, components of the project..not the chip itself.. which has its own sections to talk about.. :slight_smile:

ok shields are like daughter boards.. got ya. (wouldnt work for this project then really)

ok..so the .wav support might be ore diffcult or need other support..

this is a KEY part of this project that the Arduino board would be controlling.. audio & LED control)..

a KEY part of this project that the Arduino board would be controlling.. audio

It is possible to simulate PCM audio on arduino user a 16 bit timer and perhaps the orion board does something similar. This page shows one way to do this: Arduino Playground - PCMAudio

What is the minimum acceptable audio functionality you need?

if you really need stereo, that code needs two 16 bit timers so would require something like the ATmega1280 chip. This chip has similar onboard memory and peripherals to the PIC24Fj64G. (perhaps not useful for your app, the 1280 has many more I/O pins than the PIC) . This page has some more information on the official board, nothing stopping you building a smaller board customized for your app that runs the same software.

I think it 'has' stereo potential/option..but its not/wasnt needed..

however the 2 channel mono 8-bit was something id like to replicate.

for example.. always playing a sound while the board/project is on..and whenever a sensor is triggered..playing another 8-bit mono sound over it..

I will check out the link..and see if I can make some sense of it..

thanks.

update:

Im not 100% but it looks like they are taking the sound file (.wav or whatever) and running it through some sort of conversion that outputs the sound into text.. like an array of numbers to be used in playback?

Stereo and two channel mono would require similar resources. If you want two audio channels that can play wav data without external hardware, I would think you would need something with at least two 16 bit timers plus at least one 8 bit timer. That is if you use the approach in that playground article.

It looks to me like the ReplicantFX is some standard embedded processor chip that some one has dressed up to look like it is more than it is. I have not come across it before but it has all the hall marks of a bit of a scam, or just kids playing about.

I don't think it's a scam. Writing special purpose SW (or designing hardware) for a particular target market (in this case, prop builders) is a valid business model. And it looks like the ReplicantFX has some neat features for those purposes. All irrelevant, since it's no longer available (one advantage of being truly open source is that the community can pick up support for a project if the original owner is no longer able or interested. One of the disadvantages of open source is that the frequently doesn't happen, and you wind up with interesting projects that sound good but are essentially abandoned and "unfit for inexperienced users.")

In any case:

  1. Arduino is aimed at a somewhat lower level of functionality than the ReplicantFX chip. It won't do what you want without a pretty significant effort, and I'd say that the chips used in arduino are "not quite power enough" to make it easy. (See the Adafruit "wave shield" for something that is "almost" there.)
  2. The PIC24 (or perhaps a dsPIC, which is pin compatible) is somewhat more powerful than the ATmega CPU from arudino, but is even further away from making the high-level functionality you want easy-to-use.
  3. The interpreter for the FX Orion chip does not appear to be available in source form to allow you to copy that functionality onto bare PIC chips. That's too bad, but even if this source was available it probably wouldn't do "end users" much good without a significant support community.
  4. Fitting any device with the functionality on a board the size you are talking about is pretty significant effort; enough so that the $30-60 price range for arduino boards will start to seem pretty small. In some sense, the arduino is a "prototyping" platform: you figure out how to write your code and set up your hardware using a standard board and SW environment (arduino) and HW modules (shields), and then when you have things working to your satisfaction, you combine the hardware you actually need (schematics/etc being open source), strip off the portions you DON'T need, and lay it out on a board in the desired form factor, and give it a new name (SaberDuino! Or perhaps PropDuino.) Still a lot of hard work, but easier than starting all the way from scratch.

Its not a scam.. (thanks)..

And yes it is 'dead' until the developer comes back from deplyoment he told me.. (I talk to him on email and the phone sometimes)..

I do however have the HEX file he gave me to flash my own chips.. but Im not good at the hardware side of things to complete the Open Saber Project...

and without some bugs worked.. Im not sure I can use it as is...

I have a pretty good handle on the code/API (interpreter) that he created.. but if ther is/was a bug.. I cant fix it without source code (even if I knew how..lol).. I only have the HEX file.

its too bad it was a VERY versatile project.. not just for saber usage..

the API was very user friendly for the most part..

I am in a similar position to the OP - really new to electronics, want to build a lightsaber w/ light, flash on clash, constant & mometary sound. As I want to work up to more complex motorized props, I thought the arduino would be a good way to learn, using it as a design platform. Does this sound like a good approach? I am thinking of using cheap recording & playback DIPs instead of sound from an SD. Any thoughts, suggested tutorials would be appreciated. My only real experience is maintaining, moding Fender, Marshall tube amps, and 4 circuit-bending projects.

I think it's really easy to misinterpret how fundmentally simple the Arduino is at first glance.

If you keep telling yourself that it's really just a standard AVR Microcontroller (and at that point nearly identical to a PIC solution) and what's been done is these nice guys got together and made a "wrapper" around all the hard stuff... so people can create right away with the Arduino versus spending hours figuring out what you additionally need to buy (IE; HI-TECH PIC-C, CCS-C for PICS, Hardware programmers PICKIT2, etc) unless of course you are happy programming in PIC assembler.

I think one of the main goals of Arduino was... Buy it, start coding right away and trying stuff with no major expenses beyond the board itself.

..but still needs WAY other components to be added for the final goal

At a basic level, this is not totally true. You literally need no more support hardware than your average PIC solution. That is, if you don't mind giving up some convenience build that was into the Arduino. Some of these conveniences are wasted if you are making a final design.

You don't HAVE to have the USB interface... but it's nice. You could just as well have an FTDI/RS232 break out board handy that you attach as needed when you want to program.

You don't HAVE to have the large "board footprint" unless you plan to buy and attach "shields". You don't need onboard LEDS's unless you feel you need them. Personally, I prefer the Breadboard compatible "boarduino" for development.

So the most basic items in a final design would be Reset Circuit, and 16MHZ Crystal with 2 20pF caps. That's not any different than a PIC... and with some playing around and some external hardware, you could still do the Bootloader based serial programming as needed.

If you eventually tire of the Arduino solution, with no additional expense, you can migrate to the AVRGCC (real C/C++) solution... or as I like to call it... the AVRgeeks graduation present for persevering with the easy C-like syntax of Arduino.

I still have not picked up an "actual" Arduino at this point.. I use an Adafruit BoArduino- a minimal design that is set for plugging directly into a standard breadboard... the USB connectivity stays in the cable, further reducing cost. I think they go for around $15.. even cheaper is the Anarduino, which even skips the voltage regulator.. runs about $10.. and there's even some goof that just piggybacked the resonator and such directly on the back of the 328.. can't get more basic..

For me, the site and general feel of the project is what makes it superior to PIC. Hardware on both sides will be roughly equal, give or take- so it comes down to usability and support... and on that, Arduino is the winner, IMO. Even other "generic" AVR-related sites don't have the community that seems to have grown here.. some places can be a little unfriendly to new people and/or "silly" questions..