#avr | Logs for 2014-07-27

Back
[03:19:55] <rue_bed> does the 20mb/sec have to go thru the microcontroller?
[06:20:23] <Jartza> agh
[06:21:16] <Jartza> so many suggested kicad, but again I'm running into strange troubles like before and can't get any footprints assigned
[06:21:26] <Jartza> so I guess it's back to eagle, no matter what people say :)
[06:21:42] <NooM> diptrace is good and simple
[06:22:07] <NooM> and free (for non-commercial stuff)
[06:22:17] <NooM> i luv
[06:24:30] <Jartza> hmmh
[06:24:35] <Jartza> it seems to have a mac version too
[06:24:42] <Jartza> I could give it a try
[06:24:51] <NooM> and it makes sweet 3d renderings
[06:25:19] <NooM> http://www.eevblog.com/files/uCurrentRev5schematic.pdf
[06:25:25] <NooM> ups
[06:25:26] <NooM> wrong
[06:25:39] <NooM> https://www.dropbox.com/s/6n9qcyy5qf7ky30/new_pcbs_front.png
[06:25:42] <NooM> like that
[06:27:50] <Jartza> how good component library it has?
[06:28:13] <NooM> iam more than happy, and its very easy to make own footprints
[06:28:41] <NooM> all the standard, dip, soic, sot, qfn, resistor, capacitor stuff
[06:28:54] <NooM> and some parts with allready named pins, like for avr's
[06:29:03] <Jartza> ok
[06:29:20] <Jartza> the reason why I want something else than eagle is component creation
[06:29:23] <NooM> i mean, lots of that stuff with named pins, but i dont use that a lot
[06:29:25] <Jartza> I find it quite tedious with eagle
[06:29:34] <NooM> its _very_ simple with diptrace
[06:29:53] <Jartza> well, I'll download the free version to try it
[06:30:01] <NooM> i made footfints myself for various parts
[06:30:13] <NooM> like tiny crystals for avr's
[06:32:01] <NooM> https://www.dropbox.com/s/u19xpk76x6mtnua/Bild133.jpg
[06:32:06] <NooM> my atmega 1284p :D
[06:36:44] <Jartza> cool
[06:40:54] <Jartza> umm
[06:40:59] <Jartza> the osx version is using wine :o
[06:43:19] <NooM> hm
[06:43:24] <NooM> dunno, i use windows
[06:48:26] <Jartza> well it seems osx version is just windows version packed together with wine
[06:48:39] <NooM> :D
[06:49:24] <Jartza> well it's just more or less irritating then, as the UI won't be osx-style
[06:49:44] <Jartza> and all those osx-shortcuts that come from the spine wont work :P
[06:50:16] <Jartza> and I have zero windows licenses :P
[06:50:59] <NooM> :(
[06:52:18] <twnqx> hm, it can be better than eagle, but in the end it's sufficient
[06:52:23] <twnqx> once you created enough footprints
[06:53:17] <NooM> dunno, i couldnt handle eagly, but than iam not a pro
[06:53:25] <NooM> eagle
[06:54:38] <Jartza> well, I'm quite far from pro :D
[06:55:11] <Jartza> started learning the electronics-stuff like less than half a year ago
[06:55:16] * twnqx has a pro license but isn't pro
[06:55:29] <NooM> eagle ?
[06:55:32] <twnqx> yeah
[06:55:35] <Jartza> I've done embedded programming for years though, but someone else has taken care of the hw
[06:55:58] <twnqx> though i haven't checked if it works with eagle 7...
[06:55:58] <NooM> hehe, i gave eagle up after 10 minutes :D
[06:56:17] <twnqx> i yet have to see another usable native linux soft
[07:10:47] <Jartza> hmm
[07:10:54] <Jartza> maybe I'll continue with eagle for now
[07:11:01] <NooM> :D
[07:11:31] <Jartza> diptrace might be nice, but it doesn't have the components either and I'm not fancying now to create those again :)
[07:11:36] <Jartza> as I already made them for eagle
[07:11:54] <NooM> what component you need?
[07:12:13] <Jartza> I would've liked to use kicad, but the osx version seems to have problem with footprints and libraries
[07:12:21] <Jartza> lot of warning windows about missing libraries etc.
[07:16:14] <Thrashbarg> might have some paths defined which aren't there
[07:16:46] <Thrashbarg> but yea, FOSS generally doesn't work out of the box :P
[07:18:13] <Jartza> NooM: ncp1402 and few lcd-displays :P
[07:19:26] <NooM> diptrace has sot23-5
[07:19:33] <NooM> the displays, dont think so
[07:20:06] <NooM> https://www.dropbox.com/s/il24aqdsyl41xy7/new_pcbs_back.png
[07:20:16] <NooM> that kind it has, but i didnt looks closley
[07:20:28] <NooM> btw: thats a nice ic, gonna remember it :D
[07:23:58] <Jartza> yeah it is
[07:24:11] <Jartza> I use it to run attinys at 3.3V with one aaa
[07:24:37] <NooM> mhm
[08:49:50] <Bushman> hi
[08:50:23] <Bushman> the avr-gcc spits out:
[08:50:25] <Bushman> BMP085_RF12test.c:65:5: error: attempt to use poisoned "SIG_OUTPUT_COMPARE1A"
[08:50:44] <Bushman> but the same code compile without problem on windows
[08:50:54] <Bushman> any insight?
[08:53:56] <Bushman> is is that my compiler don't want to take old interupt vector name?
[08:54:12] <Bushman> http://www.nongnu.org/avr-libc/user-manual/group__avr__interrupts.html
[08:54:22] <Lambda_Aurigae> same version of avr-gcc?
[08:54:32] <Lambda_Aurigae> a
[08:54:41] <Lambda_Aurigae> and avr-libc? and avr-binutils?
[08:54:43] <Bushman> i've replaced it with the new name from this website and now it compiles, still will have to check if works the same tho
[08:55:04] <Bushman> not the same
[08:55:18] <Bushman> his is for windows, and i don't know which build
[08:55:30] <Bushman> mine is linux, latest from ubuntu repos
[08:56:32] <Lambda_Aurigae> so different versions might have updated names for things.
[08:57:07] <Lambda_Aurigae> you can compile the same versions for both linux and windows,,,and mac, assuming anyone would actually use a mac for anything other than playing music....{ducks and runs}
[08:59:30] <Bushman> naah, i'll just tell my father to update his gcc and use new name for the IRQ
[09:00:09] <Bushman> right now i'll just test if it works like it used to
[09:00:10] <Lambda_Aurigae> that works too.
[09:02:15] * twnqx wonders if bushman is a notpronner
[09:04:35] * Lambda_Aurigae wonders what the heck is a "notpronner"
[09:06:19] <Bushman> twnqx: no i'm not
[09:06:24] <Bushman> i'm a notpr0ner
[09:06:46] <Bushman> also the core works
[09:06:48] <Bushman> *code
[09:07:44] <Bushman> so now i may start implementing some witty averaging technique for my variometer
[09:08:56] <Bushman> together with some clever tone generator that takes the rate of climb/fall and turns it in to nice soothing beeping sound ;]
[09:18:32] <Bushman> man... the floats still don't work and my dad keeps putting them in printf ;/
[09:19:11] <Bushman> i'll have to hijack his code and replace it with something intiger :P
[09:24:14] <twnqx> there's a workaround for floats in printf
[09:24:21] <twnqx> but you'll have to edit your makefile
[09:26:01] <twnqx> -Wl,-u,vfprintf -lprintf_flt -lm
[09:26:08] <twnqx> (or maybe -lm in front)
[09:26:34] <twnqx> it just makes things so big it's not enabled by default
[09:31:14] <Bushman> yup
[09:31:27] <Bushman> tried that, it compiles
[09:31:48] <Bushman> float in printf prints '?'
[09:32:06] <twnqx> mh
[09:32:24] <Bushman> i can show you my makefile if that helps.
[09:33:18] <twnqx> pastebin it, why not
[09:34:20] <Bushman> few people genuinely tried to help me solve it
[09:34:30] <Bushman> some from here.
[09:35:04] <Bushman> but no matter what they suggested or where i have put the flags, it does makes the errors go away but does not make the float to display
[09:36:27] <Tom_itx> http://www.avrfreaks.net/index.php?name=PNphpBB2&file=printview&t=104785&start=0
[09:36:49] <Tom_itx> I want to creat strings with printf that include floating point but the outputs always appear as '?'.
[09:38:26] <Tom_itx> http://winavr.scienceprog.com/avr-gcc-tutorial/using-sprintf-function-for-float-numbers-in-avr-gcc.html
[09:41:29] * Bushman bauds to twnqx
[09:41:41] <Bushman> he fixed my makefile ;]
[09:42:35] <Lambda_Aurigae> what was the problem?
[09:42:41] <Bushman> Tom_itx: thanks, that won't be needed anymore, twnqx managed to properly add the flags in my makefile
[09:43:02] <Bushman> Lambda_Aurigae: 16:18:19 < Tom_itx> I want to creat strings with printf that include floating point but the outputs always appear as '?'.
[09:43:08] <Bushman> that
[09:43:15] <Bushman> but it's fixed now ;]
[09:43:17] <twnqx> wrong printf lib (the standatrd non-float one=
[09:43:20] <Lambda_Aurigae> yeah...I meant what was the problem with the makefile?
[09:43:30] <Tom_itx> your lib will be HUGE now
[09:43:31] <Bushman> well..
[09:43:40] <Lambda_Aurigae> aahh..can we post before and after?
[09:43:57] <Bushman> umm...
[09:44:06] <Bushman> let's see
[09:44:12] <Lambda_Aurigae> just so those of us who might need it can see it?
[09:44:52] <twnqx> Lambda_Aurigae: http://www.mikrocontroller.net/articles/Beispiel_Makefile
[09:45:05] <twnqx> scroll down to the PRINTF_LIB part
[09:45:40] <Tom_itx> PRINTF_LIB_FLOAT = -Wl,-u,vfprintf -lprintf_flt
[09:45:49] <twnqx> + -lm
[09:45:53] <Lambda_Aurigae> got it.
[09:45:57] <Bushman> Lambda_Aurigae: it's just a matter of me putting the flags in wrong places and not giving enough parameters
[09:46:54] <Lambda_Aurigae> it's the -lprintf_min vs -lprintf_flt
[09:47:10] <twnqx> almost
[09:47:19] <twnqx> you have three options: default, min and flt
[09:47:37] <twnqx> not sure what's the difference between min and default, though
[09:49:21] <Lambda_Aurigae> Since the full implementation of all the mentioned features becomes fairly large, three different flavours of vfprintf() can be selected using linker options. The default vfprintf() implements all the mentioned functionality except floating point conversions. A minimized version of vfprintf() is available that only implements the very basic integer and string conversion facilities, but only the # additional option can be specified using conversion f
[09:49:21] <Lambda_Aurigae> lags (these flags are parsed correctly from the format specification, but then simply ignored).
[09:50:06] * Bushman is having a piece of celebration cake
[09:50:09] <Bushman> ;]
[09:50:48] * twnqx brought his tricore emulator to 439/785 opcodes today
[09:50:50] <twnqx> sigh
[09:52:19] * Lambda_Aurigae is still waiting for his tricorder to show up.
[10:01:06] <mike_papa> Hello. Is there any way to use Dragon, or STK600 to flash BIOS on bricked mainboard? flashrom does not support those as SPI programmers, and I doubt avrdude will be willing to flash non-avr chip.
[10:01:43] <twnqx> i would be tempted to say "no"
[10:02:18] <mike_papa> you make me sad :(
[10:02:41] <twnqx> sorry :(
[10:02:53] <twnqx> but you could probably mod avrdude to solve that
[10:03:25] <Lambda_Aurigae> you could use a dragon to program an avr to play programmer for the flash chip on your motherboard.
[10:03:34] <Lambda_Aurigae> is the flash chip parallel or serial?
[10:03:43] <twnqx> normally serial these days
[10:03:49] <twnqx> and he explicitly said spi
[10:04:10] <Lambda_Aurigae> get a bus pirate
[10:04:27] <Lambda_Aurigae> there have been multiple articles about using those to reprogram the flash chips on motherboards.
[10:04:44] <twnqx> the easiest is, as he suggested, flashrom.
[10:04:48] <twnqx> with a bus pirate
[10:04:51] <twnqx> but actually
[10:05:01] <mike_papa> I'm not really able to get any new hardware now. Unfortunately. :(
[10:05:11] <twnqx> i like that idea with the stk
[10:05:18] <twnqx> or avrdude in general
[10:05:49] <Lambda_Aurigae> so make a serial to spi adapter out of an avr that is compatible with flashrom.
[10:06:19] <mike_papa> That could work, and doesn't seem to be very complicated.
[10:06:29] <twnqx> but check the voltage of your flash chip
[10:06:42] <twnqx> 3.3 might already be too much for some
[10:06:52] <mike_papa> modding avrdude might be too much for my simple skils
[10:07:00] <mike_papa> It's 3.3
[10:07:09] <twnqx> learning by doing!
[10:07:16] <twnqx> flash chips are really easy
[10:08:03] <mike_papa> There is a lot tutorials on how to prepare DIY cable for flashrom. Unfortunately I have no way to get parraler port.
[10:08:25] <twnqx> wigglers for the win, eh
[10:08:35] <Lambda_Aurigae> oh..oh..I know! use the SPI port on your vga port!
[10:08:42] <Lambda_Aurigae> http://hacking.majenko.co.uk/node/104
[10:08:45] <twnqx> that is i2c, not spi
[10:08:52] <Lambda_Aurigae> oh.
[10:08:54] <Lambda_Aurigae> hehe.
[10:08:55] <Lambda_Aurigae> nevermind.
[10:09:00] <Lambda_Aurigae> I posted that link too fast anyhow.
[10:09:21] <twnqx> (also, 5V, but that would have been solvable)
[10:10:21] <twnqx> lol @ that vga interface
[10:10:30] <Lambda_Aurigae> it went the wrong way.
[10:10:36] <twnqx> do software VGA like true AVR!
[10:11:17] <Lambda_Aurigae> yeah.
[10:11:18] <mike_papa> ok. I'll go learn how to make serial spi adapter then. ;)
[10:11:21] <Lambda_Aurigae> I've done it multiple times.
[10:11:40] <twnqx> 100 lines of C?
[10:11:42] <twnqx> less? :>
[10:11:46] <Lambda_Aurigae> mike_papa, it also needs to support that particular protocol that flashrom uses.
[10:11:56] <twnqx> in reality not
[10:12:06] <twnqx> he could just make up his own protocol and ignore flashrom
[10:12:19] <twnqx> he'd have to write a driver for flashrom anyway
[10:12:57] <mike_papa> seems a bit like an overkill to rescue mainboard worth... maybe $30.
[10:12:59] <Lambda_Aurigae> looks like flashrom can work with a serial port if your adapter supports that protocol.
[10:13:02] <Tom_itx> mike_papa, read this: http://tom-itx.ddns01.com:81/~webpage/mtkflash/flash_howto_index.php
[10:13:44] <Lambda_Aurigae> the protocol is called serprog....but,,,the link to the protocol documentation is dead.
[10:14:20] <twnqx> i'd just build a serial to spi pipe...
[10:16:19] <mike_papa> that seems to be easiest.
[10:16:40] <Tom_itx> i just happened to have one of those old drives and it _did_ work
[10:16:41] <twnqx> put a flash erase up front, and auto insert flash program as needed...
[10:24:40] <R0b0t1> mike_papa: There should be USB parallel ports
[10:24:47] <mike_papa> Seems like all I need is STK with almost any atmega. http://flashrom.org/Serprog/Arduino_flasher
[10:24:53] <R0b0t1> And/or PCI[e] cards
[10:26:28] <mike_papa> Sure there are many. But I'm curently in the middle of nowhere with 7 stiches on my right heel, unable to drive, and move anywhere. ;)
[10:26:42] <Lambda_Aurigae> R0b0t1, usb parallel adapters don't usually let you access the individual pins like you can on a built in parallel port.
[10:27:01] <Tom_itx> stay away from the mrs' sewing needles
[10:27:20] <Lambda_Aurigae> I have 5 of them and none are usable as anything but printer interfaces...
[10:37:49] <Jartza> darn
[10:37:52] <Jartza> updated eagle to 7.0
[10:38:05] <Jartza> now I can't even add the included libraries
[10:38:06] <Jartza> wut
[10:38:30] <Jartza> add component only shows my own library and no stock component
[10:38:52] <Tom_itx> i still use 4.16 :)
[10:39:30] <Jartza> maybe I should somehow delete preferences from old version
[10:39:59] <Tom_itx> shouldn't matter
[10:40:04] <Tom_itx> i've got several ver installed
[10:49:27] <mike_papa> thanks for help. see you
[13:33:21] <Jartza> can't figure out what's wrong in eagle :(
[13:44:35] <Jartza> add component looks like this: https://www.dropbox.com/s/cc7wx0xzy7mtfya/Screenshot%202014-07-27%2021.24.25.png
[13:44:49] <Jartza> all the standard components are now missing after update
[13:53:05] <Jartza> the libraries do show up in the "main view"
[13:53:25] <Jartza> and I also tried selecting "libraries" and picking "use all" from submenu
[13:53:28] <Jartza> still nothing
[16:39:46] <Jartza> dah
[16:39:54] <Jartza> got it to work by removing all old config files :P
[16:39:58] <Jartza> (eagle, that is)
[16:40:06] <Tom_itx> hurray!
[16:44:33] <Jartza> might be that I had some failure in library path, and the old eagle just didn't care
[16:59:16] <Jartza> cool
[16:59:21] <Jartza> got also the rgb backlight working
[16:59:34] <Jartza> https://www.dropbox.com/s/3z8d074bg41hfol/20140728_004.mp4
[16:59:42] <Jartza> some disturbance in camera
[17:00:27] <Jartza> quite smooth in real life
[19:23:13] <Jan-> faster to read flash for a lookup table, or faster to use a random number generator?
[19:26:36] <inflex> Well, depends on the quality you're after
[19:27:16] <Jan-> candle led flicker thing
[19:27:18] <Jan-> not terribly great :)
[19:27:43] <Tom_itx> just give it a bad solder joint. it'll flicker by itself
[19:27:53] <inflex> bottom bit of an untied ADC input :)
[19:27:57] <inflex> hi Tom_itx
[19:28:02] <Tom_itx> hi
[19:28:13] <inflex> or just the bottom bit of the current timer
[19:28:14] <Jan-> oh hey Tom_itx
[19:28:29] <Jan-> I just spent a while writing a fastish software PWM thing
[19:28:30] <inflex> ( though I suppose that's a bit lock-stepped if your program is very simple )
[19:28:39] <Jan-> it seems OK, I just need to make it ramp brightness up and down now
[19:29:03] <Jan-> I guess there'll be some fiddling to do to make it "right"
[19:32:32] <Jan-> This is my 6-channel PWM generator, did I do anything stupid? http://pastebin.com/XrvkKzMz
[19:33:08] <Lambda_Aurigae> does it work?
[19:33:12] <Jan-> yup
[19:33:19] <Lambda_Aurigae> then nothing stupid.
[19:33:19] <Jan-> I was trying to make it fast
[19:33:27] <Tom_itx> is it fast?
[19:33:30] <Jan-> it uses a lot of RAM (1kb for 10 bit resolution)
[19:33:41] <Jan-> well it's an absolute metric shit brick faster than the arduino calls I was using before.
[19:33:59] <Jan-> So I guess. But I don't know. I'm not an expert. I may be doing something really stupid.
[19:34:30] <Jan-> I can avoid some read-modify-writes on the port by caching, not sure how much it matters.
[19:34:39] <Lambda_Aurigae> dos on an 8MHz 8088 is faster than arduino libs.
[19:35:45] <Jan-> I'm doing I guess AVR code inside the arduino framework
[19:35:46] <Tom_itx> by far
[19:35:48] <Jan-> which is convenient and seems fast
[19:36:05] <Jan-> is what I did reasonably sane, anyway?
[19:38:05] <dkordic> Lambda_Aurigae: LOL
[19:38:17] <Lambda_Aurigae> I said something funny?
[19:38:58] <dkordic> Yes, DOS vs Arduino.
[19:39:16] <Jan-> be nice, arduino makes certain things possible
[19:39:52] <Jan-> do things like _BV(n) get compiled out?
[23:17:58] <Grievre> Why do AVR chips bother having EEPROM in addition to flash?
[23:18:04] <Grievre> Is it faster to write to than the falsh?
[23:18:05] <Grievre> flash
[23:18:06] <Grievre> ?
[23:22:21] <Casper> more endurance
[23:22:32] <twnqx> flash has to be edeleted in blocks
[23:22:46] <Casper> and that too
[23:22:53] <twnqx> while eeproms don't have to be wiped before being programmed
[23:23:06] <Casper> twnqx: not quite right on some
[23:23:17] <Casper> you still need to write some eeprom in word or dword
[23:23:29] <Casper> instead of by bytes...
[23:23:37] <twnqx> but not in several kbyte blocks
[23:23:48] <twnqx> but yes, eeproms have a word size
[23:23:49] <Casper> I think the biggest I saw is 32 bytes
[23:23:55] <twnqx> Oo
[23:24:11] <Casper> yeah...
[23:55:53] <myself> At the silicon level, aren't the eeprom memory cells the same as flash cells, floating-gate FETs with tunneling to place/remove electrons?
[23:56:04] <myself> just organized differently?
[23:57:07] <twnqx> well, eeproms are afaik always SLC