Welcome, Guest. Please login or register.

Username: Password:
Pages: 1 [2] 3 4

Author Topic: Arduino Instructions  (Read 42265 times)

TCWORLD

  • Administrator
  • *****
  • Posts: 809
    • View Profile
    • AstroEQ
Re: Arduino Instructions
« Reply #15 on: November 21, 2014, 15:20:45 »

Hi Paul,
Not sure if you saw my post above :)
Logged
Tom Carpenter (AstroEQ)

pterodyne

  • Sr. Member
  • ****
  • Posts: 91
    • View Profile
Re: Arduino Instructions
« Reply #16 on: November 21, 2014, 15:34:29 »

Did you try analog 0 and 1 like in Tom's last post?  I haven't had a chance yet
Logged

photo444

  • Full Member
  • ***
  • Posts: 29
    • View Profile
Re: Arduino Instructions
« Reply #17 on: November 21, 2014, 18:23:32 »

Thank you both of you.  I am trying but having another problem.  The computer does not recognize the serial port. It is intermittent, and comes and goes as it wills.  I will report when it is working. -Paul
Logged

photo444

  • Full Member
  • ***
  • Posts: 29
    • View Profile
Re: Arduino Instructions
« Reply #18 on: November 22, 2014, 16:05:01 »

I have burned the regulator chip on the MEGA board but replaced with 7805 and is working!  Attached is a CRUDE drawing of the circuit diagram (somebody may upgrade in an elegant ways).  Slew is working at 800X, currently it is tracking with Cartes du Ciel!  -Paul
« Last Edit: November 22, 2014, 22:13:29 by photo444 »
Logged

photo444

  • Full Member
  • ***
  • Posts: 29
    • View Profile
Re: Arduino Instructions
« Reply #19 on: November 22, 2014, 16:51:34 »

Here is one more picture I want to share. Next is implementing the circuit on the EQ mount.  Thank you Tom. -Paul
« Last Edit: November 22, 2014, 22:09:13 by photo444 »
Logged

TCWORLD

  • Administrator
  • *****
  • Posts: 809
    • View Profile
    • AstroEQ
Re: Arduino Instructions
« Reply #20 on: November 22, 2014, 17:03:04 »

Paul, I think you have the Mode pins for the DEC axis reversed in your diagram.

I've attached an Eagle schematic of the Arduino Mega variant (finally got around to making one). I am also going to make a PCB layout for building this on an Arduino Proto-Shield.
Logged
Tom Carpenter (AstroEQ)

photo444

  • Full Member
  • ***
  • Posts: 29
    • View Profile
Re: Arduino Instructions
« Reply #21 on: November 22, 2014, 21:57:38 »

You are right, Tom. It was corrected. The mistake happened while drawing but I did wire right.  I just came back from my honey-due work, and trying to put together with my mount. Thank you very much. -Paul
« Last Edit: November 26, 2014, 01:10:42 by photo444 »
Logged

photo444

  • Full Member
  • ***
  • Posts: 29
    • View Profile
Re: Arduino Instructions
« Reply #22 on: November 29, 2014, 19:38:07 »

Tom, this is a follow up of what I have been doing.  I have finished the board with Arduino Mega 2650 R3 and two stepper drivers from Polulu.  I am very excited to have a GOTO system of my own and have been playing quite a bit. 

I have found a small problem.  Whatever gear-ratios are entered for my DEC, the DEC movement is always constant.   I think the gear ratio is somewhat hard-coded in the routine. For example I was playing with rations (1.8deg-4-90-32MS, 1.8-6-90-32, 1.8-6-120-32, 1.8-4-60-32, etc.) but all gave unchanged DEC movements. From the parked position DEC=90:00:00) to Alp Phe (-42:18:27), my setting circle reads always are -01:00 regardless the ratios I enter.  While CDC commands a movement of 132 degrees my mount moves only 91 degrees (68.9%). RA seems alright. Please let me know if you find something. I hope I can do something before Christmas.

Another thing is that when your AstroEQ setup is done, EQMOD key pad says "Cannot be connected".  I have been turning off and on before running CDC to make it work. I don't know this is a bug or my own problem. This is another reason I should wait for the Christmas.

Paul
« Last Edit: November 29, 2014, 19:49:02 by photo444 »
Logged

