#garfield Logs
Nov 13 2020
#garfield Calendar
06:18 PM rue_mohr: so, I need to work out how to tag a 'sub machine' inside a state machine
06:24 PM rue_mohr: I SHOULD do it with another rom, but thats not always warranted
06:24 PM rue_mohr: polprog, so what ya say, go controllerless? FSM for the future?
06:24 PM polprog: yes
06:25 PM rue_mohr: .. I might have to rename the program
06:25 PM rue_mohr: :)
06:26 PM rue_mohr: I have another program for state machines
06:26 PM rue_mohr: its called combo
06:27 PM rue_mohr: the rules dont work in it yet
06:27 PM rue_mohr: it can grounp input and output bits
06:27 PM rue_mohr: it generates all the combinations for you
06:27 PM rue_mohr: and can express the result as C code
06:27 PM polprog: oh, nce
06:27 PM polprog: nice*
06:27 PM polprog: i should try to hack sth myself
06:28 PM rue_mohr: for that lcd thing
06:28 PM rue_mohr: I needed like a subroutine
06:28 PM rue_mohr: I didn't use table2ihex
06:28 PM rue_mohr: I just did it in C
06:28 PM rue_mohr: but its got me thinking
06:29 PM rue_mohr: combo and table2ihex are supposed to merge
06:30 PM rue_mohr: polprog, can you run an old dos exe?
06:31 PM rue_mohr: it probably runs ok in wine?
06:31 PM rue_mohr: http://ruemohr.org/~ircjunk/software/romctrl2.exe
06:31 PM rue_mohr: it was written in qbasic
06:31 PM rue_mohr: its version 2
06:32 PM rue_mohr: building a state machine for a rom, is as easy as that coding
06:32 PM rue_mohr: thats what set me down these two paths
06:32 PM polprog: hmm, i have real dos at hand
06:32 PM polprog: not now though
06:33 PM polprog: ill finish this supper and go to sleep
06:33 PM rue_mohr: ok take a quick look when you have a chance
06:33 PM polprog: sure
06:33 PM polprog: ill try tomorrow
06:33 PM rue_mohr: you will kinda see what I'm trying to target
06:33 PM polprog: :)
06:33 PM rue_mohr: its like programming a ROM in BASIC to run a program
06:34 PM rue_mohr: I'm going to try to write a state machine sub-routine tonight
06:34 PM rue_mohr: I dont know if this can be done
06:38 PM polprog: should be doable
06:38 PM polprog: not sure about basic
06:40 PM rue_mohr: that program is it
06:40 PM rue_mohr: its just awkward in its simplicity
06:41 PM rue_mohr: Tom_L, I'm going into year2 of a machine waiting for me to assemble it
06:41 PM Tom_L: man, i didn't realize how hard it would be to find a green silicon carbide bench grinder wheel locally
06:41 PM rue_mohr: I have a massive box of parts
06:41 PM rue_mohr: did you succeed?
06:41 PM Tom_L: what machine?
06:41 PM rue_mohr: anyone know what you were talking about?
06:41 PM rue_mohr: one to replace the sherline
06:41 PM Tom_L: the industrial supply ordered one
06:41 PM rue_mohr: funny enough
06:42 PM Tom_L: i finished mine
06:42 PM rue_mohr: yea I asked around for a green wheel and all they could cough up were green wheels
06:42 PM rue_mohr: not for carbide
06:42 PM rue_mohr: yea, you've lapped me like 3 times now
06:42 PM Tom_L: it may be green and may be right but unless it says it, i don't want it
06:43 PM Tom_L: at least i'll be able to sharpen my lathe tools now
06:43 PM Tom_L: the boring bars etc
06:43 PM polprog: i need to get these 271024
06:44 PM rue_mohr: hahah
06:44 PM Tom_L: rue_mohr, you've done more just spread it out over multiple things
06:44 PM rue_mohr: I want to make a pcb with a buffer on the back
06:45 PM Tom_L: gals are small ehh?
06:45 PM rue_mohr: yes, but more a problem right now, I cant take my state machine stuff and get it into a programming file for them
06:46 PM rue_mohr: so for now, simple machine and logic
06:46 PM Tom_L: they are simple minded
06:50 PM rue_mohr: I'm trying to catch up to myself
06:51 PM Tom_L: my problem is, the mill was the project. now i need a project
06:52 PM rue_mohr: yea but not 200 sprayer triggers
06:52 PM rue_mohr: you need something a bit of a challenge and kinda fun
06:52 PM Tom_L: was that what i sent? i don't even remember now
06:53 PM rue_mohr: there were some, I think he used them up
06:53 PM rue_mohr: were going on cast ones now :)
06:53 PM Tom_L: how's the mold holding up?
06:53 PM rue_mohr: I'v only done like 2? runs
06:53 PM rue_mohr: so their fine
06:54 PM rue_mohr: their black, but no degredation
06:54 PM Tom_L: use pam to spray them?
06:54 PM rue_mohr: initially, but it doesn't seem to make a diff at those temps
06:55 PM polprog: goodnight
06:55 PM rue_mohr: gn
06:57 PM Tom_L: you should probably coat them with something so they don't rust
06:58 PM rue_mohr: a workshop
06:59 PM rue_mohr: in my program, its a lot of trouble to set up the bit fields for in and out
07:00 PM rue_mohr: .... maybe I could make the other program do that
07:00 PM rue_mohr: it could assign all the constants and build the masks
07:01 PM Tom_L: for your fsm?
07:01 PM rue_mohr: yea
07:01 PM rue_mohr: I'd like to make this easy
07:02 PM rue_mohr: there is a guy who set up an SDRAM to run as a state machine
07:02 PM rue_mohr: I'm loosing my edge
07:02 PM rue_mohr: but he didn't really go anywhere with it
07:02 PM * Tom_L gives rue_mohr a green stone
07:02 PM rue_mohr: heh
07:03 PM rue_mohr: I was setting up a VFD on a customers lathe, while chatting he said he had an extra and passed it along
07:03 PM rue_mohr: :D
07:03 PM rue_mohr: so I have it carefully squirreled away
07:10 PM Tom_L: nice
07:10 PM Tom_L: AC or dc?
07:10 PM rue_mohr: there is a patten forming tho
07:11 PM rue_mohr: it was 3 phase AC
07:11 PM rue_mohr: he kept tripping his breaker with the hard starts
07:11 PM Tom_L: I'm not so sure there is much difference
07:11 PM rue_mohr: he had other reasons he wanted a vfd
07:11 PM rue_mohr: the quick stop he loved
07:11 PM Tom_L: external brake
07:11 PM Tom_L: i really haven't noticed much difference in stopping
07:12 PM rue_mohr: yea but not lathe
07:12 PM Tom_L: right
07:12 PM rue_mohr: I'd love a quick stop on my drillpress
07:12 PM Tom_L: alot more mass to stop
07:12 PM rue_mohr: I made a DC inj but it died
07:12 PM Tom_L: i noticed the local industrial supply had some sitting out on the bench display
07:13 PM Tom_L: he said they'd just put them out
07:13 PM Tom_L: but
07:13 PM Tom_L: they didn't do 'instant stop' either
07:13 PM Tom_L: from fwd to rev
07:13 PM Tom_L: i kinda doubt any of them do
07:14 PM Tom_L: i watched the signals on my rigid tapping routine and it doesn't trip the brake before reversing
07:14 PM Tom_L: i kinda doubted it did
07:14 PM Tom_L: what's the input voltage on your vfd?
07:15 PM rue_mohr: mine? no
07:16 PM Tom_L: the one he gave you
07:16 PM rue_mohr: the customer one was 240 single phase
07:16 PM rue_mohr: no he gave me a green wheel
07:16 PM rue_mohr: heh
07:16 PM Tom_L: OHHH
07:16 PM rue_mohr: I insalled the vfd for him
07:16 PM rue_mohr: (work)
07:16 PM rue_mohr: prolly the only sparky that can work that out
07:16 PM Tom_L: what brought up the green wheel?
07:16 PM rue_mohr: sat there scratching my head programming it for like a half hour
07:17 PM rue_mohr: just idle chitchat
07:17 PM rue_mohr: he was watching me work
07:17 PM Tom_L: did you have the instructions?
07:17 PM rue_mohr: hahahaaha
07:17 PM Tom_L: for programming it
07:17 PM rue_mohr: I think I found a pdf on the phone
07:17 PM Tom_L: you just about need those
07:17 PM rue_mohr: definitly need them, the displays are quite cryptic
07:18 PM Tom_L: mine you first have to put it into programming mode by assigning it an address
07:19 PM Tom_L: i'm not planning to mess with it much
07:20 PM rue_mohr: good after its workin
07:22 PM Tom_L: i might fiddle with the PID a little more
07:23 PM rue_mohr: this fsm is easy and hard at the same time
07:23 PM rue_mohr: its a bit of a mentral trip
07:23 PM rue_mohr: cause things are not A->B->C->D
07:24 PM rue_mohr: everything happens simotaniously
07:24 PM rue_mohr: a counter might have been an easier project
07:25 PM Tom_L: that would be so unlike you
07:25 PM rue_mohr: I have 4 things happeneing at once for excersize
07:25 PM rue_mohr: hah
07:29 PM Tom_L: mmm can't find my test tapping file
07:29 PM rue_mohr: ouch, there is ANOTHER level too
07:29 PM Tom_L: sounds like a video game
07:31 PM rue_mohr: so, at the highest level I have a machine that waits for a key, or sends a value in serial
07:31 PM rue_mohr: at the next level I have sending bit 0 / 1/ 2/ 3
07:31 PM rue_mohr: at the next level I have clocking a bit being sent _-_
07:32 PM Tom_L: mmm called it 'relay mount'
07:32 PM Tom_L: wtf
07:33 PM Tom_L: i forgot how to calculate the parameters for taps now
07:34 PM rue_mohr: :)
07:36 PM Tom_L: huh
07:36 PM Tom_L: the post works though
07:37 PM Tom_L: i must have set up taps in the post
07:37 PM Tom_L: what's the 'inch per rev' on a 10/32 thread?
07:37 PM Tom_L: yeah that's it
07:38 PM Tom_L: .03125
07:39 PM Tom_L: ok i have to set that up in the tool file, not the cad
07:40 PM Tom_L: oh hell, that's easy there. just enter the threads "32" and it calculates it
07:42 PM rue_mohr: how much of the spiral do you have to code
07:42 PM Tom_L: just the depth
07:42 PM Tom_L: on threadmills i calculate that in my macro
07:43 PM Tom_L: taps you enter the depth
07:44 PM Tom_L: i'm not so excited about doing blind holes with a tap though
07:45 PM rue_mohr: yea
07:45 PM Tom_L: the thing about thread mills, the threads don't taper off at the end like a tap
07:45 PM rue_mohr: good first?
07:45 PM Tom_L: you get all good threads
07:45 PM rue_mohr: er wood first?
07:45 PM Tom_L: that or air
07:46 PM rue_mohr: oh I have to see a peice of carefully threaded foam!
07:46 PM Tom_L: pretty sure i've run this file before though
07:46 PM rue_mohr: I wonder if it tears out too easy
07:46 PM Tom_L: it should thread just fine
07:46 PM Tom_L: you can reenter the hole multiple times with the tap too, it's indexed
07:50 PM Tom_L: http://tom-itx.no-ip.biz:81/~webpage/rue/relaymount.txt
07:50 PM Tom_L: the unedited output file
07:50 PM Tom_L: should just run
07:51 PM Tom_L: maybe i didn't have all the tools on in that one.. one sec
07:53 PM Tom_L: ignore the drill tool comments
07:54 PM Tom_L: i use the same one for several sizes
07:58 PM rue_mohr: hah, isn't it great to wake up infront of a project you didn't know you dozed off infront of?
07:58 PM Tom_L: heh i couldn't count the times
07:59 PM Tom_L: actually, it's more the inbetween time that gets me
08:00 PM Tom_L: just don't doze off on a hot iron
08:01 PM rue_mohr: i need to be able to handle the bitfield splicing better
08:02 PM rue_mohr: which is exactly what the other program does
08:05 PM rue_mohr: COMMENTS would also be awesome
08:05 PM rue_mohr: ok, first state,
08:05 PM rue_mohr: if we are waiting for a key, and we dont have one,
08:05 PM rue_mohr: keep waiting
08:12 PM rue_mohr: :S this is a scale of complexity so far above everything else
08:12 PM rue_mohr: I'm getting vertigo
08:15 PM Tom_L: need food?
08:15 PM rue_mohr: no, this is crazy
08:15 PM rue_mohr: I... might actually be able to make a state machine that crashes if I'm not carefull
08:15 PM rue_mohr: addrule ((KR==1)&(TXFBI==waitkey)) (TXFB0=dobit0)(SBFBO=dsetup) -100
08:16 PM rue_mohr: its like walking into a server room that had network cables strug thru the air everywhere
08:17 PM Tom_L: with 1 unhooked?
08:17 PM rue_mohr: I should have been doing this stuff back in '97
08:17 PM rue_mohr: no, just a cacoon of network wires
08:20 PM rue_mohr: I'm going to write some rules, and its going to simotaniously figure out everything that could ever happen
08:53 PM rue_mohr: if this works, it might actaully take some time for my compiler
09:02 PM rue_mohr: dear god.... I think thats it...
09:02 PM rue_mohr: monster...
09:12 PM rue_mohr: about 2 seconds
09:12 PM rue_mohr: but there is a problem
09:12 PM rue_mohr: its not taking some of the rules
09:22 PM rue_mohr: oh my
09:23 PM rue_mohr: think I used strsep wrong
09:25 PM rue_mohr: oh bug
09:25 PM rue_mohr: two spaces dont go over well
09:26 PM Tom_L: always just one thing
09:27 PM rue_mohr: the string seperator does not handle multiple delimeners right
09:27 PM rue_mohr: so, if you put two spaces, it borks up
09:27 PM Tom_L: change the delimiter
09:27 PM rue_mohr: no its not that
09:27 PM Tom_L: i had that on a java app on the phone
09:27 PM rue_mohr: there are mutiple delimns, and so it presums a param was empty
09:28 PM rue_mohr: aka
09:28 PM Tom_L: was missing dozens of records due to it
09:28 PM rue_mohr: 1 2 3
09:28 PM rue_mohr: its told the delim is a space
09:28 PM rue_mohr: so it choughs out 1,2,3
09:28 PM rue_mohr: but if I give it
09:28 PM rue_mohr: 1 2 3
09:28 PM rue_mohr: it chokes, and says the answer is 1,2,
09:28 PM Tom_L: which is correct
09:29 PM Tom_L: in it's mind
09:29 PM rue_mohr: 1,2,3
09:29 PM rue_mohr: ugh
09:29 PM rue_mohr: this is what I get for using someone elses library
09:30 PM rue_mohr: ok, that will be annoying to fix
09:32 PM rue_mohr: ... thats not right....
09:34 PM rue_mohr: aha
09:37 PM rue_mohr: yea that cant be it
10:09 PM rue_mohr: omg I
10:10 PM rue_mohr: ok, this is insane
10:10 PM rue_mohr: I think I got it
10:11 PM rue_mohr: a hardware uart in 1024 bytes of memory wrapped into a FSM
10:13 PM rue_mohr: I folded it down into a 2 layer state machine
10:14 PM rue_mohr: one layer sends a bit, the other sequences the bits and manages the write pulse
10:15 PM rue_mohr: I uh...
10:15 PM rue_mohr: need some food
10:15 PM * Tom_L mentioned that a while back
10:15 PM rue_mohr: so, with a piffle amount of memory, I can replace most microcontroller things
10:16 PM rue_mohr: *and a latch
10:17 PM rue_mohr: its 8kbits
10:17 PM rue_mohr: ->bits<-
11:54 PM aandrew is now known as Guest31998