Hi everyone,
I'm a newbie to Arduino. I need to store data from a digital balance (with an RS232 port) in an SD card for a school thesis.
The devices are correctly connected but I don't know what the code should look like.
The parameters of the balance (baud rate, data bits, parity, handshake) are known.
Any help is well appreciated.
Thanks.
Edit: I'm using Arduino Uno R3 and a Mettler Toledo balance with an RS232 port for data transfer. We used RS232/TTL to connect it to the circuit, which is connected to an SD card shield.
The connection between RS232/TTL and the SD shield are TX-RX; RX-TX; 5V-VCC; Ground-Ground.
My first goal would be to read the data of the scale on the Serial Monitor. Haven't gotten that far yet.
To facilitate our help and reduce the number of questions,
provide recommended information.
For example:
What "arduino" are you using? Which model of balance you want to read the data. (or link).? What module are you using, (RS232/TTL, SD card) ? Schematic of your connections between arduino and modules? Code (posting using the appropriate </> tags) that you are using ?
and any other information that facilitates our help.
After all, the project is in your brain............. not in ours.
I'm using Arduino Uno R3 and a Mettler Toledo balance with an RS232 port for data transfer. We used RS232/TTL to connect it to the circuit, which is connected to an SD card shield.
The connection between RS232/TTL and the SD shield are: TX-RX; RX-TX; 5V-VCC; Ground-Ground.
This is a brand that sells many, many models of scales. Can you give a link to the model you are using?
Do the scales transmit the current weight reading continuously, or with a fixed period such as every second or only when a button on the scale is pressed?
If the weight reading is transmitted continuously or on a fixed period, do you want every reading to be saved, or only when a button attached to the Arduino is pressed, or some other criteria (for example the weight has been steady for some period and it's over some minimum weight)?
Do you need to record the date and time that each weight is saved? Does your SD card shield also have an RTC (Real Time Clock)?
We got to that point (printing data on a .txt file) but with a direct connection from the balance to computer (RS232->USB).
With the circuit in between it gets harder: we tried with many different codes from other forums but none of them gives an "echo" of the data on the serial monitor.
Trying "other codes" thinking it will work is wasting time. You need to learn programming. Modifying example code is often a good way to start.
Learn managing SD write, readin serial etc.