584,817 active members*
4,550 visitors online*
Register for free
Login Register
HEIDENHAIN Forum
Open Source Controller Boards > Rotary table indexer - Page 2
Page 2 of 41 123412
Results 21 to 40 of 815
  1. #21
    Join Date
    Sep 2007
    Posts
    11
    Hello,

    Pictures about my hardware, which is not working is not a good idea.
    I am very interested with this thread, because my rotary head hardware is quite completed now, and I was writing the software in 8051 assembler when I have discovered this thread.
    All functionalities I wished, are in the software already writed by kwackers.
    But I don't know the 18F452 and configuration bits have not been discussed in this thread.

    So, I'm waiting some help.

    Best regards.

  2. #22
    Join Date
    Dec 2003
    Posts
    24216
    An added feature I could see usefull is the ability to interface with a CNC mill etc, If the host machine can output say a BCD or Octal code for e.g. and a strobe bit, the rotary table controller could have up to say 8 pre-stored positions, the mill places the Octal code on the three lines and issues a strobe, the table moves to position and send a done bit signal back to the CNC when in position.
    I have done this in the past with a Galil Motion card and Maple systems display, but this would require less cost & putting together.
    Al.
    CNC, Mechatronics Integration and Custom Machine Design

    “Logic will get you from A to B. Imagination will take you everywhere.”
    Albert E.

  3. #23
    Join Date
    May 2006
    Posts
    184
    Quote Originally Posted by Rebus View Post
    hello,
    I have completed the component installation on the PCB, but I have some difficulties to start.
    Using a brand new 18F452, I have used the HEX file with IcProg 1.06A, but about Config bits ?
    What values must be entered ?
    Thanks for your help.
    Hi Rebus, the config bits are part of the HEX file - at least they appear to be if loaded into MpLab.

    However, everything is disabled, brownout, watchdog etc.
    The oscillator is set to HS-PLL.

    I've attached a screen grab of the config window from MpLab in case this is any help.
    Attached Thumbnails Attached Thumbnails config.jpg  

  4. #24
    Join Date
    May 2006
    Posts
    184
    Attached is a zip file containing a powerpoint of the construction (.pps).
    I've never used PP before so apologies for it's crudeness but it should give some idea of what's involved.
    It assumes use of a PCB so if you're using stripboard or other prototyping board I'm afraid you're on your own... ;-)
    Attached Files Attached Files

  5. #25
    Join Date
    May 2006
    Posts
    184
    Hi Al,
    The input and ack you mention already exist and work - although the input is only single bit and so you can only advance the table by one division or by the same number of degrees each step.

    I did some time ago start writing a programmable section which would probably do what you require but never finished it - I may look at reviving it.
    Sadly it's not likely to allow more than a single input, but as long as your step follows a pattern you could program 8 (or more) absolute positions and it would step to each one in turn before looping back to the start and repeating.

    Steve.


    Quote Originally Posted by Al_The_Man View Post
    An added feature I could see usefull is the ability to interface with a CNC mill etc, If the host machine can output say a BCD or Octal code for e.g. and a strobe bit, the rotary table controller could have up to say 8 pre-stored positions, the mill places the Octal code on the three lines and issues a strobe, the table moves to position and send a done bit signal back to the CNC when in position.
    I have done this in the past with a Galil Motion card and Maple systems display, but this would require less cost & putting together.
    Al.

  6. #26
    Join Date
    Apr 2003
    Posts
    1873
    Steve,
    The construction.pps is a winner!

    Thanks
    Ken

  7. #27
    Join Date
    Sep 2007
    Posts
    11
    Hello Kwackers (and others..)

    Thank you very much for your's configuration bits.
    I don't like really using breadboard, and designed/etched quickly a PCB (Eagle).
    With a good configuration bits, a valid display appears, but the reset part is totally erratic, and only key number 3 is accepted..... I have to investigate on the keyboard matrix....

    I don't know if there is some starting oscillator delay to program as like AVR chips... actually I need around 20 power-on, power-off to have a valid display.

    Using Icprog is not the best way, but I have removed Mplab long time ago, because I appreciated very much the Dallas DS89c4xx.
    I'm not a professionnal, asm programming is only a hobby, so my device choice is more about pleasure than efficiency....

    Best Regards to all, and thanks to share your experience.
    Attached Thumbnails Attached Thumbnails RTU_1e.jpg  

  8. #28
    Join Date
    May 2006
    Posts
    184
    Hi Rebus, glad it's working (after a fashion).
    I've never had any trouble with reset - even with a rats-nest construction the device should reset properly on power up.
    Some things to check:- One of the 0.1uF capacitors should be close to the PIC to provide supply decoupling. Also check that pin1 (mclr) is tied to VDD. Check the circuitry around the crystal for stray capacitance etc, anything that may prevent the oscillator from starting consistently.
    One thing you could try is connecting VDD to mclr via a 10k resistor then resetting by briefly pulling it to VSS - this should tell you whether it's resetting properly or whether there's an issue around the crystal (and 33pf caps).

    There is a power on reset delay - this is the power up timer in the configuration bits, you could try enabling this although it shouldn't be necessary.

    With regards the keypad - the circuitry around this is very simple. However I can't see the 4 x 10k pull up resistors on your circuit board, these are very important for correct operation. Finally check that pin 2 is at logic 0 - if not this can cause some strange effects (the circuitry around Q1 is responsible for this).

    If you need any more help let me know.

    Steve.



    Quote Originally Posted by Rebus View Post
    Hello Kwackers (and others..)

    Thank you very much for your's configuration bits.
    I don't like really using breadboard, and designed/etched quickly a PCB (Eagle).
    With a good configuration bits, a valid display appears, but the reset part is totally erratic, and only key number 3 is accepted..... I have to investigate on the keyboard matrix....

    I don't know if there is some starting oscillator delay to program as like AVR chips... actually I need around 20 power-on, power-off to have a valid display.

    Using Icprog is not the best way, but I have removed Mplab long time ago, because I appreciated very much the Dallas DS89c4xx.
    I'm not a professionnal, asm programming is only a hobby, so my device choice is more about pleasure than efficiency....

    Best Regards to all, and thanks to share your experience.

  9. #29
    Join Date
    Sep 2007
    Posts
    11
    Hello Kwackers,
    Thanks to have a look on my problem.
    Resistors are present, but SMD, it is one of the reason why I have changed your layout.
    I will try what you say about MCLR.
    Now, after a lot of power-up/power-down when I got the presentation menu, the software go to the second menu which is asking a profile number.
    Only the three left keys of the upper row are working, and provide a number "3".
    I can't go further because all other keys are not reconised.
    Using an oscilloscope I see the scan pulses, routed on the corresponding row when a key is pressed, but not accepted....
    Best regards.

  10. #30
    Join Date
    Sep 2007
    Posts
    11
    Hello Kwackers,

    With a 10k pull-up resistor on MCLR, now the reset is working fine.
    But, I'm still locked in the profil menu.
    Just an idea, the eeprom memory is empty, because I never save anything.
    Does the software is stopped because there is no data previously saved ?
    Best Regards.

  11. #31
    Join Date
    May 2006
    Posts
    184
    Hi Rebus,
    No the program checks to see if the selected profile contains valid data and if not resets all the vars and then saves them back.

    I notice you have a sounder attached - it should beep for each key pressed...

    I've also attached a keypad checker .hex file (zipped). If you program the PIC with this, when you turn it on you should get a grid of 'O's like so:-

    O O O O
    O O O O
    O O O O
    O O O O

    Each one corresponds to the relevant key, pressing that key should result in an 'X' appearing instead of the 'O'. Hope this helps.

    P.S - don't forget to check pin 2 of the PIC it should be at close to 0v.


    As an aside I've had a look at what might cause your reset issue - and the best idea I can come up with is a 'slow' power up. This is covered on page 26 of the data sheet - viewable here:- http://ww1.microchip.com/downloads/e...Doc/39564c.pdf
    It's possible the internal resistance of your supply combined with the 470uF capacitor cause the voltage to rise too slowly for a proper reset.

    Steve



    Quote Originally Posted by Rebus View Post
    Hello Kwackers,

    With a 10k pull-up resistor on MCLR, now the reset is working fine.
    But, I'm still locked in the profil menu.
    Just an idea, the eeprom memory is empty, because I never save anything.
    Does the software is stopped because there is no data previously saved ?
    Best Regards.
    Attached Files Attached Files

  12. #32
    Join Date
    Sep 2007
    Posts
    11
    Hello Kwackers,

    Pin 2 of the CPU seems to have no effect on my problem, I have fitted a 10k to GND to be sure.
    When I press one of the three left upper keys, I got 2 bips, but the result on the LCD is the number "3" for every key pressed.

    Thanks for the small kbd test, I will try it, but only at the end of next week.
    To morrow morning I will go, as every week to your country, I live in France but I work in London King's Cross.
    I will follow this thread from UK.

    Thanks you very much for your help, have a good week I will inform you very soon about my test.

    Best Regards for all Cnc Zone members.

  13. #33
    Join Date
    May 2006
    Posts
    184
    Hi Rebus,
    You should only have one beep... Are the pull up resistors 10k?

    The test program should tell you a lot.

    You can also try manually 'pulling' the keys, using a short piece of wire and shorting pins 22 & 27 should give you a '1'.

    In pin number terms the matrix looks like this.
    Code:
        27  28  29  30
    22 [1] [2] [3] [Speed]
    21 [4] [5] [6] [S]
    20 [7] [8] [9] [C]
    19 [] [G]
    So shorting pins 20 & 29 should give a [9].

    Enjoy your week - I don't feel so bad about my 10 minute bicycle commute now... ;-)

    Quote Originally Posted by Rebus View Post
    Hello Kwackers,

    Pin 2 of the CPU seems to have no effect on my problem, I have fitted a 10k to GND to be sure.
    When I press one of the three left upper keys, I got 2 bips, but the result on the LCD is the number "3" for every key pressed.

    Thanks for the small kbd test, I will try it, but only at the end of next week.
    To morrow morning I will go, as every week to your country, I live in France but I work in London King's Cross.
    I will follow this thread from UK.

    Thanks you very much for your help, have a good week I will inform you very soon about my test.

    Best Regards for all Cnc Zone members.

  14. #34
    Join Date
    Sep 2007
    Posts
    11
    Hello Kwackers,

    This morning I wake up earlier to load your keyboard test in the 18F452, before taking the plane to UK.

    First remark, all keys are working !

    Second remark, no key pressed, 4x4 matrix on Lcd show 16 cross.

    When a key is pressed, three small circles appear in the corresponding column,

    Why three?

    I was supposing only one at the proper junction between row and column, where the key is located.

    Is this what you have planned in your software ?

    Thanks for your answer,

    Best Regards,

  15. #35
    Join Date
    May 2006
    Posts
    184
    Hi Rebus,

    I'm going to have to apologise - when you described the results from the keypad test program the reason was obvious...

    I've checked the PCB layout and it confirms it - the 4 x 10k resistors are connected to ground, not 5V.

    I drew the circuit diagram from the pcb layout, but either misread the area around the resistors or simply assumed they were 'pull up'...

    Hope this is easy to rectify on your own layout - at least you know what the problem is.


    Apologies to everyone - the correct circuit diagram is attached (if you're using the original PCB there's no problem because this is correct).


    Steve. :withstupi


    Quote Originally Posted by Rebus View Post
    Hello Kwackers,

    This morning I wake up earlier to load your keyboard test in the 18F452, before taking the plane to UK.

    First remark, all keys are working !

    Second remark, no key pressed, 4x4 matrix on Lcd show 16 cross.

    When a key is pressed, three small circles appear in the corresponding column,

    Why three?

    I was supposing only one at the proper junction between row and column, where the key is located.

    Is this what you have planned in your software ?

    Thanks for your answer,

    Best Regards,
    Attached Thumbnails Attached Thumbnails Rotary1.1 circuit.jpg  

  16. #36
    Join Date
    Sep 2007
    Posts
    11
    Hello Kwackers,

    It is a good new !
    Don't apologies, it is interesting to debug also the schematic....
    Next friday I will quickly reverse resistors, to GND, and after I hope that I could go throught your software, and energize the stepper motor of my rotary table, before Christmas.
    Anyway, thanks a lot for your help, I will post again next weekend, on this forum about my progress.
    Best regards for all readers.

  17. #37
    Join Date
    May 2006
    Posts
    184
    Hi,
    In response to a number of queries I've had, I've decided to spend a bit of time over the holidays adding 'programmability' to the division software. This is an addition to the existing software, requires no hardware changes and doesn't impinge on the existing functionality.

    Attached to this reply is a zip containing documentation and a .hex file with v1.2 of the software. Please note, I've tested this a fair bit but it is very much a beta and is still in test. I've uploaded it to give anyone who's interested the chance to have a say before I finalise the code...

    There are some code examples at the end of the documentation which together with the command set should give people the chance to see what the program mode offers.

    In summary the command set allows:-
    Absolute / relative movement by an angle.
    Loops.
    Control over speed and direction.
    Ability to wait for an external event, the operator or an amount of time before continuing.
    A program can be up to 64 steps, there are 10 load/save slots and a single step mode for 'debugging'.

    Again - hope it's of use, any suggestions gratefully received.

    Oh - I should have added, this is intended to be used in conjunction with the .zip file attached to the initial post. You may also wish to view the powerpoint file on page 2 of this thread for some indication of construction...

    Steve.
    Attached Files Attached Files

  18. #38
    Join Date
    Mar 2004
    Posts
    54
    thanks for posting this! the controller is something I could really use .The only part of this that I don't get is how to load the firmware onto the IC's there must be some top secret mojo that I missed somewhere... I guess I need the electronics for dummies explanation.... or if you could sell a pre loaded IC ?

  19. #39
    Join Date
    May 2006
    Posts
    184
    Quote Originally Posted by Ben Olson View Post
    thanks for posting this! the controller is something I could really use .The only part of this that I don't get is how to load the firmware onto the IC's there must be some top secret mojo that I missed somewhere... I guess I need the electronics for dummies explanation.... or if you could sell a pre loaded IC ?

    Hi Ben, there are a whole host of ways to get the code into a PIC...

    Assuming there's nobody close to you that can do it - I'd start with a look here:- http://www.ic-prog.com/index1.htm This is a piece of freeware that supports a whole range of hardware, some of the hardware it supports (JDM programmer for example) are available on eBay for under 10 UKP.

    The benefits of having your own programmer are that if the software changes you can upgrade it for free! At the moment V1.1 is the stable version but a final version of 1.2 should be available in another week or so.

    I can send out a programmed chip - but bear in mind the above. At the moment I'd mail 1.1 - but later 1.2 would be available and probably not worth mailing the old chip back for upgrades... And even when 1.2 is available, suppose I find a serious bug and need to issue another update? The cost of the chips could soon rack up to the cost of a cheap programmer... I'd suggest if you want to go this route you place a query about lo cost programmers in the PIC section of these forums - I've bought cheap programmers in the past and been happy with them but don't have any knowledge of the current crop.

    I'm unsure what the chips cost at the moment but a guideline would be between £2.50 and £5 plus P&P to your address. (Prices in U.K pounds). If anyone is interested I'll look into this further. Postage should be minimal.

    Steve.

  20. #40
    Join Date
    Sep 2007
    Posts
    11
    Hello,

    I have started playing with your software and I can say that it is really excellent.
    I have to spend some time to adjust speed and acceleration parameters, to avoid step loss.
    Any mechanical backlash has been reduced as I could and so the motor has to provide some torque.
    I have used a 96 teeth worm gear, and timing pulleys in a 16/30 ratio.
    One motor rotation (400 steps) move main axis by 2 degrees.

    Keyboard resistors are pulldown (I confirm),

    MCLR pulled to VCC with 10k provide a reliable startup,

    It could be a good idea, to have the choice of Enable signal direct or invert (I have added one transistor).

    Last request if you are working on a new release, is the need of a small adjustable offset, (+/-) without cancelling the programmed division number.
    If you cut a gear, after a complete rotation it is useful to offset slightly the dividing head and give a last small cut to every tooth, on the left and on the right side.

    Best Regards to all and thank again to Kwackers.

Page 2 of 41 123412

Similar Threads

  1. Stand alone rotary table indexer.
    By kwackers in forum PIC Programing / Design
    Replies: 13
    Last Post: 01-29-2023, 03:01 PM
  2. CNC Rotary Indexer/Table
    By desman in forum Commercial CNC Wood Routers
    Replies: 2
    Last Post: 08-11-2015, 03:32 PM
  3. 4th Axis CNC Rotary Indexer Table Plans
    By Modular CNC in forum News Announcements
    Replies: 4
    Last Post: 05-11-2011, 07:55 PM
  4. Manual indexer-rotary table vertical
    By silverfoxx03 in forum Want To Buy...Need help!
    Replies: 0
    Last Post: 02-18-2011, 09:04 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •