Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - vitaliy

Pages: 1 ... 7 8 9 10 11 [12] 13 14
166
8051 Development Tools / Re: Server51
« on: June 17, 2006, 01:04:58 am »
CClientAPI::ReadAnalog

Form
long ReadAnalog(short DeviceType, short Channel, short * pVal)
Return value is ERRCODE value.

Description
Reads the analog input value from ADC board .
DeviceType value is a type of Analog-to-Digital converter
that is installed on the board

DEVICE_TLC2543.

Available values of Channel are:

ANALOG_CHANNEL1
ANALOG_CHANNEL2
ANALOG_CHANNEL3
ANALOG_CHANNEL4
ANALOG_CHANNEL5
ANALOG_CHANNEL6
ANALOG_CHANNEL7
ANALOG_CHANNEL8
ANALOG_CHANNEL9
ANALOG_CHANNEL10
ANALOG_CHANNEL11
ANALOG_CHANNEL12

DEVICE_MAX127, DEVICE_MAX128
Channel defines a number of physical analog input of ADC board.
Available values of Channel are 0,1,2,3,4,5,6, 7.
pVal is a pointer to the variable that receives analog input information.

Example

// Create an object

CClientAPI obj;

short Value;

if ( !obj.InitPort())

{

// Get the analog input value of channel #4

ERRCODE ec=board.ReadAnalog(DEVICE_TLC2543, ANALOG_CHANNEL4, &Value);

if ( !ec )

// Good request

else

// Bad request

}


167
8051 Development Tools / Re: Adding new registers to compiler\'s library
« on: December 12, 2005, 01:25:41 pm »
asm
{
P4      EQU $C0
P5      EQU $C7
}
extern register unsigned char P4,P5;

void main()
{
     int val;
     val = P4;
     P5 = 0
     P5 |=1;
.....      
}

168
8051 Development Tools / Re: How To Declare \'Alternate Function\' vs GPIO
« on: December 08, 2005, 04:05:48 pm »

169
8051 Development Tools / Re: How To Declare \'Alternate Function\' vs GPIO
« on: December 08, 2005, 03:59:27 pm »
Please read
http://www.bipom.com/cgi-bin/yabb/YaBB.pl?board=8051;action=display;num=1114595527

setbit(P1.3) ;// input or weak pull-up output
clrbit(P1.3); // low output

170
8051 Development Tools / Re: Software implementation of UART
« on: April 21, 2005, 12:30:01 am »
Please install 8051/52 development system from BiPOM Electronics and try C:\\bipom\\devtools\\MicroC\\Examples\\8051\\tiny\\SoftUART\\2ndUART.prj example

171
8051 Development Tools / Re: Writing EEprom
« on: December 09, 2004, 12:15:08 pm »

172
8051 Development Tools / Re: Writing EEprom
« on: December 02, 2004, 04:28:13 am »
sorry

   deviceNumber |= (address >> 8 ) ;

   ec = Transmit( I2C_DEVICE_24CXX | I2C_WRITE | (deviceNumber << 1) );

173
8051 Development Tools / Re: Writing EEprom
« on: December 02, 2004, 04:27:05 am »
Please note, you changed the original  source.
It had contained
....

   deviceNumber |= (address >> 8);
   ec = Transmit( I2C_DEVICE_24CXX | I2C_WRITE | (deviceNumber << 1) );
...

174
8051 Development Tools / Re: Writing EEprom
« on: October 12, 2004, 09:50:48 am »
If you use 8051/52 development system
you will be able to find EEPROM example under
C:\\bipom\\devtools\\MicroC\\Examples\\8051\\tiny\\eeprom\\24C04 folder.
Please try it.

Best regards,
Vitaliy

175
8051 Development Tools / Re: debug messages
« on: November 14, 2004, 01:01:56 am »
The following Preprocessor  commands are recognized by the MicroC compiler
if they occur at the beginning of the source file line:  
1)
#error <text>
 Causes  MicroC to  issue  an  error  message  containing   the
specified text, and then terminate.

2)
#message <text>
Outputs an informational message (does not terminate).

For example,
#message "SOME MESSAGE"

Best regards,
Vitaliy

176
8051 Development Tools / Re: MINI-MAX/51-D Communication problem
« on: October 12, 2004, 09:47:59 am »
Please download the latest release from http://www.bipom.com/software.shtm
This known problem was fixed a few months ago.
Mini-Max/51-C loaders of the new releases were modified to support AT89C51ED2 chip.

Best regards,
Vitaliy

177
8051 Development Tools / Re: 8051 development
« on: June 07, 2004, 11:32:46 am »
"8051/52  DevelopmentSystem" includes:
- Micro-IDE;
- Micro C compiler from Dunfield Development Systems;
- XASM 8051/8052 Cross Assembler;
- Help documentation in HTML form;
- Examples for all shipped hardware;
- 8051/52 Simulator;
- debugger;
- loaders.

Micro-IDE is a Windows based Integrated Development Environment for micro-controller systems application development.
Micro-IDE integrates essential components of software development including:
- Multi File Editor with C and Assembly language syntax coloring;
- Integration with toolkits including command line compilers, assemblers, linkers;
- Project Manager;
- Tools: Terminal program, Calculator, ASCII Chart.

178
68HC12 Development Tools / Re: Running C programs
« on: March 07, 2004, 04:22:00 am »
I guess you have some problems with CSTARTUP files.
In other words, you should  adapt the start-up code for your board.
Please check 6812RLM.ASM, 6812RLP.ASM, and 6812RLS.ASM files
under C:\\bipom\\devtools\\MicroC\\Lib12 folder.
As minimum action  you have to uncomment  RESET vector (6812RLS.ASM)

*
* DDS MICRO-C 68HC12 Runtime library - Suffix file
*
?heap      EQU      *            Heap memory goes here
* For stand-alone ROM system, uncomment the following
     ORG      $FFFE            Position to reset vector
     FDB      ?begin            Set start address
*00000

179
68HC08 Development Tools / Re: Illegal address reset
« on: June 27, 2005, 01:18:46 am »
If you use Mini-Max/908 board the system can be reset if PTC1 goes low for 2 seconds.


180
WebCat/WebCatPlus / Re: WebCat and DIO with tags
« on: January 14, 2007, 03:32:12 am »
> Found a possible solution.. let me know if it\'s correct
yes, it\'s correct.
It is necessary to empty I2C buffer periodically.
The buffer has only 8-byte depth.

Also, you can reset the I2c Pointer only (CLR=IP).
This way you can re-get all the bytes from buffer again.

> Question :  
> How can I explicitly set some lines as inputs and some > as outputs in port A ?

You can do that using TRISA unit.

#define PORTA_UNIT                        0
#define TRISA_UNIT                        1
#define PORTB_UNIT                        2
#define TRISB_UNIT                        3
#define PORTC_UNIT                        4
#define TRISC_UNIT                        5


For example, you would like to have 3 inputs( PORTA0..2) and 3 outputs (PORTA3..5).
It means you have to write 7 (000111B) to TRISA.
1 defines  input
0 defines output

Pages: 1 ... 7 8 9 10 11 [12] 13 14