pterodyne

  • Sr. Member
  • ****
  • Posts: 91
    • View Profile
Re: Arduino Instructions
« Reply #23 on: November 29, 2014, 20:06:35 »

I had the same problem with the not connecting on a true r3 arduino mega.  My sain smart r3 does not have this problem.  Not sure what could cause the difference.  Always the solution was to remove power to the arduino then it connects fine, until you use the utility to burn the firmware and settings, then only after a reset does it work.
Logged

photo444

  • Full Member
  • ***
  • Posts: 29
    • View Profile
Re: Arduino Instructions
« Reply #24 on: November 29, 2014, 20:18:17 »

Mine is SainSmart, too. 
Logged

TCWORLD

  • Administrator
  • *****
  • Posts: 809
    • View Profile
    • AstroEQ
Re: Arduino Instructions
« Reply #25 on: November 30, 2014, 18:09:05 »

I'll have to have a look into it. Trouble is at the moment all of my Arduino boards are back in the UK.

Different ratios in the config utility should have a different effect in terms of movement. If they are not it suggests that either the utility is failing to program them properly, or EQMOD is failing to read them properly.
There is a info screen in EQMOD which shows you what worm steps/rev it is using, this should match the sVal reported in the config utility.

One thing to try is using a serial utility such as PuTTy or the Arduino serial monitor, connect to the board and see what it responds with the following commands:
RA axis...
:a1
:b1
:s1

DEC axis...
:a2
:b2
:s2

Make sure to set the line ending in the serial terminal to be 'Carriage Return' only. And use 9600 baud.
They should return '=abcdef' which are an encoded string with the values of aVal, bVal and sVal. The decode them, type them into a hex to decimal converter in the order: 'efcdab'
Logged
Tom Carpenter (AstroEQ)

photo444

  • Full Member
  • ***
  • Posts: 29
    • View Profile
Re: Arduino Instructions
« Reply #26 on: December 01, 2014, 02:19:42 »

After reprogramming the unit, I was able to get the numbers with arduino IDE. The numbers are
:a1=004038, :b1=E43300, :s1=006400, :a2=00BC34, :b2=4D3B00, :s2=009600
The numbers from the AstroEQ table are
:a1=004038, :b1=CF3300, :s1=006400, :a2=00BC34, :b2=393B00, :s2=009600
These numbers are identical to those on the screen when the parameters are loaded into EEPROM.
Please refer the screen shots below.

I also have found the RA movement is 75% of CDC command value. So both RA and DEC show errors as indicated above.

Thanks for the information, Tom.
Logged

photo444

  • Full Member
  • ***
  • Posts: 29
    • View Profile
Re: Arduino Instructions
« Reply #27 on: December 05, 2014, 15:28:05 »

Tom, is there any way to change the code for Mega 2650 for the proper gear ratio?
Everything else than the gear ration seems working fine. Now I am watching my telescope swinging from one position to another.  I know I should (better) spend my time for something else. :D >:( :)

Paul
Logged

TCWORLD

  • Administrator
  • *****
  • Posts: 809
    • View Profile
    • AstroEQ
Re: Arduino Instructions
« Reply #28 on: December 06, 2014, 16:38:12 »

Hi Paul,

I'm not totally sure what is going on. It may be something with the new firmware (I merged the uploading and running firmware together in the last release).

I've managed to get hold of an Arduino Mega from someone over here, so I will have a play this weekend to see if I can replicate the issue.
Logged
Tom Carpenter (AstroEQ)

TCWORLD

  • Administrator
  • *****
  • Posts: 809
    • View Profile
    • AstroEQ
Re: Arduino Instructions
« Reply #29 on: December 06, 2014, 20:19:59 »

Seems to be working fine for me. The values I upload are read back correctly (tried the settings you used too).

There is an Arduino example sketch called 'eeprom_clear'. If you upload that to your Mega, and let it run (will happen pretty much instantly).
There is also an example sketch called 'eeprom_read'. If you run this next, you should see that the eeprom is all 0's (only the first 44 addresses matter). If they are not all zeros then there is something wrong with the EEPROM on your chip.

Assuming they are 0, then try running the AstroEQ config utility again.
« Last Edit: December 06, 2014, 20:21:34 by TCWORLD »
Logged
Tom Carpenter (AstroEQ)
Pages: 1 [2] 3 4