#avr Logs

Apr 19 2017

#avr Calendar

12:15 AM daey_ is now known as daey
01:10 AM vishwin60 is now known as vishwin
06:11 AM hetii: Hi :)
07:17 AM limpkin: these atsamd sure have a few silicon bugs
07:30 AM Lambda_Aurigae: complain to microchip
07:30 AM limpkin: I shall
07:57 AM julius: rue_house: oh it did...over and over again..but in the end i managed to get a .pdf out of it
08:08 AM Emil: limpkin: what kind of bugs?
08:08 AM Emil: Reading the errata?
08:10 AM limpkin: rtc module not counting if input clock not above 3kHz
08:10 AM limpkin: nothing in the errata
08:17 AM Emil: I'm tempte to believe this is a PEBKAC but :D
09:59 AM julius: limpkin: why do you have a input of ~3khz?
09:59 AM limpkin: I can set it to whatever I want, but i noticed that below 3khz the rtc module isn't counting
10:05 AM julius: wasnt there some magic frequency that makes the rtc module go right?
10:05 AM julius: i mean, you want a perfect time or what?
10:39 AM Lambda_Aurigae: rtc clock module should be 32768hz or something like that normally.
10:40 AM Lambda_Aurigae: for most rtc modules anyhow.
11:03 AM Emil: yeah but it should still clock at whatever is set up
11:52 AM Lambda_Aurigae: yes.
11:52 AM Lambda_Aurigae: that not clocking if input is above 3kHz is really strange though.
12:07 PM Emil: Lambda_Aurigae: below
12:07 PM Emil: slower thab 1kHz
12:08 PM Lambda_Aurigae: ok...yeah..I missed the "not" up there.
01:03 PM * Lambda_Aurigae gots a nema-34 3-phase 490W brushless DC motor...it says DC490V on the label...gonna turn it into a wind turbine!
01:03 PM xentrac: 490V or 490W?
01:03 PM xentrac: and what is 3-phase dc?
01:04 PM xentrac: I didn't know there existed NEMA-34 BLDC motors
01:26 PM Lambda_Aurigae: 410V, 490W, on the label.
01:26 PM Lambda_Aurigae: it's wired with 3 coils and a common
01:26 PM Lambda_Aurigae: brushless dc motor basically.
01:27 PM Lambda_Aurigae: https://picclick.at/Shinano-Dr-85310-001-147-0193-70-Motor-351390018948.html
01:27 PM Lambda_Aurigae: can't find any specs beyond what's on the sticker.
01:31 PM * antto sneaks in and puts a pokemon sticker over the existing sticker..
01:31 PM JanC_ is now known as JanC
01:31 PM * antto runs
01:32 PM Lambda_Aurigae: did a quick test here with my flukey meter and spinning it by hand gives me 8 to 15 volts.
01:32 PM Lambda_Aurigae: on one coil.
01:33 PM xentrac: am I misremembering or do you use a screenreader?
01:34 PM Lambda_Aurigae: on occasion I do.
01:34 PM Lambda_Aurigae: it's not running as I'm remoted into my computer from worky.
01:34 PM xentrac: is there an equivalent of a screenreader for a multimeter?
01:34 PM xentrac: like, are there multimeters with usable audio output?
01:34 PM Lambda_Aurigae: I've seen talking multimeters.
01:35 PM Lambda_Aurigae: hit the hold button and it tells you the current reading.
01:35 PM Lambda_Aurigae: it's been a while but I have seen them before.
01:35 PM Lambda_Aurigae: think it was a probe type...like an old 80s era logic probe kinda meter.
01:36 PM Lambda_Aurigae: http://www.omega.com/pptst/HHM2.html
01:37 PM xentrac: but I guess you didn't find it useful
01:38 PM Lambda_Aurigae: not really.
01:38 PM Lambda_Aurigae: I use the screenreader for irc because I have too many windows open
01:38 PM Lambda_Aurigae: not because I can't see.
01:38 PM xentrac: oh, interesting
01:39 PM Lambda_Aurigae: it's a convenience thing...
01:40 PM Lambda_Aurigae: and because I can walk around the house with a bluetooth earpiece in and still hear IRC channels..like while I'm cooking or cleaning or something.
01:46 PM Lambda_Aurigae: hmmm..ok..no center tap
01:46 PM Lambda_Aurigae: just 10.2 ohms between any two of the 3 wires coming out of the motor.
01:51 PM xentrac: that's normal for BLDC motors
01:52 PM xentrac: some are delta-wired, others are wye-wired, but usually if there's a fourth wire it's a Hall-effect sensor
01:52 PM Lambda_Aurigae: full wave rectifier set between each pair of wires.
01:52 PM Lambda_Aurigae: this has some kind of rotation sensor board in it too.
01:52 PM Lambda_Aurigae: haven't taken it apart to look at what it is.
01:52 PM Lambda_Aurigae: it's the drum drive motor out of a xerox colorqube 9303
01:53 PM Lambda_Aurigae: I know it has to control speed and direction very precisely
01:53 PM xentrac: BLDC motors are good for that; you usually get many, many pulses per rotation
01:53 PM Lambda_Aurigae: turns the drum up to 13 revolutions to print an image onto it then presses the paper to the drum to transfer the ink(molten wax) onto the paper.
01:58 PM xentrac: I think the paper part is pretty forgiving
01:58 PM xentrac: I mean the paper moves with the drum because it's pressed to it
01:59 PM xentrac: but wait, the wax is molten on the drum? I thought the drum held the toner electrostatically on those things, like on a laser printer
01:59 PM xentrac: I figured that control of drum speed was crucial to getting the laser pulses at the right height on the paper
01:59 PM Lambda_Aurigae: not toner
02:00 PM Lambda_Aurigae: it's wax
02:00 PM Lambda_Aurigae: high temp inkjet
02:00 PM xentrac: ohh
02:00 PM Lambda_Aurigae: the wax melts at 100C
02:00 PM xentrac: I had no idea that was how thermal wax printers worked
02:00 PM Lambda_Aurigae: it is kept at 120C in the reservoirs, umbilicals, and printheads.
02:00 PM xentrac: and jetted onto the drum piezoelectrically?
02:00 PM Lambda_Aurigae: it's how the colorqube system works..the old tektronics phaser technology.
02:00 PM Lambda_Aurigae: yep.
02:01 PM Lambda_Aurigae: high temp inkjet.
02:01 PM Lambda_Aurigae: the drum is kept at 105C
02:01 PM learath: Interesting.
02:01 PM learath: Lambda_Aurigae: so more like wax?
02:01 PM Lambda_Aurigae: and there is a cool press roller that presses the paper to the drum as it passes.
02:01 PM Lambda_Aurigae: exactly like wax
02:01 PM Lambda_Aurigae: non-toxic wax even.
02:02 PM Lambda_Aurigae: I think the original formulation was even entirely organic.
02:02 PM Lambda_Aurigae: it was designed as a "green" printing system by tektronix back in the 80s/90s
02:02 PM Lambda_Aurigae: the bought in 2000 by xerox
02:02 PM Lambda_Aurigae: when tektronix couldn't get it working reliably.
02:03 PM Lambda_Aurigae: it melts and drips the wax into open reservoirs
02:03 PM Lambda_Aurigae: then that is pumped through heated umbilicals to the printheads.
02:03 PM Lambda_Aurigae: and squirted onto the drum
02:04 PM xentrac: does none of the wax stick to the drum after being cooled onto the paper?
02:04 PM Lambda_Aurigae: it has 4 printheads that cover a 12 inch long area, give or take.
02:04 PM Lambda_Aurigae: a little.
02:04 PM Lambda_Aurigae: the drum spins and the heads shift with each rotation
02:04 PM Lambda_Aurigae: each head has 800 jets
02:04 PM Lambda_Aurigae: 4 colors, cyan, magenta, yellow, black...200 of each on each head.
02:04 PM Lambda_Aurigae: overall it gets 600dpi resolution.
02:05 PM xentrac: so the drum goes through several revolutions to accumulate the image 800 columns at a time?
02:05 PM Lambda_Aurigae: once it presses the image onto the paper a scraping blade removes excess and an oil roller reoils the drum for the next image.
02:05 PM Lambda_Aurigae: yup.
02:05 PM xentrac: holy fuck, a scraping blade
02:05 PM xentrac: this printer is fucking rocket science
02:05 PM Lambda_Aurigae: up to 13 by my count watching the thing print with the covers off.
02:05 PM xentrac: how do you get the scraping blade not to scratch the drum?
02:06 PM Lambda_Aurigae: it's 1970s oh fuck lets see what we can do,,science.
02:06 PM Lambda_Aurigae: it is very smooth, very flat, and lays against the drum just so.
02:06 PM Lambda_Aurigae: the blade is also much softer than the drum.
02:06 PM xentrac: 80s/90s, 2000, or 1970s?
02:06 PM Lambda_Aurigae: the technology was officially unveiled in the 80s.
02:06 PM Lambda_Aurigae: but it looks like something from the 70s to me.
02:07 PM xentrac: it sounds a bit beyond what you could practically achieve in the 70s
02:07 PM Lambda_Aurigae: probably.
02:07 PM Lambda_Aurigae: the electronics have definitely evolved from the original tektronix design.
02:07 PM xentrac: but maybe I'm being too pessimistic. also I'm kind of ignorant; did you know I hadn't realized until a few weeks ago that some laser printers have humidity sensors in them?
02:07 PM Lambda_Aurigae: I'm guessing they took hp inkjet tech and modded it.
02:07 PM Lambda_Aurigae: many of them do
02:07 PM Lambda_Aurigae: specially color ones
02:08 PM Lambda_Aurigae: temp and humidity
02:08 PM xentrac: yeah. I took apart a 2600n and my girlfriend looked up the datasheet for this weird little board and it turned out to be a humidity sensor!
02:08 PM Lambda_Aurigae: they adjust high voltage levels depending on temp and humidity.
02:08 PM xentrac: what kind of temperature sensors do they use? surface-mount thermistors?
02:08 PM Lambda_Aurigae: sharp mx-2600n?
02:08 PM xentrac: LaserJet Color 2600n
02:08 PM Lambda_Aurigae: oh.
02:08 PM xentrac: sorry
02:09 PM Lambda_Aurigae: the sharps and xeroxes use specialized temp sensors.
02:09 PM Lambda_Aurigae: both temp and humidity on the same little board usually too.
02:09 PM xentrac: is there a way to recognize them when you're ripping the thing apart?
02:09 PM Lambda_Aurigae: I think they are made by maxim/dallas.
02:09 PM Lambda_Aurigae: know what you are looking at
02:10 PM xentrac: because I looked up thermistors on Digi-Key and decided that there was no possible way I could tell an SMD thermistor from any other SMD resistor
02:10 PM Lambda_Aurigae: a matter of paying attention and looking things up before you destroy or toss.
02:10 PM Lambda_Aurigae: there isn't.
02:10 PM Lambda_Aurigae: not really.
02:10 PM xentrac: I mean except to heat it up while measuring its resistance and being like "what a shitty temperature coefficient"
02:10 PM Lambda_Aurigae: yeah.
02:11 PM Lambda_Aurigae: most(all) resistors can be used as temperature sensors given the right circuit and calibration and all.
02:11 PM Jartza: hallo
02:11 PM Lambda_Aurigae: heya Jartza
02:11 PM Jartza: hi Lambda_Aurigae
02:11 PM Lambda_Aurigae: I'm making a wind turbine with a BLDC motor out of a copier!
02:11 PM Lambda_Aurigae: hehe
02:12 PM Lambda_Aurigae: xentrac, I'm working on a colorqube right now in fact.
02:12 PM Lambda_Aurigae: I'll take some pics of it naked.
02:21 PM xentrac: heh, that's true
02:21 PM xentrac: but some of them are a lot better at it
02:21 PM xentrac: I'd love to see the naked pics
02:22 PM Lambda_Aurigae: https://drive.google.com/drive/folders/0BxaP1wMEe_6aT3BZaDYwZzZkMXc?usp=sharing
02:23 PM xentrac: gorgeous
02:24 PM Lambda_Aurigae: 13440 is the 4 printheads
02:24 PM xentrac: what was wrong with it?
02:25 PM Lambda_Aurigae: it's dead jim!
02:25 PM xentrac: have you read jacquesm's writeups of his windmill project?
02:25 PM Lambda_Aurigae: or at least, has martian mumps and will be dead soon.
02:25 PM polprog: thats a hell of a printer
02:25 PM xentrac: 134440?
02:25 PM Lambda_Aurigae: I've read dozens of windmill projects.
02:25 PM xentrac: which ones do you recommend?
02:25 PM Lambda_Aurigae: that's the last digits on the photo number.
02:26 PM Lambda_Aurigae: I've been reading them for years..never built one..so no clue.
02:26 PM xentrac: heh
02:26 PM Lambda_Aurigae: polprog, 25000 USD for that printer
02:26 PM polprog: wow
02:27 PM Lambda_Aurigae: yeah.
02:27 PM Lambda_Aurigae: and worth every penny of none of it.
02:27 PM xentrac: cheap at half the price
02:27 PM Lambda_Aurigae: biggest pieces of sh*t ever created.
02:27 PM specing: lol
02:27 PM Lambda_Aurigae: tektronix couldn't make it work so mothballed it.
02:27 PM Lambda_Aurigae: then xerox found out about it and someone there thought it would be fun to play with
02:27 PM specing: you sure there is not a shittier printer in existance?
02:27 PM Lambda_Aurigae: so they bought the entire division.
02:28 PM xentrac: <specing> it would have worked if Tektronix had used Ada
02:28 PM Lambda_Aurigae: specing, not that I'm aware of.
02:28 PM specing: xentrac: yeah
02:28 PM Lambda_Aurigae: give me a laser/toner device any day!
02:28 PM Lambda_Aurigae: when working on this thing, expect to take half a day.
02:29 PM Lambda_Aurigae: turn it off, make change, turn on, wait 15 to 20 minutes before it will actually print..
02:29 PM Lambda_Aurigae: and when working on the printheads and connected bits, you have to let it cool half an hour before disassembling or you end up with molten wax ink all over..
02:29 PM Lambda_Aurigae: said wax/ink is conductive when molten too.
02:30 PM xentrac: that's weird! is the pigment ionic?
02:30 PM Lambda_Aurigae: no clue.
02:31 PM Lambda_Aurigae: not sure if it's conductive solid..never checked.
02:31 PM Lambda_Aurigae: but the reservoir sensors are just two metal strips in a narrow V down into the ink.
02:31 PM xentrac: oh, that would be a lot less mysterious
02:31 PM Lambda_Aurigae: the more ink in there the less the resistance.
02:31 PM xentrac: right
02:32 PM xentrac: even if it weren't conductive you could probably measure its permittivity
02:32 PM xentrac: which is probably higher than air's
02:32 PM xentrac: like a capacitive humidity sensor
02:33 PM Lambda_Aurigae: I've been working on this machine now on and off for 2 weeks.
02:33 PM Lambda_Aurigae: every time I fix one error another comes up.
02:33 PM Lambda_Aurigae: it is like the thing took a lightning hit or something.
02:33 PM Lambda_Aurigae: heaters blown, power supply not putting out the right voltages, boards acting flaky.
02:34 PM xentrac: no wonder you hate it
02:34 PM Lambda_Aurigae: and, as I said, replace one part and it's 20 minutes till you know if that fixed something or not.
02:34 PM Lambda_Aurigae: I've replaced 8 parts today.
02:34 PM Lambda_Aurigae: and about to do at least 1 if not 2 more.
02:34 PM xentrac: so it's off to the glue^Wwindmill factory?
02:34 PM Lambda_Aurigae: I have another 3 hours of work..
02:35 PM Lambda_Aurigae: well, the motor I have is from another one that came to us dead..
02:35 PM xentrac: oh, haha
02:35 PM Lambda_Aurigae: first time we fired it up it leaked ink everywhere and just fried stuff all over.
02:35 PM xentrac: that half-horsepower precision motor might be worth a couple hundred bucks on its own
02:35 PM Lambda_Aurigae: it never worked right...we finally called it DOA and it became an organ donor.
02:35 PM Lambda_Aurigae: 40 dollars on ebay.
02:36 PM xentrac: seriously?
02:36 PM Lambda_Aurigae: http://www.ebay.com/itm/SHINANO-DR-85310-001-147-0193-70-MOTOR-/351390018948
02:36 PM Lambda_Aurigae: it's custom for Xerox
02:36 PM Lambda_Aurigae: no documentation anywhere that I can find on it beyond the sticker on the back.
02:37 PM Lambda_Aurigae: found 3 more steppers in the same machine that are the same way..custom built..similar to others out there but like nothing on the sensor units and such.
02:37 PM Lambda_Aurigae: I'm thinking getting two more of them to use in a homemade tank.
02:37 PM Lambda_Aurigae: RC tank
02:38 PM Lambda_Aurigae: something the size of a go-cart.
02:40 PM xentrac: yeah, but using a BLDC motor without a datasheet is a lot more tractable than, say, using one of those custom Epson microprocessors without a datasheet
02:40 PM xentrac: half a horsepower seems like it would be an extremely decent go-kart, especially if you put one on each wheel
02:43 PM polprog: could you tell me if thats ok for a beginner hot air solder joint? 62sn/36pb/2ag paste
02:43 PM polprog: https://drive.google.com/file/d/0B7nrducTAtMTM1NxOEZJRlFFS2s/view?usp=drivesdk
02:45 PM Lambda_Aurigae: polprog, long as you don't want it to last too long.
02:45 PM Lambda_Aurigae: looks cold to me.
02:45 PM polprog: hmm
02:45 PM polprog: not enough flux?
02:45 PM polprog: or wrong temp?
02:45 PM Tom_itx: yes
02:46 PM Tom_itx: too much solder for one
02:46 PM Lambda_Aurigae: from what I can see, it looks like cold solder joints.
02:46 PM Tom_itx: i wipe the pads with a flux pen if i'm using solder paste manually
02:47 PM Tom_itx: i seldom do that though since i've got .015" solder
02:47 PM Lambda_Aurigae: hehe.
02:47 PM Lambda_Aurigae: wish I had a hot air rework station.
02:47 PM Tom_itx: it would be handy
02:47 PM xentrac: it seems like they should be easy to build
02:47 PM Tom_itx: what little i do now, it wouldn't be worth it
02:47 PM polprog: Lambda_Aurigae: i have one of those dremmel hot air gas irons
02:48 PM polprog: it was easy to get, ill tell you the story later
02:48 PM xentrac: type-K thermocouple, a resistor, a transistor to turn it off, an AVR with PID control, and a fan?
02:48 PM polprog: damn its still a cold joint even after reflowing with flux again
02:49 PM Tom_itx: wick some of that solder off it
02:49 PM polprog: will do
02:50 PM Tom_itx: btw, that top resistor is backwards
02:50 PM Tom_itx: or the other two are
02:50 PM polprog: yes, it triggers me too ;)
02:51 PM xentrac: haha
02:51 PM polprog: "resistor is backwards"
02:52 PM polprog: hehehe
02:52 PM Tom_itx: http://tom-itx.no-ip.biz:81/~webpage/boards/atmega32u4/atmega32u4_1.jpg
02:52 PM Tom_itx: that was completely hand soldered
02:52 PM polprog: i saw that
02:52 PM polprog: ;)
02:54 PM polprog: https://drive.google.com/file/d/0B7nrducTAtMTbFllYW44Zm5Rd0k/view?usp=drivesdk
02:54 PM polprog: thats my assembly learning thing
02:54 PM polprog: it will be expanded over time
02:55 PM Lambda_Aurigae: I do almost everything through hole or bent pin smt.
02:55 PM Lambda_Aurigae: depends on how lazy I am feeling.
02:55 PM Lambda_Aurigae: and whether or not I want to drill holes.
02:55 PM polprog: bent pin smt is like a dip mounted smd?
02:55 PM Lambda_Aurigae: yup.
02:55 PM polprog: heh, i got that idea too once
02:56 PM Lambda_Aurigae: my best though was the ultimate through hole smt installation.
02:56 PM polprog: useful if you are a cheapskate and you get your rasterboards single sided
02:56 PM Lambda_Aurigae: tqfp 144 chip
02:56 PM Lambda_Aurigae: put the evenpads on top of the board
02:56 PM Lambda_Aurigae: odd pads on bottom of the board.
02:56 PM Lambda_Aurigae: then cut a hole that the CHIP would fit through the board.
02:56 PM polprog: wow
02:56 PM Lambda_Aurigae: bent the even pins up, stuck it in the hole and soldered the odd pins down
02:57 PM Lambda_Aurigae: then bent the even pins down and soldered them one at a time.
02:57 PM Lambda_Aurigae: flush mount tqfp chip.
02:58 PM Lambda_Aurigae: I want to do some of those again with something in the 32bit range on a business card.
02:58 PM Lambda_Aurigae: flush mount everything.
02:59 PM Tom_itx: cut square holes in the board and flush mount the smd chips
03:00 PM polprog: i wanted to mess around to breakout the raspi compute module, that needs a 144pin so dimm, im nout sure how hard is that to do
03:10 PM Lambda_Aurigae: number 2 printhead leaked ink all over number 1 printhead, causing number 1 to fail and report no reservoir fill...and yet another error in a long line of errors!
03:11 PM Lambda_Aurigae: Tom_itx, that's what I did...but I put half the pins on top and half on bottom..gave me more room to solder.
03:13 PM polprog: is the stuff on avr-libc site the "proper" assembly?
03:13 PM polprog: http://www.nongnu.org/avr-libc/user-manual/assembler.html
03:18 PM Lambda_Aurigae: it is for that assembler, yes
03:24 PM xentrac: polprog: gas uses AT&T syntax, which is more visually pretty but I think less readable than the Intel syntax that Atmel prefers
03:24 PM cehteh: its often a bit confusing as 'assembler' isnt specified as stringently as C for example. different assembler programs can have different features and even different syntax for one and the same platform
03:25 PM xentrac: true of diffrent C compilers too ;)
03:25 PM cehteh: for C you have at least some standards you can refer to
03:25 PM cehteh: for assembler only the result, the machine code you get at the end matters :D
03:25 PM xentrac: the C standards suck pretty badly though
03:26 PM cehteh: in some parts yes
03:26 PM cehteh: but thats C :)
03:26 PM cehteh: love it or hate it
03:26 PM xentrac: or fix it
03:26 PM cehteh: there is a lot historic crap wich cant easily be fixed
03:27 PM cehteh: at least not compatibly, you would get some new language with a C like syntax
03:29 PM polprog: crap, the example on that site uses some deprecated stuff
03:29 PM cehteh: as in?
03:30 PM specing: xentrac: git gud in Ada
03:30 PM cehteh: AT90S1200 ?
03:30 PM cehteh: sounds like a old mcu
03:31 PM Lambda_Aurigae: it is.
03:31 PM Lambda_Aurigae: but the basic avr core commands are the same for the most part.
03:31 PM Lambda_Aurigae: might be some new ones added, probably are.
03:31 PM xentrac: cehteh: the language specified in the C standards is "some new language with a C-like syntax", and that's the problem
03:32 PM cehteh: lol
03:32 PM Lambda_Aurigae: we should all be programming in B
03:32 PM cehteh: BCPL
03:33 PM cehteh: i am happy that C still evolves .. and not as drastically as C++ which is a complexity nightmare now
03:34 PM xentrac: yeah. unfortunately it's evolving in a direction that serves compiler vendors at the expense of users
03:34 PM polprog: arrgh. how can i know that the code in tutorial X will work with avr-gcc
03:34 PM cehteh: still many except very old (k&r syntax) programs still work more or less in modern C compilers, sometimes you have to relax the checks with some options or do some light fixes but its still ok
03:35 PM cehteh: by trying
03:35 PM cehteh: (or knowing/learning)
03:37 PM xentrac: yes, but almost all of those programs execute "undefined behavior" on almost every execution. as do new programs
03:38 PM xentrac: have you read http://blog.regehr.org/archives/1292?
03:39 PM xentrac: polprog: code in a tutorial will probably still work with avr-gcc. gcc isn't changing that fast
03:40 PM antto: it haz C++11
03:41 PM xentrac: from the comments: "I find this article very scary. SQLite is in my opinion the highest quality major open source C project. SQLite’s approach to correctness borders on fanatical ( they have 800 lines of test code for every line of library code).
03:41 PM xentrac: "It is also one of the most widely deployed pieces of code (there are probably around a billion instances of SQLite running right now). If despite this, there is still undefined behavior, what hope does any C or C++ project have of not having undefined behavior?"
03:41 PM xentrac: and that is absolutely correct.
03:41 PM xentrac: except I can't vouch for the 800
03:42 PM xentrac: Hipp himself weighed in: "Prof. Regehr did not find problems with SQLite. He found constructs in the SQLite source code which under a strict reading of the C standards have “undefined behaviour”, which means that the compiler can generate whatever machine code it wants without it being called a compiler bug."
03:43 PM xentrac: "That’s an important finding. But as it happens, no modern compilers that we know of actually interpret any of the SQLite source code in an unexpected or harmful way."
03:43 PM Emil: polprog: what's the issue?
03:43 PM xentrac: "The point of Prof. Regehr’s post (as I understand it) is the the C programming language as evolved to contain such byzantine rules that even experts find it difficult to write complex programs that do not contain UB."
03:43 PM xentrac: And that is also absolutely correct.
03:43 PM Emil: also compile coders are the scum of earth
03:43 PM Emil: the fuckers will do absolutely disgusting things if they are technically allowed to in the name of perd
03:43 PM Emil: perf*
03:44 PM Emil: I should compile a list of gcc arguments that are absolutely necessary
03:44 PM polprog: hmm, ive included <avr/io.h> from that tutorial (the libc site) and it says DDRD is not recognized
03:44 PM Emil: then either: no DDRD on chip or you have written wrong
03:45 PM Emil: both are absolutely possible
03:45 PM Emil: not all chips have ddrd
03:45 PM Lambda_Aurigae: what chip do you have selected to compile to?
03:45 PM xentrac: it's possible you're trying to compile it for a chip which doesn't have a port D
03:45 PM xentrac: even if the chip you are actually using does
03:45 PM Emil: also thay
03:46 PM polprog: Lambda_Aurigae: tiny4313, it has ddrd
03:46 PM Emil: which is why I use my own cancerous script to compile and upload instead of even more cancerous but industry stabdard makefiles
03:46 PM polprog: im now including fr_defs.h
03:46 PM polprog: sfr_defs.h*
03:46 PM polprog: lets see
03:46 PM polprog: no, doesn't work. Undefined reference to DDRD
03:46 PM xentrac: the tiny4313 has a port D?
03:47 PM Lambda_Aurigae: xentrac, yes
03:47 PM xentrac: maybe the definition of the tiny4313 in avr-libc is wrong
03:47 PM Lambda_Aurigae: now, is that chip supported fully by the version of avr-libc you have there?
03:47 PM Lambda_Aurigae: isn't it one of the new chips?
03:47 PM polprog: let me check
03:47 PM xentrac: yeah, it's pretty new
03:47 PM xentrac: Emil: you don't trust make?
03:47 PM polprog: it says it is
03:48 PM xentrac: Emil: have you thought about just writing everything in your own dialect of Forth if you don't trust anything? ;)
03:48 PM Emil: xentrac: nonono
03:48 PM Emil: it's not that I dont trust make
03:48 PM Emil: I absolutely do
03:48 PM Emil: it is a tried and verified program
03:48 PM Emil: it is that I absolutely loathe the syntax and refuse to use such tumour indusing tools
03:49 PM Emil: :D
03:49 PM Lambda_Aurigae: glad I'm not the only one.
03:49 PM Lambda_Aurigae: I have written make programs in csh, bash, and C
03:49 PM polprog: wait, it's a linker error
03:49 PM Lambda_Aurigae: well, build scripts anyhow.
03:50 PM Lambda_Aurigae: aahh
03:50 PM polprog: what should i put in the gcc invocation?
03:50 PM xentrac: Emil: have you tried redo? you will probably like redo a lot
03:50 PM Lambda_Aurigae: polprog, so, gcc supports it but ld does not.
03:50 PM polprog: crap
03:50 PM Lambda_Aurigae: your binutils-avr needs to be updated.
03:50 PM xentrac: no
03:50 PM Lambda_Aurigae: or avr-binutils
03:50 PM Lambda_Aurigae: either way.
03:50 PM xentrac: I don't think
03:50 PM Emil: xentrac: what I like are standards and verified programs
03:50 PM Emil: is redo such?
03:50 PM xentrac: I mean is the linker really responsible for defining DDRD?
03:50 PM Emil: I also absolurely hate splintering of tools
03:50 PM xentrac: I'd think that would be defined in a .h file
03:51 PM xentrac: with, like, a #define or enum
03:51 PM Lambda_Aurigae: xentrac, if you try to link against something that's not proper, you can get such an error.
03:51 PM polprog: let me summarize it in a paste so we can get the whole picture
03:51 PM Lambda_Aurigae: that would help.
03:52 PM Lambda_Aurigae: a word is worth a thousand pictures.
03:52 PM Emil: polprog: you do have -Wall and -Werror on?
03:52 PM xentrac: not if the C preprocessor is replacing DDRD with an absolute memory address. but I guess I shouldn't comment since I haven't looked at how avr-libc implements things like PORTA and PINB
03:52 PM Emil: xentrac: defines for volatile addresses
03:53 PM xentrac: then the problem isn't the linker because the linker will never see "DDRD"
03:53 PM xentrac: Emil: make is standardized by POSIX
03:53 PM polprog: http://wklej.org/id/3090528/ , hastebin acting up
03:54 PM xentrac: standards and not splintering tools is why I use make
03:54 PM Emil: something like #define DDRB *(volatile unsigned char*)number)
03:54 PM polprog: i never did assembly before
03:54 PM xentrac: not because it's so much better than everything else
03:56 PM xentrac: cehteh: http://blog.regehr.org/archives/1307 explains how e.g. https://stackoverflow.com/questions/1349542/john-carmacks-unusual-fast-inverse-square-root-quake-iii is not allowed by standard C
03:56 PM Emil: but I mean
03:56 PM Emil: I dont see how you can have link errors here
04:04 PM polprog: stupid avrfreaks forum blanks out the #includes
04:07 PM Emil: Yeah the format they write in is idiotic imho
04:10 PM polprog: im searching other code examples but i cant find any clue what may be ering in that DDRD. i tried _SFR_IO_ADDR(DDRD) and it says "missing ,"
04:12 PM twnqx: i have written things in "make" that should have never been written in it :S
04:16 PM polprog: hmm i changed DDRD to 0x31 (its id from the datasheet) and it compiles
04:16 PM polprog: weird
04:16 PM Emil: not weird
04:16 PM polprog: it would be nice to be able to write DDRD instead of 0x31
04:16 PM polprog: easier to read
04:22 PM Lambda_Aurigae: still say it sounds like you need to update binutils
04:23 PM polprog: im doing it on my xubuntu lappy, no binutils update. ill try on arch tomorrow
04:24 PM polprog: it works with 0x31 instead of DDRD
04:27 PM Jartza: polprog: what assembler are you using?
04:27 PM Jartza: I suggest to try http://www.avr-asm-tutorial.net/gavrasm/index_en.html
04:28 PM polprog: damnit i put this away for tomorro
04:28 PM Jartza: that is compatible with atmel studio assembler
04:28 PM Jartza: the code, I mean
04:28 PM Jartza: and macros etc
04:29 PM polprog: the laptop's display just died
04:29 PM polprog: Jartza: im using avr-gcc
04:29 PM polprog: thanks for all the help
04:29 PM polprog: goodnight
04:29 PM Emil: polprog: just do the define yourself :D
04:29 PM polprog: i did :D
04:30 PM Jartza: polprog: ouch, gcc asm syntax is horrid
04:30 PM Jartza: I never liked it, and I don't use it unless I really have to
04:37 PM xentrac: I don't mind it much; I used it as the output format for Ur-Scheme
04:37 PM xentrac: but I do think the Intel syntax is better
04:58 PM Emil: Hmm
04:58 PM Emil: Hey
04:58 PM Emil: Hmm, I think sadly no
04:59 PM Emil: Wondering if I could do #include <SOMETHING> but that would require running the preprocessor twice
04:59 PM Emil: right?
04:59 PM Emil: where SOMETHING is a #define statement
04:59 PM xentrac: hmm, I don't think you can use a macro to tell the preprocessor which file to include, no
04:59 PM xentrac: but I haven't tried
05:01 PM specing: I think you can
05:02 PM specing: but Ada is still superior :D
05:08 PM cehteh: you can use #include SOMETHING (w/o the <> and "")
05:09 PM Emil: cehteh: you mean
05:09 PM Emil: #define SOMETHING stdio
05:09 PM Emil: #include SOMETHING
05:09 PM Emil: works?
05:09 PM Emil: #define SOMETHING stdio.h*
05:09 PM cehteh: there you need the <>
05:09 PM cehteh: or gcc -D'STDIO=<stdio.h>'
05:10 PM Emil: you said without
05:10 PM cehteh: without the #include <SOMETHING>
05:10 PM cehteh: there
05:10 PM Emil: ah
05:10 PM cehteh: mhm lemme try maybe even that works
05:10 PM Emil: so #define STDIO <stdio.h> should work
05:10 PM cehteh: no doesnt
05:11 PM cehteh: that .. yes
05:11 PM cehteh: interlaced discussion :D
05:11 PM cehteh: just try
05:12 PM Emil: yeah :D
05:13 PM Emil: I'm just doing something absolutely horrible for my friend who is having his C course
05:13 PM Emil: https://emil.fi/jako/kuvat/2017-04-20_00-43-27_bGfbELv1_putty.png
05:14 PM Emil: there's errors yet
05:14 PM Emil: dunno how far I can push the cancer
05:15 PM specing: aww man there is always beauty in chaos
05:15 PM specing: wait what, unicode macro names? gcc can eat that?
05:16 PM specing: Emil you are using Nano ?!?!?!
05:16 PM Emil: IIRC yes :D
05:16 PM specing: #emacsmasterrace
05:16 PM Emil: specing: nano masterrace 😎
05:16 PM specing: wheres PERHELE?
05:16 PM specing: PERKELE*
05:16 PM Emil: It's coming
05:17 PM specing: but really how can you use nano seriously
05:17 PM Emil: I have to actually think how to do it since this much fucking around is making the actual coding harder
05:17 PM Emil: specing: because I quite like it
05:17 PM Emil: Though I do agree that VI(M) is superior
05:17 PM specing: as compared to emacs and vim?
05:17 PM Emil: But it's like
05:17 PM Emil: git is also super fucking important
05:17 PM Emil: and make is standard
05:18 PM Emil: but have I bothered to learn them yet
05:18 PM Emil: nääääääääääääääääääääääh
05:18 PM specing: I've heard good things about Fossil
05:18 PM specing: it has wiki & issue tracking integrated into the repo itself
05:18 PM specing: supposedly
05:20 PM specing: add some žšč as well
05:31 PM Emil: Fuck this
05:31 PM Emil: fucking around takes too much effort
05:31 PM Emil: Easier to just code normally :D
05:33 PM specing: and learn Ada
05:35 PM Emil: Remember kids
05:35 PM Emil: if you want to fuck around
05:36 PM Emil: it's easier to code nice and proper first
05:36 PM Emil: and then edit it to goofy
05:43 PM arij is now known as arij_work
05:49 PM Jartza: I coded goofy vga-thingie with C
05:49 PM Jartza: then made it proper with asm
05:51 PM specing: lol
05:51 PM specing: I've done something like that before
05:52 PM specing: It went C->ASM and then back to C a week later
05:52 PM Emil: hehe
05:54 PM Jartza: https://github.com/rakettitiede/octapentaveega
05:54 PM Jartza: this turned out to be that
05:54 PM Jartza: :P
05:54 PM Jartza: so it's old news already
05:54 PM Lambda_Aurigae: and it rocks!
05:54 PM Jartza: sure it does :)
05:54 PM Jartza: that would be pretty hard to turn back to c
05:54 PM Emil: sniff sniff
05:54 PM Emil: haistanko minä täällä itsekehua
05:56 PM Jartza: it's hard to be modest when you're as good as me
05:56 PM Jartza: :D
05:56 PM Jartza: lol
05:57 PM Emil: :p
06:28 PM Jartza: that surely was convo killer :D
06:57 PM Emil: Nah
06:57 PM Emil: just sleepy
07:00 PM Lambda_Aurigae: creating a new race of Merfolk for Worlds of Darkness/Changeling the Dreaming Roleplay game.
08:27 PM arij_work is now known as arij
10:04 PM rue_shop3: hmm
10:17 PM Tom_itx: hmm?
10:18 PM Casper: hmm!
10:19 PM Tom_itx: hrm