Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

ccd scanner

Status
Not open for further replies.

hani_a

New Member
Hello people,

I'm programming a ccd scanner via ATMega16. I'm using the following code to transmit the signal from the chip to the scanner but i'm getting absolutely no response:

while (1){

putchar(0x1b);
putchar(0x54);
putchar(0x0d);
// this code should buzz the scanner but it's not buzzing :(
}


the scanner's datasheet is at **broken link removed**

and the chip's datasheet is at http://www.atmel.com/dyn/resources/prod_documents/doc2466.pdf

would anyone please have a look at the datasheets and tell me what it is i might be doing wrong...

I really appreciate the help!

Hani A.
 
Have made sure that you are transmitting at the same baudrate and with the same "protocol" as chosen in your DIP switch in the scanner.?

I guess that putchar() is a serial output command. But where are you defining the way it should transmit. You are going to need 1 start bit, 8 bit data no parity, and 1 stop bit. (aka 8N1)

Also you do realize that it buzzes and lights only for 150msec. So you at least have to do this command 5-6 times for you to see it.

Hope it helps,

Ivan
 
Hello,

first of all, thanks so much for your response. second of all, i'm pretty sure that i've sent 8n1 data packets. i've actually checked the output signal via the oscilloscope. now my questions are:
1) you say that i need to send the packet 5 or 6 times to be able to see it, i put it in the while loop, so i expect it to keep buzzing forever. am i correct?
2) since it would buz for 150ms, i should hear a fast buzz, correct?

thanks a million for the help!
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top