MartinSant.net

Software Engineering | MicroMachines

  • Airplane
  • Electronics
  • Model Trains
  • Chickens
  • 3D Design
  • German Shepherds
  • Garden
  • Protothrottle

Magic Crystals? Not so much.

Posted by admin on December 22, 2013
Posted in: Other Stuff.

xtal

I’ve retrofitted one widget and am building another from scratch, both have 18.432Mhz crystals driving the clock instead of the internal resonator for some experimentation and prototyping. Adding a crystal takes two pins but what can you do eh?

I have one running and so far and everything seems a bit tighter, but not dead nuts on like I was looking for. Note the couple of nanoseconds off on the first pulse. Main servo cycle is also 15ms instead of 20ms. Not sure I like that.

I think I’m missing something in the algorithm aspect of the servo drivers so I may refactor it for the third time. The above is a hack, I’m not fond of it but it works.

The big revelation here is that the timers must have some intrinsic slop which you have to compensate for. I found this while fixing the s/w uart so perhaps some servo driver adjustments are prudent.

Speaking of, the s/w serial out is now dead on, I get zero errors out at 4800 baud. So now I have one dedicated h/w serial link to the Xbee, a dedicated h/w serial RX from the RFID reader and a s/w tx to the sound boards. Sweet.

Posts navigation

← Timer Inconsistencies
Attiny Software UART →
  • Recent Posts

    • All finished, well almost
    • New Paint
    • Train Layout Rebuild
    • New Computer
    • Airplane Refurb
  • Pages

    • 2D vector drawings into 3D models
    • 3D Printed Figures
    • Android – Reels Game App
    • AVR Attiny 1634 s/w UART
    • Bluetooth Diagram and Descriptions
    • Building a G Scale Turnout
    • Burnley Country Store
    • Flying to York PA
    • New Puppy – Sophie
    • Protothrottle
    • Protothrottle to Airwire Beta
    • Rail Layout Editor
    • Raspberry Pi Zero W Wifi Access Point
    • RPi Android HTML5 Servo Control
    • Steam Engine and Dynamo
    • Tin Can Steam Boiler
    • Wixel Breakout Board
    • CRM C# Autonumber Plugin
    • Microsoft CRM and C#
    • EightWay Game
    • Dice In A Stone Box
    • About Martin
Proudly powered by WordPress Theme: Parament by Automattic.