#robotics Logs

Dec 31 2017

#robotics Calendar

12:03 AM anonnumberanon: ok got sorting figured out
12:06 AM rue_shop3: button
12:06 AM anonnumberanon: now to do the port manipulations, hopefully i can build bitmasks from different origins into one and apply that one
12:06 AM rue_shop3: Tom_L, k, I'll dig some out of the box and make them up
12:06 AM anonnumberanon: THEN check if i can do the same dynamically in asm
12:06 AM anonnumberanon: this middle step handles the case when you want to turn on 2 pins exactly at the same time, for those of use who like these sorts of things
12:07 AM anonnumberanon: ok, it sorts the array, not to change from array to array of structs for holding more info about the pin
12:09 AM anonnumberanon: although im kind of skipping fully understanding what is "const void * a" and how i can make my own of this, not critical, will skip it
12:10 AM anonnumberanon: "const void pointer"
12:10 AM anonnumberanon: "const pointer to void"
12:10 AM anonnumberanon: googling it could take me into a rabbit hole, better continue
12:12 AM anonnumberanon: array of structs, array of structs, show your face to me
12:16 AM rue_shop3: anonnumberanon, are you writing your own grbl?
12:17 AM anonnumberanon: you wish
12:20 AM rue_shop3: I was kinda hoping you would have something physical moving by now
12:30 AM anonnumberanon: this is like taekwondo, hitting the bag over and over won't help you do more damage
12:30 AM rue_mohr: yea, I think your too far into the bush for me to help ya
12:31 AM rue_mohr: buuuuuuuuuuuuuuuuuuuuuut icecream and peanutbutter sounds good
12:31 AM rue_mohr: oOOOOOOOOOOOOOO with chocolate
12:31 AM rue_mohr: hell yea
12:33 AM anonnumberanon: rue_mohr, http://www.openculture.com/2012/09/the_illustrated_guide_to_a_phd-redux.html
12:34 AM anonnumberanon: I have an intuition and I will not stop until I prove it to have been wrong.
12:35 AM anonnumberanon: Subsequently I will then have less trust in my intuition if I am wrong.
12:39 AM rue_mohr: haha
12:39 AM rue_mohr: you see, we havn't caught up to what we can do NOW
12:40 AM rue_mohr: I dont need to be in the future, the present and past are more than enough to create what I need going forwards
12:40 AM anonnumberanon: ah, googling for answers I HATE IT
12:41 AM * rue_mohr throws the 1974 magazine at anonnumberanon , the one that talks about how HDTV is just around the corner and how in another 5 years there will be amazing new piture quality
12:41 AM rue_mohr: NOTHING IS NEW
12:41 AM SpeedEvil: Now all they need to do is to work on amazing program quality
12:41 AM anonnumberanon: lol
12:41 AM SpeedEvil: I was reading an interesting paper from 1987 today.
12:42 AM SpeedEvil: (on how much artificial light you need to grow enough food for a person)
12:42 AM rue_mohr: nothing for the 12' mecca I'm working on is newer than about the early 70's
12:42 AM SpeedEvil: (it's around 3kW, with modern lights)
12:42 AM SpeedEvil: rue_mohr: batteries?
12:42 AM SpeedEvil: rue_mohr: neodynium magnetted motors
12:42 AM rue_mohr: gas engine
12:43 AM rue_mohr: you tell me, when were pneumatic muscles developed?
12:43 AM rue_mohr: hint, japan
12:44 AM anonnumberanon: okay damn, done
12:44 AM anonnumberanon: sorting array of structs, GOOD
12:45 AM anonnumberanon: googled it, closed my eyes while clicking back on dev file, tried to look over program, fixed gross mistake, it worked
12:45 AM anonnumberanon: good feeling
12:45 AM anonnumberanon: this is why im careful about googling right away, it can make you dumb and needy
12:45 AM rue_mohr: so, it looks like each thingiverse object generates about .5 views/day
12:45 AM anonnumberanon: lo
12:45 AM anonnumberanon: l
12:46 AM rue_mohr: I'd like to try flooding my profile, but I'v posted anything of use alrady
12:46 AM rue_mohr: less the new cnc pendant
12:47 AM rue_mohr: anonnumberanon, did you see my new helping hands? its kinda freaky
12:47 AM rue_mohr: https://www.thingiverse.com/thing:2739421
12:47 AM anonnumberanon: yes it's nice, don't have time to make one, ship to me nao
12:47 AM rue_mohr: haha
12:47 AM rue_mohr: it took waay too much work
12:48 AM anonnumberanon: oh wait this does not include the solder girlfriend?
12:48 AM anonnumberanon: I'll wait
12:48 AM rue_mohr: 14 peices made on lathe
12:48 AM rue_mohr: 6 peices made of general metalsmithing
12:51 AM anonnumberanon: cool
12:52 AM anonnumberanon: oh well ship me it anyway mine is the ridiculous one with the loop
12:52 AM anonnumberanon: although i suspect if i finally got less lazy and actually pressed it to my table, it wouldn't be as shitty
12:53 AM anonnumberanon: the crocodile clamps are kinda okay, although loose sometimes and require retightening from time to time
12:53 AM anonnumberanon: ok next
12:53 AM anonnumberanon: where are we
12:53 AM anonnumberanon: oh yeah, building port bitmasks
12:54 AM anonnumberanon: first, assign a pin to each struct
12:54 AM anonnumberanon: should be simple enough, although too simple, something's cooking...
12:55 AM anonnumberanon: okay yeah before just adding pins, figure out what will be the best format for this
12:55 AM anonnumberanon: look up port manipulation
12:56 AM anonnumberanon: rather, read avr datasheet, think that's where i found it last
12:56 AM ace4016: some ports need additional setups with the configuration vectors
12:56 AM anonnumberanon: or was it a #avr dude who told me about it
12:57 AM rue_mohr: #define SetBit(BIT, PORT) (PORT |= (1<<BIT))
12:57 AM rue_mohr: #define ClearBit(BIT, PORT) (PORT &= ~(1<<BIT))
12:57 AM rue_mohr: #define IsHigh(BIT, PORT) (PORT & (1<<BIT)) != 0
12:57 AM rue_mohr: #define IsLow(BIT, PORT) (PORT & (1<<BIT)) == 0
12:57 AM rue_mohr: #define NOP() asm volatile ("nop"::)
12:57 AM rue_mohr: #define ABS(a) ((a) < 0 ? -(a) : (a))
12:57 AM rue_mohr: #define SIGN(x) (x)==0?0:(x)>0?1:-1
12:57 AM rue_mohr: #define limit(v, l, h) ((v) > (h)) ? (h) : ((v) < (l)) ? (l) : (v)
12:57 AM rue_mohr: #define inBounds(v, l, h) ((v) > (h)) ? (0) : ((v) < (l)) ? (0) : (1)
12:57 AM rue_mohr: #define RangeRemap(v,Il,Ih,Ol,Oh) (((((v)-(Il))*((Oh)-(Ol)))/((Ih)-(Il)))+(Ol))
12:57 AM rue_mohr: #define RampUp(k,top) (((k)<(top))?(k++):(k+=0))
12:57 AM rue_mohr: #define RampDown(k,bot) (((k)>(bot))?(k--):(k+=0))
12:57 AM anonnumberanon: keep going
12:57 AM anonnumberanon: i dont see it it there
12:57 AM rue_mohr: #define DetectOn() SetBit(1, PORTB)
12:57 AM rue_mohr: #define DetectOff() ClearBit(1, PORTB)
12:58 AM anonnumberanon: it's supposed to be less instructions than (PORT |= (1<<BIT))
12:58 AM rue_mohr: tahts one instruction
12:58 AM rue_mohr: in that cause sbi
01:01 AM anonnumberanon: must be this i guess
01:01 AM anonnumberanon: https://hekilledmywire.wordpress.com/2011/02/23/direct-port-manipulation-using-the-digital-ports-tutorial-part-3/
01:01 AM rue_mohr: nomatter what I say, your going to go in some strange direction
01:08 AM anonnumberanon: ok, so toggling with PINx is good
01:08 AM anonnumberanon: and fast af
01:08 AM anonnumberanon: but you can't build a bitmask for PINx that will have pins coming from different ports
01:08 AM anonnumberanon: , how to solve that now...
01:08 AM * anonnumberanon takes water break
01:15 AM anonnumberanon: so we could store the port into each struct, but with that and the pwm duration in it, that's 2 calls
01:15 AM anonnumberanon: 2 calls to structs
01:15 AM anonnumberanon: both through the array pointer
01:16 AM anonnumberanon: heavy shit for trying for only a few instructions in assembly
01:16 AM anonnumberanon: oh fuk damn it man
01:18 AM anonnumberanon: this MUST be possible
01:21 AM anonnumberanon: or we could store the 3 ports into each order, that way we execute them all if any port is in need of togglingg
01:22 AM anonnumberanon: for speed this means one pin is turned on on a port, and another on another port is turned on right after and is 62 to 125 nanoseconds late, even though the robot's brain intended on them being fired exactly at the right time
01:23 AM anonnumberanon: in retrospect this would be an issue regardless of the frequency of the microcontroller
01:23 AM anonnumberanon: wow
01:23 AM anonnumberanon: unless a micro has a port that has 17 pins on it instead of 8 for the avr
01:28 AM anonnumberanon: man... now we're talking rue_mohr ehh?
02:10 AM anonnumberanon: now...
02:11 AM anonnumberanon: in order to decrease the nefarious effect of not being able to fire pins from different ports exactly at the same time, we can do the following
02:11 AM anonnumberanon: assign:
02:11 AM anonnumberanon: pin 1 to left knee
02:11 AM anonnumberanon: pin 2 to right knee
02:11 AM anonnumberanon: get the idea?
02:11 AM anonnumberanon: those pins being on the same port
02:12 AM anonnumberanon: would help robot balancing tremendously
02:21 AM anonnumberanon: over and out
03:32 AM rue_mohr: huh, they were using 1 bit adcs before cd players, for telephony, they called it CVSD
07:54 AM Tom_L: oh and btw, why does the Smith family get all the credit for metalworking?
09:38 AM SolG is now known as Solgriffin
09:39 AM Solgriffin is now known as SolGriffin
10:03 AM Tom_itx is now known as Tom_L
12:53 PM mrdata_ is now known as mrdata
02:25 PM anonnumberanon: Nice one Tom
02:40 PM Tom_L: what'd i do now?
02:41 PM Tom_L: i'm thinking about welding the motor mount in place on the Y axis. it could be a big mistake but i'm considering it
02:47 PM anonnumberanon: It sounded like a joke
02:47 PM Tom_L: what did?
02:49 PM anonnumberanon: Because blacksmith
02:49 PM Tom_L: ahh
02:49 PM Tom_L: yeah
02:49 PM anonnumberanon: Your question abouth Smith
02:49 PM Tom_L: lost the scroll back here so i wasn't sure
02:51 PM Tom_L: The term blacksmith derives from iron, formerly called “black metal
02:52 PM Tom_L: still doesn't explain why the Smith family gets all the credit...
02:53 PM Tom_L: The origin of "smith" is debated, it may come from the old English word "smythe" meaning "to strike" or it may have originated from the Proto-German "smithaz" meaning "skilled worker."
02:53 PM Tom_L: ok we'll go with that.
02:54 PM Tom_L: i still think the Smith family was a violent bunch
03:27 PM rue_mohr: so does that mean tin bashers are next to take on a name?
03:57 PM Tom_L: rue_mohr, how much current can that sherline spindle motor safely draw?
03:57 PM Tom_L: i've got it fused but i'm not sure what fuse is right for it
03:57 PM Tom_L: loading it pretty good i popped a 3A fuse
03:58 PM Tom_L: now i gotta remember where i put the fuses so i wouldn't forget where i put the fused
03:58 PM Tom_L: s
05:52 PM Tom_L: ok, made a shim for the Y axis ballnut mount to the plate
05:53 PM Tom_L: rue_mohr, sherline didn't care much for the 3/8" cutter but i got it
05:53 PM Tom_L: (full width cut)
06:05 PM AchiestDragon: happy 2018 gmt uk
06:20 PM anonnumberanon: Just finished doing the lighting foor my moms opera show
06:20 PM anonnumberanon: The breaker for the strong lights jumped twice i was livid
06:20 PM anonnumberanon: They used a 10a first time around.
06:21 PM anonnumberanon: Upgraded to 20a after i yelled(at electricians)
06:21 PM anonnumberanon: And its still jumping from time to time.
08:01 PM rue_shop3: back
08:01 PM rue_shop3: just a sec
08:08 PM rue_shop3: Tom_L, its funny I'd not noticed before, there is no fuse
08:08 PM rue_shop3: there is _NO_ fuse
08:18 PM mrdata: heh
08:47 PM rue_shop3: the owner isn't here... hmm
08:51 PM Tom_shop: no fuse?
08:51 PM Tom_shop: ok, starting on the X axis ballscrew mounting...
09:02 PM rue_shop3: NO fuse
09:02 PM rue_shop3: It thought there was one on the control board
09:02 PM rue_shop3: nope
09:02 PM rue_shop3: no fuse
09:10 PM Tom_shop: what size would you suggest for that motor?
09:11 PM mrdata: the designer got tired of putting fuses in, because the critical component always blows (thus protecting the fuse)?
09:11 PM mrdata: so no fuse
09:51 PM rue_shop3: hard to say, the only rating on the driver is "240V"
09:52 PM rue_shop3: the motor...
09:52 PM rue_shop3: is 90V?
09:54 PM rue_shop3: http://sherline.com/product/33050-dc-motor-speed-control-units/
09:54 PM rue_shop3: 1/2Hp
09:54 PM rue_shop3: 3u73w
09:54 PM rue_shop3: klasudfyhioasudhfg
09:54 PM rue_shop3: 373w
09:55 PM rue_shop3: ohm -p 373 -v 90
09:55 PM rue_shop3: Wattage is: 373.000000
09:55 PM rue_shop3: Current is: 4.144444
09:55 PM rue_shop3: Voltage is: 90.000000
09:55 PM rue_shop3: Resistance is : 21.715818
09:55 PM rue_shop3: so about 4A
09:55 PM rue_shop3: so I'd go with 6-8A
09:57 PM rue_shop: I have 4 more hours to enjoy this year
09:57 PM rue_shop: where...
09:57 PM rue_shop: where is shop2?
09:57 PM Tom_shop: so i'm fairly close on the fuse
09:58 PM Tom_shop: you should see the finish i'm getting with this 3/8" cutter
09:59 PM Tom_shop: when it's done i'll take a pic
10:00 PM Tom_shop: making the shim for the X axis ballnut
10:01 PM Tom_shop: it's just taking a bit
10:17 PM Tom_L: http://tom-itx.no-ip.biz:81/~webpage/cnc/Mill_Steel/Assembly/Shims/X_Axis_ballnut_shim1.jpg
10:17 PM Tom_L: http://tom-itx.no-ip.biz:81/~webpage/cnc/Mill_Steel/Assembly/Shims/X_Axis_ballnut_shim2.jpg
10:17 PM Tom_L: goin back to finish the holes now and cut it out
10:19 PM Tom_L: the flycutter wouldn't reach that far down or i would have used it
10:36 PM rue_shop: Tom_L, bots are comming
10:36 PM rue_shop: Tom_L, dress up
10:37 PM -!- #robotics mode set to +o by ChanServ
10:51 PM * Tom_shop grabs a bag of popcorn and sits back to watch