#avr | Logs for 2014-08-31

Back
[00:24:17] <FoxGT> Tom_itx, are you still selling your programmers?
[00:25:27] <FoxGT> I may need another one.
[00:27:41] * rue_shop3 watches smoke wift from the one he had
[00:28:07] <FoxGT> Mine caught fire.
[00:28:24] <FoxGT> Weird. Also damaged the usb port it was attached to on the pc.
[00:29:42] <FoxGT> J/k. :P It has worked flawlessly for me. I have a friend that wants to learn how to program them too after seeing me build a couple things. I'm just steering traffic Tom's way since he helped get me set up with mine.
[00:32:13] <tpw_rules> well i blew all the fuses by accident being stupid with avrdude so regular programming doens't work (atmega168v)
[00:32:41] <tpw_rules> and now it is such that if the chip is powered i apply 12v to /reset, ready goes high
[00:33:02] <tpw_rules> it doesn't unlatch when i remove 12v either without power cycling, so i think there's some internal fault rather than it entering into program mode
[00:33:06] <FoxGT> Is winavr more risky to use than studio?
[00:33:18] <tpw_rules> define "risky"
[00:33:23] <FoxGT> I've only been using studio, but I dislike how demanding it is.
[00:33:24] <tpw_rules> this operation wasn't avrdude's fault at all
[00:33:44] <FoxGT> comparing setup & debugging between the two.
[00:33:56] <tpw_rules> oh i have no idea
[00:33:57] <FoxGT> Am I more likely to mess my uc up?
[00:34:17] <tpw_rules> the way to mess it up properly is to burn the fuses by accident
[00:34:26] <tpw_rules> i don't know how to do it with either so i can't give you any input. i'm new as of like thursday
[00:35:36] <tpw_rules> i know just enough to start costing myself money, one might say
[00:36:30] <FoxGT> You're not far behind me then!
[00:37:08] <FoxGT> I have only built one thing that was useful, fancy brake lights for my motorcycle.
[00:37:19] <FoxGT> You may actually be ahead of me.
[00:37:20] <tpw_rules> i have plenty of experience with other micros
[00:37:28] <tpw_rules> but i think you have me beat on avr
[00:37:32] <FoxGT> Oh, then yeah, you're way ahead.
[00:37:42] <tpw_rules> i just know how to ruin one
[00:37:53] <tpw_rules> i've never made one do something directly useful before
[00:37:56] <FoxGT> I just learned what decoupling capacitors were two months ago.
[00:38:12] <tpw_rules> baby steps
[00:38:24] <tpw_rules> i literally blew up three transistors today trying to figure out how they worked
[00:38:27] <rue_shop3> dont turn the reset into an io pin, disable jtag, and dont set it to external oscillator (use external crystal if you want, not external oscillator)
[00:38:40] <tpw_rules> ^^^^^
[00:38:42] <rue_shop3> did you read the transistor howto I posted?
[00:38:51] <tpw_rules> yeah, i got it all figured out
[00:38:58] <rue_shop3> was it clear?
[00:39:03] <FoxGT> Lol.
[00:39:17] <rue_shop3> its an odd style
[00:39:21] <FoxGT> I fried one of my pins by sending 12v to an input a couple weeks ago.
[00:39:35] <FoxGT> rue_house, what is this transistor how to??
[00:39:36] <rue_shop3> http://ruemohr.org/~ircjunk/tutorials/elex/qwhathow.html
[00:39:40] <tpw_rules> i just was trying to do it with pnp transistors, which seem to have the property of needing 11.6v gate voltage to turn off
[00:39:46] <rue_shop3> ^^ that fixed you all up tho?
[00:40:08] <tpw_rules> npn transistors are far better
[00:40:42] <tpw_rules> but once i stopped being cheap and bought some npns it worked in like 30 seconids
[00:41:30] <tpw_rules> but, of course, i wasn't not cheap long enough to get a working avr or a fuse doctor
[00:42:10] <rue_shop3> but you read that transistor course, yes?
[00:42:20] <rue_shop3> so now you know why the pnp wouldn't turn off?
[00:42:31] <tpw_rules> because i didn't have a high enough voltage to it?
[00:42:46] <rue_shop3> maybe read it!
[00:42:55] <tpw_rules> i can't now, i'm too tired
[00:43:56] <tpw_rules> it doesn't explain pnp much. my micro's high impedance had too much leakage to turn it off
[00:43:57] <rue_shop3> READ IT its an easy read
[00:44:11] <tpw_rules> i promise i will tomorrow
[00:44:18] <tpw_rules> i'm going to bed in 12 seconds
[00:44:52] <tpw_rules> good night
[00:45:03] <FoxGT> rue, I have a slight issue you may be able to help with.
[01:34:55] <rue_shop3> try me
[02:18:48] <megal0maniac> rue_shop3: Ta :) A good read. I did this stuff last year but I was unsure of myself
[02:32:27] <rue_shop3> I think that process worked well for making a howto
[04:57:07] <Trieste> hi, I have an atmega328p that *might* be dead - http://pastebin.mozilla.org/6246526
[04:57:42] <Trieste> is there anything else besides the avrdude test that I can do, or should I start arranging a funeral?
[05:07:12] <Lambda_Auriga_> Trieste, did you do something prior to make it dead?
[05:07:29] <Trieste> Lambda_Auriga_: not aware of any such thing
[05:07:33] <Lambda_Auriga_> like, too much current draw through a pin or too high voltage feed in somewhere or screw up the fuses?
[05:07:55] <Trieste> It's from a broken Arduino, which a friend of mine did indeed kill
[05:08:09] <Trieste> and this is supposed to be the new atmega328p as a replacement
[05:09:01] <Lambda_Auriga_> my furst suggestion is to use something not based on usbasp as a programmer...it seems that most programmer problems come from people using usbasp type programmers...might be coincidence or might be just most newbies get the cheapest programmer out there or might be the usbasp is crap(which is my experience)
[05:09:55] <Lambda_Auriga_> second suggestion is to provide the chip with a 1MHz clock pulse stream and see if the fuses are just messed up.
[05:10:09] <Lambda_Auriga_> first first though would be to check wiring.
[05:10:42] <Trieste> the programmer is crap, but works - I tested on an AVR that I know is functional
[05:10:58] <Trieste> wiring is also okay, I double and triple checked
[05:11:09] <Trieste> and how would I go about the second suggestion?
[05:13:46] <DigiGram> Trieste do you supply the crystal or use onboard?
[05:14:19] <Lambda_Auriga_> get or build a pulse generator....another avr putting out a constant stream of pulses works well and it goes into the X1 pin.
[05:14:35] <Trieste> DigiGram: right, onboard oscillator...
[05:15:02] <DigiGram> okay, are you sure the fuse for onboard is set?
[05:15:06] <Lambda_Auriga_> if for some reason the fuses have been horked then the onchip oscillator might be disabled.
[05:15:33] <Trieste> DigiGram: no, I just realized
[05:15:48] <DigiGram> I once had a "dead" 328p, and it turned out I forked up with the osc fuse, so once I applied a 8MHz external, I got it working again
[05:15:49] <Lambda_Auriga_> depending on how it is set, usually an external clock source might work better than a crystal.
[05:15:54] <Trieste> okay, so 1MHz pulses to X1, and then? try reading the fuses again with the programmer?
[05:16:23] <Lambda_Auriga_> you could try putting a crystal on it too...that would be easier if you have one handy.
[05:16:33] <Trieste> I don't, unfortunately
[05:17:34] <DigiGram> doesn't your programmer have a mode to use external clock (internal to programmer)
[05:18:21] <Lambda_Auriga_> DigiGram, not all usbasp programmers have that...in fact, most of the cheapy ones don't.
[05:19:20] <DigiGram> I know Lambda_Auriga_, my cheapy self-build doesn't either, but was worth to ask
[05:19:43] <Lambda_Auriga_> first time I screwed up clock fuses on an avr I used a 555 timer to supply the clock...worked well.
[05:20:04] <DigiGram> I was thinking of a 555 now as well
[05:20:38] <Lambda_Auriga_> still have that circuit on my bench and used it several times.
[05:20:52] <Lambda_Auriga_> although, these days I just drop the chip into the fuse doctor and fix it.
[05:24:37] <Lambda_Auriga_> speaking of which, I really should make the attiny version of the fuse doctor one of these days.
[05:28:00] <Lambda_Auriga_> hmm....time to upgrade instead....this one I found supports tiny and mega chips.
[05:28:09] <Lambda_Auriga_> http://mdiy.pl/atmega-fusebit-doctor-hvpp/?lang=en
[05:30:02] <DigiGram> Lambda_Auriga_ that might be a good next build for me too
[05:31:48] <Lambda_Auriga_> for mine I modified the power supply and have a 7805 and 7812 onboard...I feed it 15VDC to the 7812 then the 7805 pulls off the 12V output from that.
[05:31:58] <Lambda_Auriga_> so the 7805 isn't having to drop from 15V down.
[05:32:01] <Lambda_Auriga_> works well.
[05:32:36] <DigiGram> why? To minimize the heat loss at the 7805?
[05:32:45] <Lambda_Auriga_> yeah.
[05:33:08] <DigiGram> so just heat, not really concerned about power losses?
[05:33:17] * twnqx doesn't get people who just use switchers
[05:33:24] <twnqx> one chip, one coil, two caps
[05:33:28] <Lambda_Auriga_> yeah, not really concerned about power.
[05:33:45] <Lambda_Auriga_> twnqx, because I have piles of 78xx chips here...literally hundreds of them.
[05:34:10] <twnqx> still no good reason to turn two thirds of input power into heat
[05:34:23] <DigiGram> yeah and switchers are still kinda expensive? Or is there a nice on available as cheap as 78xx?
[05:34:26] <Lambda_Auriga_> if I'm running from battery then I use a switchmode supply.
[05:35:15] <Lambda_Auriga_> DigiGram, there are some switcher chips that are super cheap.
[05:35:50] <twnqx> and super simple to use
[05:37:31] <Lambda_Auriga_> what chip do you recommend twnqx ?
[05:38:56] <twnqx> depends, i like the TI simpleswitchers
[05:40:12] <twnqx> e.g. tps62203
[05:41:45] <Lambda_Auriga_> http://www.gravitech.us/35v1aswvore.html these make a nice drop-in replacement for 7805.
[05:41:54] <Lambda_Auriga_> bit pricier though.
[05:44:51] <Lambda_Auriga_> I like the lm7805 regulator chip as it comes in a dip package...does need an external diode though as well as the caps and coil.
[05:45:33] <DigiGram> I might just sample the tps62203, looks good for battery projects
[05:46:10] <Lambda_Auriga_> should be fine...only drawback for me is no through hole package...all surface mount.
[05:46:48] <DigiGram> yeah that is stupid, but it's a small price to pay for efficiency
[05:47:31] <Lambda_Auriga_> http://www.romanblack.com/smps/smps.htm here is one that uses transistors instead of a chip.
[05:50:54] <Lambda_Auriga_> grr...just realized what I said up there...not the lm7805 regulator chip but the lm2574 regulator chip.
[05:50:55] <Lambda_Auriga_> sheesh.
[05:51:02] <Lambda_Auriga_> have 7805 on the brain this morning.
[05:54:10] <DigiGram> does these switching regulators have the same issue of requiring atleast 1-1.5V more that what they need to supply?
[05:57:20] <specing> no
[05:57:30] <specing> they can even up convert
[05:57:39] <Lambda_Auriga_> oooooo..LM78S40...universal regulator..boost, buck, etc.
[05:57:52] <Lambda_Auriga_> specing, only boost/buck converters will up convert I thought.
[05:58:11] <specing> Lambda_Auriga_: Im sure there are obscure types that will do so too
[05:58:14] <Lambda_Auriga_> lm2574 is only a buck converter and won't boost..
[05:58:15] <DigiGram> great stuff! I might just try the MP2105 (only because its easy to get my hands on)
[05:59:25] <specing> Lambda_Auriga_: the rohs ones cost twice as much as non rohs ones lol
[05:59:35] <Lambda_Auriga_> specing, yup.
[05:59:44] <specing> in other words, its pretty cheap for pre-made stuff
[05:59:48] <twnqx> Lambda_Auriga_, not quite "only" - i am a fan of sepic :P
[06:00:00] <specing> sadly only 1.5A output :/
[06:01:19] <DigiGram> well guys, thank you for teaching me something cool today! some sort of switching supply will make it's way into my solar project
[06:02:34] <specing> Ooooh there is a 5V 5A design in the doc
[06:02:42] <specing> wonder where that 1.5A limit applies
[06:02:54] <twnqx> likely internal fet
[06:02:54] <Lambda_Auriga_> specing, for which chip?
[06:03:04] <specing> Lambda_Auriga_: the LM one
[06:03:10] <specing> 78S40
[06:03:25] <Lambda_Auriga_> aahh...don't they use an external fet for that 5A circuit?
[06:04:15] <Lambda_Auriga_> hmmm...bjt transistor..
[06:04:17] <Lambda_Auriga_> odd.
[06:05:25] <specing> ouch 70-80% efficiency
[06:05:28] <specing> not good
[06:06:17] <Lambda_Auriga_> dangit..forgot my ti.com password.
[06:07:02] <specing> "I need a chip that can take in 220V and turn it into rainbows!"
[06:07:08] <specing> NOW
[06:07:14] <DigiGram> specing I have one
[06:07:19] <Lambda_Auriga_> I have a bunch that can take in 220V and turn it into magic blue smoke.
[06:07:19] <DigiGram> if you like blue rainbows
[06:07:34] <specing> Lambda_Auriga_: lel
[06:08:41] <specing> the good thing is that 220V is AC so you can throw a transformer in there
[06:08:51] <specing> so thats easy to bring down to 20V or so
[06:09:27] <specing> mouser says that out of 10000 chips only 3 take 220V
[06:10:06] <Lambda_Auriga_> any chip will take 220V
[06:10:11] <Lambda_Auriga_> not many will survive it long
[06:10:14] <Lambda_Auriga_> but they will take it.
[06:13:01] <specing> Any good undergrad books on electronics? I need to study this...
[06:13:33] <specing> All I can do is connect stuff based on existing schematics and hope it doesen't explode :/
[06:14:44] <twnqx> Oo
[06:14:44] <Lambda_Auriga_> order placed for some lm78s40, lm7672n-adjustable and lm7672-5v
[06:15:02] <Lambda_Auriga_> specing, so start connecting stuff that isn't in the schematic and see what happens!
[06:15:13] <Lambda_Auriga_> that's how I started....38ish years ago.
[06:15:49] <Lambda_Auriga_> I suggest starting with Getting Started in Electronics then move to the mini-notebooks and up from there...Forrest M. Mims III is an awesome teacher.
[06:28:35] <megal0maniac> Hmmm... this isn't working
[06:29:35] <specing> 128 pages seems kinda low
[06:31:13] <Lambda_Auriga_> specing, lots of info in 128 pages....it's a beginners electronics book...starts with this is a wire this is a battery and works up from there.
[06:31:55] <specing> also "mini-notebooks"?
[06:33:02] <Lambda_Auriga_> engineers mini-notebooks..
[06:33:09] <Lambda_Auriga_> originally all hand drawn and lettered.
[06:33:20] <Lambda_Auriga_> opamps and transistors and stuff.
[06:33:29] <Lambda_Auriga_> were put out by radio shack back in the day.
[06:33:37] <Lambda_Auriga_> today I think he sells them directly.
[06:34:32] <Lambda_Auriga_> is a bit below undergrad level though.
[06:34:41] <Lambda_Auriga_> is very beginner
[06:36:01] <megal0maniac> I'm getting 1.5V at the base. The pull-up is not working very well :/
[06:37:26] <Lambda_Auriga_> megal0maniac, what exactly are you trying to accomplish?
[06:40:10] <specing> Lambda_Auriga_: maybe I should just signup on coursera hehe
[06:40:19] <megal0maniac> Sorry, I'm kind of thinking aloud. I need to control a pin with a microcontroller. Open collector, so either pulled up or grounded. I also need an LED to show the status, but I only have 1 IO. Putting the LED in-line means it will never reach 0V. I'm using a transistor to drive the LED, but it seems like the transistor is loading the IO too much so it only rises to like 1.7V
[06:40:48] <Lambda_Auriga_> megal0maniac, you running at 3.3V or 5V?
[06:40:52] <megal0maniac> 5V
[06:41:22] <megal0maniac> Although the IO is TTL, so my range is <0.8V or >2.0V
[06:42:15] <Lambda_Auriga_> can't just hook LED to gnd through resistor and tie it to the i/o pin at the same time as what you are driving?
[06:42:37] <Lambda_Auriga_> this is an output from the microcontroller, yes? or is it input/output?
[06:44:21] <megal0maniac> Well from what I understand, the voltage drop over the LED prevents the IO from ever reaching 0V, so that doesn't work. I'm switching between input and output. i.e High Z and driven low
[06:44:46] <Lambda_Auriga_> aahh...does make things more difficult then.
[06:45:24] <Lambda_Auriga_> I would use a small fet to drive the LED then and tie the gate to the pin through a resistor...shouldn't get too much current flow through that throwing things off.
[06:45:36] <megal0maniac> That's why I'm using a transistor, but the base seems to load too much. Maybe a smaller resistor.
[06:46:06] <megal0maniac> How about just driving the pin high/low directly? Then 1K into the transistor to drive the LED
[06:46:51] <Lambda_Auriga_> yeah....I prefer fets to bjts myself....but..dunno which you are using.
[06:47:01] <Lambda_Auriga_> http://www.angelfire.com/oh3/ebjoew/SamePinIO.html
[06:47:26] <Lambda_Auriga_> I know...it's a pic page...but..
[06:47:35] <megal0maniac> Just a 2n2222. Main point, though, is that I guess I don't necessarily have to do this open drain thing. The microcontroller can have full control, so I can just drive it
[06:54:04] <mux_> hey abcminiuser, how much fun have you had with xmega mass storage :P
[06:54:25] <abcminiuser> None yet, just got my email inbox from 48 to 18
[06:54:31] <abcminiuser> I need to find more time for emails :(
[06:54:40] <abcminiuser> Got in some old patches and old projects I had half-finished
[06:54:41] <mux_> do you know CGP Grey?
[06:54:54] <abcminiuser> Err, should I?
[06:54:58] <mux_> nevermind then
[06:55:04] <mux_> he has a very good system for dealing with e-mails
[06:55:14] <Lambda_Auriga_> repeating delete button?
[06:55:19] <mux_> more or less :P
[06:55:24] <mux_> highly recommended
[06:55:48] <abcminiuser> Heh
[06:55:53] <megal0maniac> In other news, laptop power supply is not a good fit for a class D amp IC. Thought the noise wouldn't matter as much, but it does :/
[06:56:04] <abcminiuser> But I'll try to get to it this week, would be nice to have all the bootloaders finally XMEGA ported
[06:56:09] <Lambda_Auriga_> unfortunately, some of us need to respond to those emails for workly porpoises.
[06:57:42] <specing> megal0maniac: needs more capacitors
[06:57:45] <mux_> abcminiuser: I'm not pressuring or anything, just happy to finally have a proper xmega usb mass storage solution
[06:58:07] <mux_> megal0maniac: you should always do very heavy local filtering for audio applications
[06:58:08] <abcminiuser> Yeah you and everyone else, I've had people hounding me for ages to get that working
[06:58:16] <abcminiuser> Expect great adulation when it's comitted
[06:58:58] <mux_> it's still got a few minor issues that people will keep hounding you for probably
[06:59:31] <mux_> 2 issues I can see coming up are: auto-reboot on completion and reflashing the boot section
[07:00:22] <mux_> I'm sure you are aware, but xmega is very different to avr8 in how it handles resets, it has a proper reset source table
[07:00:24] <abcminiuser> Reflashing boot section? Bootloaders shouldn't update themselves
[07:00:28] <mux_> which I used in the code I sent you
[07:01:24] <mux_> well, if you're not going to include bootloader self-reprogram then that's one less issue to worry about in the future :)
[07:01:35] <mux_> I'm going to implement it at some point in the next ~4 months
[07:01:48] <abcminiuser> Hell no, bootloaders horking themselves is never a fun thing
[07:02:39] <Lambda_Auriga_> gotta love the word "hork" and all derivatives thereof.
[07:04:16] <abcminiuser> Yay someone appreciates my lingo
[07:04:28] <abcminiuser> Not sure where I picked up half of it from, but hey keeps life interesting
[07:04:50] <mux_> abcminiuser: are you interested in getting one of my boards in the near future? do you have a use for a usb current sensor with lots of resolution? I'm probably also sending one to dave from EEVBlog, thought you might appreciate one as well
[07:05:20] <abcminiuser> "No, I don't want free stuff", said literally no one ever
[07:05:27] <mux_> :D
[07:05:45] <abcminiuser> But actually yes, I'd love one of those for work, as well as for some home experiments
[07:05:56] <abcminiuser> Also blog fuel
[07:06:32] <mux_> I have only 9 assembled atm and it's double sided with QFNs on both sides, so I'll probably wait for a zero series from an assembler before I'm sending samples out
[07:07:20] <mux_> so... october-ish probably
[07:07:31] <abcminiuser> No worries, no rush
[07:08:12] <mux_> alright, back to working on the interface now
[07:08:34] <mux_> it's in html5/javascript... fun times with 250kB/s of measurements coming in
[07:24:29] <andi__> hi guys. we try to port IAR code to AVRGCC. when we tried to change the line "olatile __io PMSMflags_t fastFlags @0x0a;" to "#define fastFlags (*(volatile PMSMflags_t*)_SFR_MEM_ADDR(GPIOR0));" and try to compile it, we get the failure message "error: expected expression before '=' token" for different lines which points to "fastFlags"
[07:24:35] <andi__> any ideas how to fix it?
[07:25:43] <andi__> mux_: do you have an idea?
[07:26:03] <mux_> ohai
[07:26:47] <mux_> you should remove the semicolon on the end of that define
[07:27:04] <mux_> (if that fixes it, I'm going to pull an IT crowd)
[07:27:19] <andi__> if I do that, I get "internal compiler error"
[07:27:28] <Roter> Hey guys! Im using linux and a text editor, i used to have a premade, simple makefile and it worked, its here: http://pastebin.com/PfVZVBvU . The problem is i dont know how to make it run multiple files. I will start learning about makefiles a little later, so i just wanted to know if there is an easy fix.
[07:28:17] <abcminiuser> andi__, can you post the full relevant code sample to pastebin?
[07:28:55] <mux_> I had an internal compiler error before with this shit... as dean said: if you post the full relevant code we might get an idea what's going wrong
[07:29:11] <abcminiuser> Wait GPIOR0 is already correctly defined inside avr-libc to be a volatile uint8_t register
[07:29:12] <andi__> oky, give me a minute
[07:29:32] <andi__> should be defined
[07:29:45] <abcminiuser> So just #define fastFlags (*(volatile PMSMflags_t*)&GPIOR0) should work
[07:31:15] <mux_> if that doesnt work, inline asm is probably the fastest surefire solution to your problem...
[07:31:37] <abcminiuser> Compiles fine here
[07:32:03] <andi__> http://paste.ubuntu.com/8196465/
[07:32:38] <mux_> we also need to see the code where this is actually used
[07:34:00] <andi__> here is the declaration: http://paste.ubuntu.com/8196493/
[07:36:14] <andi__> here it is used in the interrupt routine: http://paste.ubuntu.com/8196506/
[07:38:13] <mux_> is this the only time it's used?
[07:38:37] <mux_> because if this is the only PMSMflags_t type, I really don't understand why it's being mapped to GPIOR0
[07:38:43] <mux_> this can just be left to the compiler
[07:39:00] <mux_> and it's probably going to interfere big time with the ISR boilerplate code
[07:40:10] <andi__> boilerplate code??
[07:40:41] <andi__> it is not the only time it is used
[07:40:54] <andi__> I can paste the complete code if u like
[07:41:14] <mux_> when you compile an ISR from C, it's going to insert a little bit of code before and after your ISR to make sure the Z register and, for instance, GPIOR0 are stored to somewhere else to make sure the interrupt doesn't change intermediate values used by the main program
[07:42:12] <mux_> that's a standard bit of code
[07:42:36] <mux_> standard code, or standard texts like disclaimers, are sometimes called boilerplate (in case English is not your first language)
[07:43:10] <andi__> a, ok, thank you very much!
[07:43:16] <andi__> good explanation
[07:43:49] <mux_> I'm a bit busy right now so I don't really feel like looking through all your code
[07:44:05] <andi__> I understand
[07:44:12] <mux_> but if it seems like you don't necessarily need to map that struct to a low-address register, I'd recommend just dropping that type entirely
[07:44:38] <mux_> bit fields are a big problem to use in C as it stands anyway, I'd imagine this is where IAR and GCC are very different
[07:45:21] <mux_> oh now I remember, I got the same error when I tried to use bit fields for a recent project
[07:45:52] <mux_> I dropped the bit field struct and just went with bit masks instead
[07:46:06] <andi__> the problem is, if it is not nececessarry i want to know anyway how to do it for the next time i need id
[07:46:24] <mux_> I don't think I bothered to investigate how to fix it, so can't help you there
[07:46:28] <andi__> but did you map it to a register?
[07:46:43] <mux_> 'internal compiler error' is very vague, it probably doesn't even give you a line number
[07:46:47] <mux_> no, I didn't
[07:47:08] <andi__> oky
[07:47:23] <andi__> I will try without mapping it to tha specific adress
[07:47:25] <andi__> thank you
[07:47:54] <mux_> maybe someone else may be able to help you on avrfreaks if you really want to know the answer
[07:48:29] <andi__> thank you very much for yout help
[07:48:45] <andi__> I will try to get it working :-)
[08:26:53] <Roter> Hey guys! Im using linux and a text editor, i used to have a premade, simple makefile and it worked, its here: http://pastebin.com/PfVZVBvU . The problem is i dont know how to make it run multiple files. I will start learning about makefiles a little later, so i just wanted to know if there is an easy fix.
[08:27:09] <Roter> soory for spamming, last time before i go
[08:43:33] <brabo> Roter: i'm also still learning about makefiles, but i found the example makefile included with Make: AVR Programming to be very very usefull
[08:44:33] <brabo> Roter: https://github.com/hexagon5un/AVR-Programming/blob/master/Chapter02_Programming-AVRs/blinkLED/Makefile
[08:45:10] <brabo> you just change the mcu etc and then you can add the other .c files to LOCAL_SOURCE =
[08:46:45] <brabo> if you need a different flag for the mcu in avr-gcc and avrdude, i just added DUDEMCU = m8 and used $(DUDEMCU) in the avrdude lines
[08:52:59] <Roter> Alright, thanks! Looking into the makefile right now!
[08:55:48] <brabo> Roter: sure, and if you have problems, hilight me, i've been using this makefile for a little bit already and i think i get the gist of it ;)
[08:56:07] <brabo> and perhaps someone else has even beter stuff to share hehe
[08:58:37] <Roter> :)
[08:59:47] <brabo> Roter: if you haven't read it yet, the book itself is worth a read
[08:59:56] <brabo> Make: AVR Programming
[09:21:56] <Roter> Well i was following this persons tutorials: https://newbiehack.com/MicrocontrollerWritingthefirstprogramandtransfer.aspx
[09:22:34] <Roter> And its pretty good, tho it has its flaws
[09:33:22] <Trieste> http://pastebin.mozilla.org/6246526 - is my avr dead? How can I check? I just realized I actually did try programming it while in the arduino board, so unless the on-board crystal is fried, it should have worked
[09:34:38] <tpw_rules> Trieste: it's possible you enabled oscillator mode. a crystal won't work with that because the avr won't start the crystal oscillating
[09:35:03] <tpw_rules> i'm currently in much the same boat. how did he program it the first time? was it simply with the arduino bootloader?
[09:35:04] <Trieste> tpw_rules: I did try programming it just on a breadboard too
[09:35:18] <Trieste> I have no idea about the state of this atmega
[09:35:19] <tpw_rules> in that case you'll need another chip to supply an external clock
[09:35:42] <Trieste> is the on-board crystal not enough?
[09:35:46] <tpw_rules> no
[09:35:50] <Trieste> oh
[09:35:52] <tpw_rules> it has crystal mode and oscillator mode
[09:36:06] <tpw_rules> in crystal mode, it will generate voltage to start an external crystal going
[09:36:16] <tpw_rules> in oscillator mode, it just uses a square wave input to X1
[09:36:32] <Trieste> I see, I thought "oscillator mode" meant "internal oscillator mode"
[09:36:33] <tpw_rules> so you need to do something like program an other arduino to generate a mhz or so
[09:36:37] <tpw_rules> there is that as well
[09:36:42] <Tom_itx> hehe
[09:36:47] <tpw_rules> internal and external oscillator
[09:36:58] <Tom_itx> my programmer puts out a recovery clock signal for just such occasions
[09:37:07] <tpw_rules> ah, phancy
[09:37:08] <tpw_rules> wire it up then
[09:37:14] <Trieste> I know, I just didn't know about the ext. oscillator option
[09:37:20] <Trieste> alright then, will do, thanks!
[09:37:25] <tpw_rules> good luck
[09:38:20] <tpw_rules> i managed to program my avr to need an external oscillator, to disable serial programming, and to disable /reset
[09:39:15] <Trieste> heh.
[09:39:25] <Trieste> I'd probably just throw the avr out at that point
[09:39:26] <tpw_rules> i'm trying to wire up a high voltage programmer, but i think i fried the chip
[09:39:28] <Tom_itx> that requires HVPP to recover
[09:39:33] <tpw_rules> well i'm viewing it as a learning experience
[09:39:39] <Tom_itx> like a dragon
[09:40:03] <tpw_rules> oh my fuck that's expensive
[09:40:07] <Tom_itx> and lots of jumper wires
[09:40:22] <Tom_itx> it's your cheapest off the shelf option sir
[09:40:24] <tpw_rules> i have all the jumper wires and a suitable micro and etc but it just isn't behaving like i expect
[09:41:45] <tpw_rules> http://i.imgur.com/iADKzz1.jpg :D
[09:42:26] <Tom_itx> that looks more like open heart surgery
[09:43:00] <tpw_rules> unfortunately, i think the defribrillator as it were blew up the patient's brain
[09:43:00] <Getty> LOL....... there is a reason why real electronic people dont use bread boards ;)
[09:43:12] <tpw_rules> well what else do i do
[09:43:15] <Tom_itx> btw the recovery clock needs to be 4x the spi rate
[09:43:27] <tpw_rules> oh hello Tom_itx you're the person i wanted to talk to last night
[09:43:27] <Tom_itx> maybe not on HVPP but isp for sure
[09:43:32] <Tom_itx> no i'm not!
[09:43:44] <Roter> This is strange, i used this makefile: https://raw.githubusercontent.com/hexagon5un/AVR-Programming/master/Chapter02_Programming-AVRs/blinkLED/Makefile , the one brabo suggested. It doesnt work, says: no rule to make target code.elf, needed by code.hex. End
[09:43:46] <tpw_rules> somebody else threw you under the bus
[09:43:47] <Getty> yeah well, while you learn you dont have many options, my dad soils a small board every time for his experiments
[09:43:59] <Tom_itx> yeah well i'll get him later
[09:44:17] <Roter> the only thing i changed was the mcu to atmega32 and blinkLED.c to code.c
[09:44:21] <tpw_rules> so ready goes high whenver 12v is applied
[09:44:34] <Tom_itx> on reset yes
[09:44:43] <Tom_itx> now you know all i do about HVPP
[09:44:44] <tpw_rules> if i take it away and put it back without powering down the chip, it comes back on
[09:44:45] <brabo> Roter: pastebin?
[09:44:47] <tpw_rules> oh
[09:45:17] <tpw_rules> the datatsheet sounds like it must be applied within us of the chip starting and will turn off ready permanently when it is removed
[09:45:25] <Tom_itx> i did HVPP to _one_ chip _one_ time
[09:45:33] <Tom_itx> does that somehow make me an expert?
[09:45:44] <tpw_rules> [22:49] <tpw_rules> anybody have experience with high voltage programming? trying to build my own and i think i blew up my chip
[09:45:44] <tpw_rules> [22:55] <rue_shop3> Tom_itx, has lots
[09:45:45] <tpw_rules> go blame him
[09:45:52] <Tom_itx> i will
[09:46:05] * tpw_rules guess he is on his own
[09:46:12] * Tom_itx glares at rue_shop3
[09:49:03] <tonsofpcs> Hi all. About to dive head first into ASM for the Atmega328 :)
[09:49:19] <tonsofpcs> is Atmel Studio a good tool for ASM?
[09:50:14] <krysmin> I think yes
[09:51:31] <Lambda_Auriga_> works as well as anything.
[09:52:21] <krysmin> Is good idea to write larger project on asm?
[09:53:13] <Lambda_Auriga_> sure, why not?
[09:53:49] <krysmin> Some people say better in c
[09:54:30] <Lambda_Auriga_> all depends on what you are comfortable working in.
[09:55:10] <tonsofpcs> krysmin: I'm using ASM because timing matters *a lot* for this project
[09:55:28] <Lambda_Auriga_> I've seen some massive projects written in assembly that work great....including but not limited to GPS satellite systems, nuclear weapons detonation control systems, and ballistic gun control systems.
[09:55:41] <tonsofpcs> the one thing I'm still struggling with is to figure out how to even out the time when a BREQ is followed without always padding it
[09:55:52] <tonsofpcs> I'm sure I'll find that solution though
[09:56:55] <krysmin> What is different in atmega88 and atmega8?
[09:57:16] <twnqx> an 8!
[09:57:33] <tonsofpcs> the URL of the spec sheet.
[09:57:41] <tonsofpcs> ;)
[09:57:43] <Lambda_Auriga_> atmega88 is an updated version of the atmega8...has more toys built in.
[09:57:57] <Lambda_Auriga_> like pin change interrupts on all i/o pins.
[09:58:34] <Lambda_Auriga_> atmega8 only runs at 16MHz...atmega88 runs at 20MHz..
[09:59:08] <Lambda_Auriga_> atmega88 has one more instruction than atmega8
[09:59:19] <krysmin> More toys? Like?
[09:59:34] <Lambda_Auriga_> atmega88 has qtouch hardware where atmega8 does not.
[10:00:10] <Lambda_Auriga_> http://www.atmel.com/Images/2545S.pdf atmega88 summary
[10:00:23] <Lambda_Auriga_> http://www.atmel.com/Images/Atmel-2486-8-bit-AVR-microcontroller-ATmega8_L_summary.pdf atmega8 summary
[10:00:25] <Lambda_Auriga_> compare the two.
[10:00:58] <Lambda_Auriga_> atmega8 can only run down to 2.7V where the atmega88 can run down to 1.8V
[10:02:57] <Lambda_Auriga_> beyond those, they are basically the same chip.
[10:29:54] <tonsofpcs> ok, so looking at the spec sheet... what is the difference between the ATmega328 and ATmega328P (presuming I'm not looking at the -xN variants of the 328P that are rated to 105 C)?
[10:30:47] <Trieste> I wonder what kind of application requires withstanding temperatures of up to 105°
[10:31:01] <tonsofpcs> oh, P = Picopower
[10:31:34] <tonsofpcs> Trieste: being in a confined space with no airflow and added heat?
[10:31:56] <Trieste> oh, right
[10:32:18] <tonsofpcs> I mean, the other option is 85 C
[10:32:43] <Trieste> I was trying to think of actual 105°C situations
[10:33:46] <tonsofpcs> if you've ever had a piece of equipment have capacitors fail you'll notice that mostly the 85C caps fail and the 105C+ caps are fine. I had stacks of linksys switches that had PSUs with good caps and switch boards with failed caps...
[10:34:49] <tpw_rules> bah, i'm petting this chip is fried
[10:34:53] <tpw_rules> betting*
[10:35:03] <tpw_rules> /busy never goes low
[10:35:27] <Trieste> "I'm petting this chip"
[10:35:45] <tpw_rules> hey, at least i didn't mangle it sufficiently so it would burn me when i did tht
[10:38:19] <tpw_rules> is it unable to handle 3v3 IO?
[10:41:05] <tpw_rules> i can't get an avr without ordering one :<
[10:42:06] <Lambda_Auriga_> you could steal one.
[10:42:21] <tpw_rules> there's nobody who has one. this is the south
[10:42:51] <Lambda_Auriga_> I'm in the midwest and probably the only person within 300 miles of here who has an avr that is not on an arduino board or built into something.
[10:42:57] <tpw_rules> exactly
[10:43:48] <tpw_rules> but they should be able to sense 3v3 logic, right?
[10:44:04] <Lambda_Auriga_> yup...just remember to reverse the polarity of the neutron flow.
[10:44:16] <tpw_rules> it's also sucking 55ma of current doing nothing
[10:44:27] * tpw_rules looks in datasheet
[10:45:33] <tpw_rules> but if the clock isn't running it shouldn't be taking any current...
[10:45:50] <Lambda_Auriga_> you put it into deep sleep mode?
[10:47:03] <Trieste> oh jesus
[10:47:12] <Trieste> switching around vcc and gnd isn't good, right?
[10:47:15] <Lambda_Auriga_> your diety can't help you now.
[10:47:21] <Lambda_Auriga_> probably not a good thing, no.
[10:47:22] <tpw_rules> depends
[10:47:42] <Trieste> well, at least it solves whether this avr is dead or not
[10:47:43] <tpw_rules> i'd be afraid to do it for more than a few nanoseconds
[10:48:01] <tpw_rules> actually, i think all that 55ma is leaking into the programming micro
[10:49:14] <tonsofpcs> is there a good way to jump or branch based on a register... like if the register is 0x01, jump to command1: and 0x02, command2:, etc.
[10:49:21] <tonsofpcs> (atmega 328)
[10:49:22] <tpw_rules> do a compare?
[10:49:40] <tonsofpcs> right, but is there a way to do it in a single instruction for all values or do I need a compare for each possible?
[10:49:57] <tpw_rules> you could do a jummp table
[10:50:58] <tpw_rules> have a table of all the destinations for 0, 1, 2, etc then do some sort of indirect jump
[10:51:21] <tpw_rules> if they're all <64k, load z from the table, then do ijmp
[10:52:46] <tonsofpcs> hmmm... reading the wikipedia entry on branch table, I think I understand the concept... I think I understand how I would write it if I were writing in straight machine code, how do I write it in assembly?
[10:52:57] <tpw_rules> the same way? i don't know how it works on avr though
[10:53:07] <tonsofpcs> ok, thanks. I'll see if anyone has a good guide
[10:53:23] <tpw_rules> but you have a table of destinations, then you load an address from that table based on your criteria, then you jump to it
[10:53:34] <tpw_rules> it shouldn't be difficult to figure out with just an instruction reference
[10:54:10] <tonsofpcs> right, but in assembly my destinations are just routine names not known addresses (at least, not until assembled)
[10:54:33] <tonsofpcs> (labels)
[10:55:06] <tonsofpcs> I'm actually now thinking that maybe this particular problem I might want to tackle a different way though...
[10:55:32] <tpw_rules> you can make a table of labels
[10:57:02] <tonsofpcs> esentially I will have a register that contians a value 0, 1-0x12, or 0xff. Based on that value I want to turn a pin high and set a register to 0 (unless that value is 0 or 0xff, 0 = noop, 0xff = jump elsewhere to set all outputs low)
[10:58:33] <tonsofpcs> so rather than a table of labels/addresses, could I maybe make a table of registers (or two, one for pins one for my iterator registers that are being set to 0) and simply issue two command (and have 0x0 and 0xff operate on dummy registers)?
[10:59:59] <tpw_rules> sure
[11:00:05] <tpw_rules> do whatever you want!
[11:00:08] <tpw_rules> actually
[11:00:34] <tonsofpcs> I'm wondering if that's possible. Last time I wrote ASM was on a Z80 on a TRS-80 CoCo model 3 (unless you count fixing some Z80 ASM on a Ti83+)
[11:00:38] <tpw_rules> i don't believe you can indirect through registers but i could be wrong
[11:03:17] <tonsofpcs> (I'm essentially building a SPI to Parallel converter with custom holdoff timing so that a more advanced machine can control a bunch of devices and not worry about highs/lows)
[13:02:57] <tpw_rules> http://imgur.com/a/oyoZi >:(
[13:04:35] <Getty> why?
[13:04:53] <aandrew> tpw_rules: feel better?
[13:04:57] <tpw_rules> i think it was already fried
[13:05:05] <tpw_rules> it just wasn't doing high voltage programming, so i made it
[13:05:06] <aandrew> well at least you've removed all ambiguity
[13:05:10] <tpw_rules> yup
[13:05:20] <Lambda_Auriga_> better to do that with 220uF/16V electrolytic caps
[13:05:30] <tpw_rules> oh god the stink
[13:05:49] <tpw_rules> incidentally, best place to get like 5 atmega328ps? they seem most expensive at digikey but i don't want to wait four weeks from chiuna
[13:05:51] <Lambda_Auriga_> should have a video of that.
[13:06:03] <Lambda_Auriga_> tpw_rules, depends on where you live.
[13:06:10] <tpw_rules> tn
[13:06:19] <Lambda_Auriga_> as in tennessee?
[13:06:21] <tpw_rules> yeah
[13:06:23] <tpw_rules> -PU at the end means DIP>?
[13:06:32] <Lambda_Auriga_> I
[13:06:35] <Lambda_Auriga_> I think so.
[13:06:42] <tpw_rules> cause -au is cheaper but it's qfp
[13:07:38] <tpw_rules> how does $3.23 sound?
[13:07:57] <Lambda_Auriga_> amazon has them for 2.51 with the arduino bootloader on them.
[13:07:58] <Lambda_Auriga_> hehe
[13:08:05] <Lambda_Auriga_> http://www.amazon.com/ATMEGA328P-PU-with-Arduino-Bootloader-Uno/dp/B007SH0D0A
[13:08:05] <tpw_rules> yeah but it's like $4 shipping
[13:09:09] <tpw_rules> eh well might as well get 10 for experiments
[13:09:16] <tpw_rules> i may have to sacrifice some more to figure out hvpp
[13:09:33] <Lambda_Auriga_> did you look up the avr fuse doctor?
[13:09:46] <tpw_rules> yeah. i couldn't find anything on how to actually obtain one?
[13:09:48] <tpw_rules> i could be stupid
[13:09:54] <Lambda_Auriga_> build it.
[13:10:04] <Lambda_Auriga_> all the instructions and everything is there..including schematics.
[13:10:15] <tpw_rules> can an atmega328p boot another or do i need somethimg sturdier?
[13:10:31] <Lambda_Auriga_> sure...
[13:10:48] <Lambda_Auriga_> Use one of the following microcontrollers as the doctor-chip: Atmega8, Atmega88, Atmega88P, Atmega168, Atmega168P, Atmega328, Atmega328P – and their newer/low-voltage “A” or “L” versions.
[13:10:55] <Lambda_Auriga_> right from the fuse doctor webpage.
[13:11:01] <Lambda_Auriga_> http://mdiy.pl/atmega-fusebit-doctor-hvpp/?lang=en
[13:11:31] <Lambda_Auriga_> sparkfun has the atmega328p for 4.30 each...not sure on shipping though.
[13:11:40] <tpw_rules> it's probably cheaper from amazon if i get a bunch
[13:11:56] <Lambda_Auriga_> let's look at the distributors for atmel!
[13:12:16] <tpw_rules> it seems amazon is the cheapest :P
[13:12:22] <Lambda_Auriga_> they suggest digikey or mouser.
[13:12:42] <Lambda_Auriga_> I use arrow electronics myself.
[13:13:01] <tpw_rules> so i guess i'll have to figure out how to make my own pcp
[13:13:03] <tpw_rules> pcb*
[13:13:08] <tpw_rules> :P
[13:13:12] <Lambda_Auriga_> 2.28 each from arrow.
[13:13:35] <tpw_rules> 405 not allowed. i broke it
[13:13:39] <Lambda_Auriga_> why not just order some cheap 328 based arduino boards from ebay?
[13:13:47] <Lambda_Auriga_> http://parts.arrow.com/item/detail/atmel/atmega328p-pu#RJpF
[13:14:23] <Lambda_Auriga_> seems to be a very popular chip.
[13:16:03] <tpw_rules> yeah, i can get like 3 fake arduinos for $10 each
[13:16:56] <Lambda_Auriga_> nice part of that is they usually have the usb-serial adapter built in.
[13:17:15] <tpw_rules> oh hm, apparently atmega328p was just a lie
[13:17:20] <tpw_rules> it actually has a 16u2
[13:17:36] <Lambda_Auriga_> the usb version?
[13:17:46] <tpw_rules> this is a pet peeve but why hasn't full-sized usb-b died yet
[13:17:48] <tpw_rules> http://www.ebay.com/itm/US-UNO-R3-ATmega328P-ATmega16U2-2012-Version-Board-Free-USB-Cable-for-Arduino-/251459710321?pt=LH_DefaultDomain_0&hash=item3a8c2aad71
[13:17:49] <Lambda_Auriga_> those are nice too...usb built into the chip.
[13:18:21] <tpw_rules> what can it do? host and device?
[13:18:45] <Lambda_Auriga_> device only...full speed.
[13:18:54] <Lambda_Auriga_> http://www.atmel.com/devices/atmega16u2.aspx
[13:18:56] <tpw_rules> but i assume whatever vid/pid i want
[13:19:01] <Lambda_Auriga_> yup..
[13:19:14] <tpw_rules> bah, i need the 32k of flash
[13:19:15] <Lambda_Auriga_> use LUFA usb stack for it..
[13:19:27] <Lambda_Auriga_> there is a 32u2 as well.
[13:19:39] <tpw_rules> also i still need a chip to build a fuse doctor just in case
[13:19:45] <Lambda_Auriga_> that one you posted has 2 chips on the board.
[13:20:06] <tpw_rules> "Atmega 16U2 replace the 8U2. ATmega16U2 offers Arduino UNO R3 the ability to show up as a variety of USB devices - keyboard, mouse, joystick, MIDI etc."
[13:20:09] <Lambda_Auriga_> the 328p for the arduino side and the 16u2 for the usb interface.
[13:20:15] <tpw_rules> oh
[13:20:17] <Lambda_Auriga_> it's a dual processor machine.
[13:20:21] <Lambda_Auriga_> you can see both in the picture.
[13:20:23] <tpw_rules> i thought that was just an ftdi thing
[13:20:27] <Lambda_Auriga_> 16u2 is the little chip by the usb port.
[13:20:31] <tpw_rules> ah, neat
[13:20:37] <tpw_rules> i'll get one of those and a couple other chips
[13:20:41] <Lambda_Auriga_> so, programmable for various things.
[13:20:44] <tpw_rules> schweet
[13:20:54] <Lambda_Auriga_> an ftdi chip limits you to CDC---virtual serial.
[13:21:06] <tpw_rules> yeah
[13:21:08] <Lambda_Auriga_> the 16u2 allows you to turn it into a keyboard or joystick or even mass storage device.
[13:22:08] <Lambda_Auriga_> as I recall from some time back in the near past someone around here did a usb printer driver interfaced bootloader/programmer thingie
[13:22:10] <tpw_rules> okay 10x atmega328p-pu for shenanigans
[13:22:15] <RikusW> full size usb b is better for heavy use, it doesn't break as easily as mini or micro
[13:22:22] <tpw_rules> i've never had a problem with mini breaking
[13:22:27] <Lambda_Auriga_> get some atmega1284p chips! those are the boss!
[13:22:47] <tpw_rules> are they bigger?
[13:22:50] <Lambda_Auriga_> I've had minis break all the time...
[13:22:51] <tpw_rules> pins-wise
[13:22:54] <Lambda_Auriga_> 40pin
[13:23:00] <RikusW> Lambda_Auriga_: abcminiuser did the print bootloader in LUFA
[13:23:01] <tpw_rules> i need at least one for my clock
[13:23:13] <Lambda_Auriga_> lots of i/o, 128K flash, 16K sram!
[13:23:17] <Lambda_Auriga_> 32i/o pins.
[13:23:20] <tpw_rules> i still like my propellers
[13:23:27] <RikusW> tpw_rules: mini and micro are fully smt and tends to rip from the pcb
[13:23:48] <Lambda_Auriga_> I work with kids, as a hobby thing, teaching them electronics and microcontrollers.
[13:23:48] <RikusW> mu
[13:23:50] <tpw_rules> what do you do to your poor usb ports
[13:23:53] <RikusW> most full z
[13:23:55] <Lambda_Auriga_> and they are hard on boards and ports.
[13:24:03] <RikusW> size are through hole
[13:24:05] <tpw_rules> i suppose
[13:24:22] <Lambda_Auriga_> lately we have been playing with the devil's chips though rather than avr.
[13:24:27] <Lambda_Auriga_> pic32.
[13:24:36] <RikusW> heh
[13:25:08] <Lambda_Auriga_> 28pin 128K flash, 32K flash, 50MHz mips m4k core.
[13:25:14] * tpw_rules flies away with his beanie
[13:25:30] <Lambda_Auriga_> like, 80 mips.
[13:25:46] <Lambda_Auriga_> in a dip package.
[13:25:58] <Lambda_Auriga_> with device/host/otg usb onboard.
[13:26:02] * tpw_rules coughs and points at his propeller
[13:26:16] <Lambda_Auriga_> that's a low end pic32.
[13:26:34] <tpw_rules> it's whatever it desires!
[13:26:40] <tpw_rules> can the pic do video output?
[13:26:44] <tpw_rules> genuinely curious
[13:26:48] <IsaacGT> Tom_itx alive?
[13:26:50] <Lambda_Auriga_> haven't tried yet.
[13:27:14] <Lambda_Auriga_> but I'm sure it can...it will be the core for my next revision on my vga controller.
[13:27:28] <tpw_rules> do you have to bitbang it like the propeller?
[13:27:40] <Lambda_Auriga_> this particular one, yeah.
[13:28:36] <tpw_rules> i suppose i should diversify but then you start getting into literally thousands of chips that are all subtly different
[13:28:50] <Lambda_Auriga_> yup.
[13:28:54] <tpw_rules> genius if you're selling something but painful for a hobbyist
[13:29:00] <Lambda_Auriga_> each has its advantages and disadvantages.
[13:29:22] <Lambda_Auriga_> I work with pic, pic32, avr, and 8052 chips here....well, play mostly.
[13:29:34] <Lambda_Auriga_> and have toyed with avr32, arm, and msp430
[13:29:49] <tpw_rules> i doubt i'd ever put a propeller in something commercial but i don't run into a 4-7 business day halt because this chip doesn't do what i need
[13:31:47] <Lambda_Auriga_> what I find interesting about the pic32 is the use of the mips32 m4k core. It seems to be a very popular cpu core.
[13:33:14] <tpw_rules> why would microchip do that?
[13:33:17] <tpw_rules> the pic was all in house
[13:33:18] <tpw_rules> right?
[13:33:38] <Lambda_Auriga_> 8bit and 16bit pic was...when they went for the 32bit they licensed the mips core.
[13:33:41] <tpw_rules> ah
[13:34:15] <Lambda_Auriga_> dspic chips rock too but coding for them can be a bitch sometimes....well, for any of the pic chips really.
[13:34:53] <kastein_> coding for 8 bit pic is an exercise in frustration. 35 instructions that suck, no real registers to speak of...
[13:34:59] <kastein_> it is why i came to avr
[13:35:26] <Lambda_Auriga_> kastein_, different 8bit pics have different instruction sets too...there is the basic set then 16 and 18 devices add more instructions.
[13:37:03] <Lambda_Auriga_> pic has it's uses though here and there. I have some pic16f chips that I use for usb-serial(i2c, spi, usart) adapters and nothing else...they are cheap and easy to work with.
[13:38:21] <tonsofpcs> does the Uno use the 328 or 328p?
[13:38:43] <_RaD> re all
[13:38:53] <Lambda_Auriga_> tonsofpcs, probably 328p
[13:39:12] <tonsofpcs> Lambda_Auriga_: gah... I just started working with 328 figuring that's what it was... now to figure out how to switch project if necessary...
[13:39:23] <tonsofpcs> the wiki pages all say "328 base" but don't get more specific
[13:39:34] <Lambda_Auriga_> tonsofpcs, should be the same chip...just the P version has picopower capability.
[13:39:44] <tonsofpcs> the 328p apparently has a couple more instructions due to the power chanes
[13:39:46] <tonsofpcs> *changes
[13:40:12] <Lambda_Auriga_> from the ardweeny website picture it is an atmega328p-pu.
[13:40:14] <tonsofpcs> and iirc (I'll have to pull the spec sheets back up), the P also executes certain commands in different numbers of clocks
[13:40:23] <_RaD> ppl, I need some help with attiny13 and switching mode via reset EXTRF bit
[13:40:35] <Lambda_Auriga_> if you aren't using the picopower stuff it's the same chip other than different ID code.
[13:40:41] <_RaD> it works well in avrstudio but doesn't work on breadboarf
[13:41:01] <rue_shop3> _RaD, you didn't turn the reset into an io pin did you?
[13:41:03] <Lambda_Auriga_> aand, time for me to go do something useful...entertain the wifey.
[13:41:30] <_RaD> rue_house, no, I don't want to touch fuses
[13:42:04] <_RaD> https://github.com/RaD/SolderPaste14M2/blob/master/firmware/solderpaste.asm#L117 - this is my way
[13:51:28] <rue_shop3> _RaD, if your trying to use the reset pin as an input or output, without resetting the fuses, the processor will reset every time the pin is put low. If you change the reset to an io pin, you have to have a high voltage programmer to reprogram it
[13:58:23] <_RaD> rue_shop3, I understand that, and I don't want to make HV programmer, that is why I reproduce dirty hack with EXTRF bit, that helps detect that RESET was made softly, with this type of reset MCU keep registers
[16:36:18] <krysmin> Hell
[16:36:33] <krysmin> Hello*
[17:36:15] <petershaw> i am try a board with v-usb, is it possible to connect data+ and - to PD3 and PD4 of a atmega328?
[17:36:32] <petershaw> just checking bevor i solder it :-)
[17:38:18] <evil_dan2wik> petershaw, check the requirements of v-usb
[17:45:11] <petershaw> ok, and can it be clocked with 16Mhz or do i need the exact 12Mhz from the examples. Can't get it from the text.
[18:00:48] <evil_dan2wik> petershaw, I am pretty sure you can go faster
[18:01:15] <petershaw> evil_dan2wik: thank you.
[18:01:34] <evil_dan2wik> petershaw, Can be clocked with 12 MHz, 15 MHz, 16 MHz or 20 MHz crystal
[18:19:56] <black_13> is there gcc for the arduino/avr chips that can be used on windows?
[18:36:04] <Tom_itx> black_13 yes
[18:36:16] <Tom_itx> in fact you can download it from the atmel site
[18:36:32] <black_13> thanks
[18:37:02] <black_13> I was thinking about playing around with an rtos on the arduino board i have
[18:39:04] <black_13> http://www.atmel.com/tools/atmelavrtoolchainforwindows.aspx ?
[18:41:48] <Tachyon`> hem
[18:41:56] <Tachyon`> writing your own os?
[18:44:20] <black_13> I am not that smart I want to compile and use some of the ones i have seen there are more than a few
[18:44:31] <black_13> Chibios and i think one called FemtoOs
[18:47:53] <FoxGT> Tom_itx, Where are the goods??
[18:49:32] <FoxGT> Need to purchase a programmer.
[19:01:57] <Tom_itx> you do?
[19:06:46] <Tom_itx> FoxGT
[19:30:18] <krysmin> Hello