To: | |
---|---|
Subject: | [ts-7000] Re: TS-7260 DIO with 2.6.21-ts kernel |
From: | "r_bergo" <> |
Date: | Wed, 31 Aug 2011 20:22:46 -0000 |
Hello Don ! Last year I migrated my TS7260 software to kernel 2.6.34 and I got some toubles. One of those whose about DIO. Please, download my IO library from here , compile the included iotest (make -f IOTEST), unplug any DIO connectors from your TS and run ./bin/iotest The output on my Ts7260 boards is: # ./bin/iotest TEST OUTPUT BITS ON PORT A [ Port 0000, Dir 001F, Value 0000 ] write 0000 read 0000 ------------------- PASS [ Port 0000, Dir 001F, Value 0055 ] write 0015 read 0015 ------------------- PASS [ Port 0000, Dir 001F, Value 00AA ] write 000A read 000A ------------------- PASS [ Port 0000, Dir 001F, Value 00FF ] write 001F read 001F ------------------- PASS ---->OK TEST OUTPUT BITS ON PORT B [ Port 0100, Dir 00F8, Value 0000 ] write 0000 read 0000 ------------------- PASS [ Port 0100, Dir 00F8, Value 0055 ] write 0050 read 0010 ------------------- FAIL bit 0040 !!! [ Port 0100, Dir 00F8, Value 00AA ] write 00A8 read 00A8 ------------------- PASS [ Port 0100, Dir 00F8, Value 00FF ] write 00F8 read 00B8 ------------------- FAIL bit 0040 !!! ---->ERROR BITS: 40 TEST OUTPUT BITS ON PORT C [ Port 0200, Dir 0001, Value 0000 ] write 0000 read 0000 ------------------- PASS [ Port 0200, Dir 0001, Value 0001 ] write 0001 read 0001 ------------------- PASS ---->OK TEST OUTPUT BITS ON PORT F [ Port 0300, Dir 0000, Value 0000 ] write 0000 read 0000 ------------------- PASS [ Port 0300, Dir 0000, Value 0002 ] write 0000 read 0000 ------------------- PASS ---->OK TEST OUTPUT BITS ON PORT H [ Port 0400, Dir 0038, Value 0000 ] write 0000 read 0000 ------------------- PASS [ Port 0400, Dir 0038, Value 0055 ] write 0010 read 0010 ------------------- PASS [ Port 0400, Dir 0038, Value 00AA ] write 0028 read 0028 ------------------- PASS [ Port 0400, Dir 0038, Value 00FF ] write 0038 read 0038 ------------------- PASS ---->OK Test <<FAILED>> Everiting works well except two bits on port B! If you run the same test on the same board using kernel 2.4 instead of 2.6.34 you will get a different result but not ok at all. Please give me a feedback. Roberto --- In "Rekcut_Nod" <> wrote: > > If I run a little utility (see below) to read and write to the memory register corresponding to the DIO data on the DIO1 header of the TS-7260 board, I get different results depending upon whether I'm running the TS stock 2.4 kernel, or their (unsupported) 2.6.21-ts kernel. Has anyone experienced this? Has anyone found a way to get the DIO lines to work with the 2.6 kernel? > > Any assistance is greatly appreciated! > Don > > utility source: > > int main(int argc, char **argv) > { > volatile unsigned char *PBDR, *PBDDR; > unsigned char *start, _ONE_=0x1; > int fd = open("/dev/mem", O_RDWR|O_SYNC); > int i; > > start = mmap(0, getpagesize(), PROT_READ|PROT_WRITE, MAP_SHARED, fd, > 0x80840000); > PBDR = (unsigned char *)(start + 0x04); // port b > PBDDR = (unsigned char *)(start + 0x14); // port b direction register > > *PBDDR = 0xff;// all output > > for(i=0;i<8;i++) > { > *PBDR = ONE<<i; > printf("*PBDR=%02x\n",*PBDR); > sleep(2); > } > > close(fd); > return 0; > } > > Results, with DIO_4 (pin 9) grounded: > 2.4 kernel: > PBDR=01 > PBDR=02 > PBDR=04 > PBDR=08 > PBDR=00 > PBDR=20 > PBDR=40 > PBDR=80 > 2.6 kernel: > PBDR=0f > PBDR=0f > PBDR=0f > PBDR=0f > PBDR=0f > PBDR=2f > PBDR=4f > PBDR=8f > __._,_.___
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: | Re: [ts-7000] TS-7550 XUARTs, mike ingle |
---|---|
Next by Date: | Re: [ts-7000] TS-7550 XUARTs, Mark Featherston |
Previous by Thread: | [ts-7000] TS-7260 DIO with 2.6.21-ts kernel, Rekcut_Nod |
Next by Thread: | Re: [ts-7000] Re: TS-7260 DIO with 2.6.21-ts kernel, dtucker |
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