Search the Community
Showing results for tags 'Clock'.
Found 2 results
Here's a little article I ran into at "archive.org" from an 1980 "Byte" magazine... A link to the web-link is below. I haven't read it fully, but I do understand that those interrupts can be pretty fast when used properly, especially on the TI-99 with it's limitations. I've attached a PDF file to this post to specific article discussing an "Interrupt Driven Real Time Clock" with source code. I bet there's all sorts of useful things that can come from the article for anyone who's interested. https://archive.org/details/byte-magazine-1980-09 An Interrupt-Driven Real-Time Clock for the TMS 9900.pdf
In the June 1985 issue of ANALOG (#31), the "ATARI CLOCK" by Jonathan Buckheit was published. It is a machine language program that added an extra text line to the top of the screen display and printed the time once per second. I remember typing in CLOCK1.BAS to create an AUTORUN.SYS file and CLOCK2.BAS to set the time. I also remember using it but soon tired of inputting the time for each REBOOT. Download ANALOG issue #31 for more information. http://www.atarimania.com/atari-magazine-analog_18.html The forums had several links to that issue's disk image. This is one of them. Download AN31 B.atr and check it out. ftp://ftp.pigwa.net/stuff/collections/holmes%20cd/Holmes%203/ANALOG/index.html Almost 5 years ago a RTC circuit was purchased to hook up to the Arduino Uno only so that it would be available for a project. Setting the ATARI CLOCK using data from the RTC seems to be that project. So while I've been waiting for some divine inspiration to point me toward the best way to transfer the data from the Arduino to the Atari, the RTC battery died. I have also tired of waiting for the divine intervention and will start by using the RS232 interface(850 or P:R: Connection) for the link. Step 1. Find information on RTC and Arduino As it happened, the RTC in my parts box is a SainSmart I2C RTC DS1307 module, TinyRTC v1.1.( http://www.sainsmart.com/arduino-i2c-rtc-ds1307-at24c32-real-time-clock-module-board-for-avr-arm-pic.html ) There are several boards and different clock chips that can do the job. I don't have enough information to make a recommendation. Adafruit has a lot of information on their DS-1307 RTC kit. Worth the read. https://learn.adafruit.com/ds1307-real-time-clock-breakout-board-kit/overview Step 2. Arduino Software: Arduino.cc has a library that works with the DS-1307 based RTC. Another source for information and a software example was found at Tronixstuff. John Boxall, author of the book, Arduino Workshop, has written the tutorial. His program does not use a library to set or read the time-date information. This gave me a clearer picture of how it all works. http://tronixstuff.com/2014/12/01/tutorial-using-ds1307-and-ds3231-real-time-clock-modules-with-arduino/ The RTC and Arduino were wired using the tutorial information. Clock - Arduino Vcc -5V Gnd - Gnd Scl - A5 Sca - A4 I copied the code and pasted it into the Arduino IDE. Then I compiled and ran it. The serial port was then monitored to view time and date. This is when I found out the backup battery was dead. When you change the battery or want to set the clock, the program needs to be modified to call the SETDS3231time function. Remove the comment delimiter from line in setup() with the SETDS3231time function and set the parameters. The SETDS3231time function needed to be moved to just before setup() function. An undefined function error occurred until it was moved. The time was now being sent to the serial monitor. Now, put the comment delimiter back in front of the SETDS3231time in setup() and reprogram the Arduino. If you don't, every time the Arduino is powered up the clock gets reset to the time specified in the call. Most if this is explained in the tutorial. (I disconnected the RTC to be sure I didn't accidently reset the time.) Step 3. Communicate through the RS232 shield. The RS232 Shield was plugged into the Arduino and the RTC was wired into the shield. An RS-232 - USB converter was plugged into the computer and RS232 shield. A 9V battery was used to power the Arduino instead of the USB connection because the USB port on the Arduino and RS232 shield share the same pins for data transfer. The converter was defined as COM3 and reproduced the data stream to the Serial Monitor. The RS232 Shield had been used in a previous project and was expecting these results. (Atari 8 bit <-> 850 Interface <-> RS232 Shield <-> Arduino) . At least I know that the RTC module, Arduino, RS232 shield are working properly. I'm waiting for a gender changer to make the connection to the 850. And I'm still waiting for that inspiration.