8051 and ADC

Hello All,

I am trying to build a 8051 based single board computer. I am planning to have an ADC (0804) and serial port drivers ( 1488 and 1489) on it too. The project is to read the voltages form the temparature sensor and update a website portal using serial port.

And I have following worries and questions

  1. Let suppose the temparature sensor updates itself every one second. The 8051 is also commnunicating with the PC via serial port and then PC is updating the portal. My question is that how will I keep everything synchronize?

  1. What should be the size of the RAM and EPROM?

  2. What should be the relation between the serial communication baud rate and the update rate of the portal and the ADC update rate?

  1. How can I measure the serial baud rate generated by the 8051?

  2. Can somebody advice me how to make interface with portal on the PC side?

Please advice! John

Reply to
Loading thread data ...

Well you can generate the timing from one of three places here: You can i) Pump out data asynchronously to the PC and have it update the website. ii) Have the PC interrogate the 8051 and then post the resulting data to the website. ii) Wait until a user requests a temperature from a web page, then go and get it from the 8051 and serve it from the PC

Large enough, but no larger.

Put it this way - do you think 0.0001 Baud would be sensible?

Well you could use an oscilloscope. But why would you want to? Surely you are in control of the 8051s baud rate?

I would be more than happy to bid for the work - about =A320K would be about right.

More homework?


Reply to


Thanks Ted. Its not home work. I have to build the whole thing. Can any body suggest any link or some pointers to build the portal interface using some programming language. Plus I am open for more suggestions on the questions.

Regards, John

Reply to

Google bit more;-)

What ever OS you are using does not matter, single thread should fix it. Fetch data form serial port and update the DB, file or web field.

What ever comes with your controller should be enough for given situation.

Use timer in PC (portal) envirment if you want to update the status atomatically. Moreoever, portal update cann't succedd the rate of ADC.

0- Controller interrupts when ADC is done. 1- Handle inturrpt of send routine (serial port in PC) . 2- Update the DB , webpage or file in same thread.

Ted made that clear, get your self next to oscilloscope.

If you are on M$ then activeX or simple dll. On *ix go for batch or maybe php.


Reply to

ali wrote: If you are on M$ then activeX or simple dll. On *ix go for batch or maybe php.

Would you please explain a little more?

Regards, John

Reply to

This *really* sounds like homework - from 1980! :)

Or maybe not...

Very, very small.

If it's only once a second it does not matter.

With an oscilloscope


John Devereux
Reply to
John Devereux

  1. For quick and easy, I'ld use VisualBasic and MSComm for the serial port. VB will sit and listen to the serial port and do whatever when the 8051 sends somthing... or ... have the 8051 wait on the serial port and have VB request a reading from it.

Too rusty on web programming to remeber how to have HTML do VB.

Reply to

Write activeX or DLL in your favourite language (vc or vb) todo serial port stuff. Now call your activeX or dll in html page. Google for using activex or dll in webpage. Sure, you got to do server side scripting too that can be done in java, asp etc.

For *nix type machines try CGI it simple and best way. or just write some batch that will read serial port and send back to caller which will be java or php server page. I didn't try this design by my self but quite sure should work. And as far as activeX or dll is concern that 100% solution.

BTW, what platfor you are on? ali

Reply to

I assume you are serious.

1 - First how are you making the board? 2 - ditch the 1488 and 1489 use a MAX232. 3 - some 8052 have a built in A2D 4 - memory a standard 8052 has 8K of flash and 256 bytes of RAM more than enough. 5 -
formatting link
6 - What language are you programming this in C Pascal ,asm, Forth? 7 - How will you talk to the 8052 from the PC? 8 - Budget? 9 - Why If it is not homework. Do you need to measure temperature for a website? Are you making 1 or many?
Reply to

It sure takes less time to wire up a breadboard using 1488s and 1489s than MAX232s (fewer discretes) -;)


Reply to

And requires more power supplies (+12,-12, and +5)

There are protoboards available with the Max232 amd caps set into the PCB.

Googleing for 8051 + protoboard lists all kinds of boards available.

Some even blank.

good luck


Reply to

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.