Hi everybody,
I want to receive data from a Loadcell Indicator throughout RS485. The LoadCell Indicator only send data to Micro chip. I also want my Micro chip communicate with the computer in both ways (transfer and receive) by RS232.
Can I do like that?
This is the first time I code for micro chip. I already try to use RS232, but with RS485 I do not have enough material to do. Please help me with any idea, useful links, papers or example codes.
I'm using T89C51AC2 micro chip and C in coding.
Thank you so much, Huy
This is exactly my first project with Micro then i strongly recommend that you buy a SILabs devboard (F0xx, f1xx, f2xx - stay away from f3xx, f4xx and f5xx) it will give you ICE functionality which gives yo the ability to see everything that goes on inside the chip in real life, not 'simulated'
one more hint
there is, here, the Keil device database
http://www.keil.com/dd/parm_search.asp
it allow you to select 2 UARTs and get a list of all '51 derivatives with that.
Erik
Thank you Sirs,
But I am student, I bought this chip so I have to use this one. I think may be I can use another small chip to receive data from LoadCell and pass it to main chip by P0 and P2. (Actually, the loadcell has 19 bits, but I will cut 3 LSBs to get 16 bits)
(P1.3 is used to generate PWM, and P3.0 P3.1 are used for RS232 so P0 and P2 are free)
May I do like that?
"But I am student, I bought this chip so I have to use this one."
So, Hopefully, this is your first lesson learned: don't buy the chip until after you have determined which chip you need!
As Erik said, this is a classic example of "putting the cart before the horse".
Anyhow, if you're really stuck with it...
"I think may be I can use another small chip to receive data from LoadCell and pass it to main chip"
Yes, although that's an extra cost - check carefully that it won't work out cheaper to just go and buy a 2-UART 8051! And also consider your timescales to design it in - what is your deadline?
You can get external UART chips with parallel interfaces and also with SPI or I2C connections to the main processor. You could even use a 2nd, small, cheap, microcontroller...
Again, there's the soft-UART option...
Thank you all for your comments.
Huy