#avr Logs

Oct 18 2017

#avr Calendar

12:40 AM rue_ is now known as rue_mohr
02:53 AM Emil: https://hackaday.com/2017/10/17/bad-rsa-library-leaves-millions-of-keys-vulnerable/
03:33 AM ThomasK_: Hello, does anybody know where I can find a good example for the data transfer with LwIP? I modified the echo example and tried to send data by modifying the payload, but this does not work.
04:04 AM LeoNerd: tpw_rules: Currently, an LTC2400. But it's a bit slow and unipolar, so I have plans to make a better one on a MAX11200
05:29 AM Lambda_Aurigae: ThomasK_, not seeing any fully implemented LWIP stacks for AVR..a few minimal ones that aren't complete.
05:29 AM Lambda_Aurigae: uIP or ethernut would be a better choice for an 8bit microcontroller.
09:38 AM rue_mohr: if you dont want to use an additional chip, start with a bigger chip
09:38 AM rue_mohr: the W5500 worked for me
09:56 AM karols141: Hello anyone can tell me where I can find datasheet or something similar for nokia 3310
09:56 AM karols141: ?
09:57 AM polprog: you mean the display?
09:57 AM karols141: Yea
09:57 AM karols141: I mean, I can find tons turtorials etc
09:57 AM polprog: the driver is called PCD8544
09:58 AM karols141: But I want just learn it from datasheet, to understand how it work, no blank examples
09:58 AM karols141: Yea but how do you know ?
09:59 AM polprog: i googled "nokia 3310 display" and it was in the description of the result: https://screenshots.firefox.com/jBrL9D8JgHiTWOnC/www.google.pl
10:00 AM karols141: Yea I find It like that too, I think that you got some nokia datasheets or something
10:01 AM polprog: nice i found the datasheet
10:01 AM polprog: http://eia.udg.edu/~forest/PCD8544_1.pdf
10:02 AM karols141: I just was curious how someone got idea that it's that driver
10:02 AM karols141: By disassemble it or what
10:02 AM polprog: maybe they stuck a logic analyzer at the data lines and guessed it
10:03 AM karols141: Wow I don't even thing about it
10:03 AM polprog: maybe it leaked - those displays are in DYI electronics for quite a long time
10:03 AM karols141: So much to learn
10:03 AM polprog: i remember reading an article (in a polish hobby electronics magazine) 10 years ago about that display
10:04 AM polprog: logic analzers are cheap nowadays
10:04 AM karols141: Yea got one <cheap china stuff>, don't have time to even use it one time
10:04 AM karols141: Don't even how to use it for now
10:04 AM polprog: trust me, you will have to use it one day
10:05 AM polprog: is it by any chance a clone of a Saelae?
10:06 AM karols141: https://duckduckgo.com/?q=saelae+clone&t=ffab&atb=v64-6af&iar=images&iax=images&ia=images&iai=https%3A%2F%2Fchiptron.cz%2Fimages%2Fnews%2FLogic_analyzer_Saleae%2FLogic_analyzer_Saleae_4.jpg
10:06 AM karols141: Like this
10:09 AM rue_mohr: so
10:10 AM rue_mohr: you want to make your own driver, from the datasheet info (not knowing which info in it is erroneous) but you want to reverse engineer an existing driver while doing it...
10:10 AM rue_mohr: instead of just using an existing driver
10:10 AM rue_mohr: (library)
10:11 AM rue_mohr: .. that someone has corrected the major isues with
10:11 AM polprog: this chip was released 18 years ago, id be surprised if there wasnt a lib written for it for any CPU out there.
10:11 AM karols141: I just want to know, how somebody got idea what driver was in that screen, possible ways to detect that
10:12 AM polprog: 1) xray
10:12 AM rue_mohr: even then, not much of any library for it will be hardware specific
10:12 AM polprog: 2) logic analyzer sniff
10:12 AM rue_mohr: see what the arduino env uses
10:12 AM rue_mohr: its all just C anyhow
10:12 AM polprog: 3) datasheet/docs leak or publication
10:13 AM rue_mohr: connect to arduino, load example, observe
10:13 AM karols141: Anyone maybe know what was the name of open source app for unix to connect various electronic equipment to pc
10:13 AM rue_mohr: karols141, cat
10:13 AM polprog: a terminal
10:13 AM karols141: I mean
10:13 AM karols141: I start from g
10:13 AM polprog: if you are curious how is reverse engineering done, esp displays, skim through this: http://electricstuff.co.uk/ipodlcd.html
10:13 AM karols141: but I am not sure
10:13 AM karols141: Thanks for link
10:14 AM polprog: if you have couple hours to spare you can watch the vids too
10:14 AM rue_mohr: sigh..
10:14 AM polprog: what exactly do you want to achieve
10:14 AM polprog: and what do you mean by connecting "equipment to pc"
10:15 AM karols141: If I want to connect my logic analizer for example to my Os < FreeBSD >, how to do that ?
10:15 AM karols141: thinkpad X200
10:15 AM polprog: via usb and use a tool called sigrok
10:15 AM polprog: for that analyzer
10:16 AM polprog: it's well supported
10:16 AM karols141: polprog: That is that name
10:16 AM polprog: what do you mean?
10:16 AM karols141: I have no idea why I remember that it start with g
10:16 AM karols141: I just was looking for that
10:16 AM karols141: sigrok
10:17 AM karols141: I remember app but don't name
10:17 AM rue_mohr: gdb?
10:22 AM karols141: rue_mohr: No, I mean sigrok but don't remember name correctly
12:06 PM eballetbo: By chance there is anyone that has experience using and xmega as spi slave and a linux as spi master, I'm seeing some weird and random things
12:08 PM eballetbo: basically this is the code I'm running on both sides
12:10 PM eballetbo: master polls slave every 2 minutes and normally works well, but sometimes the message is corrupted
12:39 PM Ristovski: It seems that the auto erase cycle in avrdude causes the programming to fail. With it enabled, the chip is blank after burning. With -D to disable this feature, it works fine.
12:39 PM Ristovski: Manually erasing the chip and then burning works fine as well
12:47 PM Cracki: eballetbo, got the cpol+cpha right?
12:47 PM Cracki: attach a logic analyzer, capture it all
12:49 PM Ristovski: oh so running it at 8mhz fixed this
02:36 PM JanC is now known as Guest47467
02:37 PM JanC_ is now known as JanC
04:10 PM eballetbo: Cracki, thanks to answer, I attached a logic analyzer and data send does not match with data in memory_map[addr], something is happening in the ISR.
04:10 PM eballetbo: ie. if a normal packet is ... 31 38 36 35 35 20 31 73 32 70 00 00 00 00 00 00 ... sometimes sends something like ... 00 61 62 63 64 65 66 67 68 69 6a 6b 6c 6d 6e 6f ...
04:11 PM eballetbo: curious that when data is wrong is sequential
04:11 PM polprog: how does your ISR routine look like>
04:11 PM polprog: ?
04:11 PM polprog: that sequentiality could be a good clue
04:11 PM eballetbo: polprog: https://hastebin.com/gujosajaci.php
04:14 PM Cracki: uh incrementing numbers?
04:15 PM polprog: try to send spi_data[addr] and addr via uart in that ISR (if you set high enough baudrate you will not overwrite it)
04:15 PM Cracki: ah right an xmega, those are unfamiliar to me
04:15 PM polprog: as a debug solution, to "add" those data on the analyzer trace
04:15 PM Cracki: what type is memory_map?
04:16 PM Cracki: perhaps the memory itself is being overwritten somewhere
04:16 PM Cracki: also: that if has no else
04:17 PM Cracki: so out of bounds error
04:17 PM polprog: yeah, so it sends both dummy and memory_map
04:17 PM polprog: heh
04:17 PM Cracki: grml I always seem to misplace my electronic modules! I'm missing some microphone stuff now
04:18 PM polprog: im bored, i may as well try to crack rs485 now
04:18 PM polprog: now that i have my 232 working
04:18 PM polprog: ill try 485!
04:20 PM eballetbo: polprog, Cracki: volatile uint8_t memory_map[SBS_MEMORY_MAP_SIZE];
04:21 PM Cracki: k
04:21 PM polprog: try fixing the lack of else
04:21 PM Cracki: grml where's my stuff
04:21 PM eballetbo: note that I'm a bit of newbie, so can be something silly
04:21 PM Cracki: you're doing good. the code could look a lot worse :P
04:21 PM polprog: ^^
04:22 PM Cracki: yay found some more stuff I'm not looking for -.-
04:23 PM Cracki: eh, it'll turn up
04:24 PM papirkop1 is now known as papirkopi
04:34 PM Cracki: :D found the stuff! of course it was put away neatly, just didn't see it
04:37 PM polprog: yay
04:38 PM polprog: it's working
04:39 PM Cracki: and I found four dumb microphones, but not the one with the max9814 amplifier
04:39 PM Cracki: good enough for clapping detection
04:44 PM polprog: http://picpaste.com/IMG_20171018_230803-6Li73NdG.jpg
04:44 PM polprog: my rs485 driver is working
04:46 PM Cracki: :D found it!
04:46 PM Cracki: nice
04:46 PM Cracki: waveforms are way too clean
04:48 PM polprog: you think so?
04:48 PM polprog: ive got ringong on the lines
04:48 PM polprog: ringing*
04:48 PM polprog: not visible on the pic
04:49 PM polprog: 30% overshoot the scope says
04:49 PM polprog: at Vamp = 2V
04:49 PM Cracki: oh
04:49 PM LeoNerd: Rigol 1054Z
04:49 PM polprog: i craked up the baudrate on the converter to 2M
04:49 PM Cracki: either echo (terminated properly?) or the driver is driving to hard
04:50 PM polprog: terminated properly, and biased
04:50 PM polprog: wonder what happens if i remove termination
04:50 PM polprog: oh god
04:50 PM polprog: off the scale :D
04:50 PM polprog: 60%
04:51 PM Cracki: hah
04:51 PM Cracki: more termination?
04:51 PM Cracki: what's the datashyte say?
04:52 PM polprog: didnt look, honestly
04:52 PM polprog: i use 120 ohm which is standard for rs485
04:52 PM polprog: actually it should be 120 but its 100
04:53 PM Cracki: close enough
04:54 PM Cracki: so either phys in general should tolerate this overswing or this phy is odd
04:55 PM Cracki: I have sooo many esp modules flying loose
04:57 PM polprog: allright
04:57 PM polprog: works, cool
04:58 PM polprog: now i gotta buy a pci[e] rs232 card
04:59 PM Cracki: why
05:00 PM polprog: because the builtin mobo rs port doesnt receive data
05:00 PM Cracki: I have an usb dongle that works just fine
05:00 PM polprog: it sends, but doesnt receive
05:00 PM Cracki: ah you want a fixed installation
05:00 PM Cracki: rusty pin header?
05:00 PM polprog: temporary
05:00 PM polprog: noo it's a new mobo
05:01 PM Cracki: that's just crazy, a simplex uart
05:01 PM polprog: i think it's the superIO chip
05:01 PM polprog: because it wont work under linux AND windows
05:01 PM Cracki: Oo
05:01 PM polprog: get this, it fails the loopback test (short pin 2 and 3)
05:02 PM polprog: no dice :/
05:02 PM polprog: i can get a pci serial card for like $2
05:02 PM polprog: this weekend, so ill get one, or three
05:02 PM Cracki: fauly connector?
05:02 PM Cracki: t+
05:02 PM polprog: no, tested
05:03 PM Cracki: if you get a card, get one with lots of ports
05:03 PM Cracki: no point in wasting a whole slot for just one :P
05:03 PM polprog: i spent the better part of monday trying to get it work
05:03 PM polprog: yeah, given that i have only 1 pci slot
05:03 PM polprog: not sure if i can get a pcie card there :D
05:04 PM Cracki: 2 bucks is cheaper than working on it for even a quarter hour
05:04 PM Cracki: oh you can get anything
05:04 PM Cracki: it'll be a chain of adapters on a pcb, but it'll work :>
05:04 PM polprog: even got gender changers and a 5m nullmodem cable
05:04 PM Cracki: seen those sd-card raid "drives"?
05:04 PM polprog: yeah
05:04 PM polprog: funny
05:04 PM Cracki: insane
05:05 PM polprog: "SSD"
05:06 PM polprog: looool, there are offers for 2x rs232 PCIe card for... 23$
05:06 PM polprog: i can have a whole computer with rs232 builtin for that price
05:07 PM polprog: what a monstrosity: http://allegro.pl/kontroler-pci-e-2x-rs232-db9-com-lpt-low-profile-i5111899433.html
05:07 PM Cracki: tape worms
05:18 PM eballetbo: hmm, not sure if add the printf in the isr was a good idea, doesn't seem to print the correct values
05:18 PM polprog: dont add print
05:18 PM polprog: f
05:18 PM polprog: it's too heavy for an isr
05:19 PM polprog: just write a byte to UDR
05:19 PM polprog: it will be sent immediately "in the background"
05:20 PM eballetbo: UDR ?
05:20 PM * eballetbo looks
05:20 PM polprog: usart data register
05:20 PM polprog: dunno how that's called in xmegas
05:23 PM eballetbo: ok, got it
05:40 PM polprog: but i like rs422 over rs485
05:40 PM polprog: i think it has both advantages of rs232 and 485
05:47 PM polprog: night
09:15 PM robinak is now known as robink
09:44 PM ColdKeybo[a]rd is now known as ColdKeyboard
11:58 PM day__ is now known as daey