robotics company robot company  

Go Back   Trossen Robotics Community > Robotics > Brains of my Robot

Brains of my Robot Questions relating to SBCs, Microcontrollers, Mini Computers, PDA's, Handhelds, Laptops, Fullsize, etc.

» Navigation Menu
Homepage
Forums
TRC Tutorials
Member Blogs
Data Center
Image Galleries
Links Directory
Contact Us

Shop Robotics
» Join our Chatroom!


You'll need an IRC Client
» Introduction Tutorials

» Robot Parts!
» Find Us on Facebook!
» Arbotix
» RoboGames
» ComBots
» Turrets!
» Trossen Robotics Blog
Trossen Robotics DIY Project Contest...
Like Us! Like Us!...
Interlink FSRs now with Female Connector...
InterbotiX Robot Turrets...
RFID Login for Windows 7 Walk Through...
» Join Us Elsewhere!






» Bioloid Premium Kit
» Online Users: 330
16 members and 314 guests
blobbington, BMW1028, elaughlin, HyperMouse, innerbreed, italian_guy299, Jennero, kanda, lnxfergy, Rick Brooks, Robonaut, SteamAutomaton, Stobs, TOhm, Tyberius, Upgrayd
Most users ever online was 1,301, 09-11-2009 at 05:59 PM.
» Stats
Members: 4,281
Threads: 2,902
Posts: 37,199
Top Poster: Adrenalynn (5,316)
Welcome to our newest member, elitetech
Reply
 
Thread Tools Search this Thread Display Modes
  #11  
Old 07-04-2009
WGhost9's Avatar
WGhost9
WGhost9 is offline
Quantum Gate
 
Join Date: Mar 2009
Posts: 94
Images: 67
Rep Power: 11
WGhost9 is a jewel in the roughWGhost9 is a jewel in the roughWGhost9 is a jewel in the rough
Re: Axon Programming Questions

haha, thats the trouble, I cant find it in any header :P-- which of course would be exactly why its not recongized by the compiler. If only I knew the header I could include it :/
Reply With Quote
  #12  
Old 07-04-2009
Adrenalynn's Avatar
Adrenalynn
Adrenalynn is offline
Banned from posting too much :-)
 
Join Date: Apr 2008
Location: Sacramento, CA, USA Area
Posts: 5,316
Blog Entries: 8
Rep Power: 147
Adrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant future
Re: Axon Programming Questions

http://www.wingrep.com/
__________________
I Void Warranties™

CCTV Camera Systems and Security Camera Accessories by eMS. Ignore the CCTV Camera linkage. Just taking advantage of an inbound link opportunity...
Reply With Quote
  #13  
Old 07-05-2009
lnxfergy's Avatar
lnxfergy
lnxfergy is online
Fergalicious!
 
Join Date: May 2008
Posts: 1,297
Blog Entries: 3
Images: 139
Rep Power: 61
lnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant future
Re: Axon Programming Questions

timer640.h

Right out of the documentation on Society of Robots: http://www.societyofrobots.com/axon/...t.shtml#delays
Quote:
There are two ways to create a time delay, or a pause, in your code. The first way offers the maximum time resolution possible. This method should be used if you do not require exact timing, but works well enough for servos and general wait commands:
delay_cycles(65500);
The second method involves using a timer interrupt on timer0. Typically this is the 'correct' wait for doing a delay, but could potentially cause conflicts if you are using other timer interrupts or have other time-sensitive algorithms running simultaneously.
delay_us(1000);//delay for 1000us
delay_ms(1000);//delay for 1000ms
delay_cycles uses a long int, so you can't delay more than 2^16 = 65536 (for 0 to 65535). Just do something like this to delay longer:
delay_cycles(65500);
delay_cycles(65500);
delay_cycles(65500);
Refer to timer640.h for more documentation on the timer. Note that the compiler will ignore delay_cycles if you turn on compiler optimization.
Reply With Quote
  #14  
Old 07-05-2009
WGhost9's Avatar
WGhost9
WGhost9 is offline
Quantum Gate
 
Join Date: Mar 2009
Posts: 94
Images: 67
Rep Power: 11
WGhost9 is a jewel in the roughWGhost9 is a jewel in the roughWGhost9 is a jewel in the rough
Re: Axon Programming Questions

Thanks for all the advice; timer640.h indeed includes the timer_inits however it is already #included in the SOR_UTILS and should therefore be defined. I treid including it a second time in my control.c but the functions remain unrecognized.
Reply With Quote
  #15  
Old 07-05-2009
lnxfergy's Avatar
lnxfergy
lnxfergy is online
Fergalicious!
 
Join Date: May 2008
Posts: 1,297
Blog Entries: 3
Images: 139
Rep Power: 61
lnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant future
Re: Axon Programming Questions

