#avr | Logs for 2016-07-06

Back
[01:02:36] <rue_house> since when is there a goto instruction?
[01:14:24] <l9> is there any good circuit drawer/simulator for ubuntu?
[01:15:10] <_ami_> rue_house: i was looking for alternative to asm ("jmp x") in C :)
[01:15:16] <rue_house> use eagle to draw them, simulate them on a BREADBOARD
[01:15:27] <rue_house> if you test it in real life, and it works, it'll work in real life
[01:15:38] <rue_house> if you test it in a simulator, it'll work in a simulator
[01:15:54] <_ami_> l9: 123dcircuits.io is also not bad! not good for advanced stuff though .
[01:16:06] <rue_house> _ami_, ah yea, goto, but only use goto if you dont know how to code C properly
[01:17:37] * l9 apt install eagle
[01:18:02] <_ami_> rue_house: i know other alternative too. like void (*jmp_to_addr)(void) = x; jmp_to_start();
[01:18:28] <_ami_> it does not hurt to find more alternatives.
[01:22:05] <_ami_> rue_house: goto is just got the bad name. if you use it properly, it helps in many catch 22 situations.
[01:22:41] <_ami_> most of kernel developers uses goto: and it does not mean they don't know C properly. probably they know C far better than u and me.
[01:22:48] <rue_house> really, you do not need to use goto in C
[01:23:05] <rue_house> it can help optimize things, but its bad form, really, it is
[01:24:05] <rue_house> most of the time people use goto because they dont know how to layer their if/while/for properly
[01:25:49] <_ami_> goto is handy if u have a common error handling code in every if/else.
[01:29:41] <rue_house> break / return
[01:29:56] <rue_house> error code in a fuction or macro
[01:30:22] <rue_house> sorry, I HATE to see goto in C
[01:31:51] <_ami_> :)
[01:33:28] <rue_house> in ...
[01:33:53] <rue_house> 23 years of coding C I'v never needed goto
[01:35:19] <tkoskine> Nested loops are kind of annoying and I am often tempted to use goto to get out of them.
[01:35:55] <rue_bed> if you cant use return, your putting too much in one function
[01:38:08] <rue_bed> are people using goto in c++ too?
[01:39:37] <rue_bed> has anyone used a TLC5934 yet?
[01:41:27] <tkoskine> rue_bed: Probably embedded code(rs) uses more goto than "desktop" code(rs) as it might save you some bytes and therefore allow your to use smaller avr chip (or stay with the current one).
[01:42:15] <rue_bed> I findthat if gcc knows there is only one way out, it'll insert a return or a goto as req'd
[01:42:52] <rue_bed> does the tiny13 and tiny26 adc work the same?
[01:43:02] <rue_bed> where are my datasheets
[01:44:52] <rue_bed> admux matches...
[01:45:50] <rue_bed> adsra matches...
[01:47:36] <rue_bed> no adsrb on the tiny26...
[02:03:53] <rue_bed> huh, min Vref for the adc is 2V
[02:44:16] <Jartza> rue_bed: what's TLC5934?
[04:09:51] <_ami_> Jartza: yo! whats up
[05:30:03] <Emil> Yo
[05:30:13] <Emil> What's the difference between AN and ANR
[05:30:16] <Emil> and AU and AUR
[05:32:19] <osteri> rue_bed: out of bed, now!
[05:42:12] <LeoNerd> Emil: I -think- the trailing R means it comes on a reel rather than in those plastic tubes
[05:42:19] <LeoNerd> I.e. same chip, different box
[05:43:33] <Emil> LeoNerd: thanks
[05:43:45] <Emil> That's what I figured, too
[05:43:54] <Emil> and AN and AU differen in temperature range
[05:44:09] <LeoNerd> Some manufacturers publish handy reference guides to what the various characters in their chips mean. Atmel don't :(
[06:37:54] <Emil> https://www.itead.cc/2layer-green-pcb-5cm-x-5cm-max.html
[06:37:59] <Emil> Is this really what is says?
[06:39:15] <Lambda_Aurigae> probably.
[06:39:24] <Lambda_Aurigae> is similar to dirtypcb
[06:40:52] <Emil> What's the dirtypcb protopack +-10
[06:41:06] <Lambda_Aurigae> $14.00
[06:41:35] <Lambda_Aurigae> claims tested too..guessing etesting,,,as in, making sure all the traces are connected where they should be.
[06:42:00] <Emil> But you can select exactly 10, too
[06:42:01] <Lambda_Aurigae> for $25.00 you can get 10x10cm boards from dirtypcbs.com too
[06:42:31] <Lambda_Aurigae> yeah..exactly 10 is $28.00
[06:42:36] <Lambda_Aurigae> for the 5x5
[06:43:00] <Lambda_Aurigae> and for 10x10
[06:44:08] <chriii> hi guys, I'm trying to program a xmega32c4 with avrdude, but it does not work because it expects a wrong (?) signature. the output is "avrdude: Expected signature for ATxmega32C4 is 1E 94 43" but according to the atmel datasheet this should be 1E 95 44.. can somebody help me?
[06:44:38] <Lambda_Aurigae> fix the avrdude.conf file.
[06:44:51] <Lambda_Aurigae> what signature is it getting?
[06:45:08] <chriii> it is getting the right one which is specified in the datasheet
[06:45:42] <Lambda_Aurigae> then fix the avrdude.conf file
[06:46:58] <Lambda_Aurigae> edit the avrdude.conf file and change the signature entry for the part in question.
[06:47:16] <Lambda_Aurigae> looks like a typo maybe
[06:47:42] <Lambda_Aurigae> what signature is it getting?
[06:48:53] <chriii> thx, worked. the one which is entered is the one for the xmega16c4
[06:51:04] <chriii> and the one which is entered for the x16c4 is the one for the x32c4, I guess somebody mixed up those two.
[06:53:34] <chriii> ok, it
[06:53:48] <chriii> it's already reported: https://savannah.nongnu.org/bugs/?47776
[06:53:48] <chriii> thx for your help!
[06:55:49] <_ami_> chriii: using ubunut?
[06:55:55] <chriii> yes
[06:56:11] <_ami_> same mistake on my avrdude config also.
[06:56:34] <_ami_> desc = "ATxmega32C4";
[06:56:34] <_ami_> signature = 0x1e 0x94 0x43;
[09:08:39] <rue_house> did someone oops a sig?
[09:08:55] <LeoNerd> Mm?
[09:09:17] <rue_house> in avrdude,
[10:01:48] <bss36504> Figured out my smoking xmega issue (sort of). Soldered a new one on with more care and it worked great.
[10:19:24] <Casper> bss36504: that ain't figured... you replaced...
[10:44:54] <carabia> bss36504, nice, this can be used for future reference!
[11:06:38] <Jartza> evening
[11:20:17] <bss36504> Casper: Ironically this is a reflow oven controller. I wouldnt have had this problem if I could have reflowed the board :)
[11:40:48] <carabia> you really need an xmega for that?
[11:42:16] <carabia> or i don't know, never really tried them out apart from minor fiddling
[12:03:32] <bss36504> Oh, you must have missed my explaination. I'm using the comparator, DAC, and XCL for my phase control scheme. Necessary? no. Cool? Very.
[12:09:25] <LeoNerd> XCL?
[12:09:43] <bss36504> Xmega custom logic
[12:09:58] <bss36504> It's how I'll be implementing the one-shot to trigger the SSRs
[12:11:08] <LeoNerd> Ohyes, that thing
[12:12:13] <bss36504> The one shot should be a little annoying to set up though, since it seems that there is a total of about 12 lines about it, between the datasheet and the App note for the XCL
[12:12:20] <bss36504> so we shall see how that goes
[12:32:56] <antto> xmega is much x, very mega
[12:38:52] <bss36504> wow
[12:57:41] <bss36504> http://hackaday.com/2016/07/05/the-future-of-eagle-cad/
[12:57:53] <bss36504> So as we know Eagle was bought up by autodesk
[12:59:11] <bss36504> I cant for the life of me figure out why AD would do that? I think we can assume they want to convert eagle into a more Autodesk Look and Feel, as well as integrate it with their other tools. So at that point, it seems like it would have been easier for AD to just leverage their other "shape drawing" programs like autocad into an EDA package.
[12:59:43] <bss36504> Any counterpoints? Just seems like bringing the eagle codebase into the fold would be harder than adding on EDA features to their existing platform
[13:15:08] <Tom_itx> i thought farnell or some company like that bought it
[13:15:19] <bss36504> Farnell sold it off
[13:15:21] <Tom_itx> and added that part association thing to it
[13:15:29] <Tom_itx> hmm
[13:15:39] <Tom_itx> i'm still using an old version anyway
[13:16:20] <Tom_itx> must not have brought the revenue they thought it would
[13:16:26] <twnqx> no
[13:16:34] <twnqx> farnell itself was sold, and non-core business spun off
[13:17:41] <twnqx> and i need something far better than eagle :(
[13:18:08] <bss36504> Well maybe autodesk can fix some of the issues it has
[13:18:21] <twnqx> doubt it
[13:18:38] <twnqx> it will stay hobbyist tier, it's like 10 years of missing development
[13:19:24] <bss36504> Well therein lies the question; why would autodesk bother buying it?
[13:19:51] <twnqx> the article (or comments) for the sale on hackaday gave some ideas
[13:20:27] <twnqx> http://hackaday.com/2016/06/29/the-eagle-has-landed-at-autodesk/ read for yourself
[13:24:03] <bss36504> Yeah I read that one too
[13:25:56] <bss36504> I like eagle, it's my go to PCB software since I can do everything I need with it. BUT, it's also super clunky. I assume that most software aquisitions need to have some sort of valuable IP, and lets face it, eagle does not have valuable software IP. They don't even have a push and shove router! So if you're autodesk, why bother? Maybe they just wa
[13:25:56] <bss36504> nt the name, but I can't see them simultaneously integrating it into their ecosystem while not having to rewrite massive (read: all) amounts of code.
[13:36:40] <_ami_> smart idea: https://www.kickstarter.com/projects/bagel-labs/bagel-the-worlds-smartest-tape-measure
[14:19:01] <Emil> _ami_ that's pretty cool