80 unsigned int ui_NoOfChannel;
85 *data = (*data >> ui_NoOfChannel) & 0x1;
93 printk(
"\nSpecified channel not supported \n");
128 if ((data[0] != 0) && (data[0] != 1)) {
130 "Not a valid Data !!! ,Data should be 1 or 0\n");
167 unsigned int ui_Temp, ui_Temp1;
169 if (
devpriv->b_OutputMemoryStatus) {
177 data[0] = (data[0] << ui_NoOfChannel) | ui_Temp;
182 data[0] = (data[0] << (2 * data[2])) | ui_Temp;
187 printk(
"\nSpecified channel not supported\n");
194 data[0] = ~data[0] & 0x1;
196 ui_Temp1 = ui_Temp1 << ui_NoOfChannel;
197 ui_Temp = ui_Temp | ui_Temp1;
199 (data[0] << ui_NoOfChannel) ^
201 data[0] = data[0] & ui_Temp;
207 data[0] = ~data[0] & 0x3;
209 ui_Temp1 = ui_Temp1 << 2 * data[2];
210 ui_Temp = ui_Temp | ui_Temp1;
214 0xffffffff) & ui_Temp;
220 printk(
"\nSpecified channel not supported\n");
225 printk(
"\nSpecified functionality does not exist\n");
254 unsigned int ui_Temp;
255 unsigned int ui_NoOfChannel;
261 *data = (*data >> ui_NoOfChannel) & 0x1;
269 printk(
"\nSpecified channel not supported \n");
342 unsigned int ul_Command1 = 0, ul_Channel_no, ul_Polarity, ul_DAC_Ready = 0;
347 ul_Polarity = 0x80000000;
348 if ((*data < 0) || (*data > 16384)) {
349 printk(
"\nIn WriteAnalogOutput :: Not Valid Data\n");
355 if ((*data < 0) || (*data > 8192)) {
356 printk(
"\nIn WriteAnalogOutput :: Not Valid Data\n");
361 if ((ul_Channel_no < 0) || (ul_Channel_no > 7)) {
362 printk(
"\nIn WriteAnalogOutput :: Not Valid Channel\n");
367 while (ul_DAC_Ready == 0) {
369 ul_DAC_Ready = (ul_DAC_Ready >> 8) & 1;
375 (
unsigned int) ((
unsigned int) (ul_Channel_no & 0xFF) |
376 (
unsigned int) ((*data << 0x8) & 0x7FFFFF00L) |
377 (
unsigned int) (ul_Polarity));
416 unsigned int ul_Command1 = 0;
454 ul_Command1 = ul_Command1 & 0xFFFFF9FE
UL;
481 (ul_Command1 & 0xFFF719E2
UL) | 2UL << 13UL | 0x10UL;
517 unsigned int ul_Command1 = 0;
525 ul_Command1 = (ul_Command1 & 0xFFFFF9FF
UL) | 0x1UL;
532 else if (data[1] == 0)
538 ul_Command1 = ul_Command1 & 0xFFFFF9FE
UL;
542 }
else if (data[1] == 2) {
546 ul_Command1 = (ul_Command1 & 0xFFFFF9FF
UL) | 0x200UL;
559 ul_Command1 = (ul_Command1 & 0xFFFFF9FF
UL) | 0x1UL;
564 }
else if (data[1] == 0) {
569 ul_Command1 = ul_Command1 & 0xFFFFF9FE
UL;
575 else if (data[1] == 2) {
580 ul_Command1 = (ul_Command1 & 0xFFFFF9FF
UL) | 0x200UL;
636 printk(
"\nIn ReadTimerCounterWatchdog :: Invalid Subdevice \n");
659 int i_Count = 0, i_temp = 0;
660 unsigned int ul_Command1 = 0, ul_Polarity, ul_DAC_Ready = 0;
665 ul_Polarity = 0x80000000;
667 for (i_Count = 0; i_Count <= 7; i_Count++) {
670 while (ul_DAC_Ready == 0) {
673 ul_DAC_Ready = (ul_DAC_Ready >> 8) & 1;
679 (
unsigned int) ((
unsigned int) (i_Count & 0xFF) |
680 (
unsigned int) ((i_temp << 0x8) & 0x7FFFFF00L) |
681 (
unsigned int) (ul_Polarity));
712 unsigned int ui_Timer_AOWatchdog;
713 unsigned long ul_Command1;
718 ul_Command1 = (ul_Command1 & 0xFFFFF9FDul);
722 ui_Timer_AOWatchdog =
726 if ((!ui_Timer_AOWatchdog)) {
737 ul_Command1 = ((ul_Command1 & 0xFFFFF9FDul) | 1 << 1);