#avr | Logs for 2013-06-20

Back
[00:07:33] <Roklobsta> hmmm, how can I stop the USART spittng out some garbage when I start up my UART application?
[00:09:21] <Roklobsta> I always get a + on the terminal when it starts.
[01:43:26] <caesius> can I still #include <avr/io.h> in assembly source if I'm compiling with avr-as?
[01:43:47] <caesius> rather than avr-gcc
[03:00:22] <Tom_itx> caesius there are header files in studio you use with asm
[03:04:18] <caesius> Tom_itx: I'm just using text editor+avr-gcc+binutils
[04:33:27] <antto> "Page Size: 128 words" <- what does this mean?
[04:35:25] <antto> word = 2 bytes?
[04:51:22] <Roklobsta> 256 byte
[04:51:27] <Roklobsta> 2x128
[05:03:32] <antto> ahum
[05:03:55] <antto> Q: if you're running the firmware - can you "jump" to the bootloader?
[05:18:09] <RikusW> antto: yes
[05:18:23] <RikusW> two ways, use the WDT to reset the AVR
[05:18:31] <Roklobsta> or jmp
[05:18:35] <RikusW> or just jmp to address
[05:20:04] <RikusW> using WDT thats assumes the BOOTRST fuse is set
[05:20:45] <RikusW> antto: I've even called functions in the bootloader code from normal fw
[05:21:00] <RikusW> just put a jump table right at the end
[05:22:48] <Roklobsta> why did you need to call boot loader functions? sort of like bios calls?
[05:26:06] <antto> BOOTRST is set i guess, cuz when powered up, the thing goes thru the bootloader, which checks for a specific condition, and depending on that either remains waiting or jumps to address 0
[05:31:12] <antto> can you read the fuses when you're in the firmware?
[05:31:23] <antto> ..to determine the address of the bootloader ;P~
[05:34:01] <RikusW> Roklobsta: yes, my USB CDC stuff is in the bootloader
[05:34:12] <Roklobsta> handy
[05:34:18] <Roklobsta> cdc being serial
[05:34:22] <Roklobsta> generic serial
[05:34:24] <RikusW> antto: you can read but not write fuses
[05:34:40] <Roklobsta> did you use lufa or roll your own
[05:34:51] <RikusW> my own 800 byte asm one
[05:35:28] <Roklobsta> cheecky
[05:35:53] <Roklobsta> is this using an avr that has some native usb bits?
[05:36:27] <Roklobsta> or a complete roll your own two pin special?
[05:49:03] <RikusW> m32u2
[05:49:16] <RikusW> https://sites.google.com/site/megau2s/
[05:49:39] <RikusW> Like Bear Grylls ? https://www.youtube.com/watch?v=1MI5Fklo21Q
[05:53:56] <Roklobsta> aha is your bootloader closed source?
[05:54:52] <theBear> i think he's a justifiable sissy !
[06:00:22] <RikusW> Roklobsta: USB CDC is on my site in the JTAG source
[06:00:39] <RikusW> but for now the bootloader is closed
[06:01:00] <RikusW> (actually shouldn't tell you the CDC is in the JTAG code :-P )
[06:02:04] <RikusW> theBear: the above link makes fun of Bear Grylls
[06:02:42] <RikusW> so will theBear Grills Bear Grylls if he gets hold of him ? :-P
[06:05:19] <theBear> aha, it's qeued up (damn, how do you spell queue? hmm, that time looked better :)
[06:06:07] <theBear> and yeah, i'd make fun of him, then think of a creative way to shame (and maybe cripple him, or at least ruin his pretty face,) then make fun of him some more :)
[06:06:53] <RikusW> heh
[06:06:58] <theBear> orright then.... http://wpc.556e.edgecastcdn.net/80556E/img.news/NEEn3nStBRdYIG_1_2.jpg vs http://testing.rememberit.com.au/pics/building/IMAGE_00198.jpg here's my pair of links from last night... i aint got no pretty camera-friendly face, no sir :)
[06:07:29] <theBear> apparently most people don't notice why i paired them, it's the eyes if you wondering
[06:08:03] <RikusW> thats you ?
[06:08:50] <theBear> and while we at it, i was drunk a few days ago, so time to freshen up the haircut, as it always is wehn i find myself drunk and relatively flexible during the daytime .... http://testing.rememberit.com.au/pics/bearhead/
[06:09:03] <theBear> yep, the one that aint in movies
[06:09:34] <theBear> also, i'm usually a LITTLE whiter than that, when i haven't been pulling cables in a filthy warehouse all day
[06:10:03] <RikusW> can think
[06:10:37] <theBear> can think ? well that's probably an advantage
[06:10:43] <theBear> keep it up !
[06:11:46] <RikusW> Working on a farm gets you dirty too
[06:11:46] <theBear> i aint a big photo-shower, but it's so seldom i actually get around to putting ANYTHING on the wide wide world of web, that when i do i try to use them a few times before i forget them :-)
[06:11:58] <theBear> there's no denying it !
[06:13:02] <RikusW> If you're careful its possible te get less dirty...
[06:14:34] <RikusW> wearing overalls andd gumboots helps too
[06:16:23] <theBear> yeah, but that was an extreme situation, couple hundred meters from international runway, so constant supply of carbon-dust, was a 'personal' kinda project, so didn't wanna waste time, and there was a STUPID amount of stuff both to remove and to replace, most of it in places noone had gone for years.... http://testing.rememberit.com.au/pics/building has a shitty-gallery of random pics i took during that per
[06:16:23] <theBear> iod if yer interested in anything from building to ancient power boards to light-construction ultra-soundproofed/isolated studios to err, some other stuff
[06:17:12] <theBear> might be a little of 'our' custom designed accoustic treatments towards the end too, and probly somehalf built speakers and stuff
[06:18:05] <theBear> i did the maths/testing and other dude well, basically supplied the tools and it turned out in the end,a whole lot of bullshit and lack of character
[06:19:37] <theBear> but taht was the studios that bear built, from the ground (well slab) up, did the maths, designed and built the avr-based remote-control-mixer-panels, specced and 90% installed all the electricals, etc etc, too bad the ass ran it into the ground
[06:20:13] <RikusW> thats unfortunate...
[06:20:49] <theBear> even ran them 100+hours/week for the first couple years or so after opening, but i won't say why i had to run the place on my own bear-shoulders, that'd just be bitching at things i've long since come to accept :-)
[06:20:56] <cart_man> theBear: Hi
[06:21:00] <cart_man> RikusW: Hi
[06:21:14] <RikusW> hi
[06:21:20] <theBear> hi cart_man, dude , sup ?
[06:21:46] <cart_man> Not much sitting at home coding some AVRs
[06:21:55] <cart_man> Motor TV project
[06:21:56] <theBear> dammit ! 2nd coffee i let go cold today, at least it's only a few degrees under lukewarm, not 4 hours past this time :)
[06:22:16] <cart_man> Hate cold coffee though
[06:22:23] <cart_man> just made my second
[06:26:44] <cart_man> Have to drive a motor with an Arduino >.< seriously not making my day
[06:27:03] <cart_man> Think the Arduino Uno is running at 2Mhz
[06:29:15] <theBear> sun has already gone down adn i still haven't finished this 2nd one, dammit ! i'm way behind the 8ball today
[06:36:05] * RikusW had 0 cups of coffee the last month :-P
[06:38:28] <theBear> speaking of 0 cups of, i wanna go buy a case of $4 shitty (but surprisingly drinkable) wine up the corner shop to last hopefully most of this fortnight, but my lend-a-car is awol, it's all gone fubar ! i gotta get my jar-necks and redfaces and get outta here before the whole operation goes south !
[06:39:58] <antto> what does "something: ..." in the Makefile mean?
[06:43:34] <twnqx> something is a target (something that is to be made), and ... are the prerequisites it's made from
[06:44:19] <antto> ahum
[06:50:56] <theBear> heh, make something && make something_install
[06:51:29] <antto> recompiling a bootloader, i get undefined references to __eerd_byte_m1280
[06:53:28] <Roklobsta> rikus: functiony cpu's are good like that. i endorse what you have going on there.
[06:54:06] <Roklobsta> you used to be able to buy modem chips which were just dsp's with a closed rom, so more like a functional block.
[07:18:22] <Roklobsta> has anyone ever flash their avr more than 10000 times (ie started getting program failures from too many cycles?)
[07:19:03] <Tom_itx> never gonna happen
[07:19:03] <antto> oh, clean fixed it
[07:19:08] <antto> \o/
[07:21:25] <theBear> even with my style of 'fine-tuning' certain things thru a combination of laziness at proper debugging and repeatedly fine-tuning/reprogramming code, i never managed to break a few hundred... tho programs that modify the flash as part of 'normal' operation it's worth keeping in mind, if the application/project is likely to run a LONG time
[07:24:45] <twnqx> cat .build
[07:24:45] <twnqx> 1544
[07:25:03] <twnqx> 1544 successful compile runs on this project... and likely <1000 flash runs
[07:59:22] <Roklobsta> tom: maybe while doing a complex roject?
[07:59:26] <Roklobsta> project
[08:02:53] <RikusW> I think the retention time shortens
[08:45:57] <braincracker> h
[08:47:07] <braincracker> bored? solve this? http://en.wikipedia.org/wiki/File:Extrapolation_example.svg ( http://en.wikipedia.org/wiki/Extrapolation )
[08:49:21] <vectory> not bored enough
[08:51:50] <vectory> i read /ar7
[08:52:03] <vectory> wrong channel
[09:00:38] <braincracker> was exploring interpolation methods for use in mcu
[09:01:24] <braincracker> for example, temperature calibration using an NTC resistor
[10:40:16] <scipy53> having trouble with TWI code ... when I am checking the TWI status registers, the data sheet often says to use values like START or MT_SLA_ACK
[10:40:21] <scipy53> what are these values?
[10:40:31] <scipy53> For example: while((TWSR & 0xF8) != START);
[10:40:53] <scipy53> waits until ack received
[10:41:01] <scipy53> post sending start command
[11:02:45] <scipy53> Found the answer, datasheet confused me here
[11:18:25] <braincracker> yeaa http://paulbourke.net/miscellaneous/interpolation/
[12:36:14] <antto> how do you jump to an address?
[12:36:39] <antto> i found this: asm volatile ("ijmp" :: "z" (0x1F000)); but avrgcc complains
[12:42:18] <specing> antto: that it can't fit a 20-bit number in a 16-bit register? lol.
[12:43:21] <antto> "impossible register contraint" <- whatever that means
[12:43:54] <braincracker> life is hard
[12:45:15] <specing> antto: why not putting the address directly into asm?
[12:45:53] <antto> i don't know nothing about asm
[12:46:41] <antto> i'm trying to jump to the bootloader from within the firmware
[12:46:57] <antto> i was told it's possible
[12:51:29] <specing> it is
[12:52:46] <specing> antto: you are just bumping into the joys of gnu inline assembly
[12:54:55] <antto> found something else.. goto *0x1F000;
[12:57:47] <antto> seems to work \o/
[13:01:14] <Essobi> WEEEEE.
[13:30:40] <jadew> http://vplay.ro/watch/794ds7g7
[13:40:25] <vectory> *seems to compile
[13:40:30] <vectory> so far :P
[13:58:34] <vectory> CapnKernel: ping
[14:22:53] <braincracker> http://www.youtube.com/watch?v=DIce8OkqrfA :) at 0:37 he used up at least one lives
[15:24:56] <scipy53> I am trying to write some code to read from a TWI device, but when sending the address slave, I keep getting the "no acknowledgement". Any basic diagnostics I should run? Here is my code: http://pastebin.com/3q1zf7ze
[16:13:47] <scipy53> anyone?
[16:14:55] <Tom_itx> http://tom-itx.dyndns.org:81/~webpage/avr/i2c/
[16:15:05] <Tom_itx> master, no slave
[16:21:28] <scipy53> thanks Tom_itx
[19:57:58] <Horologium> Roklobsta, if you reprogrammed it every 5 minutes, 8 hours a day, it would take you over 3 months to kill it.
[19:58:28] <Roklobsta> ha yeah I am just wondering. shoulda done the maths 1st
[19:58:41] <Roklobsta> and that's guaranteed 10000 cycles
[19:58:46] <Roklobsta> could be way more
[19:58:50] <Horologium> if you cut it down to 2 hours a day then you get over 400 days.
[19:59:00] <Roklobsta> ok so my AVR is safe
[19:59:10] <Roklobsta> i am doing lots of debugging/program cycles
[19:59:11] <Horologium> I think there was a flash destroyer project that tested just that.
[19:59:36] <Roklobsta> it just *feels* like I have done 100000
[20:00:15] <Horologium> http://dangerousprototypes.com/flash-destroyer-manual/ but that's more an eeprom destroyer.
[20:00:37] <Horologium> which went over 10 million rewrites.
[20:01:12] <Horologium> http://dangerousprototypes.com/2010/06/07/flash-destroyer-dead-at-11-49-million/
[20:02:10] <Horologium> flash is not quite so durable as eeprom though.
[20:02:37] <Horologium> I've yet to have an avr give me verify errors and I've been playing with them for at least 8 years.
[20:03:04] <Horologium> only time I've had one go bad is when I did something stupid like letting 10KV hit one,,,
[20:03:10] <Horologium> surprisingly, it still ran, mostly.
[20:03:59] <Roklobsta> mkay
[20:04:00] <Horologium> but couldn't reprogram it, the ADC stopped responding, and only one of the i/o pins responded to button pushes.
[20:04:15] <Horologium> 10KV jumped an optoisolator.
[20:04:32] <Horologium> it also jumped several other parts on the way to the opto.
[20:05:20] <Horologium> I was trying to make a mini magnetic railgun.
[20:05:36] <Roklobsta> opto is good for 3kV?
[20:05:43] <Horologium> depends on the optoisolator.
[20:06:02] <Horologium> I had a wire burn out and drop from the high voltage side to the medium voltage section.
[20:06:12] <Roklobsta> i tried making a rail gun once, but it was going to be a mains powered "ramset"
[20:06:14] <Roklobsta> FAIL
[20:07:15] <Roklobsta> we had hoped we could make a compact rail gun that would drive a nail into concrete. Alas black powder charges can't be beat for energy density.
[20:07:33] <Roklobsta> what we made was pathetic but it was fun
[20:08:42] <Roklobsta> and we only dealt with charging up caps to 240V. Learned much later one needs many kV
[20:11:31] <Roklobsta> unless there is a super duper development in capacitors and room temp superconduxctors you'll never get an electric version of these: http://www.ramset.com.au/Document/Section/160/Powder-Actuated
[20:12:35] <Valen> Roklobsta: you just need to extend the duration you apply the power for
[20:12:46] <Valen> a motor + spring system could work perhaps
[20:12:54] <Valen> and be much less smelly than powder
[20:13:06] <Roklobsta> but it'd never be as compact as a ramset gun
[20:13:43] <Valen> most tradies I know use butane or air powered nailguns, Presumably because the consumables are cheaper and you don't need to replace them as often
[20:13:43] <Roklobsta> gas and charge powered systems are excellent good for the size.
[20:13:49] <Roklobsta> right
[20:13:59] <theBear> by the time you get to a few kv things like optos are best rated as 1000v/mm/avg humidity in extreme cases, and most of them don't have THAT much distance between the low and high sides, letalone the high switching pins
[20:14:09] <Roklobsta> the butane ones I notice have CPU fans in them. ;)
[20:15:00] <Valen> I'm just saying an electric nailgun isn't an instant fail, particularly if you can make it more reliable
[20:15:08] <Roklobsta> thebear: yeah, make your own opto with a big gap, maybe an light duct and led/phototrannie
[20:15:16] <theBear> Valen, 'cos electric ones suck and overheat and cook the coil in no time, and the butane ones are hopelessly unreliable (yes, even the famous paslodes) after a couple full service/rebuilds worth of use
[20:15:32] <theBear> i been studying weird-optics this week, it's called a light-pipe :)
[20:16:09] <theBear> for reference fender (valve amps, guitar mostly) used to just put a neon and a ldr in a bit of heatshrink for many years :)
[20:16:53] <Roklobsta> mmm, light pipe
[20:16:59] <Valen> theBear: overheating is an implementation issue, not an inherent issue ;->
[20:17:00] <Roklobsta> loys of modem's jave them
[20:17:18] <Roklobsta> overheating is a lack-of-room-temp-superconductor issue
[20:17:20] <Valen> losts of consumer electronics does
[20:17:36] <Valen> electric motors seem to work without overheating
[20:17:55] <Valen> use thicker copper, more volts less amps it'll heat less
[20:18:07] <theBear> Valen, oh, yeah technically, but it's usually due to trying to squeeze high-duty-cycle EXPLOSIVE force into a similar form factor
[20:18:29] <theBear> at least with the few/uncommon electric 'impact' tools i've seen/used
[20:19:39] <Valen> I would suggest a better system would be use the "motor" to pull a spring + hammer back, you can take .25 seconds to do that
[20:19:39] <Valen> then that can actuate at whatever speed you feel like
[20:21:25] <theBear> mmm, certainly makes more sense... like many industry/commercial things i suspect this is one of the situations where the person that designs these things at best uses them occasionally, and almost NEVER has awesome cross-discipline experience/knowledge like many of us <grin>
[20:24:30] <Horologium> here's a design idea for you....big honking springs at either end of a tube...magnet in tube so it can float back and forth between the springs...a coil or three on the tube that can accelerate the magnet weight both directions as it passes...making it go boing boing boing boing faster and faster until it bottoms out a spring on one end far enough to impact an object and force it out.
[20:24:43] <Horologium> lower power coils that just impart energy as it goes back and forth.
[20:25:30] <Horologium> yes, lots of loss on the spring returns and all but would it not give you a way to up the impact force by steadily adding energy in a shorter tube?
[20:25:49] <Valen> it'd vibrate like a mofo in the hand ;->
[20:25:54] <Horologium> true.
[20:25:58] <Valen> worst case the builders wife would be happy lol
[20:25:59] <Horologium> so, it has dual purpose!
[20:27:15] <Horologium> was actually thinking of a bigger version to launch something long distance...the object to be launched held inside the magnetic carrier and released by some signal or other and pass through the center of the spring on one end.
[20:27:30] <Horologium> say, 100 meters long....bouncy bouncy bouncy bouncy zing!
[20:27:52] <Valen> nah, losses would kill that
[20:28:09] <Horologium> ok, cut it down to 1 meter then.
[20:28:39] <theBear> i dunno, sounds inefficient, all that creating and reveresing motion
[20:28:43] <Valen> still call it borderline, spring energy return isn't really that great
[20:28:50] <Valen> something like 80% i thnkg
[20:28:52] <Valen> think
[20:29:06] <theBear> only efficient way i seen something go back and forth is piston/cam drive style
[20:29:17] <theBear> conceptually speaking
[20:29:27] <Valen> also you need to look at their spring rates and such, there is a limit to how fast you can push them
[20:29:34] <Horologium> yup.
[20:29:45] <Horologium> was just a thought that sprang into my twisted little brain.
[20:29:46] <Valen> oh theBear I wouldn't use a straight solenoid either, I'd put a bunch of coils and run it like a linear stepper
[20:29:49] <Horologium> sprang
[20:29:51] <Horologium> sprung
[20:29:54] <Horologium> springed
[20:29:58] <Valen> trolololol ;-P
[20:30:39] <Horologium> somewhere I saw a system that used multiple smaller linear "motors" to generate energy for a larger one.
[20:31:06] <theBear> however you do it, feels like a lot of energy is being wasted
[20:31:22] <theBear> somewhere, like, in a website about a railgun ?
[20:31:37] <Horologium> they would use multiple coils to accelerate the slugs along a long tube then at the end of the tube another larger/denser coil to extract the energy in a short burst.
[20:31:46] <Valen> nah, efficency of that setup should be around 60% from battery to nail
[20:31:51] <Horologium> it was some time ago...guess that's how they do the good ones.
[20:31:55] <theBear> which makes me think, if they can make electronic machine guns that are faster than traditional ones, surely a similar concept can work for nails
[20:32:18] <Valen> you mean railgun or minigun?
[20:32:20] <Tom_itx> nail machine gun?
[20:32:39] <Horologium> m134 gatling gun.
[20:32:41] <theBear> Valen, 60% isn't real good, and way i see it even ignoring the reversing of momentum, that final 'tap' on the nail isn't gonna be real hard
[20:32:46] <Horologium> made by general electric!
[20:33:21] <Valen> My system only has one spring remember, you just stretch it up then hit the nail once
[20:33:31] <Valen> no resonance
[20:33:41] <theBear> railgun re: multiple smaller linear "motors" , adn i dunno what electronic machine guns are called or the details, but i remember hearing STUPID firerates,from memory somewhere in the 50-100/second range
[20:34:07] <theBear> oh, sorry, it's early, only just started paying attention to nicks a couple lines back :)
[20:34:12] <Valen> ;->
[20:34:34] <Valen> I was just saying to reduce heating somewhat, rather than a solenoid run it like a linear stepper
[20:36:03] <theBear> mmm, makes sense in many ways, apart from anything else the 'explosive force' is the spring that has been 'charged' by the motor, like a giant manual-staple-gun, and those suckers always work fine
[20:36:16] <Valen> basically
[20:36:32] <Valen> and the moving parts are mechanically simple at least
[20:36:34] <Horologium> theBear, 6000 RPM on the m134 as I recall.
[20:36:49] <Valen> that'd make some decent gyro forces
[20:36:51] <theBear> i suppose energy-release-wise the approach isn't much different to an air-powered nailgun, which are by far the most reliable and powerful
[20:37:06] <Valen> do they use a spring or fire the piston
[20:37:12] <Valen> they would have to use a spring
[20:37:12] <Horologium> 6 barrels, 1000 rounds per minute per barrel.
[20:37:16] <Valen> fry the seals otherwise
[20:37:41] <Horologium> RPM being rounds(bullets) per minute.
[20:37:53] <theBear> tho i suppose it's having a 120l tank on a 'small compressor' vs a roughly 1/8th litre firing/piston style chamber on a gas gun
[20:38:02] <theBear> Valen, nah, the air is the spring
[20:38:13] <theBear> conceptually/energy wise <grin>
[20:38:38] * theBear likes thinking in a holistic manner when freewheeling-design
[20:41:15] <theBear> grr, i think i gonna have to make a usb-ps2 passive adapter cable, after never needing one ever i finally noticed i need one NOW when willy mentioned how useless they are the other day, i bet my mums even got spare ones, but i don't ! got 3 that go the opposite way, new and unused ! i must be the only person in the world old fashioned enough not to have one !
[20:41:49] <Valen> probably cheaper to replace whatever has the PS2 port ;-P
[20:42:01] <theBear> but i cross-referenced a bunch of websites, and i'm pretty darned sure that my trusty old trackball will work with one, then i get to use my new core2duo for a desktop
[20:42:41] <theBear> nah man, i loves my trackball ! i even got an identical one unopened somewhere incase i ever can't fix this one anymore, but it's up to around 15years now, and looking good :)
[20:46:46] <theBear> hmm, i gettin suspicious google are fighting back even further on the no-anti-ad-apps on droid stuff... just got my shiny new battery and haven't really looked at my phone much apart from msgs and occasional updates, but maps was missing, reinstalled it and while i haven't got a gps fix yet (bad weather, under 2 stories of concrete flats and surrounded by monitors) i suspect it's complaining about a lackof
[20:46:46] <theBear> network connection not cos of no gps fix, but cos it's trying to load ads or reach doubleclick or soemthing
[20:47:04] <Horologium> http://vimeo.com/68074303
[20:48:29] <theBear> hmmm, looks like it would blow away :-)
[20:48:42] <theBear> ooh, cute little brushless coils
[20:49:39] <theBear> hmm, he aint done enough math for such a smart sounding intro, everyone knows until you get up to the limits of ground effect that ANY HINT of a 'skirt' gives you much better efficiency
[20:49:59] <theBear> even angling down the panels a few degrees and filling the corners in would make a huge difference
[20:50:57] <theBear> back when motors were less efficient and batteries were shitty andheavy and micros didn't exist, i had a BIG thing for hovercrafts, i know everything about them inside out
[20:54:58] <theBear> also no internet back then, i'd ride my pushbike all the way to the statelibrary on the weekends 'cos i'd long since used up all the technical info the local library had :)
[20:56:16] <Horologium> I have a little cheapy 30 dollar RC hovercraft.
[20:56:20] <Horologium> it's about 10 years old.
[20:57:30] <theBear> mmm, i always wanted a 'typhoon',the only commercially available one of any price (cheapy) at the time, but i never got one, and you gotta do somethign with yer sparetime, not to mention i was making ones 10times as good, even if i didn't know what i now know about durability/mechanical construction :)
[20:58:42] <Valen> I had a hovercraft RC when i was a kid
[20:58:47] <Valen> powered by nicads
[20:58:59] <Valen> the TV had it going over pools and the like just fine
[20:59:22] <Horologium> mine goes good on water.
[20:59:25] <theBear> yeah, and yeah, with VERY FRESH batteries they struggled to clear 5mm bumps
[20:59:28] <Valen> my memory of it at the local pool was of it sitting on a kickboard and driving around because the fan didn't have enough herbs to keep it dry
[20:59:29] <Horologium> unless it's choppy.
[20:59:39] <theBear> i should make one now with allthat i have learned
[20:59:48] <theBear> not to mention bldc and battery tech :)
[20:59:49] <Valen> dad then pulled the fan wire and the drive fans had heaps more power
[21:00:03] <Horologium> I used to run it out on the beach at the lake then right out onto the water.
[21:00:30] <Horologium> haven't been to the lake in a few years though.
[21:00:54] <Horologium> it got some serious speed running up and down the long open concourse at the mall too!
[21:01:12] <theBear> lol, the old rc-ankle-breaker approach
[21:01:17] <Horologium> yup.
[21:01:27] <theBear> only WAY harder to stop than something that touches the ground :)
[21:01:39] <Horologium> would go in early in the morning to run when it was snowy outside.
[21:02:03] <Horologium> it had a lift fan kill button so it would skid to a stop pretty quick.
[21:02:05] <theBear> i always liked balancey/floatey things including of course hovercrafts, so gentle and elegant to observe, letalone manouvere
[21:02:12] <Horologium> unless you hit a bump when you did that then it might flip.
[21:02:24] <theBear> pfft, a fun-kill button you mean !
[21:02:59] <Horologium> the old ladies would get mad if you ran into them.
[21:03:04] <Horologium> then beat you with their walkers.
[21:03:50] <theBear> heh, that's one of the many disadvantages of not being theBear !
[21:26:01] <Roklobsta> oh this is annoying. AVRS6.1 says one of my global structs is optimised away in the watch window by the disassembly clearly shows it writing to the struct.
[21:26:28] <Roklobsta> by=but
[21:26:49] <Roklobsta> W.T.F.
[21:38:15] <vectory> Roklobsta: turn of optimization?
[21:38:26] <vectory> in the build menu
[21:38:27] <Roklobsta> it shouldhn't happen with opt on
[21:38:37] <vectory> it clearly does, though :)
[21:38:40] <Roklobsta> volatile global should be visible to the debugger
[21:38:49] <Roklobsta> it was working earlier
[21:38:54] <Roklobsta> WTF
[21:40:02] <vectory> "was working earlier" <- i know that
[21:44:16] <Valen> i really should look into debuggers
[21:45:14] <Roklobsta> OK, weird effect. In main() the volatile globals are optimised away, go one nested function in and they magically appear.
[21:45:54] <Roklobsta> this is such a hge time waster
[21:46:41] <damjan> nested functions in C?
[21:47:22] <vectory> are they optimized away or not yet used?
[21:48:00] <Roklobsta> i mean in main the code says "Globalstruct.param = 1", the disassembly shows it's doing just that and the Watch Window says GlobalStruct optimised away
[21:48:30] <Roklobsta> man, Atmel has had years to get this debugger shit right
[21:51:40] <Roklobsta> same crap for -O1 and -O0
[21:52:45] <Roklobsta> Not happy, Jan!
[21:55:39] <vectory> then the dissasembly doesnt assign to a slot in a struct, just to a register
[21:56:51] <vectory> assign values to all members of the struct?
[21:58:13] <Roklobsta> nono it's def loading thr r's with immediate data then writing them out to ram with STS
[21:58:46] <Roklobsta> if they are global variables i should be able to watch them anytime, anywhere
[22:02:10] <vectory> still, are you sure the mem adrr is alligned to the adress of the struct in spe?
[22:02:21] <vectory> just curious, cause im learning atm
[22:15:02] <Roklobsta> i wonder if i have some sort of stack bugger up
[22:15:03] <Roklobsta> hmmm
[22:15:17] <Roklobsta> weird shit is usualy precipitated by stack overruns
[22:22:29] <Roklobsta> C:\data2\home\toolsbuild\jenkins-knuth\workspace\avr8-gnu-toolchain\src\avr-libc\libc\stdio\fputc.c
[22:22:37] <Roklobsta> hmm, who is kenkins-knuth
[22:22:38] <Roklobsta> j
[22:22:42] <Roklobsta> he must work at atmel
[22:23:10] <Roklobsta> bloody debugger disassembly won't go into prebuilt .o files like csprint
[22:23:13] <Roklobsta> vsprintf
[22:23:25] <Roklobsta> I get the green step arrow
[22:24:04] <Roklobsta> the debugger just asked to load that .c file
[22:26:24] <Tom_itx> i'm not that fond of 6.1
[22:27:13] <Roklobsta> should I just go back to 6.0?
[22:28:03] <Tom_itx> i don't use any of em to develope code really
[22:28:07] <Tom_itx> just a txt editor
[22:28:09] <Roklobsta> hmmm
[22:28:12] <Roklobsta> \yes
[22:28:31] <Roklobsta> i have complex interactions so i need to check that it's aok
[22:29:27] <Tom_itx> debuggers can't do alot of things
[22:29:42] <Tom_itx> no interrupts that i'm aware of, no adc really
[22:29:45] <Roklobsta> i am expecting too much?
[22:29:49] <Tom_itx> i dunno
[22:29:57] <Tom_itx> they're handy for some things
[22:30:02] <Roklobsta> it seems to catch interrupt just fine with breakpoints
[22:30:24] <Roklobsta> i've been able to debug and get my task scheduler working just fine with all it's hairy interrupts.
[22:30:41] <Roklobsta> now i move onto stuff that has vsprintf in it and it all goes to crap
[22:31:25] <Roklobsta> the stack for the dogy task is big enough.
[22:50:26] <Valen> how does one find how much ram an AVR is using, outside of declaring everything as global that is
[22:50:41] <Valen> is there some automated way or do i need to bust out a tally sheet and a calculator
[22:52:56] <Tom_itx> does avrdude report it on download or just the load size?
[22:53:12] <Tom_itx> does -vvv get you any more info?
[22:53:32] <Tom_itx> i'm not really sure Valen
[22:54:50] <Valen> avrdude just does the flash size
[22:55:02] <Valen> its not really going to get into ram consumption I shouldn't think
[22:55:11] <Valen> it feels more like something the compiler should be doing
[22:55:22] <Tom_itx> i suppose you need to calculate it then
[22:55:38] <Valen> cmon this is the 21st century!
[22:55:39] <Valen> ;->
[22:55:48] <Tom_itx> ram gets reused though doesn't it?
[22:55:54] <Tom_itx> depending on the scope of the var
[22:55:56] <Valen> yeah
[22:59:54] <Roklobsta> i tend to avoid heap usage on embedded systems. it's better to control your ram thiny's.
[23:00:06] <Roklobsta> so i never use malloc
[23:00:08] <Valen> looks like avr-size only works out static vars
[23:00:22] <Roklobsta> so you want to know how much stack you need?
[23:00:29] <Valen> dunno
[23:00:34] <Roklobsta> yes sounds like it.
[23:00:39] <Valen> I have a fairly straight forward program
[23:00:45] <Valen> no mallocs or any crazyness
[23:00:51] <Roklobsta> plus eveything that is statically located
[23:01:00] <Valen> just wanted to make sure i'm not going to run out of the rams
[23:01:10] <Roklobsta> malloc is fine if you have many MB of RAM and an MMU
[23:01:23] <braincracker> h
[23:01:24] <Valen> function calls are only 1 deep at any point
[23:01:30] <braincracker> http://www.youtube.com/watch?v=DIce8OkqrfA :) at 0:37 he used up at least one lives
[23:02:37] <Valen> I do wonder how many really nasty injuries wind up in hospital from those guys
[23:02:56] <Roklobsta> whne you build in avrstudio6 it repots this in the output:
[23:02:59] <Roklobsta> Program Memory Usage : 7228 bytes 5.5 % Full
[23:03:00] <Roklobsta> Data Memory Usage : 2903 bytes 35.4 % Full
[23:03:34] <braincracker> Horologium <= hahaha cool projext, flashdestroyer, eeprom destroyer
[23:04:02] <Roklobsta> is being 40 an impediment to starting and being successful in parkour?
[23:04:48] <Casper> no, some dogs do it, and they ain't 40
[23:05:17] <Valen> its all flashy stuff now, I like the older stuff where it was about going fast not just doing flips
[23:05:52] <Casper> FUCK AIRMILES
[23:05:59] <Casper> again, another IGA promo...
[23:06:27] <Casper> I'm gonna fill an official complain about them
[23:06:34] <Casper> ... this week end
[23:06:57] <Roklobsta> i need to shed 30kg by the loks of it
[23:06:57] <Casper> I don't know how many times I have unsubscribed to their IGA newsletter
[23:07:36] <vectory> Valen: seems thats the natural progression for ... lets called extreme sports
[23:08:04] <vectory> was the same with break dance, well not fast, but rythmic. then came the flashy stuff
[23:08:15] <vectory> *call it
[23:11:03] <Roklobsta> it's nice to watch
[23:11:28] <Roklobsta> somethign i wish i could do. but I need to get off my fat arse. i can't even raise my foot higher than my knee
[23:12:16] * Valen goes swimming approx 3x a week
[23:12:22] <Valen> I should go to the gym the other 2
[23:12:29] <Valen> but eh too hard basket lol
[23:14:39] <Valen> avr-size -A 1cell_2LED.elf
[23:14:48] <Valen> .data 4 8388704
[23:14:48] <Valen> .bss 60 8388708
[23:14:59] <Valen> so somewhere in the 65 byte region for global vars
[23:15:04] <Valen> which are most of mine ;->
[23:18:18] <braincracker> Roklobsta <= optoisolators used to handle 3.5kV-6.5kV transients
[23:18:24] <Casper> Houston, we have a problem!
[23:18:35] <Casper> That person called a wrong number!
[23:20:06] <Casper> google say it's a scammer
[23:20:19] <Valen> ?
[23:20:43] <Casper> 1-281-382-6532 called my cell
[23:20:52] <Valen> I C
[23:20:56] <Casper> 281 is houston
[23:22:48] <Roklobsta> valen: in the .map file I have the line " 0x00801211 PROVIDE (__bss_end, .)" looks like the end of ram. it comes just after my glbals finish in the COMMON heading
[23:23:18] <Valen> avr-size seems to do all the work for me
[23:23:35] <Valen> at least as much as its possible to statically determine anyway
[23:23:44] <Roklobsta> and a bit further down it says " 0x00801211 PROVIDE (__heap_start, .)"
[23:23:59] <Roklobsta> the map doesnt lie
[23:24:38] <Roklobsta> my avr board has 64kB of XRAM so I need to eventually figger out how to tell gcc about it
[23:25:16] <braincracker> figure
[23:25:45] <Roklobsta> prawns
[23:26:15] <Roklobsta> in australia it's spelt the correct way, 'figger' right Valen?
[23:26:33] <Valen> we use u's a lot
[23:29:00] <braincracker> http://dangerousprototypes.com/2012/03/12/hacking-the-fpga-bitstream/
[23:29:37] <braincracker> fpgas and the impossible to hack external configuration memory :)
[23:37:42] <Roklobsta> impossible for the casual user.
[23:40:20] <braincracker> man-in-the-middle is project for haxxor wannabies, decrypting the thing is a little more