#avr Logs

Jan 13 2018

#avr Calendar

12:33 AM day__ is now known as day
02:11 AM nux_ is now known as nuxil
04:10 AM day__ is now known as day
04:57 AM polprog: < Emil> polprog: also I see you have RSS
04:58 AM polprog: What do you mean?
04:58 AM polprog: ah, rainbow six
04:59 AM polprog: i need to play it... it very different than other games :P
05:00 AM polprog: (this is the first Rainbow six)
05:01 AM nuxil: "I need to play it", its called. i got video game addiction :p
05:02 AM nuxil: mornings btw
05:02 AM polprog: mornings
05:03 AM polprog: its not like i play all the time
05:03 AM polprog: last time i played one of those (fallout nv) it was 2 weeks ago or so
05:04 AM nuxil: im just having fun with google searches. like type in "white couple" and you get mixed races. type balck couple and you see only black people. type in: american inventors. and you see 90% black people on the list. google is so lol.
05:04 AM polprog: lol
05:07 AM nuxil: Alot of this google lawsuit on YT. i hope James Damore wins this lawsuite.
05:08 AM polprog: yeah, its cringeworthy. both alt-left and alt-right are idiots to me
05:08 AM polprog: extremism is never good
05:09 AM day__ is now known as day
05:09 AM nuxil: no its not.
05:10 AM nuxil: anywho. time to go do some shopping.
05:10 AM polprog: have fun
05:10 AM nuxil: lol. shopping food is never fun :p
05:10 AM polprog: haha
05:10 AM polprog: make it fun!
05:37 AM karols146: Best way to connect osciloskope on unix to os ?
06:03 AM Jartza: that question doesn't make any sense
06:03 AM Jartza: NMI
06:04 AM Jartza: (Need More Info)
06:04 AM antto: the best way is the one that stands out amongst all the rest ways
06:05 AM polprog: USB + sigrok unless it uses GPIB
06:05 AM polprog: in that case webcam + guvcview
06:06 AM antto: i tried sigrok with the cheap rigol
06:07 AM antto: well, maybe didn't look deep enough, but i expected more
06:08 AM antto: how hard is it to make a f*cking oscilloscope that has a UI that doesn't suck?!
06:26 AM polprog: hahaha
06:26 AM polprog: yeah, but in case of ds1054z sigrok aint better
06:27 AM polprog: especially if it cannot decode from analog traces
06:27 AM polprog: anyway i have this saelae clone wich works wonders and i use the riglol when i need to measure analog stuff (power rails, etc)
07:12 AM karols146: Yea sigrok, it's a best way for me. Thanks for answer
07:13 AM karols146: wow i got ds1054z too, so good to have tips
07:14 AM antto: the one at the job is DS1052E or some such
08:22 AM jragon: Finally! My graph is drawn properly :) Rather than drawing over the entire graph region it just draws a black line over the previous line. This means that it looks smooth at much higher refresh rates: my graph works now https://streamable.com/4jwuy
08:47 AM nuxil: jragon, nice.. what are you making ? oscillioscope or something?
08:48 AM jragon: PID controller
08:48 AM nuxil: oki
08:49 AM jragon: Hopefully it should graph the input, setpoint and output
08:49 AM nuxil: what are you gonna use it for?
08:50 AM jragon: a boost converter
08:50 AM nuxil: are you working on a system that needs a pid. or just for the fun
08:50 AM nuxil: ah k.
08:50 AM jragon: It also communicates over uart with my pc. You can set all the information there
08:51 AM nuxil: that nice
08:51 AM jragon: It's just for fun really. Most of the components can all be reused easily
09:23 AM Ameisen: I suspect I'm going to base this motion controller off of an ARM chip
09:23 AM Ameisen: I can get it running so far at 8KHz on a 2560, but that's kinda slow
09:23 AM Ameisen: ideally, I'd be around 200KHz
09:24 AM Ameisen: fixed point would fare better but would still be short of the goal
09:41 AM karols146: Anyone got workink Rigol DS1054Z with pulseview and sigrok
09:41 AM karols146: ?
10:29 AM polprog: karols146: i got but it is not worth it, unless you want to save waveforms to your computer
10:30 AM polprog: i dont remember whether it was over LAN or USB. i think the latter one worked
10:31 AM Emil: jragon looks great!
10:33 AM polprog: jragon: wow sweet graph!
10:34 AM polprog: karols146: and if you want to use sigrok to decode protocols then its not that simple, use the rigols builting decoder (kinda sucks but hey that's a 200$ scope!) or get a saelae clone which works wonders with sigrok
10:34 AM jragon: thanks guys! :)
10:34 AM polprog: i was thinking about making an analog to digital thresholder as a sigrok plugin which would enable people to decode from analog waveforms (protocol decoders work mostly with digital waveforms in sigrok)
10:35 AM polprog: also the sigrok gui is called pulseview
10:38 AM polprog: wow thats a weird part message lol
10:44 AM karols146: I got salae clone, now I try got only waveform saving
10:44 AM karols146: like pics on computer
10:45 AM polprog: i'd have to open up the linux laptop, but variable change dump (vcd) seem to be the most common i guess
10:46 AM polprog: theres an option in the menu to export them, but as i said i dont remember, would have to start up the laptop
10:48 AM polprog: haha you can see some of the relatively "working" GPU memory ranges there: https://www.reddit.com/r/iiiiiiitttttttttttt/comments/7pt15s/hey_guys_check_out_my_new_surface_book/
10:50 AM karols146: polprog: I got i opened but when press run nothing happened, how to save waveform in a easy way ?
10:50 AM polprog: you press run on the scope or in sigrok?
10:51 AM polprog: let me kick up the workshop pc
10:52 AM karols146: yea
10:53 AM karols146: got sr: rigol-ds: Read error, aborting capture.
10:54 AM polprog: hmm
10:54 AM polprog: usb i suppose
10:54 AM polprog: right?
10:54 AM polprog: what firmware ver do you have on the rigol?
10:54 AM karols146: 00.04.04.SP1
10:54 AM karols146: Board 0.1.4
10:55 AM karols146: But when I change options on pulse view, I see changes on rigool
10:55 AM polprog: ok, that's a good start
10:55 AM polprog: actually you have a newer version than me :P
10:56 AM karols146: but I got Rigol DS1104Z on pulseview
10:56 AM karols146: and I got DS1054Z,
11:00 AM karols146: now i got only one channel working
11:05 AM polprog: if you enable a channel on the scope panel, then pulseview wont detect it and will reset it to its settings
11:06 AM polprog: theres a cogwheel icon somewhere there where you can select channels
11:11 AM karols146: ok i check it
11:14 AM polprog: good excuse for me to install it on the workshop pc lol
11:20 AM karols146: I turned off chanels on scope
11:26 AM karols146: Hmmm I got only on channel
11:39 AM polprog: got it i think
11:42 AM polprog: let me upload this
11:43 AM polprog: just a sec
11:45 AM polprog: karols146: https://www.youtube.com/watch?v=2AWC0zHbj6o
11:45 AM polprog: hmm i should make a longer video on libsigrok
11:45 AM polprog: pulseview*
11:54 AM karols146: ok
11:54 AM karols146: I see a problem, you got rigol DS1054Z
11:54 AM karols146: I got DS1104Z
11:54 AM karols146: Hmmm
11:54 AM karols146: I wonder how to set it up
11:55 AM karols146: how you install pulseview ?
11:55 AM polprog: i have debian sid so its in the repository
11:55 AM polprog: but sid has its own annoyances
11:56 AM polprog: on the laptop i have arch, where it's in the repository as well
11:56 AM karols146: so I think that I need just to rebuild all from scratch
11:57 AM polprog: you can save WFM (proprietiary format) files to a pendrive
12:02 PM karols146: ok I got this
12:03 PM karols146: i got unlocked rigol so that's why there is another rigol
12:04 PM polprog: ?
12:04 PM polprog: what do you mean
12:04 PM polprog: also, what distro are you on?
12:05 PM karols146: Freebsd
12:06 PM karols146: When you unlock rigol pulseview see DS1054 like other rigol
12:13 PM polprog: using the keygen?
12:14 PM karols146: yea
12:16 PM polprog: hows freebsd in terms of binary packages?
12:17 PM polprog: i just installed debian over netbsd on this workshop desktop, im curious if other bsds have the same problem
02:18 PM eszett: re..
02:20 PM Jartza: eveningh
02:33 PM nuxil: whats up.
02:34 PM polymorph: hello my friends
02:34 PM polymorph: Happy new year!
02:35 PM polymorph: brought some read: https://pastebin.com/z0sw6hK7 https://pastebin.com/B0DBzNYp https://pastebin.com/v1wEu4Xd
02:36 PM nuxil: hmm.. you been busy
02:36 PM polymorph: Now i need to calculate the path length of my Interpolated Cubic Spline :( https://pastebin.com/DUp9tWju
02:49 PM polymorph: Si/IEC prefixes printf(value) and symbol in C https://pastebin.com/eEX68wt9
02:53 PM Emil is now known as Guest4197
02:54 PM Guest4197 is now known as Emil
02:55 PM nuxil: i was sitting here woundering how can i reduce my 8button keypad that uses 8 I/O ports to something minimum.
02:56 PM nuxil: making a "manual dac" reduces the i/o from 8 to 1 https://gyazo.com/e03948911a0ceaba8601146debf53015 :p
02:56 PM polymorph: matrix
02:56 PM nuxil: nah :p
02:56 PM polymorph: multiplex it ;>
02:57 PM polymorph: i like capacitive buttons more, they don't di
02:57 PM polymorph: e
02:59 PM nuxil: i dont.. i like to feel that im pushing something.
03:04 PM polymorph: :) you know that it can be made button-like right?
03:05 PM polymorph: It needs a rubbery pushblob and a piece of metaal foil
03:05 PM polymorph: It looks like i will have to bisectionally iterate the path lenght of my interpolated Cubic Spline? :(
03:06 PM twnqx: and audible feedback, like any good switch
03:06 PM polymorph: twnqx: no worries, press hard enough and it will indicate with a cracking sound
04:10 PM eszett: Just ordered some Pimoroni-Headers
04:12 PM eszett: With that, I hope to have a cheaper solution of connecting wires to my PCBs, than with a Tag-Connect cable
04:13 PM eszett: I hate it, to solder pin headers, or something in, just for a temporary connect, and have to desolder them afterwards
04:26 PM polymorph: you could pogopin pads
04:29 PM eszett: hm, ye, but don't know much about how to achieve that.
04:30 PM eszett: The most "clean" solution for ISP is probably to have a Tag-Connect footprint on the PCB to use it with a Tag-Connect-cable, but for example the TC2030-IDC costs about 35 euro, which is pretty expensive
04:31 PM polymorph: if you want cheap, leave pads for pogopins, make pogopins out of something
04:31 PM polymorph: pci slots have spring contacts too
04:32 PM polymorph: they are gold plated
04:38 PM eszett: okeay.. well now I ordered the pimoronis https://shop.pimoroni.com/products/gpio-hammer-header if that doesn't satisfy I check pogo pinnos
05:12 PM polymorph: abcminiuser_: hey dude
05:12 PM abcminiuser_: hoy
05:12 PM abcminiuser_: ahoy, rather, still waking up
05:20 PM polymorph: do you like this stuff? https://www.nxp.com/products/processors-and-microcontrollers/arm-based-processors-and-mcus/lpc-cortex-m-mcus/lpc1700-cortex-m3/256kb-flash-64kb-sram-no-can-lqfp100-package:LPC1763FBD100?fsrch=1&sr=1&pageNum=1
05:26 PM Emil: polymorph: yo
05:27 PM Emil: C didn't support that
05:27 PM Emil: iirc
05:27 PM Emil: declaring the arguments to a function with a single mention of a type
05:28 PM polymorph: i saw arm-llvm before for these what did you use?
05:29 PM polymorph: http://www.rowley.co.uk/arm/Supported_Devices.htm
05:32 PM Emil: https://emil.fi/d/2018-01-14_01-31-18_6qLu39LM.png
05:32 PM Emil: double CubicSplineInterpolate(double y0, y1, y2, y3, mu) doesn't work
05:33 PM Emil: polymorph: I mean your code
05:34 PM polymorph: oh
05:34 PM polymorph: ;/
05:34 PM timemage: you could: double CubicSplineInterpolate(y0, y1, y2, y3, mu) double y0, y1, y2, y3, mu; {} doubt anyone would recommend it though.
05:34 PM Emil: timemage: nice
05:35 PM timemage: heh
05:35 PM timemage: okay, maybe somebody would recommend it. =)
05:35 PM polymorph: double CubicSplineInterpolate_(double y0, y1, y2, y3, mu) { double a0,a1,a2,a3,mu2;
05:35 PM polymorph: did this
05:36 PM Emil: K&R can goto hell directly
05:36 PM Emil: polymorph: no
05:36 PM Emil: that does not work
05:37 PM timemage: heh
05:39 PM polymorph: Emil: and how do you like this version? ;) #define CubicSplineInterpolate(__y0__, __y1__, __y2__, __y3__, __mu__) ({ \ __clone__(__mu2__,sqr((__mu__))); \ __clone__(__a0__, __y3__ - __y2__ - __y0__ + __y1__); \ (__a0__*__mu__*__mu2__+(__y0__ - __y1__ - __a0__)*__mu2__+(__y2__ - __y0__)*__mu__+__y1__); \ })
05:39 PM Emil: ...
05:39 PM Emil: bruh
05:39 PM Emil: use a paste service
05:41 PM polymorph: Emil: https://pastebin.com/xRYSAcYf
05:41 PM Tom_L: use a different one, i don't like that one
05:41 PM Tom_L: :)
05:42 PM polymorph: ;>
05:43 PM Emil: polymorph: bruh :D
05:43 PM Emil: polymorph: macro hell is hell :D
05:43 PM Emil: but here's the thing: does it work with literals?
05:43 PM polymorph: [21:32] <polymorph> Happy new year! [21:33] <polymorph> brought some read: https://pastebin.com/z0sw6hK7 https://pastebin.com/B0DBzNYp https://pastebin.com/v1wEu4Xd
05:44 PM polymorph: [21:47] <polymorph> Si/IEC prefixes printf(value) and symbol in C https://pastebin.com/eEX68wt9
05:44 PM Emil: Whatcha guises want from a paste service
05:44 PM polymorph: plaintext, maybe highlight
05:44 PM Emil: Paste text as is, click save, get link?
05:45 PM Tom_L: i want one that will fix code for me
05:45 PM polymorph: ;>
05:45 PM polymorph: and they should pay for it
05:45 PM Tom_L: like auto correct
05:50 PM polprog: wtf this is the kind of macro that deserves to be an inline function or at least a separate c file jesus mate
05:51 PM polprog: did you get all those underscores as an extra when you bought the compiler :D
05:52 PM polymorph: no, i bought them after gcc shadoed my variables in macros calling macros :)
05:52 PM polymorph: shadowed
05:53 PM polprog: no seriously, make it an inline function
05:53 PM polymorph: nein
05:53 PM polymorph: Macro is life
05:54 PM polprog: have you seen the fibonacci macro?
05:54 PM polymorph: Also #define magic static inline
05:54 PM polymorph: magic void
05:54 PM polprog: static inline?
05:54 PM polymorph: yeah
05:54 PM polprog: is it cpp?
05:54 PM polymorph: C
05:54 PM polprog: hmm
05:55 PM Emil: :DD
05:55 PM polymorph: but note that macro is a texxt replacer, and is typeless ;>
05:55 PM Emil: polymorph: I like you already
05:55 PM Emil: You and I share similarities
05:56 PM polymorph: You like girls too?
05:56 PM Emil: yes
05:56 PM Emil: See
05:56 PM polymorph:
05:56 PM Emil: We are very similar
05:56 PM Emil: >
05:56 PM polprog: i like this too but i would not like to maintain your code
05:56 PM polymorph: hahaha imagine 6 depth macro breaking
05:57 PM polprog: anyway, whats the use of static inline? i mean, in C, variable can be static, and function can be inline... what thr hell
05:57 PM polprog: note its 1:00am here so im a bit power capped
05:57 PM Emil: polymorph: it's very clear
05:58 PM Emil: polprog: *
05:58 PM Emil: It's also 1:57 here
05:58 PM polymorph: polprog: that is what sometimes i did until i found that macro is the only way to get what i want there
05:58 PM Emil: Anycase
05:58 PM Emil: static means it's local to the file with C functions
05:58 PM Emil: and inline is a suggestion to the compiler
05:58 PM polprog: static function youre talking about
05:58 PM Emil: But it's strictly that: a suggestion
05:58 PM polprog: right?
05:58 PM Emil: But the thing is
05:58 PM Emil: macros are not more likely to generate the code you want, either :D
05:59 PM Emil: Compilers see that (hey here's this same thing again)
05:59 PM polprog: the only right way is volatile asm
05:59 PM Emil: and de facto make you a function
05:59 PM polprog: :^)
05:59 PM polymorph: Emil: yeah i'm not against optimizations, check out my 3x3 matrix transform macros
05:59 PM polymorph: gcc was happy to optimize it
06:00 PM polymorph: at every compile :)
06:00 PM Emil: polymorph: point is, simply making them macros might have no benefit
06:00 PM Emil: compared to functions
06:00 PM polymorph: they do
06:00 PM polprog: i should push lissajous renderer to github or make a video on it
06:00 PM polymorph: should i search an example code?
06:01 PM * polprog polymorphs polymorph
06:04 PM polprog: goidnight
06:07 PM polymorph: p2d_t LinearInterpolate_2d( p2d_t startpoint, p2d_t endpoint, double_t mu) { return addp2ds(startpoint, pointfromvectorin2d( mulv2d(vectorfromp2d(subp2ds( endpoint, startpoint ) ),
06:07 PM polymorph: mu * distanceofp2ds(endpoint, startpoint) ) ) )
06:07 PM polymorph: so for example layering macros that are typeless...
06:09 PM polymorph: i don't have to write 13+ versions of every logic function and the functions that could use them
06:09 PM polymorph: i know, m4 is better, but stock C has macro too
06:15 PM Emil: eh?
06:15 PM Emil: m4?
06:15 PM * twnqx prefers perl as preprozessor
06:15 PM Emil: And I was only talking performance
06:15 PM Emil: not code writability
06:18 PM polymorph: gpiops2 A GPIO PS2 driver (for Raspberry Pi (2))
06:18 PM polymorph: Emil: we have something common here, i made a ps2 keyboard with an atmega ;>
06:20 PM polymorph: random A collection of everything C - i also made a random function more than 10 years ago
06:21 PM nuxil: <polymorph> random A collection of everything
06:21 PM nuxil: reminded me of "A short hostory of nearly everything" :p
06:21 PM polymorph: well, at least his project's name is common :)
06:22 PM nuxil: *history
06:22 PM polymorph: aoeu
06:22 PM nuxil: have you hear it ?
06:22 PM polymorph: negative
06:23 PM nuxil: https://www.youtube.com/watch?v=ujGLklsWOIA
06:23 PM polymorph: okey
06:26 PM Emil: polymorph: hm?
06:26 PM Emil: whatcha referring to with the ps2 keyboard and a collection of everything C
06:27 PM polymorph: github
06:29 PM Emil: I don't understand
06:29 PM Emil: 2018-01-14 02:18:15 +0200 < polymorph> Emil: we have something common here, i made a ps2 keyboard with an atmega ;>
06:29 PM polymorph: Emil: yours no? https://github.com/emilfihlman
06:30 PM Emil: ah
06:30 PM Emil: yeah I was fucking aroundwith it
06:30 PM Emil: I should nuke my github
06:30 PM Emil: I don't support the company :D
06:30 PM polymorph: haha
06:37 PM polymorph: i think i made a double integrateBiCubicSplinePathLength(p2d_t P0, P1, P2, P3)
06:38 PM polymorph: i should test it soon ;>
07:49 PM polymorph: here is my homepage http://www.microkernel.info/
07:59 PM Casper: time to ddos it
08:12 PM polymorph: ty ;)
08:28 PM Emil: polymorph: not really a homepage, is it ;)
08:30 PM polymorph: Emil: it is the future :)
08:31 PM polymorph: mirroring all stuff and we'll see what can we do with it
11:44 PM day__ is now known as day