#avr | Logs for 2016-09-25

Back
[01:16:21] <theBear> don't suppose anyone ever succeeded or even played around trying to parport/spi-bang for a programmer over lpr/lpd non-local "printer port" server/protocol ?
[01:17:03] <theBear> or even knows if the protocol/standard is likely capable or is too printer-specific and therefore limited to abuse the port in such an unintended fashion as a programmer ?
[01:17:32] <theBear> oh stk200, that's the grownup name for what programmer i talkin bout, with one particular pinout implied
[05:45:38] <Levitator> Greetings, fellow homies.
[05:46:01] <Levitator> So, I was looking at the Interrupt table, and each entry is two bytes, but each entry is supposed to be a jump instruction.
[05:46:30] <Levitator> How is that possible? The instruction guide says that JMP is to an absolute address, so that's at least three bytes, assuming opcodes are one.
[05:47:05] <Levitator> The only way that could work is if it's a relative jump >= 0xFF away.
[05:48:52] <Levitator> In fact, the instruction set guide says JMP is 32 bits, not 16.
[05:51:42] <Levitator> Seems more likely that each entry is a memory address, and the manual writers are too brain-damaged to make that clear.
[05:52:07] <Levitator> And the address sets the program counter to jump to for the interrupt.
[06:02:32] <antto> afaik the interrupt table is.. each interrupt is located at a fixed (chip-specific) location in the flash space
[06:02:50] <antto> when the interrupt happens, the chip teleports to that place
[06:03:07] <Levitator> But what is actually in the table, an address?
[06:03:21] <antto> those interrupts are #defined in the headers
[06:03:31] <antto> well, yes, what else?
[06:03:44] <antto> they are also in the datasheet
[06:03:47] <Levitator> The table in the stupid manual shows jump instructions.
[06:03:56] <antto> oh, no idea about that
[06:04:27] <antto> but you don't jump to the interrupt, the chip does
[06:04:29] <Levitator> I think what it actually is trying to say is that the table is an address to a single instruction.
[06:04:43] <antto> you have to maybe jump out of it or return or something, when you're done
[06:04:44] <theBear> i was thinking like antto just said too... the table is more a index than anything that actually gets run
[06:05:25] <antto> ..in order to go back to what you were doing (main thread or so)
[06:46:04] <Levitator> Ok, so is the interrupt vector table R/O?
[06:46:19] <Levitator> So that there are fixed entry points into your program?
[06:46:45] <LeoNerd> The interrupt table is in program flash
[06:46:51] <Levitator> Ahhhh.
[06:47:20] <LeoNerd> Of course, there's nothing to stop your interrupt functions making some form of dynamic dispatching decision on what to do next
[06:47:27] <Levitator> So you really are supposed to just use the ISR macro and go trying to dynamically bind the ISRs.
[06:47:47] <Levitator> Well, you can rebind them after your entry point is reached, but not before, is what I'm saying.
[06:48:08] <Levitator> *not go trying to dynamically bind
[06:48:27] <LeoNerd> Yah
[06:49:04] <LeoNerd> Usually my ISR functions are really small.. maybe just bumping a flag or rescheduling a task on my scheduler
[06:49:22] <LeoNerd> ISRs on button inputs usually just start a delay counter
[14:10:18] <andrzejku> hello
[14:10:25] <Emil> hi
[14:10:26] <andrzejku> looking a way to start playing with avr
[14:10:41] <andrzejku> got some basics but want to go deeper with it
[14:10:49] <andrzejku> mean C basics
[14:10:51] <andrzejku> C++
[14:10:57] <andrzejku> linux
[14:10:58] <andrzejku> :P
[14:11:07] <andrzejku> but air is hard to touch for me
[14:11:14] <andrzejku> pretty new with it
[14:11:31] <Emil> Hey
[14:11:40] <Emil> I think my thing is just for you
[14:11:54] <Emil> https://emil.fi/avr
[14:11:55] <Emil> or
[14:12:14] <Emil> curl https://emil.fi/avr | less for maximum cli experience
[14:12:29] <andrzejku> that's pretty short ;D
[14:12:39] <andrzejku> anyway I use mac
[14:12:42] <andrzejku> ;(
[14:12:46] <Emil> It has plenty to go by
[14:12:54] <Emil> and you asked for linux ;)
[14:12:54] <andrzejku> trying to figure out
[14:13:01] <andrzejku> yeah
[14:13:02] <andrzejku> sorry
[14:13:03] <andrzejku> ;S
[14:13:08] <andrzejku> my notebook got linux
[14:13:15] <andrzejku> but actually I user iMac :/
[14:14:44] <Emil> You can run then on osx, too
[14:14:54] <Emil> just need to either brew or compile from source
[14:15:10] <antto> ascii art schematic
[14:15:11] <andrzejku> I user AVR eclipse plugin xd
[14:15:12] <antto> wowz
[14:15:27] <Emil> antto: you like it? Thanks!
[14:16:34] <Lambda_Aurigae> andrzejku, we won't hold it against you.
[14:17:08] <Emil> Lambda_Aurigae: speak fo yourself ;)
[14:17:30] <andrzejku> :-)
[14:17:37] <andrzejku> hey, if I can ask
[14:17:43] <andrzejku> what are you doing guys on air?
[14:17:46] <andrzejku> avr
[14:17:57] <Emil> ?
[14:17:59] <Lambda_Aurigae> building things
[14:18:01] <Lambda_Aurigae> learning
[14:18:02] <Emil> air? on avrM
[14:18:03] <Lambda_Aurigae> playing
[14:18:05] <Lambda_Aurigae> teaching
[14:18:05] <Emil> ?
[14:18:23] <Lambda_Aurigae> Emil, I'm betting "air" was an autocorrect for "avr"
[14:18:31] <andrzejku> yeah but example cool things
[14:18:42] <antto> autocorrect?
[14:18:47] <Emil> Lambda_Aurigae: still missing a verb, I assume "doing"
[14:18:48] <Lambda_Aurigae> robots, chicken coop auto door opener
[14:18:55] <DKordic> Spellcheck.
[14:19:06] <andrzejku> x)
[14:19:06] <antto> his computer tells him what he means to say?
[14:19:08] <andrzejku> nice
[14:19:16] <Emil> andrzejku: learning, rf, dsp, control interaces
[14:19:28] <DKordic> antto: He said Apply, didn't he?!
[14:19:30] <Emil> interfaces*
[14:19:43] <Lambda_Aurigae> been playing with video generation on pic32 lately mostly.
[14:19:55] <Emil> traitor
[14:19:57] <andrzejku> what about avr and linux?
[14:19:57] <Emil> ;)
[14:19:58] <antto> Lambda_Aurigae pics, or it didn't happen
[14:20:02] <Lambda_Aurigae> andrzejku, what about it?
[14:20:10] <andrzejku> could I run linux on air?
[14:20:11] <Lambda_Aurigae> antto, it's not really happening yet.
[14:20:20] <Lambda_Aurigae> andrzejku, yes.
[14:20:26] <andrzejku> and program some another avr peripheries?
[14:20:26] <Emil> andrzejku: please fix the autocorrect/spelling
[14:20:39] <Lambda_Aurigae> if you don't mind a 2 hour boot.
[14:20:42] <andrzejku> Emil, yeah that OS X autocorrect
[14:20:49] <andrzejku> :D
[14:20:50] <Lambda_Aurigae> http://dmitry.gr/index.php?r=05.Projects&proj=07.%20Linux%20on%208bit
[14:20:56] <Emil> Lambda_Aurigae: eh, it was like 8 hours
[14:21:06] <Lambda_Aurigae> 2 hours on his.
[14:21:18] <Lambda_Aurigae> mine was 4 hours because I ran a slower clock.
[14:21:18] <antto> why would you want to put linux on an 8bit cpu?
[14:21:35] <Lambda_Aurigae> antto, the same reason one would want to boot linux on a dead badger...just because you can.
[14:21:56] <antto> then wat? u gon' watch youtube? ;]
[14:22:02] <Lambda_Aurigae> hehe.
[14:22:07] <Lambda_Aurigae> run vi
[14:22:13] <antto> ah
[14:22:18] <Lambda_Aurigae> it should only take 35 minutes or so to open a text file.
[14:22:24] <antto> and type some stuff in it like a h4x0r
[14:22:25] <DKordic> Perhaps on 1px display.
[14:22:38] <Lambda_Aurigae> serial port interface.
[14:22:45] <antto> a real linux h4x0r doesn't need a display
[14:22:50] <antto> just a keyboard
[14:23:00] <Lambda_Aurigae> the terminal is probably more powerful than the avr running linux.
[14:23:12] <antto> the display is for others, to witness his powah
[14:23:19] <DKordic> I would say that linux runs on an SD Card rather than AVR.
[14:23:36] <Lambda_Aurigae> DKordic, there are some that do....
[14:27:24] <Emil> oh it was only 2h
[14:27:30] <Emil> thats bot too shabby
[14:27:37] <Emil> not*
[14:28:23] <Emil> I wonder how much faster one could make it with another avr as a co processor
[14:28:24] <PoppaVic> So, once again I shall ask: "IF you call SPM (in BLS) to perform a write, will it return to the app-code or suddenly see only 0xFFFF in the RWW section?"
[14:29:17] <PoppaVic> I've modded the bootloader to offer "spm\nret\n" in the hopes of doing everything else in the app.
[14:49:43] <PoppaVic> well, fine.
[15:01:32] <antto> we failed to encourage this person
[15:01:45] * antto runs before he gets SQUASHed
[15:05:12] <Emil> Oh shit, he left :/
[15:06:47] <antto> run, u fool!
[15:20:26] <Emil> I'll stand my ground!
[16:22:47] <twnqx> does any of you know how "samsung fast charge" works?
[16:22:52] <twnqx> signalling wise
[16:23:13] <twnqx> i have a power bank with 2A output, but my phone only dares to drink 0.5....
[16:25:27] <twnqx> Eventually, the USB organization came up with the USB Battery Charging specification. This connects both data wires together, signalling the charger in your phone that the power dongle supports up to 1.5A (7.5W) charging.
[16:25:27] <twnqx> hm
[16:29:40] <aandrew> twnqx: it's up to the charger
[16:30:06] <aandrew> there is the battery charge profile which for high current the *charger* shorts D+ and D- to indicate to the circuit connecting to the charger that it can pull more current
[16:30:20] <aandrew> oh
[16:30:29] <aandrew> you already know that
[16:30:44] <aandrew> your phone needs to know to take advantage of it
[16:30:54] <aandrew> any chance you're using a USB cable that is missing D+/D-?
[16:31:05] <aandrew> my BT headset has a cable like that. astounding
[16:34:21] <twnqx> it does
[16:34:26] <twnqx> phone reports "slow charging"
[16:34:52] <twnqx> and since the phone recognizes the PC with the cable, i am pretty sure it has data :P
[16:37:15] <twnqx> chinese vendors....
[16:37:16] <twnqx> man
[16:37:25] <twnqx> red cable for battery minus. black cable for battery plus.
[16:38:29] <aandrew> hm
[16:38:32] <aandrew> ugh
[16:38:36] <aandrew> had that before too
[16:41:37] <twnqx> hm, they seem to have 68r on bothdata lines
[16:50:10] <twnqx> so wtf do they do here
[16:50:21] <twnqx> they connected d+ and d- from both output poerts, ok
[16:50:34] <twnqx> they put 68r resistors on both, ok
[16:50:43] <twnqx> theose are connected on the other side
[16:50:45] <twnqx> but... to what
[16:59:52] <aandrew> VUSB/gnd?
[17:20:31] <twnqx> didn't look like it
[17:20:35] <twnqx> oh well, i reassembled it
[17:20:48] <twnqx> i'll probably mod a cable to signal high current :P