To: | |
---|---|
Subject: | [ts-7000] About RTC |
From: | "Julien" <> |
Date: | Tue, 22 May 2007 10:06:57 -0000 |
Hi Kevin About the RTC we discussed on the yahoo group, I would like to ask you some details if it's possible. Is there any way that the same data is in all addresses starting at 0x11700000 ? Because I'm trying to read hours, minutes, etc... when UIP is low, and I obtain the same value for all registers. I'm completly stucked, and have no idea of where the problem comes. [see below more details about what my program does] You said that your program read successfully registers to obtain date/hours. Did you meet my wierd problem in the past ? Thanks. Regards. Julien Here is what I'm doing on my program : **************************************** rtcfd=open("/dev/mem", O_RDWR|O_SYNC); RTC_Start_Adresse=(UINT8 *)mmap(0, getpagesize(), PROT_READ|PROT_WRITE, MAP_SHARED, rtcfd, 0x11700000); RTC_registre_A = RTC_Start_Adresse + 0xA; RTC_registre_B = RTC_Start_Adresse + 0xB; if(!(*RTC_registre_A & 0x80)) //if UIP = 0 { rt_printk("Read Possible :");} else { rt_printk("Read Not Possible !");r} **************************************** Then I simply read if the MSB of *RTC_registre_A is 0 (ie UIP), if yes I read seconds,minutes, and so on... Here is the result : **************************************** $ ./gestion_buffer_date_heure LXRT CHANGED MODE (SYSCALL), PID = 105, SYSCALL = 5. program launched ! Read Possible : Reg A = 2 Reg B = 2 Le 2 2/2/2 a 2h 2min 2sec Finish ! LXRT releases PID 103 (ID: gestion_buffer_). **************************************** __._,_.___
SPONSORED LINKS
Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required) Change settings via email: =Email Delivery: Digest | m("yahoogroups.com?subject","ts-7000-fullfeatured");=Change Delivery Format: Fully Featured">Switch to Fully Featured Visit Your Group | Yahoo! Groups Terms of Use | =Unsubscribe __,_._,___ |
<Prev in Thread] | Current Thread | [Next in Thread> |
---|---|---|
|
Previous by Date: | [ts-7000] Re: problems bypassing fastboot, oj199933 |
---|---|
Next by Date: | [ts-7000] Re: Cross Compiling, oj199933 |
Previous by Thread: | [ts-7000] installing the debian image on a new cf card, geoffjay01 |
Next by Thread: | Re: [ts-7000] About RTC, Kevin Cozens |
Indexes: | [Date] [Thread] [Top] [All Lists] |
Disclaimer: Neither Andrew Taylor nor the University of NSW School of Computer and Engineering take any responsibility for the contents of this archive. It is purely a compilation of material sent by many people to the birding-aus mailing list. It has not been checked for accuracy nor its content verified in any way. If you wish to get material removed from the archive or have other queries about the archive e-mail Andrew Taylor at this address: andrewt@cse.unsw.EDU.AU