Quote:
Originally Posted by WGhost9 View Post
Thanks for all the advice; timer640.h indeed includes the timer_inits however it is already #included in the SOR_UTILS and should therefore be defined. I treid including it a second time in my control.c but the functions remain unrecognized.
is the code possibly wrapped in a #ifdef? Might you be missing a definition related to which processor? Are you sure you have a good makefile (where said definitions would typically be)?

-Fergs
Reply With Quote
  #16  
Old 07-05-2009
WGhost9's Avatar
WGhost9
WGhost9 is offline
Quantum Gate
 
Join Date: Mar 2009
Posts: 94
Images: 67
Rep Power: 11
WGhost9 is a jewel in the roughWGhost9 is a jewel in the roughWGhost9 is a jewel in the rough
Re: Axon Programming Questions

Aha-ha! I have found the problem; the version of the timer reset and timer inits in Timer640.h have a '_' removed and added respectively changing their names slightly. Correcting their names in the ps2 code causes them to be recognized succesfully. However, this version of timer_init is no longer a void input but requires an input (defined as uint8 prescalar). I am working on what this input should be, but any suggestions are welcome . Thanks for the continued support.
Reply With Quote
  #17  
Old 07-05-2009
WGhost9's Avatar
WGhost9
WGhost9 is offline
Quantum Gate
 
Join Date: Mar 2009
Posts: 94
Images: 67
Rep Power: 11
WGhost9 is a jewel in the roughWGhost9 is a jewel in the roughWGhost9 is a jewel in the rough
Re: Axon Programming Questions

Update 2: Getting the timer functions to be recognized does not prevent the Axon from crashing on the line

delay_ms(1);
Reply With Quote
  #18  
Old 07-06-2009
WGhost9's Avatar
WGhost9
WGhost9 is offline
Quantum Gate
 
Join Date: Mar 2009
Posts: 94
Images: 67
Rep Power: 11
WGhost9 is a jewel in the roughWGhost9 is a jewel in the roughWGhost9 is a jewel in the rough
Math.h for the Axon?

Well today I go to write some inverse kinematics for my Axon controlled project only to find it lacks basic math functions like square root and inverse sine etc. Currently I am messing around with trying to import math.h from the c library of Microsoft studio but it is proving annoyingly problematic. Rather than reinvent the wheel, I was wondering i anyone here has already written a math.h for the axon and would be so kind as to share it. Thanks very much,

WGhost9
Reply With Quote
  #19  
Old 07-06-2009
lnxfergy's Avatar
lnxfergy
lnxfergy is online
Fergalicious!
 
Join Date: May 2008
Posts: 1,297
Blog Entries: 3
Images: 139
Rep Power: 61
lnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant futurelnxfergy has a brilliant future
Re: Math.h for the Axon?

Quote:
Originally Posted by WGhost9 View Post
Well today I go to write some inverse kinematics for my Axon controlled project only to find it lacks basic math functions like square root and inverse sine etc. Currently I am messing around with trying to import math.h from the c library of Microsoft studio but it is proving annoyingly problematic. Rather than reinvent the wheel, I was wondering i anyone here has already written a math.h for the axon and would be so kind as to share it. Thanks very much,

WGhost9
You probably want the math library from AVR-Libc
http://www.nongnu.org/avr-libc/user-...avr__math.html

-Fergs

Last edited by lnxfergy; 07-06-2009 at 01:51 PM.
Reply With Quote
  #20  
Old 07-06-2009
Adrenalynn's Avatar
Adrenalynn
Adrenalynn is offline
Banned from posting too much :-)
 
Join Date: Apr 2008
Location: Sacramento, CA, USA Area
Posts: 5,316
Blog Entries: 8
Rep Power: 147
Adrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant futureAdrenalynn has a brilliant future
Re: Axon Programming Questions

Quote:
Originally Posted by Adrenalynn View Post
[Moderator Note: Threads merged. They didn't really need to stand alone. Both were "Axon Programming Questions" as/per original. Thanks! -A]

[Moderator Note: Threads merged. They didn't really need to stand alone. Both were "Axon Programming Questions" by the same user, as/per original. Thanks! -A]
__________________
I Void Warranties™

CCTV Camera Systems and Security Camera Accessories by eMS. Ignore the CCTV Camera linkage. Just taking advantage of an inbound link opportunity...
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Qt and serial programming questions supawes Software and Programming 6 09-18-2009 12:47 AM
Question(s) Axon to SSC 32 WGhost9 Brains of my Robot 8 06-25-2009 08:52 PM
Question(s) Axon Digital I/O Questions (Buttons and LEDs)? JadeKnight I/O Boards and Controllers 2 02-20-2009 04:38 PM
programming axon with a-d converter robot maker Software and Programming 21 07-31-2008 04:52 PM
Question(s) Hello all - Some questions from a future rover builder (BrainStem and H-bridge related) jafoca Rovers 24 07-30-2008 02:31 AM

Powered by vBadvanced CMPS v3.2.0

All times are GMT -5. The time now is 04:37 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.