#avr | Logs for 2013-12-24

Back
[00:18:38] <rue_house> hackvana, can you help me translate to chinese then?
[00:32:06] <hackvana> A little maybe
[00:32:15] <hackvana> I'll see you in #hackvana
[01:34:06] <megal0maniac_afk> abcminiuser: Congrats on the new job :)
[01:38:53] <megal0maniac_afk> Also, could anyone please explain to me what happens here? I don't get the reading of writing to a bit. while(!SPSR & (1<<SPIF))
[01:41:37] <inflex> wth... can't find any of my AVR programmers :(
[01:41:48] <inflex> That's what I get for not doing electronics (AVRs) for 6 months
[01:52:05] <rue_house> what!? did abcminiuser get a new job!?
[01:53:10] <rue_house> inflex, I always manage to find a programmer, between the two usb ones, the 3 or so parallel port ones, and the ATA one, there is always a way
[01:57:01] <megal0maniac_afk> abcminiuser_: It feels like you're still in Norway
[02:01:50] <inflex> rue_house: found a whole box of them
[02:01:59] <inflex> but now I can't find my source code
[02:08:27] <megal0maniac_afk> Only in #avr does one have a box of programmers
[02:09:18] <rue_bed> inflex, is it under /files/programming/c/avr/atmega32/ ?
[02:10:06] <inflex> hah, I wish
[02:11:01] <rue_bed> how about /files/programming/asm/avrs/atmega32/
[02:11:16] <rue_bed> files/temp/ ?
[02:11:53] <rue_bed> huh, I have an avrisp mkII somewhere, and I'v never used it
[02:12:40] <inflex> right... found my schem and PCB at least... that's a start
[02:13:00] <rue_bed> files/projects/----/software/ ?
[02:13:02] <inflex> i've got the programmer, but I was meaning the source code for my particular project
[02:14:02] <w|zzy> got clone ?
[02:14:10] <w|zzy> git ffs auto correct
[02:14:16] <rue_bed> do you need to duplicate a project you made a while ago, and because you didn't put a sticker with the filename on the chip your not sure what software it was?
[02:15:39] * megal0maniac_afk writes this down
[02:15:42] <inflex> what happened was that I reappropriated my project ( reflow oven ) to control a fridge/freezer instead
[02:15:48] <inflex> but for some reason I can't find the modified source code
[02:16:01] <rue_bed> aah
[02:16:20] <rue_bed> was it a recent project? this year?
[02:16:54] <inflex> ja, this year, at least I'm fairly sure, so I'm doing a find with date windowing
[02:17:04] <rue_bed> good show
[02:17:31] <rue_bed> often I use ls -lrt to find where a projects source is
[02:17:41] <rue_bed> cause I usualy know what project was before and after
[02:17:45] <rue_bed> given a list
[02:22:42] <inflex> crap... nothing in my build tree ... wonder if I was stupid and built it in some other location... what an idiot
[02:27:08] <rue_bed> list all .c files and sort by modification date
[02:27:12] <Roklobsta|2> inflex: have you given up on manufacturing altogether?
[02:28:38] <inflex> Roklobsta|2: for the time being, yes.
[05:03:45] <e7p> I've got two ATTiny85. I tried to flash them using usbasp and ponyser, none of them worked, eventhough they would work on other AVRs. I tried also usbasp with a crystal connected to the Attiny, but I still get the error "avrdude: initialization failed, rc=-1". I have double checked all connections.
[05:04:56] <e7p> How can I be sure what the problem is? Maybe the fuse bits are wrong, maybe the chips are dead.
[05:05:11] <e7p> Maybe it has anything to do with the programmer.
[06:45:07] <inflex> v.unlikely it's the chips, things like 85's are pretty tough
[06:45:21] <inflex> do you have anything attached to the programming pins on the chips in circuit?
[06:45:30] <inflex> Try with a slower bitrate
[06:55:39] <e7p> inflex: tried without anything else attached
[06:55:54] <e7p> slower bitrate on ponyser (bitbanging)?
[06:56:18] <inflex> oh, ponyprog eh... never was happy with that one, always was quirky
[06:57:04] <e7p> well, I also tried with usbasp.
[07:07:11] <Epsilon-Auriga_> good old parallel port programmer still works. I've had usbasp give too many failures for no reason.
[07:08:36] * inflex has found usbtiny to be dependable.
[07:11:16] <megal0maniac> LUFA avrisp mkii is bulletproof
[07:11:25] <megal0maniac> So far, at least :)
[07:11:50] <Tom_itx> is so
[07:14:44] <inflex> ja, Tom_itx's programmers are fanastic
[07:14:46] <inflex> fantastic
[07:14:59] <inflex> lo there btw Tom_itx, been a while, hope things are going okay with yo
[07:15:01] <inflex> you
[07:15:25] <Tom_itx> yep just hangin in there
[07:21:06] <e7p> tried an attiny2313, works with usbasp
[07:22:27] <Epsilon-Auriga_> yeah..I have one of tom's programmers too and it works well.
[07:22:58] <Epsilon-Auriga_> my programming station still has a parallel port and I tend to use that programmer more than any other.
[07:42:03] <megal0maniac> Ooh! I think our internet has been upgraded
[07:42:07] <megal0maniac> 2mbps :D
[07:51:40] <Epsilon-Auriga_> nice
[07:51:49] <Epsilon-Auriga_> I got a double boost a year after I moved here.
[07:51:59] <Epsilon-Auriga_> went from 1.5Mb/s to 3Mb/s and they didn't change the cost.
[08:01:52] <megal0maniac> Nope. Still 1mbps :(
[08:03:58] <Epsilon-Auriga_> poor mega
[08:04:37] <megal0maniac> It'll be done by the end of Feb. I misread
[08:04:41] <megal0maniac> 3rd world problems
[08:04:49] <Epsilon-Auriga_> guy I work with has his "up to 25 meg" cable at home.
[08:05:03] <Epsilon-Auriga_> he is lucky to get 5 meg in the evenings when he gets home.
[08:06:26] <megal0maniac> My modem reports that it can sync at up to 17mbps, but it's limited by the account
[08:08:05] <Epsilon-Auriga_> haven't checked my modem but my provider has 3Mb, 5Mb, and 10Mb service.
[08:08:18] <megal0maniac> You have 3rd world problems too :D
[08:08:24] <Epsilon-Auriga_> yup.
[08:08:30] <megal0maniac> Where are you?
[08:08:40] <Epsilon-Auriga_> middle of no-fucking-where iowa, usa, earth
[08:08:49] <Epsilon-Auriga_> but I do have fiber to the side of my house.
[08:09:03] <Epsilon-Auriga_> get phone and internet and can get cable on it.
[08:09:37] <Epsilon-Auriga_> 200 pair fiber demark 50 feet from my front door.
[08:10:56] <megal0maniac> No such luxury here :)
[08:11:19] <Epsilon-Auriga_> it was put in about 7 years ago..2 years before I moved here.
[08:11:37] <Epsilon-Auriga_> government grant to get high speed internet to rural areas.
[09:30:51] <rue_house> good thing it wasn't a grant to get rural areas high
[09:35:46] <Epsilon-Auriga_> well, there is enough ditch weed growing around here to get one or two people high per 10 acres or so.
[09:36:10] <Epsilon-Auriga_> I understand you have to smoke half a kilo of the stuff to get high though.
[09:42:34] <rue_house> heh
[10:20:16] <uhsf> I'm making a keyboard that is split into two parts and I have to get the signal from one part to the other via a cable. What kind of cable should I use? I was thinking of USB, but my design requires that I also get the clock timing from the uC on the other part.
[12:10:23] <Epsilon-Auriga_> uhsf: piece of ribbon cable, cat5, an old unused usb cable(not using usb comms)
[12:10:43] <Epsilon-Auriga_> all depends on what you need for number of wires.
[12:11:16] <Epsilon-Auriga_> use a couple of rj45 plugs and a short ethernet patch cable and you have 8 wires to play with.
[12:13:46] <megal0maniac> Something makes me think that providing a system clock over a long run is a bad idea
[12:14:25] <Epsilon-Auriga_> I was thinking a 1 or 2 foot patch cable...even that could provide quite a bit of noise for a clock though....
[12:14:53] <Epsilon-Auriga_> again, all depends on the design and what needs to be done...the description posted leaves a lot open for interpretation as much is missing.
[13:08:32] <The_Coolest> hey guys, I'm trying to figure out a way to overload a function so that my class could handle progmem strings and sram strings properly. But here's what I get: http://pastebin.com/Un5qRWmN
[13:08:38] <The_Coolest> Any input on that/
[13:10:03] <Epsilon-Auriga_> only one...ewwww, C++
[13:10:17] <kline> Epsilon-Auriga_: why ewwww?
[13:10:29] <The_Coolest> Epsilon-Auriga_> wat
[13:10:32] <Epsilon-Auriga_> because I'm an old C weenie from way back.
[13:10:41] <The_Coolest> heh
[13:11:02] <The_Coolest> I like both languages, but prefer C if I can get away with it
[13:11:19] <Epsilon-Auriga_> I only use asm or C on microcontrollers.
[13:11:35] <Epsilon-Auriga_> but I'm old fashioned.
[13:12:16] <Epsilon-Auriga_> the whole overloading things in C++ just doesn't seem natural to me..
[13:12:19] <The_Coolest> If I had to use asm, I'd give up quite soon
[13:12:29] <The_Coolest> Epsilon-Auriga_>> I get it :]
[13:12:30] <megal0maniac> I'm pretty fresh to this stuff and I avoid C++ for microcontrollers. I pretend that it isn't a thing, although I'm sure it has a place. Just not with 8bit AVRs
[13:12:42] <Epsilon-Auriga_> 6502 was my second programming language I taught myself,,,after basic.
[13:12:57] <kline> Epsilon-Auriga_: you wiggle your fingers and you can control the flow of subatomic particles? whoever said anything about this was natural?
[13:13:27] <Epsilon-Auriga_> now, where's my punched tape?
[13:13:52] <Epsilon-Auriga_> as for your question The_Coolest, no clue...something not liking your overload.
[13:14:07] <The_Coolest> well I got into arduino at first after doing C++/C#/Java on the PC for a while. Now I'm trying Atmel Studio (and hating what Atmel did to Visual Studio) and encountered this issue.
[13:14:45] <The_Coolest> it ignores the progmem attribute in the function's declaration
[13:14:56] <The_Coolest> maybe a typedef will solve this.
[13:15:03] <kline> The_Coolest, Epsilon-Auriga_ : the reason its not valid is because the progmem bit is ignored, and you cant overload something with itself
[13:15:17] <The_Coolest> Yup I know
[13:15:25] <kline> im about to look at some of the progmem stuff to see how they do it
[13:15:31] <kline> i recommend you do the same
[13:15:40] <The_Coolest> Arduino?
[13:15:57] <The_Coolest> They made a custom string class that takes progmem strings
[13:16:06] <Epsilon-Auriga_> that makes sense kline
[13:16:18] <Epsilon-Auriga_> The_Coolest: so go play with ardwino.
[13:16:25] <The_Coolest> nah
[13:16:30] <Epsilon-Auriga_> or rip apart their code and see how they do it.
[13:16:48] <kline> The_Coolest: http://www.nongnu.org/avr-libc/user-manual/group__avr__pgmspace.html#gacd5af73767ca6defbec02736072dfb30
[13:17:00] <The_Coolest> Epsilon-Auriga_>> I looked at it a bit, too much overhead for what I need.
[13:17:24] <The_Coolest> And no more Arduino for me :) Working on my own custom board based on the ATmega328
[13:17:36] <kline> look at how they use char* for strings and a far pointer for progmem
[13:17:40] <The_Coolest> I mean on the firmware for it :P
[13:17:56] <Epsilon-Auriga_> I was actually looking at fubarino this morning...pic32 based ardweeny.
[13:18:31] <The_Coolest> heh
[13:18:36] <The_Coolest> nice
[13:18:59] <The_Coolest> kline interesting
[13:20:28] <The_Coolest> uint_farptr_t is a 32bit value
[13:20:35] <The_Coolest> let's try this.
[13:21:03] <The_Coolest> yay
[13:21:39] <kline> The_Coolest: oh hey this isnt the channel i thought it was
[13:21:57] <Epsilon-Auriga_> sometimes people even talk about AVR in here!
[13:23:04] <The_Coolest> lol
[13:25:04] <megal0maniac> Do we?
[13:25:08] <megal0maniac> Oh yeah we do
[13:25:17] <Epsilon-Auriga_> yeah...there was that one time last month
[13:25:21] <The_Coolest> ok this didn't actually work. boo
[13:25:29] <Epsilon-Auriga_> when the guy was asking about avr audio equipment.
[13:32:32] <hetii> Hi :)
[13:33:17] <hetii> Any clue How can i drive vfd display from avr uC without additional transistor or uln20xx driver ?:)
[13:35:20] <hetii> display work with 20v level that are provided by 10kohm resistors.
[13:45:29] <The_Coolest> hetii what?
[13:48:29] <twnqx> hetii: i would say you shouldn't, though you can look at the current rating of the ESD diodes. if you need less that that it could work, though i personally wouldn't do it.
[13:48:39] <twnqx> than that*
[13:53:41] <hetii> well i know its a bit ugl, but i have not much space there.
[13:57:42] <twnqx> i would test it on a breadboard or something before pcb fabbing :P
[13:59:17] <hetii> yep, thats true :)
[14:04:50] <hetii> hmm i found pcf8574, maybe will use them instead uC
[14:05:07] <hetii> as i see max input is 7v
[14:07:14] <Epsilon-Auriga_> https://www.youtube.com/watch?v=G5od6roIMtQ now that's one hell of a waterproof splice!
[14:13:21] <hetii> huh, what in the case if they will connect wrong wire :D
[14:14:24] <Epsilon-Auriga_> ever see the tv show the apprentice?
[14:14:32] <Epsilon-Auriga_> "You're FIRED!"
[14:15:29] <Epsilon-Auriga_> smoothing molten lead by hand, even with an oven mit,,,now there's hardcore.
[14:15:55] <hetii> yem i saw that :D its cool :)
[14:16:20] <Epsilon-Auriga_> more warm,,,or even hot.
[14:16:42] <hetii> I suppose they was very proud when they finish it and launch :)
[14:16:46] <Epsilon-Auriga_> about 327.5C even.
[14:17:29] <Epsilon-Auriga_> thing is, they are doing that onboard a ship...they spool out one reel of cable...move the next in place and splice...spool, splice, repeat as necessary.
[14:17:42] <Epsilon-Auriga_> and that splice job has to take several hours.
[14:20:25] <hetii> btw some time ago i build such tool: http://www.radiolocman.com/shem/schematics.html?di=65084 that rescue few of my uC maybe you know it already if not its worth to build one :)
[14:22:59] <Epsilon-Auriga_> hetii: it can be useful.
[14:23:17] <Epsilon-Auriga_> I have an avrdragon for doing that..works with more chips.
[14:23:53] <bitd> Hmm, I am having trouble implementing a simple _delay_ms
[14:24:10] <bitd> It seems my processor is just skipping it.
[14:24:20] <bitd> any known reasons for this?
[14:24:21] <hetii> here is full list of implementing uC :http://mdiy.pl/atmega-fusebit-doctor-hvpp/
[14:24:35] <Epsilon-Auriga_> bitd: compiler optimization?
[14:24:52] <hetii> 145 types :)
[14:25:01] <Epsilon-Auriga_> hetii: yeah..looking at that. looks like a lot more than last time I looked at that project.
[14:25:48] <bitd> Yes, I have -Os
[14:26:06] <Epsilon-Auriga_> bitd: that could be causing it.
[14:26:16] <Epsilon-Auriga_> it's optimizing out the delays to make things run faster maybe?
[14:26:40] <bitd> /usr/lib/gcc/avr/4.7.2/../../../avr/include/util/delay.h:95:3: warning: #warning "Compiler optimizations disabled; functions from <util/delay.h> won't work as designed" [-Wcpp]
[14:28:04] <Epsilon-Auriga_> bitd: are you doing a delay with a variable or constant in delay_ms() ??
[14:28:11] <bitd> Constant.
[14:28:18] <Epsilon-Auriga_> ok...
[14:28:49] <Epsilon-Auriga_> and using gcc, yes?
[14:29:03] <bitd> Ayep :)
[14:29:30] <Epsilon-Auriga_> and F_CPU is defined? to match your actual clock speed?
[14:30:16] <bitd> Sure is.
[14:30:48] <Tom_itx> and ckdiv8 is not set
[14:30:51] <Epsilon-Auriga_> then I have no clue.
[14:31:59] <bitd> Tom_itx, checking that now
[14:32:00] <megal0maniac> Anyone know off-hand what the USART receive vector is called?
[14:32:29] <Tom_itx> what chip
[14:32:34] <megal0maniac> 32u2
[14:32:38] <bitd> Atmega8515.
[14:32:40] <bitd> Oh.
[14:32:41] <bitd> :P
[14:32:42] <megal0maniac> *32u4
[14:33:36] <Tom_itx> #define USART1_RX_vect_num 23
[14:33:37] <Tom_itx> #define USART1_RX_vect _VECTOR(23) /* USART1, Rx Complete */
[14:33:37] <Tom_itx> #define USART1_UDRE_vect_num 24
[14:33:37] <Tom_itx> #define USART1_UDRE_vect _VECTOR(24) /* USART1 Data register Empty */
[14:33:37] <Tom_itx> #define USART1_TX_vect_num 25
[14:33:37] <Tom_itx> #define USART1_TX_vect _VECTOR(25) /* USART1, Tx Complete */
[14:33:59] <megal0maniac> Ah! It starts with USART. Where is that from?
[14:34:09] <Tom_itx> the header file silly
[14:34:24] <megal0maniac> Whoops :)
[14:34:51] <megal0maniac> Thanks
[14:57:51] <bitd> Epsilon-Auriga_, figured it out.
[14:58:00] <bitd> Had all my files correct, was just uploading an old .hex <.<
[14:58:04] <Epsilon-Auriga_> oops
[16:23:02] <rue_house> the old "NOMATTER THAT I DO TO THE SOURCE, THE AVR KEEPS DOING THE SAME THING!"?
[16:57:49] <w|zzy> rue_house: you have to compile and upload.
[17:50:24] <Epsilon-Auriga_> w|zzy: you have to compile and upload the proper file!
[18:07:01] <w|zzy> Yeah
[18:27:21] <Epsilon-Auriga_> mmm..molten sugar is a bit hot.
[18:28:40] <Epsilon-Auriga_> I remember a build server setup I had at one place I worked some years ago....it would do an automatic build of the source(started out about 10k lines of code)...then it would send an email out with a link to the current executable installer.
[18:29:01] <Epsilon-Auriga_> it worked great but we wanted some added functionality so I modded the build scripts a bit.
[18:29:08] <Epsilon-Auriga_> and it went all kinds of wacko.
[18:29:25] <Epsilon-Auriga_> things added to the code weren't showing up properly in the executable.
[18:30:04] <Epsilon-Auriga_> turns out my email script was using a variable I changed elsewhere...changed from 1 to whatever over to 0 to whatever...
[18:30:20] <Epsilon-Auriga_> so the thing was emailling a link to the previous build.
[18:30:32] <Epsilon-Auriga_> drove me nuts for most of two days trying to figure that one out.
[20:19:22] <ferdna> need something like this:
[20:19:24] <ferdna> https://www.sparkfun.com/products/11862
[20:19:27] <ferdna> but for NFC
[20:47:45] <ferdna> found one...
[20:48:04] <N2TOH> for what is the need?
[21:46:07] <ferdna> N2TOH, i just wanted to make a nfc reader... but i found some in digikey...
[23:02:17] <DarkSector> Do I need to connect resistors from ICSP headers to the individual pin on the ATTIny2313?
[23:10:16] <N2TOH> for what?
[23:44:30] <DarkSector> Uh for the ISP MK II programmer
[23:44:34] <DarkSector> sorry
[23:44:59] <DarkSector> N2TOH ^
[23:46:05] <N2TOH> ah
[23:46:36] <N2TOH> I'd like to know what it would take to build a programmer that can do the fuse bits
[23:46:43] <DarkSector> Well I found out that Arduino http://arduino.cc/en/uploads/Main/arduino-uno-schematic.pdf doesn't use it so it's cool
[23:47:50] <DarkSector> But using ATTiny2313, can PORTD be used as digital pins as well as Serial (Rx Tx)?