21.04.2013 Views

Capítulo 7 Parámetros del servo - Delta Electronics

Capítulo 7 Parámetros del servo - Delta Electronics

Capítulo 7 Parámetros del servo - Delta Electronics

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Capítulo</strong> 8 Comunicaciones de MODBUS|Serie ASDA-AB<br />

unsigned char tdat[60]={‘:’,’0’,’1’,’0’,’3’,’0’,’2’,’0’,’0’,’0’,’0’,’0’,’2’,’F’,’8’,’\r’,’\n’};<br />

void main() {<br />

int I;<br />

outportb(PORT+MCR,0x08); /* interrupt enable */<br />

outportb(PORT+IER,0x01); /* interrupt as data in */<br />

outportb(PORT+LCR,( inportb(PORT+LCR) | 0x80 ) );<br />

/* el BRDL/BRDH puede ser accedido como LCR.b7 == 1 */<br />

outportb(PORT+BRDL,12);<br />

outportb(PORT+BRDH,0x00);<br />

outportb(PORT+LCR,0x06); /* configurar el protocolo<br />

= 1AH, = 0AH<br />

= 07H = 1BH<br />

= 0BH */<br />

for( I = 0; I

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!