Shop OBEX P1 Docs P2 Docs Learn Events
BS2 - SX digital caliper position feed back — Parallax Forums

BS2 - SX digital caliper position feed back

willy1067willy1067 Posts: 107
edited 2007-04-26 02:47 in General Discussion
I would first like to thanks, all of the good people of this forum for all the help you have given me the pass few month
specially to a newbie like myself, with answer and questions posted by me.

Now, as I said before, I am not a programmer, and just getting into electronics, so please have patience with me.

I need this for my current project. and because I been using BS2 and need more I/O was suggested to add the SX to my design, I think it's a great idea; but i don't have any of the SX products YET.·· and would like to see if this is possible.

I need a simple program. (4) pins

(1) one to control the forward movement·of a gear thru·a solenoid.
(2) the second to control the reverse motion of the gear thru another solenoid.
the (3) third to receive a serial data output from a digital caliper.
and the (4) fourth to receive a serial data input from the Basic Stamp 2.

the program needs to do the following;

(1) receive a data value from a Basic Stamp 2, telling the SX where to go.
(2) for the SX to move either forward or reverse to achieve the received value data from the BS2.
(3) check the caliper data to see if the Basic Stamp value was achieved.

again, I am not a programmer.· I was just suggested to use the SX and don't have a clue where to start.
any help is greatly appreciated.

This project will go into my current project, so the more help I get, the faster I can complete it, and post it in the completed projects for future use by all of you guys.·· http://forums.parallax.com/showthread.php?p=641010

I posted a quick·picture of what I am trying to achieve.
·

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Fernando Gomez

revinc.us
gomez-rivera.com

Never compare yourself with anyone else, there will always be someone bigger·or·smaller·than you.

Post Edited (willy1067) : 4/19/2007 5:35:02 PM GMT
1151 x 849 - 88K

