#avr | Logs for 2016-12-31

Back
[00:29:13] <sntxml> Hi! look at this nice project: http://viid.me/qyTqNe You can control New Year's Eve decoration in someone's house through the network
[00:37:49] <Tigzee> Lets do it while they are sleeping
[00:39:00] <arij> Lambda_Aurigae: could it have something to do with the 10k cap i have on the reset line
[00:39:11] <arij> or resistor rather
[02:33:15] <rue_shop3> thats good, cause a 10kF cap would take a LOOOOOONG time to release a reset line
[02:35:42] <Casper> and to be ready for the next cycle
[02:40:35] <rue_shop3> 10k resistor is a fine pullup for an avr reset line, not so strong as to overpower a programmer
[04:23:20] <carabia> who doesn't have some 10k caps laying around
[04:23:45] <carabia> arij: i was away, have we managed to debug the magic smoke?
[04:55:47] <rue_shop3> damnit, every hour after about 9pm is just useless
[04:55:55] <rue_shop3> no meat at all
[04:56:08] <rue_shop3> they just vaporize like they were barely even there
[04:56:22] <rue_shop3> its 2am
[04:56:26] <rue_shop3> it should only be midnight
[04:57:10] <carabia> meat? the prostitutes sleep during sunlight hours
[04:58:03] <carabia> oh wait, nevermind canucks
[04:58:32] <carabia> you must be from the west coast
[04:59:32] <rue_shop3> ?
[05:32:21] <_ami_> Hi
[05:34:18] <carabia> Hi
[05:35:54] <_ami_> carabia: is this normal? https://pbs.twimg.com/media/C1AAfvNUsAEHAgM.jpg:large i am not reading SPDR after sending data from master
[05:37:00] <_ami_> code is SPDR = x; while (!(SPSR & (1 << SPIF))); ///miso_data = SPDR;
[05:37:56] <_ami_> it should be similar to https://cdn.sparkfun.com/assets/c/7/8/7/d/52ddb2dcce395fed638b4567.png
[05:38:25] <_ami_> ideal behavior comes when i uncomment the commented line.
[05:39:34] <_ami_> why am i getting signal in mosi line on Slave to Master phase?
[05:41:23] <carabia> hold on
[05:41:32] <carabia> while i work out a way to open the link
[05:42:14] <_ami_> ok
[05:42:17] <_ami_> sabor: ^
[05:59:49] <carabia> err _ami_ can you show the whole send function and maybe even caller?
[06:01:06] <carabia> brb
[06:01:20] <rue_shop3> _ami_, STOP trying to do 115200 baud, if you do the _math_ you will see that its NOT a proper divider for the speed of the chip, and that the baud error rate is WAY out of spec
[06:01:42] <rue_shop3> 9600 is fine, 19200 is fine
[06:01:50] <rue_shop3> not 115200
[06:02:42] <rue_shop3> unless your running a special crystal, you prolly shouldn't be doing 115200
[06:04:10] <Tigzee> Thats a nice graph...where is that from?
[06:04:37] <Tigzee> rue_shop3, that looks like he is running spi, not uart
[06:04:42] <carabia> looks like saleae
[06:05:01] <carabia> well, pretty sure it's saleae
[06:05:15] <carabia> and i'm also pretty sure it's a clone
[06:07:15] <Tigzee> maybe I will have to make one
[06:08:29] <rue_shop3> Tigzee, ok, maybe next time I'll get one
[06:08:41] <carabia> why make one when you get it for less than $10 shipped with some clips
[06:08:58] <rue_shop3> its 3:40am, the blanket is still in the dryer cause I had the heat off the first 2 rounds...
[06:09:06] <rue_shop3> maybe I can go to bed soon
[06:09:31] <Tigzee> carabia, how well do those clones work? do they come with software?
[06:10:50] <Tigzee> my problem is, I don't have an analyzer...so i kinda just blindly walk into th ings hoping my math works
[06:10:52] <rue_shop3> clone of?
[06:11:00] <Tigzee> saleae
[06:11:17] <carabia> Tigzee: the clones work just fine. the software is freely downloadable from saleae
[06:11:37] <rue_shop3> logic analizer?
[06:11:41] <Tigzee> ya
[06:11:45] <carabia> ya.
[06:11:54] <Tigzee> carabia, thats weird...usually its the software that is most protected
[06:12:10] <carabia> well, it's not.
[06:12:29] <Tigzee> what do you guys use?
[06:13:07] <rue_shop3> https://www.aliexpress.com/item/1sets-New-Arrival-USB-Logic-Analyze-24M-8CH/32306037085.html
[06:13:15] <rue_shop3> I bought one of those, is that a clone?
[06:13:20] <rue_shop3> I'v not got it yet
[06:13:38] <carabia> apparently saleae has a loonix binary too for all you commies
[06:13:46] <rue_shop3> ?
[06:14:14] <rue_shop3> the human race prospered cause Gorth let Ord know how to make a hammer instead of keeping it a secret
[06:14:19] <rue_shop3> yay for open source
[06:14:45] <carabia> Tigzee: i use a saleae clone for avr fuckery at home
[06:14:59] <rue_shop3> is that link I posted a clone?
[06:15:07] <carabia> rue_shop3: based on the link it probably is. I can't open anything right now it seems.
[06:15:43] <carabia> if it says you can use the saleae software, yes, then it's a clone. there's some communist alternatives with their own software around too, though
[06:15:53] <carabia> one or the other. description should probably tell you
[06:15:55] <rue_shop3> oh dear, dont stop typing analizer at the first 4 characters with google doing its guess-as-you-go searching
[06:16:49] <rue_shop3> wow, a spartan processor?
[06:17:23] <rue_shop3> hahaha
[06:18:01] <rue_shop3> "over 20000 embedded developers actively use logic every month"???
[06:18:03] <rue_shop3> hahahahahahaha
[06:18:35] <rue_shop3> might was well say that over 40000 accountants in the united states drink from mugs....
[06:18:46] <rue_shop3> like EVERY MORNING
[06:19:22] <carabia> spartan? that doesn't sound like the clone
[06:19:27] <rue_shop3> with numbers like that, we should all be selling mugs!
[06:19:33] <carabia> and probably is way more expensive than $6
[06:19:35] <rue_shop3> no, not the one I got
[06:19:41] <carabia> oh
[06:19:57] <rue_shop3> its 4am, and I'M TIRED
[06:20:05] <rue_shop3> i want to finish building my cnc machine
[06:20:12] <rue_shop3> but I dont think thats gonna happen tonight
[06:20:22] <specing> wish I had time to build myself a cnc machine
[06:20:24] <rue_shop3> esp cause I'd have to haul out the welder to finish it
[06:20:26] <specing> and actually use it
[06:20:41] <rue_shop3> the beads would end up a little wiggly
[06:20:45] <Tigzee> rue_shop3, could you show me what you are using for your smelter?
[06:21:01] <rue_shop3> yes
[06:21:12] <rue_shop3> I could do it if I was awake
[06:21:38] <_ami_> carabia: any hints on why the results are weird when i don;t read from MOSI line?
[06:21:53] <carabia> _ami_: can you show your whole code
[06:21:55] <rue_shop3> where does the litter S land after and before?
[06:22:04] <rue_shop3> http://ruemohr.org/~ircjunk/projects/smelter/
[06:22:12] <rue_shop3> there is no slideshow, sorry
[06:22:36] <carabia> rue_shop3: no idea, tell us?
[06:22:53] <Tigzee> rue_shop3, you use gasoline to run that?
[06:23:16] <rue_shop3> diesel origionally
[06:23:30] <rue_shop3> its propane since the blower shorted and jammed
[06:23:45] <rue_shop3> http://ruemohr.org/~ircjunk/projects/smelter/slide.htm
[06:23:55] <rue_shop3> yay, looka me, I'm doing things on my sleeps
[06:23:58] <rue_shop3> I think
[06:24:00] <rue_shop3> are you all real?
[06:24:52] <Tigzee> rue_shop3, is that an 8 inch conrete worktable?
[06:24:53] <rue_shop3> I need to bang that all out and re-line is
[06:25:18] <rue_shop3> yea, the excavator couldn't break it up, too much rebar, so its a table
[06:26:21] <Tigzee> what is the concrete like stuff called that you have lining the inside of the pot and where would one get it?
[06:27:17] <rue_shop3> its a bit of concrete mixed with lots of perline and a bit of non-silica sand
[06:27:27] <rue_shop3> its stood up REALLY well, considering
[06:27:36] <rue_shop3> I still need to make a proper lid
[06:27:48] <rue_shop3> I could do that tommmorow
[06:27:53] <rue_shop3> no, it'd be too cold
[06:27:58] <rue_shop3> and the bag of concrete set
[06:28:04] <rue_shop3> damn mousutre
[06:28:35] <Tigzee> what is perline and where do I get it?
[06:28:36] <rue_shop3> my typing rates going up as my hands are getting used to the spring buckle keybaord
[06:28:44] <rue_shop3> garden store
[06:28:51] <rue_shop3> its white volcanic rock
[06:28:55] <carabia> sometimes just sometimes i get the idea that the struggle for written text on this channel is very real
[06:29:06] <carabia> s/idea/feeling
[06:29:20] <Tigzee> If you were to do it again, would you do the same or chagne something?
[06:29:23] * rue_shop3 segfaults, parse error
[06:29:40] <rue_shop3> same, but with a cast top that has a vent hole in the middle
[06:29:52] <rue_shop3> and maybe different put hangers, they get a bit soft
[06:29:55] <rue_shop3> pot
[06:30:24] <Tigzee> that 5/8 inch rebar gets soft?
[06:30:30] <rue_shop3> dont use stainless for the pot, it reacts with things in the aluminum and corrodes out
[06:30:48] <rue_shop3> nothing like a leaking pot of 2L of molten aluminum running across the lawn
[06:30:53] <rue_shop3> yea
[06:33:06] <Tigzee> that looks like a 1 inch propane hose
[06:35:02] <Tigzee> IS the propane torch using forced air at all?
[06:35:26] <rue_house> yay, the blankets done, I can make with the bed and go to sleep
[06:41:56] <rue_shop3> make hte bed
[06:42:09] <rue_shop3> make the bed and go to sleep
[07:31:24] <Lambda_Aurigae> happy next year...err..new year...something like that.
[07:34:35] <_ami_> Lambda_Aurigae: happy new year!! :)
[07:34:54] <_ami_> https://github.com/amitesh-singh/usb-gpio-board --> GPIO12 board based on AVR-vusb
[07:36:29] <Lambda_Aurigae> have built similar.
[07:36:54] <Lambda_Aurigae> I have been using pic16f1454 for those lately.
[07:39:07] <Lambda_Aurigae> although I made them usb-cdc devices to make interface easier.
[07:40:15] <_ami_> Lambda_Aurigae: i support sysfs structure for gpio pins
[07:40:32] <_ami_> which is kind of good if you want to control things via shell script
[07:40:50] <Lambda_Aurigae> can do shell script with cdc interface too.
[07:40:51] <_ami_> that is why i wrote a gpio driver for this board.
[07:42:46] <Tigzee> Lambda_Aurigae, where are you for it to be a new year?
[07:43:49] <Tigzee> Ireland?
[07:44:27] <Tigzee> did the math wrong...australia?
[07:44:42] <carabia> it's not even new year in australia yet
[07:44:49] <carabia> you muricans are funny
[07:45:15] <Tigzee> I'm -5gmt...australia is +8 to +10 gmt
[07:46:32] <Tigzee> does that not make it a new year for them?
[07:46:45] <carabia> oh wait yeah perhaps in the east
[07:47:25] <_ami_> nah, not yet, they are still behind ~ 3.5 hrs or so.
[07:47:45] <Tigzee> since ive only seen Lambda_Aurigae speak english, I am assuming australia
[07:48:24] <carabia> pretty sure he's a redneck ;)
[07:48:42] <Tigzee> Then he's doing redneck math :) and it's still new years
[07:49:08] <Lambda_Aurigae> Tigzee, no. USA actually.
[07:49:12] <Lambda_Aurigae> very much a redneck.
[07:49:19] <Lambda_Aurigae> but it's still new years in some parts of the world.
[07:49:23] <Lambda_Aurigae> and I have been to Aussieland.
[07:50:06] <carabia> in eastern australia it should be past midnight
[07:50:35] <Lambda_Aurigae> as of 7am central time USA, sydney and melbourne should have hit midnight.
[07:55:18] <Tigzee> Have you guys dealth with bluetooth modules?
[07:56:02] <Lambda_Aurigae> Tigzee, not I. nrf modules a couple of times and I have some esp modules to play with soon.
[07:56:28] <Lambda_Aurigae> you have a specific question?
[07:57:15] <Tigzee> I was wondering how much effort it would take to install a bluetooth module in the vehicle that is mapped to the phone. that way the car would know when the phone is near by
[07:57:47] <Lambda_Aurigae> depends on what you mean by "install"
[07:57:58] <Lambda_Aurigae> what are you wanting the car to do with that information?
[07:58:25] <Tigzee> a variety of things, but to start, just turn on some lights when it know you are near
[07:58:30] <Lambda_Aurigae> with some double sided foam sticky tape I can install almost anything in a car...it won't be useful for much, but,,,
[07:58:40] <Lambda_Aurigae> that depends on the car.
[07:58:58] <Lambda_Aurigae> often you need a bypass module to get the car to start without a chipped key these days.
[07:59:13] <Lambda_Aurigae> this is part of why remote start units are so costly.
[07:59:18] <Tigzee> don't worry about the car side. I'm just wondering how feasible it is with these bluetooth modules to pair toa phone
[07:59:33] <Lambda_Aurigae> pairing to a phone shouldn't be a problem
[07:59:47] <Lambda_Aurigae> depends on the module though.
[08:00:12] <Lambda_Aurigae> I use a bluetooth module on my work computer to auto-log me in when I get into the office.
[08:00:22] <Lambda_Aurigae> but it's a premade unit.
[08:01:41] <Tigzee> it uses your phone to know you are near and then it logs you in? I guess emulates a keyboard?
[08:02:19] <carabia> Tigzee: nordic has a gui configurator, good documentation & examples, and an app for android (at least) to get shit up and running in a heartbeat
[08:02:43] <carabia> pairing itself is super easy. read the docs.
[08:03:22] <Lambda_Aurigae> Tigzee, yes.
[08:03:24] <carabia> i would worry about the car more. especially if it's one where everything runs in the can bus
[08:03:38] <Tigzee> It's an older car...before computers were made
[08:03:41] <carabia> unless you're just gonna toggle switche, that is
[08:03:53] <carabia> alright. then shit gets simple.
[08:03:59] <specing> Tigzee: from 1940s?
[08:04:06] <Tigzee> lol, not that old
[08:04:19] <specing> but computers were definetely made after that
[08:04:27] <carabia> Tigzee: you could, e.g. get one of those rf link + arm modules nordic has
[08:05:09] <carabia> iirc the biggest downside was that they didn't have any eeprom
[08:05:16] <Tigzee> I was pretty much going to try and have it so the mobile phone becomes it's remote fob
[08:05:34] <Tigzee> if you walk to the vehicle, it automatically unlocks, etc..
[08:06:16] <Tigzee> I figured phones have 802.11 and bluetooth. can connect to multiple bluetooth units and bluetooth is limited range
[08:06:32] <Tigzee> so I figured bleutooth would be superior in this situation
[08:06:46] <carabia> especially if you use btle
[08:07:00] <carabia> (i think it was called btle)
[08:07:01] <Tigzee> I was just reading that some phones now only support that
[08:07:03] <Lambda_Aurigae> and we all know how absolutely sexure bluetooth is.
[08:07:14] <Lambda_Aurigae> secure too
[08:07:21] <carabia> sexurity is key
[08:07:54] <carabia> Lambda_Aurigae: given the absolute (not even relative) scarcity of such implementations in the real world
[08:08:28] <Tigzee> I can always do a rolling key with simple encoding. It's not a vehicle worth much.
[08:08:32] <carabia> you think people are actively running around parking lots trying to get into cars?
[08:08:40] <carabia> with their cellphones?
[08:08:42] <Lambda_Aurigae> actually, yes.
[08:08:52] <Lambda_Aurigae> however, it is usually the higher end cars.
[08:09:09] <Tigzee> around here...they just cut off the catayltic converters in parking lots
[08:09:11] <Lambda_Aurigae> the ones with phone interface remote start and unlock.
[08:09:31] <carabia> well that's another point pushing for this, really
[08:11:22] <carabia> in any case, you shouldn't rely on unlocking being performed on pairing
[08:11:37] <carabia> you can implement whatever protocol after the connection is established
[08:11:42] <carabia> now good fucking luck getting through it
[08:12:23] <Tigzee> I was hoping they were just...pair with this key...oh look, now oyu have a serial port on your phone
[08:12:45] <Lambda_Aurigae> Tigzee, depends on the device...some do just that.
[08:13:15] <carabia> Tigzee: nordics stuff really just works and the docs are great
[08:13:52] <Tigzee> I haven't programmed anything complicated for android yet, so I am hoping you don't need root access for serial port access
[08:13:53] <specing> Tigzee: why not do RSA?
[08:13:57] <Tigzee> carabia, reading now
[08:14:00] <specing> challenge-response
[08:14:32] <Tigzee> specing, I was planning on doing it like samba and a lot fo other things
[08:17:42] <carabia> Tigzee: i haven't ever programmed android, but shouldn't be too hard to establish a bt connection (given the car is polling if you just want to walk to it), and then initiating whatever kind of protocol you want to perform unlocking
[08:18:36] <carabia> app running on the background, bt enabled
[08:18:48] <twnqx> is this channel womewhat unusually populated atm?
[08:19:01] <Lambda_Aurigae> twnqx, no....about normal...lots of idlers.
[08:19:25] <twnqx> hm, i had a feeling it normally was sub 100
[08:19:36] <twnqx> but ok, i'll just believe you
[08:20:03] <Tigzee> I'm relatively new here...but it is holdays, so maybe more...but I don't know
[08:52:08] <TGILITO> hi all
[08:54:40] <Lambda_Aurigae> not yet but the day is young..
[08:54:44] <Lambda_Aurigae> oh,,,hi, not high.
[08:54:46] <Lambda_Aurigae> well, hello
[08:55:53] <TGILITO> ;)
[09:00:41] <carabia> ;)
[09:07:26] <DKordic> lo
[09:41:44] <arij> carabia: i got the target voltage to read -5.2 V
[09:42:04] <arij> should that - be there tho?
[09:42:30] <arij> shouldnt it be a positive number?
[09:53:58] <Lambda_Aurigae> have you measured it with a voltmeter to see what it is?
[09:54:58] <arij> Should I measure vcc and gnd
[09:55:22] <Lambda_Aurigae> well, how is your program measuring it?
[09:55:39] <arij> That I'm not exactly sure. Possibly those two pins
[09:55:43] <Lambda_Aurigae> that is the normal measurement points for voltage.
[09:55:53] <Lambda_Aurigae> have you read the sheet on the atmel ice?
[09:56:01] <arij> I looked through it
[09:56:07] <Lambda_Aurigae> or just jumping in barefooted with no idea what it is or what it does?
[09:56:07] <arij> Didn't see anything about my issue
[09:56:22] <arij> I looked over it
[09:56:30] <arij> It's confusing at parts
[09:56:56] <Lambda_Aurigae> ok...let me make this simple.
[09:58:07] <Lambda_Aurigae> power up target board. set voltmeter to 20V range or whatever is closest to that. put the black probe on the GND pin in your programming header....put the red probe on the VCC pin in your programming header...do not touch any other pins....read voltmeter
[09:58:31] <Lambda_Aurigae> this would be the same pins the atmel ice uses to read the voltage.
[09:58:48] <Lambda_Aurigae> just like it says in the atmel ice document that I read yesterday.
[10:00:31] <Lambda_Aurigae> and, as I said yesterday, learn basic electronics first
[10:10:55] <arij> I just said that's what I was going to do.... But thanks....
[10:15:50] <arij> reads 5v on the dot
[10:20:15] <toddpratt> I'm trying to program a chip. I'm able to compile and I think avrdude seems to do what it's supposed to, but my program doesn't seem to do the right thing. It's a blink program I stole from the internet: https://pastebin.mozilla.org/8957499
[10:25:34] <arij> got the target device to read 5v but still encountering this error https://usercontent.irccloud-cdn.com/file/kR5jpzhY/
[10:27:07] <kre10s> toddpratt: what is it doing instead?
[10:27:20] <toddpratt> kre10s: not blinking
[10:27:26] <toddpratt> it's just off
[10:27:27] <kre10s> does avrdude give any errors?
[10:28:15] <toddpratt> No, but I've never used avrdude before. The program and avrdude output are in the paste link
[10:28:54] <DKordic> toddpratt: Fuses?
[10:29:11] <toddpratt> It did erase the flash and I see the tinyusb programmer's LED blink during the write
[10:29:31] <toddpratt> I don't have the -e in the avrdude command anymore. Do I always need that?
[10:30:14] <toddpratt> DKordic: it says "Fuses OK"
[10:31:29] <DKordic> Look them up in Datasheet to verify it is what You want.
[10:31:55] <DKordic> What is the schematic? Do You have VCC caps?
[10:32:19] <toddpratt> It's just on the tinyusb programmer
[10:32:28] <DKordic> ?
[10:32:52] <toddpratt> The chip is just on the programmer.
[10:33:18] <DKordic> I bet problem is Fuses ior power supply.
[10:34:10] <toddpratt> It had a blink program from arduino on it and that worked fine. I guess I need to figure out the whole fuses thing.
[10:36:33] <DKordic> toddpratt: WTF should `F_CPU' be!? That is 1E+7 Hz!! Crystal oscilator(and Fuse configuration)?!
[10:40:09] <toddpratt> the data sheet says 10mhz at 5v
[10:40:30] * DKordic nods
[10:41:38] <Jartza> well.
[10:41:44] <Jartza> I now have attiny5 chips
[10:41:53] <Jartza> maybe I need to submit something stupid to that 1kB compo
[10:44:46] <DKordic> toddpratt: Internal RC oscilator is enough to blink LEDs. Set up Fuses and F_CPU acordingly!
[10:49:34] <arij> Lambda_Aurigae: now i have a different issue
[10:49:39] <arij> https://usercontent.irccloud-cdn.com/file/y9jMA8vT/
[10:51:05] * Lambda_Aurigae shrugs
[10:51:15] <Lambda_Aurigae> I don't use that software nor that programmer, so, no clue.
[10:51:33] <Lambda_Aurigae> and I'm out watching movies.
[10:51:53] <arij> thanks for the help earlier
[10:53:06] <arij> how can i "inject a clock into the chip"
[10:53:27] <arij> does that mean ISP clock?
[11:05:39] <antto> arij when you put an external XTAL, the cpu drives it (cuz it's a weak signal) and generates a stronger clock signal which is then used to drive the cpu frequency... external clock means a strong clock signal that is fed to the cpu (a steady square wave of some frequency)
[11:06:15] <arij> So I dont need to do anything?
[11:06:28] <antto> no idea
[11:06:37] <antto> i didn't follow the whole convo
[11:06:41] * antto hides
[11:07:47] <antto> arij whether the cpu would use (and drive) an external XTAL, or require an external clock signal, or it will use its internal clock source (if any) depends on the fuse bits
[11:52:18] <Eszett> ask your question here arij, the people will help you
[11:52:45] <arij> I have been but i think i might be asking the wrong questions
[11:53:05] <arij> people have been helping that how i got past the first problem, now a new problem arise
[11:54:11] <specing> not two new?
[11:54:25] <Lambda_Aurigae> just too new
[11:55:22] <arij> me?
[11:55:28] <Lambda_Aurigae> no, the problem
[11:55:42] <arij> yea Lambda_Aurigae we fixed the not connecting issue
[11:55:50] <arij> but the new problem is in the last screenshot i
[11:55:52] <arij> posted
[11:56:13] <arij> I can post it again
[11:56:47] <antto> i don't know what that means tbh
[11:56:57] <arij> neither do :(
[11:56:59] <antto> i don't use such tools myself
[11:57:14] <arij> any other software I could try with atmel ice?
[11:57:27] <arij> atmel studio just seemed like the recommended softwar
[11:57:32] <antto> ice? is that something like jtag?
[11:57:54] <arij> oh ice it has jtag but im trying to program over ISP
[11:58:10] <arij> if that makes sense
[11:58:21] <antto> ISP.. okay, for ISP i use avrdude
[11:58:50] <arij> I could give that a shot
[11:58:57] <antto> but that doesn't mean you should too
[11:59:01] <Eszett> antto: ISP is the same as SPI, right?
[11:59:07] <antto> no
[11:59:55] <antto> SPI is a form of communication, SCK/MISO/MOSI and "chip-select" or "slave-select" .. 4 wires (plus ground)
[12:00:16] <antto> ISP is "in-system programming" iirc
[12:00:36] <Eszett> ok, so for both SPI and JTAG you use a ISP, no?
[12:00:42] <antto> it is the act of attaching a programmer to a chip which is already in a circuit, and programming it
[12:00:46] <Eszett> in-system-programmer
[12:01:02] <antto> as opposed to getting the chip off the PCB and attaching it onto a programmer
[12:01:09] <Eszett> ye, I see
[12:01:12] <antto> that's as far as i understand
[12:01:49] <Eszett> Ye, and there are in-system-programmers forJTAG and there are ones for SPI?
[12:02:41] <DKordic> Eszett: AVR ISP is using SPI.
[12:02:45] <antto> well, i'm not familiar with JTAG, afaik that's a more advanced method of dealing with the chip, which includes also mechanisms to debug it
[12:03:16] <Eszett> for example the USBASP device is a AVR SPI ISP. "AVR" is the chip architecture, SPI is the interface/protocoll, and ISP meaning "in-system-programer"
[12:03:30] <Eszett> right?
[12:03:57] <Eszett> ok got it
[12:04:15] <DKordic> Eszett: IMHO ISP is specific to AVR. It is built on top of SPI.
[12:05:48] <Eszett> Dkordic: ok. arij has both an USBASP device (AVR ISP), and the official Atmel ICE ISP
[12:06:24] <Eszett> But im not sure how to help him getting rid of his error message
[12:45:11] <rue_shop3> what is the error message?
[12:45:55] <antto> i can't even tell
[12:48:37] <Eszett> arij post your error message here, pls.
[12:49:09] <arij> https://usercontent.irccloud-cdn.com/file/y9jMA8vT/
[14:18:42] <toddpratt> figured out my problem
[14:21:27] <toddpratt> I was missing the -U in my avrdude command line
[15:38:42] <rue_shop3> oooh makefile!
[17:32:38] <Tigzee> arij, are you using an external crystal?
[17:34:34] <Tigzee> I don't know the software you are using or how to use it...but I can tell you what the error means
[17:35:09] <Tigzee> It's checking the Low Fuse register on the chip and it's getting a response back it is not expecting
[17:35:45] <Tigzee> my question would be: when does the fuses get written?
[17:36:22] <Tigzee> or is that what that page is?
[17:37:51] <Tigzee> between F4 and D9, all the bits have been triggered to do DE...so I wouldn't think its a communications issue
[17:49:13] <arij> thats the window where you change the fuse
[17:49:23] <arij> just uncheck the DIV8 then program
[17:49:55] <Tigzee> your doing more then that
[17:50:18] <arij> shouldnt be
[17:50:23] <Tigzee> you are telling it to run an external ceramic crystal with a frequency of 0.4 -> 0.9mhz
[17:50:43] <arij> i have a crystal on the pcb as well
[17:50:51] <arij> 16Mhz
[17:51:25] <Tigzee> It looks like you are trying to program LOW 0xDE
[17:51:38] <arij> yea
[17:52:19] <Tigzee> page 248 of the datasheet shows how that register is broken down
[17:52:38] <Tigzee> 0xD9= 11011001
[17:52:48] <arij> 0xDE
[17:53:11] <Tigzee> whoops...that would be why I was wrong
[17:53:18] <arij> https://usercontent.irccloud-cdn.com/file/dAQlD7XT/
[17:54:03] <Tigzee> 0x5E is the default...let me recheck 0xDE
[17:54:46] <Tigzee> you are correct, it should only be the dividing by 8 that changes
[17:55:09] <arij> yea, that divide by 8 thing is getting in the way
[17:55:10] <Tigzee> It is ok with you programming 0x5E but not 0xDE?
[17:55:14] <arij> I need to change it
[17:55:25] <arij> its already set to 0x5E by default
[17:55:46] <Tigzee> what happens when you tell it to program the 0x5E (default)?
[17:56:10] <arij> it worked
[17:57:39] <Tigzee> what are your lock bits set to?
[17:58:59] <arij> https://usercontent.irccloud-cdn.com/file/24lXYj0p/
[17:59:52] <Tigzee> I think your current setting of LB is not allowing you to write the fuse bits
[18:00:05] <arij> I will try to change it to NO_LOCK
[18:00:06] <Tigzee> is no lock features an option?
[18:00:08] <arij> ya
[18:00:11] <arij> :d
[18:00:13] <arij> :D
[18:00:26] <Lambda_Aurigae> arij, you do know that if you change the clock speed then you will have to update the software on the machine to keep the usb working, yes?
[18:00:51] <Lambda_Aurigae> if it is locked, the only way to unlock is to erase the whole chip.
[18:01:12] <arij> yea it wouldnt let me change it
[18:01:34] <Lambda_Aurigae> as I said
[18:01:37] <Lambda_Aurigae> if it is locked
[18:01:37] <arij> I dont understand what you mean by "update the software on the machine"
[18:01:40] <Lambda_Aurigae> the only way to change
[18:01:45] <Lambda_Aurigae> is to ERASE the chip.
[18:01:56] <arij> what do I do after erasing the chip?
[18:01:58] <Tigzee> I have never done this before, but from how I read it...that is your problem. I would listen to Lambda_Aurigae
[18:02:05] <Lambda_Aurigae> on the board...update software on the chip if you change clock speed.
[18:02:15] <arij> like DFU?
[18:03:42] <arij> thanks Tigzee at least you pointed me in the right direction
[18:03:51] <Lambda_Aurigae> like, the software that the chip uses to talk to the USB on the host computer.
[18:04:00] <Lambda_Aurigae> the software on the chip.
[18:04:16] <Lambda_Aurigae> if you change clock speed then you have to change pll prescaler for the usb...that is done in software.
[18:06:32] <arij> I need atmel DFU on there
[18:06:36] <arij> is that still possible?
[18:06:51] <arij> whatever they have on it from the factory
[18:07:24] <Lambda_Aurigae> I thought this was something you were building.
[18:07:31] <Lambda_Aurigae> why are you trying to change the clock speed?
[18:07:54] <Lambda_Aurigae> DFU is just the bootloader section....it is software loaded on the chip
[18:08:15] <Lambda_Aurigae> if the chip is locked, the only way to change fuses is to ERASE THE CHIP
[18:08:23] <Lambda_Aurigae> that means erasing all the software on the chip.
[18:09:47] <Lambda_Aurigae> it's right there in the datasheet
[18:11:22] <Lambda_Aurigae> you can later upload a dfu bootloader to the chip
[18:11:31] <Lambda_Aurigae> there are a couple of them out there.
[18:37:02] <arij> It's a keyboard and it's laggy
[18:37:16] <arij> I'm thinking it's because of the divide by 8 fuse
[18:37:41] <arij> And if I run at 16MHz it won't be laggy
[18:38:53] <antto> if you change the cpu freq of some existing firmware, it may not work the same way, you'd most likely have to recompile it at least, with some changes
[18:39:32] <antto> this depends on what it does and how it does it (how it's written in the code)
[18:53:19] <Lambda_Aurigae> and, I'm betting you don't have the source code.
[18:53:28] <Lambda_Aurigae> and, the chip is locked.
[18:53:38] <Lambda_Aurigae> and that won't change the thing being laggy.
[18:54:35] <antto> reality sux
[18:54:46] <antto> the year just increments
[18:55:10] <Lambda_Aurigae> could have saved you days of problems if you had mentioned this to start.
[18:55:16] <antto> or time doesn't exist, we increment some number
[18:57:44] <Lambda_Aurigae> time is just an illusion we use to keep track of the passage of the 4th dimension.
[19:11:44] <carabia> arij: what's up?
[19:12:48] <arij> carabia: i guess i need to erase the chip to change the lockbit
[19:12:59] <arij> to be able to program the fusebits
[19:13:10] <carabia> bring me up to speed. last night you were smoking chips, today the chips are locked? what's the story
[19:14:51] <arij> i guess it wasnt smoking
[19:14:58] <arij> and was able to communicate with the chip
[19:15:01] <arij> everything is just locked
[19:15:55] <carabia> well erase and reflash, can't be that hard?
[19:16:26] <carabia> i guess the real crux here is the reason why the chip's locked?
[19:17:32] <arij> all of the chips i have are the same
[19:17:39] <arij> I had 5 pcbs assembled and they are all the same
[19:17:46] <Lambda_Aurigae> arij, once you erase it, there will be no software on the chip...
[19:17:56] <Lambda_Aurigae> no dfu bootloader, no software to make it play keyboard.
[19:18:10] <Jartza> happy new year
[19:18:20] <Lambda_Aurigae> hoppy nude beer!
[19:19:17] <Lambda_Aurigae> if the chip has a dfu bootloader on it then it is meant to have the software updated.
[19:22:48] <arij> how do I update the software?
[19:22:53] <antto> "DFU bootloader" means you have to use the atmel FLIP tool, right?
[19:23:01] <arij> I dont have it but I can download it
[19:23:02] <Lambda_Aurigae> you said you had to have DFU on the chip.
[19:23:09] <Lambda_Aurigae> why?
[19:23:18] <arij> so I can program my own firmware over usb?
[19:23:19] <carabia> I am really not following this anymore
[19:24:07] <Lambda_Aurigae> why not use the ISP where you are trying to update fuses to update the software?
[19:24:20] <carabia> i thought you bought a bunch of micro breakouts and what not, and you were gonna make your own shit. Now you're saying you got assembled pcbs and they are what? Preflashed?
[19:24:30] <arij> I want to but i'm not sure how to update the software
[19:24:32] <Lambda_Aurigae> carabia, bingo.
[19:24:46] <Lambda_Aurigae> arij, does it have the DFU bootloader on it now?
[19:24:51] <arij> yea it does from the factory
[19:25:04] <Lambda_Aurigae> the chip does from the factory.
[19:25:06] <Lambda_Aurigae> however
[19:25:09] <antto> are these "brand new" mcus?
[19:25:13] <arij> yea
[19:25:14] <arij> they are
[19:25:22] <arij> ordered from mouser
[19:25:23] <antto> then they can't be "locked"
[19:25:23] <Lambda_Aurigae> those chips have been reprogrammed by the maker of those boards?
[19:25:32] <Lambda_Aurigae> what did you order from mouser?
[19:25:36] <Lambda_Aurigae> the keyboards?
[19:25:41] <arij> no, the componenets
[19:25:46] <carabia> Lambda_Aurigae: now we're getting somewhere
[19:25:47] <antto> atmegas, i guess
[19:25:48] <arij> one of which was the atmega32u2
[19:26:01] <carabia> is he trying to clone something here?
[19:26:08] <arij> the pcb fab house just made the pcb and assembled the components for me
[19:26:13] <arij> carabia: i designed a keyboard
[19:26:15] <antto> ah
[19:26:26] <Lambda_Aurigae> however, the error you showed earlier is that the fuses can not be reprogrammed due to the chip being locked.
[19:26:26] <carabia> arij: well then. You ought to have the firmware ready to go.
[19:26:34] <antto> okay.. and now you need to put a firmware in it for the first time
[19:26:54] <Lambda_Aurigae> can you read the fuses and lock bits?
[19:26:59] <arij> yea i can read them
[19:27:01] <arij> i cant write them
[19:27:43] <arij> i put a keyboard firmware on it and it worked
[19:27:52] <antto> how?
[19:27:59] <arij> over usb
[19:28:02] <antto> okay
[19:28:21] <arij> i need to change the divide by 8 fusebit because I want the crystal to run at the full 16MHz
[19:28:33] <antto> then the firmware will no longer work
[19:28:34] <Lambda_Aurigae> did you write this firmware?
[19:28:49] <arij> i did write the firmware
[19:28:58] <arij> why wont the firmware work antto ?
[19:29:11] <arij> it currently works just fine
[19:29:16] <Lambda_Aurigae> if you change the clock speed, you will have to modify the firmware to match.
[19:29:16] <antto> cuz everything that relates to time will go off
[19:29:23] <carabia> you're probably gonna have to change it, then
[19:29:31] <arij> i can edit the firmware for that
[19:29:40] <carabia> i for one am doubtful of the real author of the firmware, but that's just me
[19:29:41] <antto> you *will* have to
[19:29:42] <Lambda_Aurigae> so, what are the fuse and lock bits?
[19:29:43] <carabia> 8D
[19:30:06] <arij> https://usercontent.irccloud-cdn.com/file/XjtOFFMo/
[19:30:18] <carabia> or of the designer of said pcb, too :D
[19:30:24] <Lambda_Aurigae> that's not what I asked, however
[19:30:26] <arij> https://usercontent.irccloud-cdn.com/file/reG4nWkG/
[19:30:40] <Lambda_Aurigae> looks like you programmed the lock bits to stop it from being reprogrammed without ERASING THE CHIP
[19:30:59] <arij> I didnt program the lock bits
[19:31:19] <Lambda_Aurigae> somebody did.
[19:31:24] <carabia> the mcu will not be mint with lock bits programmed
[19:31:31] <carabia> ...
[19:31:32] <antto> could it be the DFU bootloader doing such things itself?
[19:31:37] <Lambda_Aurigae> no
[19:31:41] <antto> i'm not familiar with it
[19:31:43] <Lambda_Aurigae> DFU can not change lock bits.
[19:31:46] <Lambda_Aurigae> only jtag or ISP
[19:31:58] <Lambda_Aurigae> or debugwire
[19:32:05] <arij> it was locked before i even plugged in the isp
[19:32:12] <arij> and its a brand new chip
[19:32:15] <arij> this i know
[19:32:16] <Lambda_Aurigae> then your board maker did it.
[19:32:21] <Lambda_Aurigae> or it is a fake chip.
[19:32:23] <antto> O_O
[19:32:52] <arij> no way
[19:32:55] <Lambda_Aurigae> they do not come like that from the factory...I have several atmega32u2 chips here fresh from digikey and they are reprogrammable.
[19:33:07] <carabia> ^
[19:33:12] <arij> thats so weird
[19:33:15] <arij> i tried two of them
[19:33:16] <carabia> no, you are
[19:33:16] <antto> of course, that's.. the.. whole.. purpose of them
[19:33:19] <arij> they are atmega32u2
[19:33:22] <arij> it says atmel on it
[19:33:35] <arij> and i know because i ordered them from mouser and i sent them to the fab house
[19:33:47] <carabia> cause a fake chip totally says fake atmel on it
[19:33:53] <antto> yeah
[19:33:56] <antto> "AMTEL"
[19:34:02] <arij> i'm not sure mouser would be selling fake chips
[19:34:06] <antto> or "ATEML"
[19:34:41] <carabia> has happened that fakes have been circulating form reputable distributors. But not sure if it has happened with atmel
[19:34:43] <Lambda_Aurigae> can you read the fuses and lock bits and show them as hex or binary?
[19:35:21] <antto> if i were you, i'd use avrdude in terminal mode
[19:35:23] <carabia> however i don't believe they are fakes, there's something obvious missing here that arij is just failing to communicate, due to lack of ... expertise, so to say
[19:35:54] <arij> it just shows
[19:35:57] <carabia> in other words, the lack of rtfm
[19:35:58] <arij> when i read the bits
[19:35:59] <antto> his visual tool that deals with the programmer could be doing something
[19:36:08] <arij> its atmel studio
[19:36:13] <carabia> antto: i thought he was using atmel studio
[19:36:20] <antto> so what?
[19:36:31] <carabia> it doesn't program the fuses unless you explicitly tell it to
[19:36:40] <carabia> i.e. the fuses tab
[19:37:07] <antto> yes.. and what if you "tell it to" without realizing you did?
[19:37:27] <carabia> it would constitute to you navigating to the fuses tab and hit write
[19:37:30] <antto> ask me how i bricked the first atmega i attached a programmer to
[19:37:34] <antto> with a visual tool
[19:37:47] <carabia> also, i think it even asks you to confirm the operation
[19:38:03] <antto> "i don't know, i was pressing some buttons hoping something to happen"
[19:38:05] <carabia> this is just off the top of my head, i haven't used as in ages
[19:38:17] <arij> i have tried on two different pcbs
[19:38:25] <antto> one more thing
[19:39:15] <antto> you said you designed the pcb, you should consider carefully how to expose the ISP-related pins from the chip
[19:39:29] <antto> but i'd assume that's not a problem
[19:39:51] <antto> i've seen some example schematics where for example the RESET pin is tied to VCC
[19:41:36] <Lambda_Aurigae> so, we need to back up all the way...get something other than atmel studio installed, and try to read the fuses and lock bits.
[19:42:15] <antto> do you happen to have some more of these chips which you *didn't* send to the "fab" ?
[19:42:32] <carabia> Lambda_Aurigae: why would having "something other than atmel studio" work, apart from it going against the grain of your commie philosophy?
[19:43:19] <antto> carabia i find it hard to interpret what's going on because the information in his screenshots is too alien to me
[19:43:28] <antto> i don't have/use atmel studio
[19:44:17] <carabia> that's kind of irrelevant, if he's sending screenshots of as's fuse interface, it will show necessary information
[19:45:13] <carabia> however, arij i suggest you do a bit of googling by yourself for a change (rather than outsourcing it to the channel), and try to find people using whatever boards you are using with possible similar problems
[19:45:19] <carabia> if there are none, then it's pebkac
[19:45:22] <antto> well this sort of message "you can't program the fuses." sounds to me kinda like "i'm not in the mood."
[19:45:29] <Lambda_Aurigae> carabia, because it seems that he is having trouble with atmel studio.
[19:46:30] <Lambda_Aurigae> just trying to eliminate one problem at a time.
[19:47:10] <antto> i'm pretty sure avrdude will NOT prevent you from attempting to change fuses
[19:48:02] <antto> it will just send the commands away, and if it turns that it's not possible - you will either get an error back from the chip/programmer or you'll see nothing has been changed when you re-read them back
[19:48:13] <carabia> arij: what's the clock freq you're attempting to program it with?
[19:48:21] <arij> I'm not sure
[19:48:34] <arij> 125 maybe? I'm not at the PC any longer
[19:48:34] <carabia> you see the isp clock in the programming dialog in AS
[19:48:41] <antto> 128 what?
[19:48:45] <arij> Yea I believe it was around 125
[19:48:47] <antto> 125 i mean
[19:48:54] <arij> KHz
[19:49:02] <antto> o_O
[19:49:13] <arij> That's what it at at by default
[19:50:07] <antto> by default? who says?
[19:50:14] <carabia> AS says
[19:50:19] <antto> x_x
[19:50:24] <antto> --AS;
[19:50:27] <antto> ++avrdude;
[19:50:31] <carabia> but you can still read the fuses?
[19:52:09] <carabia> if you can't even read the fuses i guess you could try slowing the isp clock further, though 125 KHz ought to work with a mint chip
[19:52:54] <arij> Slowing to 100?
[19:54:05] <carabia> well it doesn't really matter. just slower.
[19:54:52] <carabia> just a shot in the dark, really
[19:56:44] <carabia> and to take it from the bottom up, you are absolutely sure the isp pinout is correct?
[20:01:38] <carabia> for all i know you could have damaged the god damn ice too with your smoking, who knows :)
[20:03:54] <carabia> ...which would explain none of the boards working, actually
[20:04:44] <carabia> but then again it's a bit far-fetched perhaps
[20:12:24] <antto> are the ISP pins of the chip also used normally in the circuit for other things?
[20:14:14] <carabia> oh, he hasn't provided a circuit diagram yet? I guess he's a bit scared of someone stealing the design and making big $$ off keyboards
[20:15:34] <antto> mechanical keyboards are like 100 bucks
[20:15:42] <antto> normal keyboards are 5 bucks
[20:15:42] <Lambda_Aurigae> he did yesterday.
[20:15:49] <antto> good luck with that
[20:16:14] <carabia> antto: i believe this particular design is over $250
[20:16:17] <carabia> or something.
[20:16:32] <carabia> but, good luck with that
[20:16:43] <antto> i'll buy a mechanical keyboard when their prices drop down to 10 bucks.. but that ain't gonna happen
[20:17:57] <carabia> he said it was "ergodox". Some bullshit split keyboard with a price tag of $295, apparently. This is some kind of a rip-off, I assume
[20:18:55] <carabia> maybe the chinese people are willing to let you get casts off the same molds, haha
[20:19:15] <carabia> moulds, even
[20:43:27] <arij> No
[20:43:43] <arij> It was my own design and I shared PCB and schematics yesterday
[20:44:02] <arij> It has nothing to do with ergodox
[20:44:16] <arij> It's not even a split keyboard like the ergodox
[20:44:34] <carabia> okay, that's just what you said a week ago or so
[21:03:59] <arij> I don't recall
[21:04:04] <arij> It may have been another issue
[21:08:07] <Emil> Testing OSHPark://oshpark.com/shared_projects/Fb0xg6GJ :3 3.15$ incl. shipping for 3 pieces, not too shabby imho
[21:08:25] <Emil> https://oshpark.com/shared_projects/Fb0xg6GJ
[21:16:19] <Chillum> I do love them for making little breakout boards
[21:16:49] <Chillum> I like this one: https://oshpark.com/shared_projects/1ybAAUrY
[21:16:53] <Chillum> 3 for 30 cents
[21:17:04] <Chillum> just an 0805 resistor and LED and two pins
[21:20:09] <Chillum> Emil: this is my attiny13 board: https://oshpark.com/shared_projects/uXac7ogJ The attiny goes under the board between the pins, just to make it a bit smaller
[21:20:18] <Chillum> just in a DIP-8 footprint
[21:23:53] <carabia> when will we get breakouts for individual smd resistors and leds
[21:24:44] <carabia> a dip breakout for the resistor, another for the led, maybe one more breakout for a header and then more interconnecting breakouts and then some more breakouts.
[21:24:50] <Lambda_Aurigae> design one...I'm sure someone will buy it.
[21:25:11] <carabia> i need a buzzword. resistor.io?
[21:25:20] <carabia> branding is key
[21:25:24] <Lambda_Aurigae> RIO!
[21:25:55] <Lambda_Aurigae> RIO board
[21:26:02] <Emil> Chillum: not bad
[21:26:02] <Lambda_Aurigae> and LEO...LEd Output
[21:26:51] <carabia> i'm torn between branding the different breakouts individually or should i create a family which houses them all?
[21:26:54] <Emil> Ah, just noticed a brainfart in design on my board
[21:27:03] <Emil> I should have flipped the R1 and L1
[21:27:08] <Emil> mirrored*
[21:27:22] <Emil> carabia: modularity is always a buzzword for selling things ;)
[21:30:02] <Emil> Hmm
[23:32:42] <Tigzee> Happy new year EST