I'm planning to do a project with an arduino controller and it's my first one. Before to buy an arduino I want to be certain of something with the arduino mini. When the program is running, and the mini is on communication with another serial device or waiting for it, how I can download the program for an update.
Is the reset button must be pushed and right after I can download on it....
I'm habituated with PLC's and I know that I cannot use a serial port for com and download in the same time, but I'm not sure for mini with USB-Serial adapter.
The serial port can only communicate with one device at a time.
But you can use the softserial library to create an extra serialport (in software) that uses other pins than the dedicated Tx and Rx pins on your Arduino.
jcnormandin:
the mini is on communication with another serial device or waiting for it, how I can download the program for an update.
It's not recommended to connect multiple devices to the serial pins, since it makes it difficult to prevent one or the other from communicating.
However, pushing the RESET button is not necessary. When avrdude begins uploading the code, it RESETs the ATmega chip automatically. Again, the challenge will be keeping the "other device" from trying to communicate when the code upload is happening.
I'm planning to do a project with an arduino controller and it's my first one. Before to buy an arduino I want to be certain of something with the arduino mini. When the program is running, and the mini is on communication with another serial device or waiting for it, how I can download the program for an update.
If the other device sends data while you're downloading a program it will mess things up.
What you need is an ISP programmer. This bypasses the Arduino bootloader and serial port. You can easily get one for under $15. I got mine on eBay for $12.
jcnormandin:
Is the reset button must be pushed and right after I can download on it....
Arduinos have auto-reset, no need to push any buttons.
I'm planning to do a project with an arduino controller and it's my first one. Before to buy an arduino I want to be certain of something with the arduino mini. When the program is running, and the mini is on communication with another serial device or waiting for it, how I can download the program for an update.
If the other device sends data while you're downloading a program it will mess things up. You can do software serial comms on other pins but it's a bit rubbish (it works, but it's very CPU intensive...)
I can think of two solutions:
a) Build in a way to get the other device to shut up. When the Arduino is reset its pins are disconnected so you'll lose any output from them.
b) Get an ISP programmer. This bypasses the Arduino bootloader and serial port for uploading programs. You can easily get one for under $15 (I got mine on eBay for $12).
jcnormandin:
Is the reset button must be pushed and right after I can download on it....
Arduinos have auto-reset, no need to push any buttons.