#avr Logs

Jul 08 2017

#avr Calendar

12:00 AM Casper: you can't push on the fluid
12:03 AM enhering: Wouldn't the fluid follow the magnetic field shape?
12:03 AM Casper: yes, which is a pull only
12:04 AM enhering: The stronger the field, the higher the force that will keep the fluid in shape
12:04 AM enhering: that force can be used to do work
12:05 AM enhering: or not?
12:05 AM Casper: don't think so
12:05 AM enhering: The force comes from the field
12:07 AM enhering: If you push a particle away from its rest position in the field it will be pulled back by the field
12:20 AM day is now known as daey
01:50 AM rue_shop3: there are paramagnetic materials, that push away from a magnetic field instead of pulling into it
02:14 AM antto: i'm a paragoogle person
02:25 AM antto: mr :twisted:
02:55 AM JanC_ is now known as JanC
05:09 AM julius: morning
05:10 AM julius: does anybody here work with c#? how "bad" is it compared to java / c++ or ist it even better in your opinion?
05:26 AM NoHitWonder^: you can make gui apps pretty quickly and easily with it. for example some serial terminal app can be done pretty quickly from ready made classes. its very similar to java. good language in my opinion.
05:27 AM NoHitWonder^: unity also uses it for scripting
05:31 AM NoHitWonder^: you usually use it with .NET or mono
08:19 AM julius: NoHitWonder__: thanks
09:40 AM aaa__: Hii can anyone suggest best programmer for ATtiny841 chip
09:43 AM LeoNerd: "anything"?
09:43 AM LeoNerd: It's ISP'able
09:44 AM LeoNerd: (Did we not do this the other day?)
09:45 AM aaa__: <LeoNerd> I have tried so much but nothing worked sooo we are planning to change the programmer
09:45 AM _ami_: which programmer did u use?
09:46 AM _ami_: try on different OS like linux.
09:46 AM aaa__: USBASP
09:46 AM _ami_: it would work.. i gaurantee you.
09:46 AM LeoNerd: GAHHHHHH
09:46 AM LeoNerd: Godfuckingdamnit
09:46 AM LeoNerd: I am 100% convincned now you are juts doing something stupildy wrong
09:47 AM LeoNerd: I don't know. maybe you mistyped a command or something
09:47 AM LeoNerd: since you didn't show us anytihngI can't be more specific
09:47 AM LeoNerd: I want to see lots of things
09:47 AM LeoNerd: Show me the temrinal window wher you DIRECTLY drove avrdude
09:47 AM _ami_: windows has any "user friendly" shell? ;)
09:47 AM LeoNerd: I want to ese the output of a console in which you typed the letters A, V, R, D, U, D again and E IN THAT ORDER followed by abnuch of other stuff and then pressed enter
09:47 AM LeoNerd: I want to see *the command* you typed and the output it gave
09:47 AM LeoNerd: I will then tell you what you did wrong and you can do a better one
09:48 AM * Tom_itx gives LeoNerd a frustration pill
09:48 AM LeoNerd: We will repeat untli either a) the chip works actually fine, or b) I concede that your programmer is broken
09:48 AM LeoNerd: Until we have played this game of you showing me screenshots I will not be happy to accept that your programmer is insufficient for this task
09:48 AM LeoNerd: Shall we play?
09:49 AM _ami_: LeoNerd: he was telling that (at #arduino ) usbasp is not getting detected on windows event he has installed "correct" drivers. :P
09:49 AM _ami_: eve*
09:49 AM _ami_: even*
09:49 AM LeoNerd: Ahh
09:49 AM LeoNerd: Well that's new to me.
09:50 AM LeoNerd: It's quite possible so because the usbasp is a huge pile of vusb *crap* that might or mightnot work depending on the phase of the moon and the roll of a loaded d6
09:50 AM LeoNerd: Mine happens to work on the root port in Linux, but not via any hub I've ever tried
09:50 AM _ami_: yeah, it does not work well on hub.
09:50 AM LeoNerd: But that doesn't sound consistent with the error messages that were claimed as a result
09:50 AM Tom_itx: get a real programmer would be a good place to start
09:50 AM LeoNerd: Specifically, the one where it performed a signature check and got the results 'flu' out
09:51 AM LeoNerd: (Or some other letters; I forget the exact order)
09:51 AM LeoNerd: but anyway, the signature came back as all lowercase letters, leading me to think user had typed the wrong -P argument
09:51 AM LeoNerd: which shouldn't be necessary or even accepted, given the correct -c argument
09:51 AM LeoNerd: Which lead me further to suspect the user had typed the wrong command. Hence my wanting to tead it
09:51 AM LeoNerd: *read
09:52 AM _ami_: aaa__: ??? ping..
09:54 AM _ami_: to avoid this avrdude command typing to upload the code, i use to create a make command in cmake to upload the code. make {projectname}-upload
09:55 AM aaa__: please wait guys i am making connections again
10:09 AM aaa__: https://pasteboard.co/GzZPPeg.png
10:09 AM aaa__: This is my output window
10:09 AM LeoNerd: Yah - that's not even finding the USB device now
10:10 AM LeoNerd: Soyeah, sounds like the device just plain doesn't like Windows.. Which is a known problem, it being a stupid VUSB hack
10:12 AM aaa__: https://pasteboard.co/GzZReff.png
10:13 AM aaa__: but it showing in device manager !!
10:14 AM LeoNerd: *shrug* I've no idea
10:14 AM aaa__: what might be the problem.......Programmer issue??
10:14 AM aaa__: <LeoNerd> omg please give some idea?
10:14 AM LeoNerd: Maybe? Are you sure it's that VID/PID on the device though?
10:14 AM LeoNerd: As in, you've asked for the usbasp, and that implies that given VID/PID combo. Is the device you actually have *really* known to be that?
10:15 AM LeoNerd: If device manager sees it thne maybe it is working as a USB device but a different ID?
10:15 AM aaa__: How to check that device id???
10:15 AM LeoNerd: Again I have no idea
10:15 AM LeoNerd: In Linux I'd run lsusb -v
10:16 AM LeoNerd: Windows possibly has something you can wave the mouse at? *shrug* I haven't touched a Windows box in 15 years so I can't really help there
10:16 AM LeoNerd: But I suggest find out the VID/PID values from the device you actually have and see if that matches what avrdude is looking for
10:16 AM LeoNerd: If not maybe there's a different one you can tell it it is
10:17 AM aaa__: ok I will try to find that ID
10:18 AM aaa__: <LeoNerd> I forgot to say this one it is Local made ode :D
10:18 AM aaa__: *one
10:18 AM LeoNerd: *eyeroll*
10:21 AM aaa__: Leonardo shall i check for original board and try?
10:22 AM LeoNerd: You could start by using tab-complete to highlight my name correctly without spelling mistakes
10:22 AM LeoNerd: But additionally, sure? Lots of things you could do
10:23 AM Tom_itx: LeoNerd, i've had issues with jungo not wanting to unload if it was ever loaded causing the other usb driver to fail
10:24 AM Tom_itx: if he's loaded studio that could be an issue
10:24 AM LeoNerd: jungo?
10:24 AM Tom_itx: jungo is studio's usb driver
10:24 AM Tom_itx: is he working in windows or linux?
10:24 AM LeoNerd: Ah. Ohyes that might be a thing too
10:24 AM LeoNerd: I'm guessing Windows from all the replies
10:25 AM Tom_itx: i fought one for quite a while just trying to get the driver correct
10:25 AM Tom_itx: i figured so too
10:25 AM LeoNerd: But yes that sounds plausible.. I've had cases where certain programs steal FTDI chips too hard
10:25 AM LeoNerd: It annoys me how when people make products using the FTDIs they never bother to change VID/PID or description or anything
10:25 AM LeoNerd: YES ENTTEC I AM LOOKING AT YOU
10:25 AM Tom_itx: it's more than likely a crap programmer
10:27 AM aaa__: so which one can i go for now same USBASP or anything else
10:27 AM Tom_itx: i'd say mine but i don't sell it anymore
10:28 AM LeoNerd: aaa__: see Tom_itx's idea above. Maybe currently Atmel Studio has stolen the device so avrdude can't see it
10:29 AM aaa__: But i have tried in Atmel studio also
10:29 AM Tom_itx: therein lies your problem
10:30 AM aaa__: So which sw can i use ??
10:30 AM Tom_itx: if you want to use usbasp you can't use studio and you must unload the jundo driver that it uses
10:31 AM aaa__: ohhh ok i got it now
10:31 AM Tom_itx: or libusb won't work
10:31 AM Tom_itx: and you need libusb to use avrdude
10:33 AM aaa__: now also same problem
10:33 AM aaa__: libusb am using the same one
10:34 AM Tom_itx: you couldn't have uninstalled studio that quick
10:34 AM aaa__: ohh sorry i havent uninstalled that one yet
10:35 AM Tom_itx: which will also require a reboot or three
10:35 AM _ami_: if i have to sufffer that kind of shit to just run usbasp, i would get rid of windows shit and use linux
10:35 AM Tom_itx: then do that
10:35 AM Tom_itx: avrdude works in linux just fine
10:36 AM _ami_: i wonder why people use windows for embedded development.
10:36 AM _ami_: you are hacking hardware.. linux/unix has all the things you need for that.
10:36 AM Tom_itx: no os is perfect
10:38 AM LeoNerd: _ami_: Atmel Studio only runs on Windows :/
10:38 AM LeoNerd: So people who want to run that, need to be running Windows
10:38 AM Tom_itx: and nowdays it's nothing but bloatware
10:39 AM aaa__: I dont know anything in Linux
10:39 AM aaa__: :(
10:39 AM Tom_itx: it has issues too like permissions if you don't get that right
10:41 AM _ami_: LeoNerd: i hv been using visual-studio-code on linux for bigger project and i love it.
10:42 AM aaa__: I am working for just 6 month and i am stressed on this issue
10:43 AM _ami_: LeoNerd: https://pasteboard.co/GA03GMw.png
10:44 AM LeoNerd: _ami_: what is that?
10:44 AM _ami_: visual-studio-code IDE
10:44 AM aaa__: ping u on monday guys!!hope it should work
10:45 AM LeoNerd: Oh.. Heh; yah I just run (n)vim
10:45 AM _ami_: i know why people use atmel ide.. since its an ide equivalent to visual studio
10:45 AM _ami_: LeoNerd: i was an avid vim user before. still use it but prefer vs-code now a days :D
10:46 AM Tom_itx: they started using visual stuido after about ver 4
10:46 AM _ami_: Tom_itx: ah, did not know. but atmel id is very bulkish :/
10:46 AM Tom_itx: that's why
10:46 AM Tom_itx: 4 wasn't too bad
10:46 AM Tom_itx: but it doesn't support new chips
10:47 AM LeoNerd: I think the only reason I'd contemplate running something like Atmel Studio would be the onchip debug features, but so far I've got by quite well with debug-by-GPIO
10:47 AM LeoNerd: So I don't think it's really an issue for me :)
10:47 AM Tom_itx: same here
10:47 AM _ami_: same here too. gpio or usart printf
10:48 AM Tom_itx: i did get a saleae when dean and I were debugging the TPI code
10:48 AM LeoNerd: Those Saleae clones are nice. I have one I paid a mere £14 for :)
10:48 AM _ami_: i hv those clones.. it works well! ;)
10:48 AM Tom_itx: yeah, their software supports quite a few protocols now
10:48 AM LeoNerd: _ami_: I have a nice send-only virtual UART implementation Iwrote, handy to attach to stderr :)
10:49 AM LeoNerd: Just give it some spare GPIO pin so it'll work even if the real UART is in use for something else
10:49 AM _ami_: nice.
10:49 AM LeoNerd: ... in unrelated news it's 30.5C in my workshop now :(
10:50 AM _ami_: its more humid here though because of all day raining today
10:51 AM LeoNerd: Oh Farnell... why, when I order 10 chips, do you send me an entire plastic tray to contain them?
10:51 AM Tom_itx: because shipping is on you
10:53 AM JanC_ is now known as JanC
11:17 AM _ami_: LeoNerd: is n't amazing that to start hacking atmel avrs? all you need is following pkgs: https://pasteboard.co/GA0hcET.png and thats it.
01:53 PM LeoNerd: Hrm.. random question: on chips with two SPI modules, the second is called SPI1. Is the first called SPI0 or just SPI? And more of a general opinion: should I rename the functions in my abstraction library, accordingly?
01:53 PM LeoNerd: Currently I have functions called just "spi_*" on any chip
02:01 PM cehteh: atmel isnt consistent with the nameing on other things at least. dunno about spi, prolly just do whatever suits you best
02:02 PM cehteh: maybe spi0_ and spi1_ and have spi_ aliasing to one of them or pass 0 or 1 as parameter
02:02 PM LeoNerd: Oh, definitely don't want a parameter; I don't think that will optimise into nothing like this currently does :)
02:03 PM LeoNerd: Huh.. this is annoying. On almost every chip, SPI(0)'s IO pins are all on one port, but on the 328PB, SPI1's pins are spread across two different
02:03 PM LeoNerd: MISO1 and SCK1 on PORTC, but MOSI1 on PORTE
02:03 PM LeoNerd: Which upsets my abstraction of fiddling the DDR bits for it:/
02:04 PM cehteh: i sometime make upfront macros to be sure it optimizes properly
02:05 PM LeoNerd: Youknow, I have no idea how you'd write the C code for it, but I sometimes wish that constants like PD0 were somehow typed so that you could only apply them to PORTD, DDRD, etc...
02:05 PM LeoNerd: That if I accidentally tried to PORTB |= _BV(PD0) due to some long macro chain, gcc would say "Hey, that's wrong"
02:06 PM cehteh: #define spi(port,...) spi##port(__VA_ARGS__)
02:06 PM LeoNerd: Mm.. that's kinda cute
02:06 PM LeoNerd: Ooh actually I do like that
02:07 PM cehteh: that was just some simplification ,there are some neat macro tricks :D
02:07 PM cehteh: but pp programming has its pain and dangers
02:41 PM * LeoNerd reads data sheet FOUR TIMES, determines SPI pin locations. Tests circuit. Doesn't work. Compares circuit to pinout in datasheet. Had MOSI and SCK inverted
02:49 PM JanC_ is now known as JanC
02:52 PM cehteh: LeoNerd: remember the china prominis i got where these where marked wrong on the silkscreen .. and it also had a GDN pin :D
02:52 PM cehteh: that was wtf to debug
02:53 PM LeoNerd: Hrm.. General Debug, active-low? ;)
02:53 PM LeoNerd: "I've connected GDN low, why is it not in debug mode?"
02:55 PM LeoNerd: Well anyhow.. I now have SPI1 working nicely. Which is useful, because SPI1 and TWI1 are the "isolated" interfaces on my new "328PB + digital isos" board
02:55 PM LeoNerd: ... which I might be adding to Tindie when it arrives
02:55 PM LeoNerd: Currently building various test equipment which needs floating ADCs or DACs or similar
03:38 PM Emil: >floating dacs
03:38 PM Emil: Eeeeeeeh
03:39 PM Emil: Just say isolated
03:39 PM Emil: floating is the wrong word here
03:55 PM xentrac: is "floating" more specific than "isolated", meaning that it's isolated from everything, not just your input? Or do I have that wrong?
03:55 PM enhering: hi
03:56 PM enhering: cehteh: I think I found a way
04:07 PM cehteh: mhm?
04:20 PM enhering: During initialization, COMmunications module sends a byte to the interrogatd module. That byte corresponds to a class of capabilities. The module responds with another byte, listing what he carries. Capability classes would be: MCU-ONLY, SENSORS, GPS, SERVOS, COMMUNICATIONS, POWER. Inside each class, like SENSORS, the interrogated module lists its payload by setting or clearing the bits of the answer.
04:20 PM enhering: bit 1: accelerometer, bit 2: gyroscope etc.
04:21 PM enhering: In this way the communications module can identify everything that is installed in the system, even in a mixed module, custom made by someone else.
04:22 PM enhering: The COM module builds a capacity matrix in this way and can identify and deal with redundances.
04:42 PM rue_house: and so is born the world of high speed - high latency devices
04:42 PM rue_house: "Ignore the 20s latency, your getting 2TB/s!"
04:43 PM rue_house: "But, voip?"
04:44 PM enhering: Think like you are talking to someone on the moon.
04:44 PM rue_house: not if its my realtime perphial
04:45 PM rue_house: I get impatient at about the 470ms mark
04:46 PM rue_house: sometimes even 120ms is agonazing
04:46 PM rue_house: then I think how fast micrcontrollers run
04:46 PM Emil: xentrac: floating means no reference
04:46 PM rue_house: and I REALLY feel sorry for them
04:46 PM Emil: xentrac: what LeoNerd wants is isolated
04:46 PM Emil: xentrac: galvanic isolation
04:46 PM rue_house: 3N...
04:46 PM Emil: (stupid name, I know)
04:46 PM rue_house: 137?
04:49 PM Emil: xentrac: isolation allows you to power things without worrying about potential differences
04:49 PM rue_house: oh 4N
04:49 PM rue_house: no
04:49 PM rue_house: 6N?
04:49 PM rue_house: yea 6N137
05:17 PM lemm|ngs is now known as lemmings
05:43 PM LeoNerd: Emil: How is "floating" wrong?
05:52 PM Emil: LeoNerd: you can't measure if it is floating
05:52 PM Emil: LeoNerd: isolated is the word you mean
05:52 PM LeoNerd: Hrm
05:52 PM Emil: LeoNerd: trust me, I'm an EE (student)
05:53 PM Emil: And I'm also really fucking pedantic :D
05:54 PM Emil: Hmm
05:54 PM Emil: So I had this idea
05:57 PM Emil: Hmm, yeah there are schematics alrady
05:57 PM Emil: so you know what a joule thief is, two inductors and a transistor
05:57 PM Emil: and a load
05:58 PM Emil: It's current based control entirely
05:58 PM Emil: Now I'm thinking, how about two capacitors and a mosfet, so voltage based entirely
07:22 PM dan3wik is now known as dan2wik
10:02 PM Tom_itx is now known as Tom_L
10:32 PM rue_house: If, saying "shotgun" is the way to be first, what do you say when you are making the last comment that will be in an IRC channel for the next 12 hours?
10:40 PM Tom_L: aww
10:40 PM Tom_L: i wanna be last...
10:52 PM rue_house: I'm usually last anyhow
10:52 PM rue_house: I say something in the morning, and after 9 hours of work I get back and I'v the last one spoken
10:53 PM Casper: you say: "this channel is dead!" or "Good night"