Comments

  • Sparks-R-FunSparks-R-Fun Posts: 388
    edited 2007-04-19 18:31
    willy1067,

    Certainly an SX chip can likely to be programmed to perform the tasks you describe. Yet I must question whether you really need to learn an entirely new (to you) micro-controller simply because you need more I/O pins. If you can program your existing BS2 to perform steps 2 and 3 but just need more I/O pins there are other options. I2C I/O expansion chips and even shift registers with latches might allow you to control more I/O lines without adding (and possibly needing to learn) another micro-controller. It seems like you might do well to consider those options first.

    With that being said, if you really want to learn to program the SX, "Welcome to our forum!!!"


    - Sparks
  • willy1067willy1067 Posts: 107
    edited 2007-04-19 19:52
    Not trying to learn SX, just want to add it to my design.

    by adding 20 SX to my design, it lets the basic stamp free to do what is intended to do. (manage the system, not run it.)

    I would prefer for someone to just tell me how to do what I want this project to do, without me having to learn another language.

    The project posted here is simple, for someone that has the experience with the chip.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Fernando Gomez

    revinc.us
    gomez-rivera.com

    Never compare yourself with anyone else, there will always be someone bigger·or·smaller·than you.
  • pjvpjv Posts: 1,903
    edited 2007-04-21 18:21
    Hi Willy;

    Just a question.....

    Most digital clipers (at least the inexpensive ones) don't have an analog or digital output; I'm curious how you intend to access the position from one. Their internal workings are quite complicated, and I think you will have a hard time "hacking" the position from the LCD signals. I've done that in another somewhat more complicated project, and it was all that an SX48 at 50 MHz could do to keep up to the LCD segment bit stream. Quite complicated, and really not for a beginner.

    I'm not trying to discourage you; just curious.

    Cheers,

    Peter (pjv)
  • willy1067willy1067 Posts: 107
    edited 2007-04-23 04:51
    PJV;
    Found 6" calipers for under $8.00 in Harbor Freight Tools, and it has the access port. also found online how to read the information coming from it. it's just a matter of software now.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Fernando Gomez

    revinc.us
    gomez-rivera.com

    Never compare yourself with anyone else, there will always be someone bigger·or·smaller·than you.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2007-04-23 05:11
    Fernando,

    The $8.00 price point and the presence of an access port have major implications for position feedback apps. Can you share with us what you found out? (Model number, digital/analog protocol, etc.)

    Thanks!
    Phil
  • Mike CookMike Cook Posts: 829
    edited 2007-04-23 12:29
    The link below has some information of the data output of the Harbor Freight Digital Calipers:

    http://www.shumatech.com/support/chinese_scales.htm



    <EDIT>

    Found another link:

    http://www.pcmx.net/gauge/

    </EDIT>




    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Mike

    Post Edited (Mike Cook) : 4/23/2007 2:34:20 PM GMT
  • pjvpjv Posts: 1,903
    edited 2007-04-23 15:34
    Hi All;

    Well, do I now look like a fool!

    I clicked on Mike's link above (http://www.pcmx.net/gauge/), and saw a picture identical to a caliper I recently got, and on inspection it has a little removable cover with an access port behind it!

    So was I wrong!!!!.... some recent inexpensive calipers DO have an access port!

    I am eager to get into this as it will add anice "dimension" to the "community milling machine" project I'm still working on!

    Cheers,

    Peter (pjv)
  • BeanBean Posts: 8,129
    edited 2007-04-23 17:02
    Dang 1/20480 of an inch isn't too bad !!!

    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "Educate your children to self-control, to the habit of holding passion and prejudice and evil tendencies subject to an upright and reasoning will, and you have done much to abolish misery from their future and crimes from society"

    Benjamin Franklin
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    www.hittconsulting.com
    ·
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2007-04-23 17:26
    It would be interesting to see if there are any missing codes. But I'm not sure how one could extend it slowly enough and evenly enough to find out.

    -Phil
  • Mike CookMike Cook Posts: 829
    edited 2007-04-23 17:37

    For a quick and dirty test you could use a 200 step per revolution stepper motor connected to 1/4-20 all-thread. Then make a anti-backlash nut connected to the Digital caliper, (black head) and make sure the rest is mounted where it can't move. 200 step connected to 1/4-20 all-thread will get you .00025" per step, not counting any slop in the mechanism.

    One of those back burner projects.........I've got the PIC so when/if I get some time I would like to reproduce the project and then port it to a SX, SX/B if possible.

    One problem, I need to figure out how to have a five day weekend instead of the 2 day weekend I have now! tongue.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Mike
  • pjvpjv Posts: 1,903
    edited 2007-04-23 18:23
    Hi All;

    Phil that could easily be done (once the interface is built) by mounting it on my CNC mill, and have the mill head push the caliper ahead half a thou under CNC program control, then read and record/compare/check·the output of the caliper, and loop back until all 6, 8 or 12 inches are covered.

    A little bit of work, but not too bad. After I get the interface figured/built, I'll have a stab at this.

    Very interesting......

    Cheers,

    Peter (pjv)
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2007-04-23 18:33
    Peter,

    'Sounds nice, but there are (supposed to be) ten codes in that "half a thou"!

    -Phil
  • pjvpjv Posts: 1,903
    edited 2007-04-23 19:10
    Hi Phil;

    Didn't notice that.

    Well, then we'll just move it one tenth of a thou per step. That's the limit of my machine.

    Cheers,

    Peter (pjv)
  • sawsaw Posts: 2
    edited 2007-04-25 01:37
    Hi,
    Anyone interested in this might want to have a look at http://www.yadro.de/digital-scale/protocol.html·in addition to the shumatech site·mentioned earlier.·It might lead to some ideas.
    ·I started to look into this a few weeks ago and bought one of the HBF calipers.· I have soldered the wires and can see the data and clock with a scope but I am not sure how to proceed with getting the data to the BS2 because of the clock.· Can the data be shifted in with SHIFTIN?· Can the CLK pin in the command be configured as an input?
    A friend of mine gave me a BS2 a while back so I am just now really learning how to use it and any ideas would be a big help.
    Thank
    Scott
  • willy1067willy1067 Posts: 107
    edited 2007-04-25 03:51
    Saw (scott)

    I will be working on that part of my project soon, I will be needing it; but still need to complete another phase.

    My project has been call imposible by many, but step by step is coming along.

    http://forums.parallax.com/showthread.php?p=637017

    But I would appreciate it if you get started and let me know your findings.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Fernando Gomez

    revinc.us
    gomez-rivera.com

    Never compare yourself with anyone else, there will always be someone bigger·or·smaller·than you.

    Post Edited (willy1067) : 4/25/2007 3:56:50 AM GMT
  • DosManDanDosManDan Posts: 179
    edited 2007-04-25 19:24
    Your project shouldn't be impossible. I interfaced an electronic caliper for medical research back in 1995 using a PC and a serial port. The company was out of Chicago and was named Gile's Scientific. It measured zone size readings for organism growth in petrie dishes.... about as exciting as it sounds.

    I was going to offer help when I first read your post, but I've been swamped with work lately. I haven't looked at the caliper made by Harbor Freight, but now I'm curious and might go buy one and play with it. One recommendation I have would be to use an oscilliscope to watch your signal if you are having trouble decoding the output.

    Update:
    Hey, I just ran a Google search....here it is:

    http://www.biomic.com/Industrial/IndFrameset.html

    Goto the AutoAssay Multi Plate, then look near the bottom for the Electronic Caliper version link.

    Best of luck in your efforts, I'll be watching the thread to see how you are doing,
    Dan

    Post Edited (DosManDan) : 4/25/2007 7:29:53 PM GMT
  • willy1067willy1067 Posts: 107
    edited 2007-04-25 21:45
    Dan,

    Thanks for the vote of conference about not been imposible. I wasn't talking about the caliper project, but what I am using the caliper project for.
    I added a link in the beggining of the thread and in the last one I posted.

    I already have the software and a way to connect the caliper to the pc, what I need is to either connected to a BS2 or a SX.

    I am working on a Anatomical Human Robot arm, and it has been challenging; but little by little is coming along.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Fernando Gomez

    revinc.us
    gomez-rivera.com

    Never compare yourself with anyone else, there will always be someone bigger·or·smaller·than you.

    Post Edited (willy1067) : 4/25/2007 9:50:39 PM GMT
  • sawsaw Posts: 2
    edited 2007-04-26 01:51
    Hi Fernando,

    What·software and way of connecting to a PC are you using? I would like to try that as well as figuring out how to do it with a BS2.

    Thank's,

    Scott
  • willy1067willy1067 Posts: 107
    edited 2007-04-26 02:47
    Look at Mike Cook (13 threads up ^^^^^) He listed the info and sites, I am using those.

    also check this two other

    http://www.steamboating.de/caliper/cal-main.html

    and this guy did it, but he did not post a diagram

    http://rchobby.gmxhome.de/elektro/pic/caliper/calip_eng.htm

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Fernando Gomez

    revinc.us
    gomez-rivera.com

    Never compare yourself with anyone else, there will always be someone bigger·or·smaller·than you.

    Post Edited (willy1067) : 4/26/2007 2:56:01 AM GMT
Sign In or Register to comment.