#avr | Logs for 2013-12-05

Back
[03:02:38] <defineTHIS> hello! Is it possible to have a conditional include in C? My code isn't working
[03:05:44] <defineTHIS> http://pastebin.com/vWa3eDYW
[03:08:27] <defineTHIS> I have: "#if defined(__AVR_ATmega328p__) \n #include <SPI.h> \n #endif", but it is included even if i compile for ATtiny, breaking the compilation
[03:21:58] <twnqx> that shouldn't be included unless you set that define
[03:25:14] <defineTHIS> twnqx: that's what I thought. I have tested putting other code within the define, and that code isn't included, so the #if defined seems to be working just fine
[03:25:32] <twnqx> so something else includes the SPI.h
[03:26:00] <defineTHIS> but if that #include is there, the compilation fails.
[03:26:22] <defineTHIS> If i comment out those two includes, the compilation succeeds
[03:28:33] <twnqx> is that your own .h?
[03:29:15] <twnqx> also, tried #ifdef __AVR_ATmega328p__ instead if the #if defined ()?
[03:30:13] <defineTHIS> twnqx: trying that now...
[03:34:40] <defineTHIS> preliminary results: not a success
[03:34:58] <twnqx> makes no sense to me
[03:34:59] <twnqx> :S
[03:35:35] <defineTHIS> me either!
[03:42:03] <twnqx> and if you add an #error this is compiled inside the #ifdef..#endif?
[04:40:36] <defineTHIS> twnqx: I found the cause of the problem! The SConstruct file i'm using uses a regex to look for includes like #include <.*>, and then adds (in this case) "-Ibuild/lib_00/SPI -Ibuild/local build/lib_00/SPI/SPI.cpp"
[04:40:46] <defineTHIS> thanks for your help!
[08:13:23] <beaky> hello
[08:24:37] <Tom_itx> is it morning in dubai?
[08:26:47] <beaky> no
[08:26:54] <beaky> its dark
[09:14:34] <The_Coolest> Does Atmel still manufacture Atmega88s? (not the P or PA versions)
[09:14:45] <jerkey> about to teach arduino to 7yo neice
[09:15:39] <The_Coolest> aka, is this legit? I bought from them a few times, but dunno about this one http://www.ebay.com/itm/360775260638
[09:21:05] <rue_house> odd, it loooks like gcc will restart main if it gets an unhandled interrupt
[09:21:17] <rue_house> in the interrupt
[09:22:06] <Casper> The_Coolest: might be old new stock
[09:22:54] <The_Coolest> old dies assembled?
[09:24:20] <The_Coolest> Casper I'm working on a little LCD board, and planned on using a 328P at first, but after seing that my hex is less than 4KB in size I thought I could go with a cheaper 88
[09:25:23] <The_Coolest> too bad that the atmega8 won't work for my design
[09:26:17] <Amadiro> rue_bed, sounds more like the chip is doing that... I don't know how the AVRs behave in that regard (it probably depends on the interrupt), but on x86 for instance, certain conditions can cause a reboot (triple faults)
[09:26:59] <rue_house> no actaully, I'm looking at an assembler dump of a C program
[09:27:40] <rue_house> http://paste.debian.net/69517/
[09:27:56] <rue_house> follow a bad interrupt, you get to main again
[09:28:35] <beaky> hello
[09:29:01] <beaky> why is atmega328 out of stock
[09:29:10] <rue_house> beaky, louder, nobody can hear you
[09:29:23] <The_Coolest> beaky why does the sun shine?
[09:29:25] <rue_house> beaky, @digikey or mouser?
[09:29:32] <beaky> digikey :D
[09:29:35] <rue_house> or the corner store?
[09:29:44] <rue_house> or fleabay
[09:30:09] <The_Coolest> beaky get a 88/168 unless you really need a 328
[09:30:12] <beaky> digikey only stock SMD types now
[09:30:30] <beaky> thankfully i still have 10 328s in my big box of electronic components
[09:30:35] <beaky> but i need moar
[09:30:36] <rue_house> http://www.ebay.ca/itm/2-x-ATMEGA328P-PU-ATMEGA328-MICROCONTROLLER-IC-Free-Shipping-/280994585126
[09:30:38] <rue_house> dip?
[09:30:40] <The_Coolest> also, ask digikey or buy somewhere else
[09:30:40] <beaky> yes
[09:30:49] <beaky> i guess SMD is the future
[09:30:56] <beaky> but i cant prototype with smd
[09:31:03] <Amadiro> rue_bed, huh
[09:31:09] <beaky> wow that is a good deal from tayda
[09:31:33] <Amadiro> beaky, get a bunch of breakouts. Some SMD types you can also solder onto veroboards fairly comfortable, if you first split the traces along its length
[09:31:34] <rue_house> http://www.ebay.ca/itm/NEW-1PCS-ATMEL-ATMEGA328P-PU-ATMEGA328-MCU-AVR-32K-FLASH-28-PDIP-DIP28-/231106483881
[09:33:13] <rue_house> http://www.ebay.ca/itm/10PCS-Original-ATMEGA328P-PU-ATMEGA328-MCU-AVR-32K-FLASH-28-PDIP-NEW-mjL4-/400376475466
[09:33:24] <Vutral> lol
[09:33:27] <Vutral> ^^
[09:33:29] <Vutral> expensive
[09:33:56] <Vutral> i bet canada got distributors
[09:34:05] <rue_house> http://www.aliexpress.com/item/Atmega328p-PU-Atmega328p-DIP-ATMEL-New-and-original-in-stock-deal-in-all-kind-of-electronic/1036237939.html
[09:34:22] <rue_house> yup, china is canadas distributor
[09:34:27] <Vutral> aliexpress== waiting 4-6 weeks
[09:34:41] <rue_house> but unlike ebay, ali means you definitly get it
[09:35:08] <Vutral> sure
[09:35:11] <rue_house> with canada post I bet if you send a package to your neighbour it takes 4-6 weeks
[09:35:13] <Vutral> i bought there too
[09:35:14] <Vutral> ^^
[09:35:38] <Vutral> but i anway pay only 1,8 euro per atm328p
[09:35:51] <rue_house> tahts like $4
[09:35:51] <Vutral> without waiting forever
[09:35:51] <Vutral> ^^
[09:36:00] <Vutral> well
[09:36:06] <Vutral> i dont think so
[09:36:11] <Vutral> euro has fallen ^^
[09:36:13] <rue_house> if your in europe it shoudlnt' take 4-6 weeks
[09:36:18] <Vutral> 1,46 dollar per euro ^^
[09:36:32] <rue_house> wow
[09:36:42] <Vutral> 1,41 maybe today
[09:36:42] <rue_house> damn,
[09:36:43] <Vutral> :D
[09:36:47] * rue_house races off for work
[09:36:56] <Vutral> noooooooooo
[09:36:58] <Vutral> better talk with me ^^
[09:37:03] <Vutral> it will keep euro uip
[09:37:04] <Vutral> :D
[09:37:19] <Vutral> germany pays people for keeping foreigners in talks :P
[10:10:04] <beaky> anyone tried the new attinys from atmel
[10:10:10] <beaky> i forgot the part numbers damn
[10:17:47] <tc-> On an xmega: If I call cli(), wait a little, trigger some kind of interrupt, wait a little, sti(). Now after this, will the interrupt routine run for the interrupt i triggered?
[10:22:06] <tc-> (Assuming I'm not running from this from an interrupt routine etc.)
[10:27:26] <The_Coolest> tc- the way interrupts usually work, I highly doubt it
[10:28:14] <bss36504> ThiefMaster: Did you ever figure it out?
[10:28:34] <ThiefMaster> yes, wrong clock fuses (needed to use "full-swing")
[10:29:01] <bss36504> ah ha, nice. so it was just stopping randomly, or not swinging enough?
[11:24:45] <braincracker> rue_house yes, enabled interrupts need to be served...
[11:47:35] <megal0maniac_afk> Wow. The xmega e5 has 4 calibration bytes for the temp sensor
[11:58:03] <tzanger> braincracker: keep it in the chan please
[13:30:55] <ThiefMaster> bss36504: no idea, but the signal on clkout looked somewhat ugly: http://i.imgur.com/UIwa2V6.png
[13:31:19] <ThiefMaster> i haven't scoped it again after changing the clock fuses though since i had already put the scope away
[13:31:47] <bss36504> ThiefMaster: ah well I'm glad it works
[13:35:20] <N1njaneer> Yeah that was quite the problem yesterday :)
[13:41:52] <rue_house> braincracker, not by main
[13:42:07] <rue_house> you fill an interrupt table with irets, not branches
[13:42:16] <braincracker> yes
[13:42:30] <braincracker> i was thinking about you need to define the interrupt handlers
[13:42:40] <rue_house> if you look at that code, an interrupt thats not provisioned for, restarts main
[13:42:55] <rue_house> but thats what happens whe you DONT define them
[13:43:07] <rue_house> by default, under gcc, main IS the interrupt handler
[13:43:26] <rue_house> which is scarry
[13:43:30] <braincracker> ;/
[13:49:48] <xkernel> is there a Python compiler for AVR?
[13:50:13] <beaky> arduino *hides*
[13:50:24] <beaky> oh wait arduino is C
[13:50:27] <beaky> c++*
[13:50:43] <bss36504> arduino is NOT C.
[13:52:42] <OndraSter_> arduino is Processing
[13:55:01] <ThiefMaster> xkernel: i think there's a python implementation that runs on 8-bit controllers. it does not have a stdlib and just a subset of python though
[13:55:19] <ThiefMaster> https://wiki.python.org/moin/PyMite
[13:57:00] <braincracker> hy beaky
[13:58:32] <N1njaneer> bss36504: Arduino is just an overlay on the C/C++ with macros and libraries wrapped inside of a self-contained IDE. You can write C/C++ code in to Arduino sketches just fine.
[13:58:34] <xkernel> ThiefMaster, that's a python interpreter that runs on the chip, but I'm looking for Python compiler that can produce the binary file to upload it to the MCU and execute normally
[13:58:59] <bss36504> N1njaneer: Yes, but it's not strictly speak, C or C++.
[13:59:17] <N1njaneer> bss36504: It's more like... a tragedy :)
[13:59:29] <bss36504> haha that's the word I was looking for.
[13:59:40] <beaky> arduino is quite wel designed
[13:59:50] <beaky> one board, hundreds of shields
[13:59:55] <beaky> one id
[13:59:56] <beaky> ide*
[13:59:58] <N1njaneer> xkernel: I kind of doubt you'll find a JIT compiler for AVR. Python also has a lot of things that would require a heap and a pretty reasonable amount of RAM to run.
[14:00:17] <beaky> well actually several boards, most avr, one arm one....
[14:00:58] <bss36504> http://i.imgur.com/JdpYT.gif
[14:01:09] <xkernel> N1njaneer, I think its not that hard, same like Arduino, you write their language and it's converted to AVR binary
[14:01:21] <ThiefMaster> xkernel: http://code.google.com/p/shedskin/
[14:01:21] <xkernel> of course you will not be able to use all Python's features
[14:01:35] <N1njaneer> Yeah, like... weak typing of everything.
[14:01:57] <N1njaneer> I am exceedingly dubious on getting it on even the largest AVR
[14:01:57] <ThiefMaster> it might require libpython though which would most likely make it unsuitable for a small device
[14:02:04] <bss36504> that gif was in reference to the impending arduino hate-storm.
[14:02:14] <N1njaneer> An ARM, sure.
[14:02:22] <N1njaneer> Provided you have adequate RAM.
[14:06:51] <xkernel> so what do you think guys about Arduino? can we fully depend on it or the classical way of using C is better?
[14:07:36] <N1njaneer> If you learn C, you can always write yourself out of just about any situation.
[14:08:02] <N1njaneer> Arduino is nice until you quickly hit the glass ceiling and then realize you have to learn a TON more before you can ever surpass it.
[14:08:40] <N1njaneer> In other words, when SuperEasyToUseLibrary.lib doesn't have the function you need... welll... then what?
[14:11:43] <xkernel> what functions you didn't find in Arduino?
[14:12:11] <N1njaneer> Anything beyond the basics?
[14:12:50] <xkernel> yeah
[14:13:29] <N1njaneer> I've been doing C/C++ for over 20 years now, on AVR for over 12. I've never had a reason to use anything else, since there is nothing that I can't do with any microcontroller or microprocessor, since C/C++ is completely ubiquitous to pretty much every platform out there, especially these days with how far gcc has been ported.
[14:14:24] <xkernel> nice
[14:14:38] <xkernel> what do you use AVR for N1njaneer?
[14:14:41] <N1njaneer> But from an introductory standpoint, Arduino is nice to get a handle on the basics
[14:15:07] <N1njaneer> It's a quick way to skip the difficulties of setting up a toolchain and getting code running, which is the first thing that tends to turn people away.
[14:15:38] <N1njaneer> If you don't expect Ardunio to be the end-all be-all everything of everything from the get-go, you'll do better. :)
[14:16:10] <N1njaneer> xkernel: I primarily do embedded control for the special effects and entertainment industry, mostly focused on live shows.
[14:17:24] <N1njaneer> Lighting, lasers, stuff like that :)
[14:17:35] <xkernel> and AVR is reliable for that?
[14:17:41] <N1njaneer> Extremely, yes.
[14:17:43] <xkernel> which chip do you use?
[14:18:13] <N1njaneer> Provided you engineer the supporting hardware correctly. I have a lot of mission-critical stuff out that that runs the gamut from ATTINY through ATMEGA2560's
[14:19:35] <xkernel> so why not using a laptop to control those stuff instead of chip?
[14:19:39] <N1njaneer> ATTINY13/24, ATMEGA168, ATMEGA32U2/U4, ATMEGA128, ATMEGA2560 are probably the most common, but I've used at least two dozen different models, and Atmel keeps adding more.
[14:20:51] <N1njaneer> xkernel: Somes the ultimate control comes from a PC of some sort, but you need things that go in the devices which you are ultimately controlling, and you need peripherals that a laptop simply doesn't have. You also need the reliability of a device that runs with just the bare overhead and can have absolutely deterministic behavior at all times.
[14:20:59] <N1njaneer> +sometimes the
[14:21:34] <N1njaneer> Also if you have to make 2000 of something, you can't put 2000 laptops in somewhere :)
[14:22:01] <braincracker> why not?
[14:22:08] <N1njaneer> It's about understanding what is necessary to solve the problem at hand, how to implement it as reliably and simply as possible :)
[14:22:12] <braincracker> :)
[14:22:26] <N1njaneer> braincracker: Show me a laptop that is the same cost and size as a 5x5mm QFN and I'll but some :)
[14:22:37] <braincracker> (:
[14:22:46] <N1njaneer> And browse pr0n with it
[14:22:58] <braincracker> i'm not all over laptops, try a beaglebone black, rpi, or olimex a20
[14:23:22] <braincracker> credit-card sized though
[14:23:27] <N1njaneer> I just use ARM whenever I need more processing power than an AVR, but less than a desktop.
[14:23:42] <N1njaneer> Everything here is 100% PCB-from-scratch, so chip-level spec is fine.
[14:24:22] <xkernel> N1njaneer, do you have experience with interfacing with GSM?
[14:24:43] <N1njaneer> About the only time recently that we used a module was needing interchangible build of wired/wifi capability in a super tiny part that was already FCC/RU/CE/International RF Standards compliant.
[14:24:58] <N1njaneer> I haven't done anything with GSM personally, no. GPS, yes :)
[14:31:05] <xkernel> N1njaneer, do you program AVR on Linux?
[14:33:03] <N1njaneer> Nope, Windows via AS6
[14:33:47] <N1njaneer> Which basically just wraps gcc, but is miles better than Eclipse as an IDE, and actually works 100% of the time.
[16:16:33] <ThiefMaster> is AS based on visual studio? the screenshots look a lot like VS
[16:48:11] <w|zzy> ThiefMaster: as6 is based on vs
[16:51:56] <vectory_> !seen rikusw
[16:52:50] <asteve> !seen me
[17:03:01] <OndraSter_> ThiefMaster, it uses VS2010 shell
[17:03:07] <OndraSter_> so yeah
[17:03:13] <N1njaneer> It works well :)
[17:03:25] <OndraSter_> and it is awesome, if you are used to VS and/or prefer a good IDE
[17:12:09] <ThiefMaster> yeah, VS and intellij ides are fine. going to give it a try later
[17:14:28] <ThiefMaster> s/intellij/jetbrains/
[17:26:54] <ThiefMaster> hm, weird, when i cause a reset using the watchdog i end up in a reset loop even if i call wdt_disable(); at the beginning of main() or in one of the init sections
[17:33:58] <ThiefMaster> nvm, forgot to clear WDRF
[17:34:31] <ThiefMaster> i wonder why wdt_disable(); doesn't do that...
[18:16:39] <kdehl> What do I need to include or compile with in order to be able to use inline assembly, like: asm("nop");
[18:16:47] <kdehl> I get undefined reference.
[18:19:33] <kdehl> When I use avr-gcc, that is.
[18:20:26] <Tom_itx> http://www.ibiblio.org/gferg/ldp/GCC-Inline-Assembly-HOWTO.html#s5
[18:20:44] <Tom_itx> http://www.nongnu.org/avr-libc/user-manual/inline_asm.html
[18:22:05] <Tom_itx> asm volatile ("nop"::);
[18:23:03] <Tom_itx> http://tom-itx.dyndns.org:81/~webpage/how_to/atmega168/mega168_led_blink_delay_index.php
[18:23:08] <Tom_itx> look at the delay function there
[18:23:33] <kdehl> Alright.
[18:24:01] <kdehl> Still undeclared.
[18:24:22] <Tom_itx> ^^ that program compiles and runs fine
[18:24:30] <kdehl> Hm..
[18:25:26] <vectory_> doesnt it say what reference?
[18:25:44] <kdehl> error: ‘asm’ undeclared (first use in this function)
[18:26:12] <kdehl> Must be something wrong with my environment...
[18:26:18] <kdehl> avr-gcc b.c -mmcu=atmega1284p -Os -std=c99
[18:26:26] <kdehl> Ah.
[18:26:26] <vectory_> __asm__ __volatile__("reti"::);
[18:26:36] <kdehl> It was the -std=c99 that screwed it up.
[18:26:46] <kdehl> Weird though.
[18:27:20] <vectory_> asm() might be a gnuism, c99 maybe strictly standard
[18:27:24] <ThiefMaster> Tom_itx: did you notice the rather ugly identation of the code you pasted on http://tom-itx.dyndns.org:81/~webpage/how_to/atmega168/mega168_led_blink_delay_index.php?
[18:27:34] <ThiefMaster> (it's usually a good idea to keep the indentation ALWAYS clean)
[18:27:42] <vectory_> fuck that, lol
[18:27:49] <kdehl> Crap. I've written all the libraries I use with c99...
[18:29:17] <vectory_> ThiefMaster: that does look clean only unusual/old
[18:29:27] <vectory_> its the k&r style iirc
[18:29:39] <ThiefMaster> vectory_: look again, he mixes different styles (including some of the worst ones out there)
[18:29:58] <ambro718> afaik "asm" will work in C++ (and is a reserved keyword)
[18:30:56] <Tom_itx> ThiefMaster you are forbidden to use it
[18:31:08] <ThiefMaster> https://gist.github.com/ThiefMaster/e90bb3dcee09b26759dc
[18:42:57] <kdehl> ah, fixed it.
[18:43:27] <kdehl> (By changing all for(int i = 0; i < X; i++))
[18:46:37] <The_Coolest> Hey guys, I asked this earlier, but would like more input on the subject.
[18:46:38] <The_Coolest> Does Atmel still manufacture Atmega88s? (not the P or PA versions) aka, is this legit? I bought from them a few times, but dunno about this one http://www.ebay.com/itm/360775260638
[18:58:46] * kdehl really needs a scope
[18:59:26] <kdehl> I'm trying to make a VGA generator, the screen reacs, but displays nothing, and I have no clue about what's wrong...
[19:00:17] <kdehl> I looked at this example:
[19:00:19] <kdehl> https://docs.google.com/file/d/0B0xy5kkwitunTmpxVjZfY2Jtd00/edit
[19:00:37] <kdehl> Looked almost too simple to be true, and I really don't understand where he got the timing values from.
[19:03:19] <kdehl> He runs his µC at 16 MHz, uses 8 nops for back porch, which ought to be about .5 µs, but according to http://tinyvga.com/vga-timing/640x480@60Hz a back porch is about 1,9 µs
[19:05:34] <kdehl> So I used my own calculations (lie! I stole them from http://www.lucidscience.com/pro-vga%20video%20generator-7.aspx), and used 12 nops instead, since I'm running at 20 MHz.
[19:05:37] <N1njaneer> Someone might be sailing on the USS MakeShitUp
[19:05:47] <N1njaneer> I hear it's a popular cruise :)
[19:06:11] <tzanger> lol
[19:06:16] <kdehl> Then the hsync and front porch get even weirder.
[19:06:18] <kdehl> Yeah, really.
[19:06:42] <kdehl> I figured I should try doing this in C first if it's possible, before making an assembly version.
[19:07:37] <N1njaneer> (tzanger: http://www.youtube.com/watch?v=4bBD5yyT-s0)
[19:08:40] <N1njaneer> kdehl: Easier if you can stuff it in to an FPGA since you can get zero jitter timing outputs. :)
[19:09:11] <N1njaneer> But I've seen some impressive stuff out of the Atmegas, people writing graphics demos and crazy things :)
[19:11:19] <allgood38> N1njaneer, any good youtube videos in particular?
[19:11:46] <N1njaneer> Not any links I have offhand, but they should be easy to find.
[19:12:35] <N1njaneer> http://www.youtube.com/watch?v=kSeVXhYPFCM is just a good VGA output
[19:13:14] <N1njaneer> Oh here's the awesome one -- this guy is crazy! http://www.youtube.com/watch?v=sNCqrylNY-0
[19:13:52] <N1njaneer> Schematics and code given at the link in the YouTube video description
[19:14:25] <N1njaneer> The best part is that it lierally just needs a handful of resistors and diodes to wire to the part. :)
[19:15:11] <N1njaneer> LFT has a lot of really cool stuff on there :)
[19:15:49] <N1njaneer> I like the real-time Julia sets.... IN COLOR ON A MICROCONTROLLER :D
[19:16:28] <allgood38> Haha, thats really cool, the circuit diagram is so simple
[19:16:50] <N1njaneer> Equally crazy, equally simple -- http://www.youtube.com/watch?v=6gEMKYnUADE
[19:16:58] <N1njaneer> Oh why is beaky not here to appreciate this?
[19:18:27] <N1njaneer> Oh latter video isn't AVR, is a Propeller
[19:20:09] <allgood38> So not only is he getting video output, but he's made animations and sound. The first one is an atmega88, right?
[19:23:34] <N1njaneer> http://www.linusakesson.net/scene/craft/
[19:23:49] <N1njaneer> And yes, ATMEGA88
[19:24:14] <N1njaneer> All schematics, binaries, and source provided.
[19:25:32] <tzanger> I've seen that demo before, very nice
[19:26:06] <kdehl> Ah!
[19:26:08] <kdehl> Finally!
[19:26:17] <kdehl> An image has appeared.
[19:26:28] <kdehl> I forgot to increase the line counter. Hrmpf.
[19:27:44] <tzanger> I'd liek to port that over to something with more RAM and fast proc and get the resolution up :-)
[19:28:51] <kdehl> So it is possible to do this in C, after all.
[19:29:13] <tzanger> of course it is
[19:29:48] <Casper> you can do everything in C, except do extreme optimisation and timing critical stuff
[19:31:32] <tzanger> and even that there's not much you can't do in C, but you really ahve to know your compiler
[19:35:12] <kdehl> http://dose.se/~madman/pics/avr_vga/avr_vga1.jpg
[19:35:16] * kdehl is so proud of himself
[19:38:05] <N2TOH> why?
[19:38:28] <kdehl> I managed to create a VGA signal.
[19:38:45] <N2TOH> ah yes not an easy feat
[19:38:52] <N2TOH> color?
[19:39:02] <kdehl> See the link.
[19:39:14] <N2TOH> loading
[19:39:27] <kdehl> Heh. Should have resized it.
[19:39:44] <N2TOH> I think I have that same bread board
[19:39:46] * N2TOH checks
[19:40:05] <N2TOH> nope mine has 4 binding posts
[19:40:15] <kdehl> Cheap ebay one?
[19:40:43] <N2TOH> not likely I've had it since before ebay
[19:41:19] <N2TOH> did you use the 1284P AVR chip
[19:41:21] <N2TOH> ?
[19:41:48] <kdehl> Ah. Heh.
[19:41:51] <kdehl> Yup, 1284p.
[19:42:11] <N2TOH> nice
[19:42:28] <kdehl> And you can't see it well on that picture, but I needed 3 1k resistors and 3 2k resistors. I had none.
[19:42:47] <N2TOH> have a look at this, http://minnie.tuhs.org/cgi-bin/utree.pl
[19:43:12] <kdehl> So I connected 8 16k resistors in parallel as a replacement for one of the 2k resistors, and similarly for the others... Heh. So the colors are really bad.
[19:43:30] <kdehl> And I run on a 4.5 V power supply, so the colors aren't very bright either.
[19:43:35] <N2TOH> the last time I looked into AVR VGA the last guy I observed doing so found a nifty method
[19:43:35] * kdehl checks
[19:44:11] <N2TOH> he used 2 bits per color, with 2 bits that were global so he had a even color palate
[19:44:17] <kdehl> Retro! Me likes.
[19:44:31] <kdehl> Um.. in the unix tree?
[19:44:53] <N2TOH> AVG_GCC will compile that code with the classic IE K&R switch set
[19:45:14] <N2TOH> I compiled hunt the wumpus without errors
[19:45:59] <N2TOH> I've been pondering if I should build a PDP-11 emulator for the 1284P or just try a native compile for the AVR
[19:46:04] <kdehl> You mean this one: http://www.lucidscience.com/pro-vga%20video%20generator-4.aspx
[19:46:05] <kdehl> ?
[19:46:23] <N2TOH> DING! yeah that one
[19:46:30] <kdehl> I actually stole that guy's timing calculations.
[19:46:36] <N2TOH> :)
[19:46:52] <kdehl> But wrote one helluvalot simpler program in C.
[19:47:03] <N2TOH> how much better does it run with 4 times the ram?
[19:47:13] <kdehl> Maybe I should publish it on my website, actually. It's probably about as simple as it gets.
[19:47:22] <N2TOH> linky?
[19:47:27] <kdehl> None yet.
[19:47:51] <N2TOH> have you seen the linear tech i2c programable oscillator?
[19:48:01] <kdehl> Nope.
[19:48:26] <N2TOH> it can output 1.039Khz to 68Mhz
[19:48:34] <kdehl> I don't really use any RAM on this one, though. I just paint some stripes. I will later though.
[19:49:12] <N2TOH> is there enough ram and CPU cycles to build a dumb terminal?
[19:49:19] <kdehl> Absolutely.
[19:49:34] <N2TOH> with PS/2 keyboard support?
[19:49:40] <kdehl> That will probably be exactly what I was thinking.
[19:49:41] <kdehl> Yup.
[19:49:47] <kdehl> I just did that too. Heh.
[19:50:09] <N2TOH> do yourself a favor and use RS422/RS232 serial line drivers
[19:50:23] <N2TOH> there is no reason not too
[19:50:29] <kdehl> But problem is that in order to use PS/2 you kinda need to use interrupts (not really, but it's a thousand times simpler that way), but the VGA signal is _very_ sensitive to getting interrupted.
[19:50:57] <kdehl> I'm using USART already, and I wrote a little terminal that can start and stop the VGA signal.
[19:51:13] <N2TOH> it this c case where your just better off lumping in a tinyAVR for the PS/2
[19:51:51] <kdehl> What?
[19:52:13] <N2TOH> I have seen terminals built with several AVR chips
[19:52:44] <kdehl> Yeah, it's easier to put the PS/2 funcionality on a separate chip,.
[19:53:34] <N2TOH> how many line/cols can you do with the ram in the 1284P?
[19:53:42] <kdehl> It'd be nice though to try to keep it in the same one, I will definitely give it a try.
[19:54:04] <N2TOH> can it do a common 80x25 terminal?
[19:54:29] <kdehl> N2TOH: It doesn't really have anything to do with the RAM, it's the speed of the µC that keeps you from painting too many pixels on a row.
[19:54:37] <kdehl> Dunno yet.
[19:55:08] <kdehl> Probably not.
[19:55:14] <N2TOH> http://cds.linear.com/docs/en/datasheet/69034fe.pdf
[19:55:19] <N2TOH> overclock!
[19:55:58] <N2TOH> I should check it the 1284P is available in a ceramic extended temp range version
[19:56:25] <The_Coolest> what for?
[19:56:30] <The_Coolest> just use LN2
[19:57:06] <N2TOH> there is a linear tech programable oscilator I have been playing with, and wanted to see just how far the 1284P could be over clocked
[19:58:42] <The_Coolest> hehe let me know :P
[19:58:53] <The_Coolest> I've got 2 sitting here
[20:00:14] <N2TOH> I need to go find I2C sample code
[20:00:35] <N2TOH> so I can tinker with the LTC6904
[20:00:49] <The_Coolest> http://www.amazon.com/dp/B001DZTJRQ/?tag=047-20 the reviews.. lol.
[20:11:51] <N2TOH> after that it's messing with SD cards
[23:22:05] <N1nAwayVacation> See y'all next week!