#avr | Logs for 2013-07-21

Back
[06:23:48] <mr_boo> my avr project is derived from this one http://www.scienceprog.com/avr-dds-signal-generator-v20/
[06:24:12] <mr_boo> my array looks the same as his http://pastebin.com/D4Y6fXhJ
[06:24:50] <specing> pastebin.com....
[06:24:50] <mr_boo> and the routine is taken from his project with PORTA replaced with PORTB http://pastebin.com/B2YVaPZt
[06:25:23] <mr_boo> why does my ATtiny2313 output other stuff than 0x00 and 0xff when outputting a square wave?
[06:26:13] <mr_boo> it outputs the right data most of the time but other data pass through the output
[06:26:22] <mr_boo> his square wave looks tidy
[06:26:39] <mr_boo> it is deeply unfair
[06:54:16] <twnqx> eh
[06:54:25] <twnqx> a table
[06:54:49] <twnqx> that is basically out = (in & 0x80)?0xff:0x00
[06:54:51] <twnqx> wow.
[07:04:03] <mr_boo> still learning how to write inline assembler code
[07:06:05] <specing> rofl @ that table
[07:06:27] <specing> mr_boo: what does inline assembly have to do with that table?!
[07:06:48] <twnqx> well, he can use arbitrary functions that way
[07:06:53] <mr_boo> i'm using a routine to output the table data to a port
[07:09:18] <twnqx> is there a particular reason to use asm here?
[07:10:01] <mr_boo> it takes a certain number of clock cycles to output a sample
[07:10:08] <twnqx> it a
[07:10:31] <twnqx> lso takes a certain amount of clock cycles in the function around it, since this function outputs exactly one byte
[07:10:43] <mr_boo> the function is a loop actually
[07:10:57] <mr_boo> so passing parameters and stuff only happens in the beginning
[07:11:46] <twnqx> i am not sure i am just so clueless in asm
[07:12:10] <mr_boo> do you know how i can tell the compiler to use an arbitary register?
[07:12:18] <twnqx> or if the parameter names are so badly chosen
[07:12:47] <twnqx> but that looks to me like it would wrap all through the 128kB theoretically addressable space, not only the 256 byte of the table?
[07:13:22] <twnqx> adc %A3, %2 <- and what is %A3 even=
[07:13:28] <twnqx> (i really never did avr asm)
[07:14:08] <twnqx> that uses r18/r19 as some for of 16bit counter
[07:16:45] <mr_boo> %A3 is a parameter
[07:18:09] <twnqx> i kind of thinkfrom the syntax that it must be a register
[07:18:13] <twnqx> but well
[07:18:26] <twnqx> i honestly don't understand the function
[07:18:31] * twnqx goes back to video encoding
[07:41:28] <mr_boo> "DDS Signal tables has to be placed in flash sections where address starts with 0xXX00"
[07:41:56] <mr_boo> will this happen automatically with this? static const __attribute__((__progmem__)) uint8_t square [256]
[07:46:27] <OndraSter_> no
[07:46:46] <mr_boo> then this is the most probable cause to why my program doesn't work
[07:46:55] <mr_boo> thanks OndraSter_
[07:47:09] <OndraSter_> look for the world align
[07:47:13] <OndraSter_> somewhere.. on the internet
[07:47:50] <mr_boo> heh?
[07:48:00] <OndraSter_> ok, in gcc :P
[07:48:02] <OndraSter_> docs
[07:48:03] <OndraSter_> avr-gc
[07:48:05] <OndraSter_> avr-gcc
[07:48:11] <OndraSter_> avr-gcc docs
[07:48:59] <mr_boo> the guy seems to have done something in a so called makefile
[07:49:34] <mr_boo> i was hoping one could involve an attribute directly like __attribute__(0x100) or something like that
[07:49:47] <specing> OndraSter_: that escalated...slowly
[07:51:09] <OndraSter_> mr_boo, with the align (I do not know the __attributte__ ((aligned)) structure from top of my head) you set on which boundary you want to align the data
[07:51:18] <OndraSter_> in this case you want to align it on a flash page
[07:51:31] <mr_boo> makes sense
[07:51:34] <OndraSter_> so the routine does not have to increase two registers, but only one
[07:51:49] <mr_boo> i do get the idea
[07:52:07] <OndraSter_> (which is weird, LPM Z+ should do the trick just fine.. or it cannot do on LPM?)
[07:53:48] <RikusW> LPM Z+ does exist
[07:54:15] <mr_boo> hope this was the cause to the problems
[07:54:25] <mr_boo> if its not then i'm screwed
[07:54:56] <mr_boo> that code he has written works for him then it should for me
[07:55:34] <mr_boo> makes perfectly sense that each table needs its own page for the algorithm to be effective
[07:56:06] <OndraSter_> well it would have to use DMA to be properly effective, but regular mega has no DMA :P
[07:56:38] <mr_boo> well 9 clock pulses per sample is acceptable
[07:56:47] <OndraSter_> at 20MHz core?
[07:56:56] <mr_boo> i'm only running at 11MHz
[07:56:59] <OndraSter_> oh
[07:57:03] <OndraSter_> that's barely 1 MSPS
[07:57:17] <mr_boo> yep but i'm not gonna use supersonic freqs
[07:57:26] <OndraSter_> well with 1MSPS you can do few kHz sine tops
[07:57:38] <OndraSter_> in order for it to be clean
[07:57:45] <mr_boo> yup
[07:58:07] <mr_boo> million thanks buddy
[07:58:15] <OndraSter_> does it work now?
[07:58:23] <mr_boo> haven't tried it yet
[07:58:30] <mr_boo> i'm praying that it will
[09:30:25] <OndraSter_> BJfreeman, has Valve asked you about your next Half Life episode yet?
[09:30:30] <OndraSter_> I mean, WE CAN'T WAIT MUCH LONGEr
[09:30:34] <OndraSter_> the Combine will take over!
[09:30:39] <OndraSter_> if we do not get new HL
[09:30:46] <OndraSter_> :<
[09:30:57] <OndraSter_> (I know you are BJfreeman and not GFreeman, but close enough)
[09:33:10] <antto> he could be the G-Man tho
[09:34:00] <OndraSter_> :o
[09:34:10] <OndraSter_> do you think that the G-Man's surname is Freeman as well?
[09:34:14] <OndraSter_> CAN HE BE GORDON'S FATHER?!
[09:34:34] <OndraSter_> it would be great lol. End of HL3 (HL2 EP3, HL2 EP2 PART2?) "Gordon, I AM YOUR FATHER"
[09:34:34] <antto> "phhhh ahhhhh. I am your father.."
[09:34:36] <OndraSter_> "NOOOOOOOOOOOO"
[09:35:02] <RikusW> *luke :-P
[09:35:08] <OndraSter_> but this is Gordon Freeman
[09:35:10] <OndraSter_> not Luke Freeman
[09:35:53] <RikusW> OndraSter_: seen the Ape With AK-47 vid on youtube yet ?
[09:36:14] <OndraSter_> aye
[09:36:27] <RikusW> seems its gone viral
[09:36:32] <OndraSter_> it is fairly old
[09:36:38] <OndraSter_> I remember seeing it years ago? months ago?
[09:37:06] <RikusW> I saw it yesterday ;)
[09:37:13] <RikusW> seems its posted 2 years ago
[09:37:28] <RikusW> how stupid can people be ? :-P
[09:37:34] <OndraSter_> even more than this
[09:38:09] <RikusW> next thing they'll be handing it a nuke :-D
[09:38:19] <OndraSter_> so my brother has got here his (supposedly not.. yet) gf... with her daughter. And as I went out of my room I heard the classic (90s?) disco(?) "help me mr. dick I need your..." whatever it goes :D
[09:38:44] <RikusW> heh
[09:39:05] <OndraSter_> so I went back into my room and turned my volume a bit higher
[09:39:46] <OndraSter_> because speakers are asking to be played loud
[09:40:06] <RikusW> is the daughter too young for you ? ;)
[09:40:13] <twnqx> nothing wrong with 90s eurodisco!
[09:40:27] <OndraSter_> well since my brother is 26
[09:40:30] <OndraSter_> the (not yet) gf is 25
[09:40:32] <OndraSter_> then yes
[09:40:34] <OndraSter_> haha twnqx
[09:40:40] <OndraSter_> sure, but not in the house.. this early..
[09:40:51] <twnqx> half past four in the afternoon here
[09:41:01] <RikusW> same here
[09:41:05] <OndraSter_> same here.
[09:41:13] <OndraSter_> 21:00+ required
[09:41:17] <twnqx> lol
[09:41:18] <OndraSter_> on a party
[09:41:19] <OndraSter_> not at home.
[09:41:26] <twnqx> and enough alcohol :P
[09:42:00] <OndraSter_> aye
[09:42:02] <OndraSter_> a LOT of it
[09:42:06] <twnqx> three more clips to encode for this set...
[09:42:07] <OndraSter_> still have got half of my whiskey here
[09:42:22] <twnqx> just one more hour
[09:42:24] <twnqx> sigh
[09:42:56] <OndraSter_> you could use small rendering farm :P
[09:43:13] <OndraSter_> buy 10k AVRs and hook 'em together!
[09:43:17] <OndraSter_> lol
[09:44:02] <twnqx> would still be far slower than what i use...
[09:44:18] <twnqx> i could use one or two more 4770ks
[09:45:08] <OndraSter_> dammit, why do routers that I have got at home (cheap stuff) use parallel CFI-commands flash chips and not common SPI ones?
[09:45:18] <OndraSter_> who is supposed to hack all the pins?
[09:45:27] <OndraSter_> to dump the raw flash.. and write your stuff there
[10:04:52] <megal0maniac> You got unlucky
[10:05:31] <twnqx> use jtag instead
[10:06:26] <twnqx> dir
[10:08:49] <megal0maniac> Or get a different router :)
[10:09:26] <megal0maniac> I'm stacking coins on the heatsink to draw more heat away. I'm using my dockstar as a build machine, it's never worked this hard :P
[10:09:50] <twnqx> my desktop's cpu is at 72°C
[10:10:41] <megal0maniac> This one is probably close. It's fanless
[10:11:33] <theBear> i hope they pure copper coins
[10:12:41] <twnqx> i have this somewhat larger fan on
[10:12:45] <twnqx> http://www.alpenfoehn.de/index.php/de/produkt/cpu-kuehler/10-cpu-kuehler/8-matterhorn-pure
[10:13:24] <twnqx> and i could really use more heat dissipation power than that has :(
[10:13:29] <theBear> what kinda fucked up processor you got
[10:13:35] <twnqx> 4770K
[10:13:52] <theBear> what's that in words ?
[10:14:10] <twnqx> intel haswell quadcore+hyperthreading, running at 4ghz overclocked
[10:14:33] <twnqx> with constant 100% load on all cores for a few hours now
[10:14:54] <theBear> yeah well, that's a lot of cores and a lot of overclock, and that ain't a BIG cooler
[10:15:08] <twnqx> not? i have ~3mm left in my case
[10:15:16] <megal0maniac> Water cooling
[10:15:29] <theBear> it's not about outside dimensions
[10:15:40] <theBear> and if it's that close to the case it's probably not working properly
[10:15:44] <twnqx> surface is all that matters
[10:15:54] <twnqx> 3mm on top
[10:16:03] <twnqx> that's not where the heat goes
[10:16:15] <twnqx> 120mm fan sucking air in
[10:16:22] <twnqx> ~8cm gap
[10:16:30] <twnqx> 120mm chassis fan to suck the air out
[10:16:38] <twnqx> nah, probably less
[10:16:59] <theBear> is it getting fresh air or hot air from all the hds and other shit in the case ?
[10:17:35] <twnqx> there's another 120mm fan to suck cool air in which then goes by the hdd to the gpu and cpu
[10:17:41] <megal0maniac> 100% pure
[10:17:43] <megal0maniac> 100% performance
[10:17:44] <mr_boo> is there a way to declare variables and arrays on certain memory locations in gcc?
[10:17:51] <twnqx> no
[10:17:58] <megal0maniac> 100% alphenfon? :)
[10:18:12] <twnqx> theBear: it sits at 31°C idle with 28°C room temperature
[10:18:20] <twnqx> so i think the effcientcy is not that bad :P
[10:18:36] <megal0maniac> *alpenföhn
[10:19:01] <theBear> damn, howm any watts you think it's doin at that overclock ?
[10:19:14] <twnqx> should be around 110-120
[10:19:19] <twnqx> should measure it :P
[10:19:40] <megal0maniac> Max TDP is 84w
[10:19:48] <theBear> max tdp isn't overclocked
[10:19:58] <twnqx> at 4.3ghz it went into throttling regions
[10:20:11] <megal0maniac> But max freq is 3.9ghz already
[10:20:21] <twnqx> turbo works only on one core load
[10:20:32] <twnqx> it won't go that far with 8x 100% :P
[10:21:11] <twnqx> i think it would limit to 3.5ghz at this load normally
[10:22:51] <twnqx> i think i should ask alpenföhn to make a 100% copper version of this cooler
[10:23:02] <twnqx> or graphene :3
[10:24:39] <megal0maniac> Put coins on it :)
[10:25:00] <Amadiro> wasn't there some bug with haswell that made it run unnecessarily hot
[10:25:07] <Amadiro> or did they already make a patch for that or whatever
[10:26:10] <mr_boo> i'd like to specify the address location directly since avr studio regenerates the makefile
[10:28:15] <Amadiro> hm, looks like that may have been more of a mainboard issue
[10:28:32] <twnqx> they moved the voltage regulators into haswell
[10:28:41] <twnqx> which makes it run hotter due to extra losses
[10:29:03] <Amadiro> ah.
[10:29:05] <theBear> seriously ? that's a fucking stupid idea
[10:29:23] <megal0maniac> Agreed
[10:29:44] <specing> its not
[10:29:51] <Amadiro> Maybe they don't trust the mainboard producers?
[10:29:56] <specing> now they can control voltages per core
[10:30:21] <Amadiro> That sounds like it should be possible otherwise as well.
[10:30:40] <specing> nope, the whole chip ran at the outside VRM voltage
[10:30:52] <twnqx> they even do it sub-core
[10:32:31] <theBear> they could do it on the mobo too, just seperate the power pins
[10:32:34] <mr_boo> do you know if this will automatically point to flash memory? const uint8_t sinewave[] __attribute__ ((at(0x3A00))) = {
[10:33:09] <mr_boo> does 0x3A00 by hardware mean flash memory location?
[10:36:11] <mr_boo> maybe it could be device dependent
[10:36:41] <twnqx> there is no common memory address between flash and ram
[10:36:53] <twnqx> there is address 0x0000 at flash, which is different from 0x0000 at ram
[10:38:18] <mr_boo> i see
[10:41:47] <mr_boo> do you think the guy chose 0x3A00 for the data to give room for the program code which i assume is at the beginning of the flash memory?
[10:43:31] <theBear> i thought regular variables like that were ram, i forget how to put const stuff in flash tho
[10:44:30] <mr_boo> it is no challenge to do so in assembler
[10:44:52] <mr_boo> can't see why the c compiler shouldn't feature a certain flash location for data
[10:45:19] <theBear> well it's no challenge in c, you just gotta remember the right command/syntax, and i ain't programmed avr in many years cos of a series of bullshit in real life
[10:45:29] <theBear> an ongoing series of increasingly bullshitty bullshit !
[10:47:34] <twnqx> there's no point doing it in C unless you want alignment
[10:48:09] <twnqx> e.g. you could skip the the adc instruction if your 256byte table is located at 0xXX00
[10:48:14] <theBear> oh, i didn't mean a specific location, i jsut meant getting stuff like tables and constants into flash instead of ram
[10:49:04] <mr_boo> seems like this command works in c "const uint8_t squarewave[] __attribute__ ((__progmem__)) __attribute__ ((at(0x3B00))) = {"
[10:50:29] <mr_boo> however the addresses are taken from another device ATmega16 which has more flash than my ATtiny2313
[10:50:43] <mr_boo> i'm gonna have to change that probably
[10:51:41] <theBear> well that ain't gonna help, don't jus cut and paste crap you don't understand from different procs :)
[10:52:16] <twnqx> do you even have enough flash to go up there :P
[10:52:35] <mr_boo> the tiny has 8k i think
[10:53:32] <mr_boo> i should go below 0x2000 it seems
[10:54:11] <bitd> Did you not read what theBear wrote?
[10:54:27] <mr_boo> he is right
[10:54:46] <mr_boo> that's why i consider this
[10:54:47] <theBear> damn i'm good !
[10:55:19] <mr_boo> apart from some things chunks of code can sometimes under certain conditions be used on other devices
[10:55:56] <mr_boo> there is no reason for example why the accumulator algorithm code shouldn't work with my device
[10:56:48] <antto> you sure you need a table for a square wave?
[10:56:49] <theBear> well there might be, that's why you - what i already said !
[10:57:05] <theBear> lol, table for a squarewave ? hehe, what you got like 256 or 1024 samples ?
[10:57:20] <mr_boo> antto: it will have several waveforms including square
[10:57:24] <theBear> i hope it's generated and not recorded froma real one :)
[10:57:43] <antto> what, is it bandlimited?
[10:59:03] <theBear> context !
[10:59:38] <mr_boo> i suspect that the compiler doesn't get const uint8_t squarewave[] __attribute__ ((__progmem__)) __attribute__ ((at(0x0100)))
[10:59:44] <mr_boo> it is a souble attribute
[10:59:50] <mr_boo> *double
[11:03:00] <mr_boo> this is just amazingly frustrating
[11:09:04] <mr_boo> the compiler says the "at" directive is ignored :(
[11:09:25] <twnqx> really, why do you bother?
[11:09:50] <mr_boo> since the algorithm doesn't work if the start address isn't 0xXX00
[11:09:55] <theBear> why you care where they land ? just make sure they in the right flash/mem etc
[11:10:18] <theBear> let the compiler handle addresses, you don't need to know about them at all
[11:10:23] <mr_boo> the program outputs other than 0x00 and 0xff for a squarewave for example
[11:10:48] <mr_boo> i believe it has to be due to the compiler setting the data at an uneven address location
[11:11:15] <mr_boo> the author even states that ../pmdds.c:62: warning: 'at' attribute directive ignored
[11:11:57] <mr_boo> he uses a makefile with names but avrstudio autogenerates the makefile
[11:12:10] <theBear> wtf ? addresses don't matter if data is wrong, wtf does even have to do with it ? just don't use at
[11:12:11] <mr_boo> this is why i'd like to directly specify locations
[11:12:44] <mr_boo> the data is right but the starting address must line up on a 256 byte page
[11:12:55] <mr_boo> which i don't think the compiler does
[11:13:12] <theBear> why ? why must it ?
[11:13:25] <mr_boo> the algorithm demands it
[11:13:34] <megal0maniac> You have a silly algorithm
[11:13:47] <mr_boo> i get junk data among with the correct data
[11:14:07] <mr_boo> the assembler version has .org 0x100 in the beginning of the tables
[11:14:19] <mr_boo> so if you know the c syntax please let me know
[11:14:32] <twnqx> i am pretty sure you can't fix addresses in C
[11:14:38] <twnqx> you could try with alignment
[11:15:03] <OndraSter_> mr_boo, create section in flash?
[11:15:08] <OndraSter_> and put the data there
[11:15:16] <OndraSter_> for example last two pages of flash
[11:15:35] <mr_boo> OndraSter_: can that be done in the c code or must i mess with the autogenerates makefile?
[11:15:46] <OndraSter_> autogenerates makefile? Atmel studio?
[11:15:50] <OndraSter_> just add new section in project settings
[11:16:02] <OndraSter_> and then do the same in the code, mark it so the data goes there
[11:16:50] <theBear> how the fuck can an algorithm demand memory alignment, that's stupid !
[11:16:51] <mr_boo> gonna try
[11:17:20] <theBear> sounds like you woulda finished this long ago if you just wrote it instead of trying to borrow code everywhere
[11:17:21] <OndraSter_> theBear, I am wondering as well, if it uses LPM Z+ then it can be even across page boundary
[11:17:41] <twnqx> theBear: a 256byte alignment for a 256 memory block would be nice you you don't have to ever increse the upper address pointer and get automatic wrap around on an 8bit cpu
[11:18:04] <theBear> and what's that, a single cycle on avr ? it's not that bad !
[11:18:14] <OndraSter_> http://www.instructables.com/id/ArduinoPhone/ :(
[11:23:02] <mr_boo> oops the tiny has only 2k flash
[11:23:21] <theBear> that's why they call it tiny
[11:23:27] <theBear> that, and the fact it isn't very big
[11:23:34] <mr_boo> but the project settings claims the max address is 0x400
[11:23:38] <theBear> and refer to my original fucking statement, you cut and paste monkey !
[11:23:58] <mr_boo> flash size 0x400
[11:24:15] <mr_boo> 0x400 is 1k only
[11:24:32] <theBear> maybe you shouldn't use stupid avr studio for a start
[11:24:50] <OndraSter_> 0x400
[11:24:53] <OndraSter_> at 16b
[11:25:12] <RikusW> mr_boo: AVR is harvard architechture
[11:25:14] <OndraSter_> theBear, there is nothing wrong with atmel studio
[11:26:08] <mr_boo> RikusW: does that mean that only half the flash is available for instructions?
[11:26:19] <OndraSter_> no
[11:26:19] <RikusW> wikipedia
[11:26:22] <OndraSter_> that you can't read
[11:26:28] <OndraSter_> <OndraSter_> 0x400
[11:26:28] <OndraSter_> <OndraSter_> at 16b
[11:26:30] <RikusW> it means flash and ram is on different busses
[11:26:42] <theBear> OndraSter_, maybe not, i just don't like it, and no i haven't looked at it for well over 5 years to check if things have changed :)
[11:27:00] <OndraSter_> theBear, well, #1 question: how do you feel about visual studio 2010?
[11:27:01] <RikusW> thus the need for LPM/SPM
[11:27:05] <theBear> heh, people get bad at reading when they copy and paste too much
[11:27:09] <mr_boo> still don't get why avr studio believes the flash size is only 0x400
[11:27:18] <OndraSter_> because 0x3ff is the last address
[11:27:23] <OndraSter_> but the bus is 16bit
[11:27:26] <theBear> OndraSter_, i have no idea, but everything with visual in its name last century pissed me off massively
[11:27:35] <RikusW> 0x400 = 1k words
[11:27:42] <RikusW> = 2kb
[11:27:47] <mr_boo> 0x000 to 0x3fff is 1k of space?
[11:27:57] * mr_boo brings the calculator again
[11:28:03] <RikusW> 3FF
[11:28:09] <theBear> it's 1k LOCATIONS
[11:28:24] <OndraSter_> theBear, http://clip2net.com/s/5qAJkS
[11:28:26] <OndraSter_> this is how it looks
[11:28:32] <mr_boo> each location is a word not a byte then?
[11:28:33] <OndraSter_> at least 6.0, haven't upgraded
[11:28:38] <OndraSter_> mr_boo, bingo
[11:28:40] <OndraSter_> READ THE DATASHEET
[11:28:55] <mr_boo> now i'm catching up
[11:29:28] <theBear> that looks very disappointing, and like it wouldn't run on any of my computers
[11:29:47] <OndraSter_> haha
[11:29:54] <RikusW> mr_boo: more confusing still iirc LPM use byte adressing....
[11:30:30] <theBear> i'm quite happy with a text editor and gcc
[11:30:37] <RikusW> any time you're dealing with flash make sure whether its byte or word addresses
[11:32:35] <mr_boo> now the code finally works
[11:32:40] <mr_boo> you guys rule
[11:32:50] <mr_boo> sorry for being so slow in my head
[11:34:30] <theBear> heh, you should be !
[11:34:59] <theBear> next time we won't be so forgiving
[11:37:03] <mr_boo> the conclusion that the alignment was important turned out to be correct
[11:37:48] <mr_boo> i'd say this algorithm is pretty clever
[11:58:57] <vectory> lost my old makefile :( now i dont know what im doing wrong
[11:58:59] <vectory> avr-gcc -g -mmcu=atmega8 $< -o t.elf
[11:59:08] <vectory> seems ok
[11:59:15] <vectory> avr-objcopy -O ihex t.elf
[11:59:31] <vectory> seems ok, too, but there is no new file!
[11:59:50] <twnqx> aren't there like tons of reference makefiles on the web?
[12:00:13] <vectory> yeah, big ones
[12:00:17] <vectory> that i just copied from :)
[12:00:50] <vectory> now it says "avr-objcopy:t.elf: File format not recognized" at least
[12:07:14] <vectory> oh great and now simulavr or dgb gives me a segfault *tableflip*
[12:08:17] <vectory> how else do i gauge how fast a function will run, say division. wanted to avoid to read or even write asm
[12:08:26] <vectory> s/./?/
[12:12:08] <mr_boo> vectory: sounds to me you don't do backups on your projects
[12:12:24] <mr_boo> vectory: honestly i don't either
[12:13:09] <vectory> mr_boo: you could hardly call it a project, but yes
[12:13:29] <vectory> using the long makefile i didnt read, it created elf, hex et al
[12:14:20] <vectory> mr_boo: you should
[12:15:37] <mr_boo> i know
[12:15:47] <OndraSter_> HAHAHA backups
[12:30:27] <twnqx> i have a git repository
[12:30:36] <twnqx> and every now and then i push it to another machine
[12:31:41] <jadew_m> Any idea how toxic is the gas released from an old phone battery?
[12:32:07] <Tom_itx> i wouldn't sniff it
[12:32:48] <Roklobsta|2> avoid said gas at all costs
[12:33:50] <jadew_m> Well, my first concern was to put my protection glasses on, i thought it would explode
[12:34:14] <Roklobsta|2> throw it out the window
[12:34:18] <jadew_m> I did feel the funny smell for a minute or two
[12:34:51] <jadew_m> I put it outside the window, can't throw it, migh hurt someone
[12:34:58] <Roklobsta|2> is it one of those lemon batteries with a lead anode and copper cathode jammed in it?
[12:35:44] <jadew_m> I didn't get a chance to take a better look at it
[12:35:59] <jadew_m> Nit a lemon battery though
[12:36:28] <Roklobsta|2> http://totl.net/Spud/
[12:36:31] <jadew_m> Going back in the room now
[12:36:57] <Tom_itx> tie a rope to your ankle so someone can drag you back out
[12:37:43] <jadew> haha
[12:38:02] <jadew> I was horrified for a bit, I thought it would explode
[12:38:12] <jadew> because it started releasing the gas as I was looking at it
[12:38:25] <jadew> boobie trapped phone
[12:38:58] <jadew> it's not enough that they lock them into a specific carrier, now they release poison gas if you try to open them!
[12:39:00] <Roklobsta|2> what brand of battery?
[12:39:16] <jadew> going to check now
[12:39:27] <Roklobsta|2> it might be powered by burritos.
[12:39:30] <Tom_itx> a james bond battery
[12:39:49] <Roklobsta|2> Mossad battery. It'll blow your head off.
[12:39:58] <jadew> zte
[12:40:02] <jadew> li-ion battery
[12:43:08] <Roklobsta|2> dodgy. a house in melboure caught fire the other week when some Lihiutm batteries went up in smoke while on charge.
[12:43:30] <jadew> http://batteryuniversity.com/learn/article/lithium_ion_safety_concerns
[12:43:48] <Roklobsta|2> given the motherboard capacitor fiasco 10 years ago, i am not surprised.
[12:44:46] <jadew> it appears they have a gas release vent by design
[12:45:03] <jadew> probably mine didn't, or it got covered somehow, that could explain why it swelled up
[12:45:34] <jadew> oh well, time to continue cleaning, I'm glad it didn't blow up
[12:45:47] <Roklobsta|2> lloking at that photo i wonder if the phone was sitting in the sun while charging
[12:46:28] <jadew> it's possible
[12:54:25] <vectory> its like something is trying to tell me i shouldnt try to use an emulator :(
[12:55:19] <Roklobsta|2> always use the real thing
[12:55:29] <theBear> hehe
[12:58:09] <jadew> an emulator that could do both analog and digital wouldn't hurt tho
[12:58:51] <jadew> I think proteus can do it, but you have to pay extra for the avr and pic engines
[13:02:07] <Roklobsta|2> avr is so cheap
[13:02:51] <jadew> yeah, I think the most important part is being able to nicely simulate the analog part and be able to test it while it's interfacing with the digital part
[13:03:34] <jadew> at least that's what would motivate me to use a simulator
[13:04:48] <Roklobsta|2> right, need spice with avr emuation capabilities
[13:05:01] <Roklobsta|2> actually, i wonder..
[13:05:38] <vectory> if it compiles as bad as simulavr, i dont want it :<
[13:05:54] <vectory> no dependencies listed in the INSTALL file. damn them
[13:05:55] <Roklobsta|2> i have used systems in the past that used spice output data.
[13:10:47] <Roklobsta|2> does anyone ever bother changing the PUD in MCUCR from 0 to 1?
[13:23:54] <BJfreeman> only when want ports for input
[13:26:13] <Roklobsta|2> even then that's conditional
[13:27:13] <Roklobsta|2> it PUD=0 you still need to set PORTxn to 1 for the PU to be enabled
[13:27:24] <BJfreeman> depends on uC the 328 the MCUCR handles interupts
[13:27:37] <Roklobsta|2> i only have 1280
[13:27:49] <BJfreeman> that helps :D
[13:28:21] <Roklobsta|2> are the ioport locations and bit values in io registers consistent across avr parts?
[13:29:40] <Xark> Roklobsta|2: No, not really (although there a fair bit of similarity).
[13:30:05] <Roklobsta|2> ok, so getting the right io.h is important
[13:33:14] <BJfreeman> http://www.atmel.com/Images/doc2581.pdf
[13:43:34] <Roklobsta|2> aha
[15:22:20] <megal0maniac> These attacks on Freenode are getting quite vicious
[15:23:47] <Roklobsta|2> who/why?
[15:24:58] <megal0maniac> ddos attacks. Hence all the netsplits
[15:25:20] <megal0maniac> Or at least that's what it's been the last two times
[15:25:26] <megal0maniac> I couldn't even get back online just now
[15:25:32] <megal0maniac> And some damn moroccan hacked my website and put some propaganda crap on it with stupid music
[15:27:51] <Roklobsta|2> how'd he hack it? sql inject?
[15:28:55] <megal0maniac> Not sure. It was a wordpress site, so probably some security hole that was fixed in the latest version. Didn't bother to properly check
[15:29:17] <Roklobsta|2> yay
[15:29:52] <Roklobsta|2> i'll apt-get update m y server i think
[15:30:37] <megal0maniac> Roklobsta|2: These guys: https://www.facebook.com/Dr.Dz.Eroor
[15:32:26] <Roklobsta|2> he must be Danish, going by the name "Errør".
[15:33:32] <megal0maniac> This is what I had: http://fourty2.co.za/
[15:34:57] <Roklobsta|2> drats
[15:34:59] <Roklobsta|2> well, i sorta wish i hadn't opened it
[15:35:00] <Roklobsta|2> script nasties
[15:35:36] <megal0maniac> Tell me more?
[15:35:43] <Roklobsta|2> i suspect
[15:36:11] <megal0maniac> Ah.
[15:36:12] <Roklobsta|2> i dunno, it was doing page title animations and fhnaged the mouse cursor graphic
[15:36:18] <Roklobsta|2> what else?
[15:36:25] <megal0maniac> Music
[15:36:33] <Roklobsta|2> oh i have sound disabled
[15:36:46] <megal0maniac> I don't see the point
[15:36:57] <Roklobsta|2> Now all my centrifuges are going to be reprogrammed
[15:37:25] <megal0maniac> I mainly want to see what they did, because I couldn't find any modified files, but upgrading wordpress made it go away
[15:37:42] <Roklobsta|2> maybe a redirect
[15:39:03] * megal0maniac shrugs
[15:41:23] <megal0maniac> I'm off to bed. Holiday is over, university tomorrow :)
[15:41:32] <megal0maniac> Goodnight
[16:31:34] <OndraSter_> lol school during holiday
[17:24:30] <Roklobsta> quick, what's a command line utility tha will convert a binary file or test file into an array of hex values suitable for compiling in c?
[17:25:10] <OndraSter_> hexvalues
[17:25:14] <OndraSter_> what
[17:25:17] <OndraSter_> compiling in c?
[17:27:03] <specing> Roklobsta: hexdump
[17:36:12] <Roklobsta> i just want to take a text or bin file and have it turn into "char myarray[] = {0xde,0xed ...}; or ={'D','E','A','D'...};
[17:36:24] <Roklobsta> oh hexdump will cool
[17:36:26] <Roklobsta> ?
[17:36:33] <Roklobsta> must run
[17:36:54] <OndraSter_> well for this kind of stuff I simply whip up my program... takes maybe 5 mins tops
[17:37:01] <Roklobsta> mmm
[17:37:02] <OndraSter_> but I use C# which not many people like here :D
[17:37:11] <Roklobsta> i could have done that by now. ;)
[17:40:54] <RikusW> hexdump -e '60/1 "0x%02X ""\n"'
[17:41:32] <specing> RikusW: need commas :D
[17:41:45] <RikusW> hexdump -e '60/1 "%02X, ""\n"'
[17:42:06] <specing> now we need the 0x back
[17:42:22] <RikusW> put in yourself ;)
[17:42:47] * specing puts it in like a man
[17:43:12] <specing> and 16/1 is kinda prettier
[17:43:25] <specing> also +5 for figuring out the format syntax
[18:01:56] <RikusW> :)
[20:29:33] <Roklobsta> it was faster for me to write my own hexifyer than read hexdump's manpage
[20:32:32] <vectory_> lol. expecting the same about simulavr, but then thats on a different kind of level i think
[20:33:19] <vectory_> btw, shouldnt it be emulavr?
[20:33:24] <Roklobsta> it sounds like you need a simulator that can take VHDL style stimulus.
[20:34:23] <Roklobsta> that's probably a nice project for an undergrad, clock accurate avr simulator with flexible analgue and digital stimulus.
[20:34:32] <Roklobsta> i'd do it
[20:36:23] <vectory_> i just need cycle accurate emulation to gague execution time
[20:36:30] <Roklobsta> at least with old school vhdl you'd write your vhdl code and test it with another pile of vhdl
[20:36:56] <Roklobsta> and it'd meant to be nanosecond accurate
[20:37:08] <vectory_> and realtime!
[20:37:17] <Roklobsta> on a PentiumII? Hardly
[20:37:27] <Roklobsta> I am talking The Olden Days
[20:39:08] <vectory_> i wasnt even sure vhdl models analogue signals. i gather it does, does it?
[20:45:09] <Roklobsta> yes
[20:46:42] <Roklobsta> it's actually meant to be a specification language (meaning it handles analgue and any kind of SI unit you can imagine well) which happens to work out great for 'specifying' an FPGA internals.
[20:47:31] <Roklobsta> The Ameircans invetned VHDL which is popular in Europe, and the Europeans invented Verilog which is popular in the USA.
[20:53:42] <Tom_itx> funny that
[20:54:17] <Roklobsta> I'll leave it to you guys to bitch about which one is better
[20:57:10] <Roklobsta> malzeit