buttons on pin 0 and 1, how to upload, and use the buttons?

I build a flashlight with an arduino duemilanove inside. After it was complete, I tried uploading a test code. I could not upload, no response from serial. I found the problem, two buttons on pin 0 and 1. I need all pins, and not knownig of this limitation I build a flashlight that doesn't work. I can't disconnect them every time I want to upload, allot of work to open and close the flashligh. And my idea was to be able to monitor temperature, fanspeed and brightness over serial to make a graph during operation. If nessesery I can let the realtime monitoring go, but I need those two buttons (only buttons on the flashlight). I don't have any pins left to spare.

This is the situation... As you can see, pin 0 and 1 are connected to negative with two 10K ohm resistors. This causes no serial communication at all. Does it help to make it two 100K ohm? Or can I connect the buttons different, or with diodes or something? So at least I can upload when I'm not using the buttons.

Really hope someone has an idea to solve this without much redesigning the hole pcb.

I believe the RX pin on the arduino board is low asserted. So by keeping it low all the time with a resistor you will never be able to create a connection to the PC. An option might be to install a jumper that would allow the buttons to only work while jumped then when disconnected (the jumper) the RX TX lines would be floating as if nothing is connected to them. I would do the break between the resistor and the RX TX pins of course.

I see two choices:

Change the pull-down resistor to a higher value (10k?, 100k?) so they won't interfere with the serial port.

OR

Remove the pull-down resistors, turn on the internal pull-up resistors, and connect the other side of the buttons to ground instead of +5v. When the buttons are open and the chip is reset there will be nothing to interfere with the serial port. You will have to reverse the logic in the software because the buttons will now read LOW when pressed and HIGH when not pressed.

Use an analogue input and buttons with a resistor ladder to allow you to read three buttons through one analogue input port.

A resistor ladder, verry interresting, did not think of that when I was desiging. But I loose one analog that I need for temperature, potentiometer and 4 LiPo cell volt meters. But nice idea, may use that in a future project.

Are two diodes on pin 0 and 1 posible? So only current can flow in, they are both inpunts no problem there.

mwhens: Are two diodes on pin 0 and 1 posible? So only current can flow in, they are both inpunts no problem there.

I don't see how diodes are going to isolate your serial I/O pins while still allowing your pull-down resistors to pull them down and your buttons to pull them up.

Again, I say: Cut out the pull-downs, wire the buttons to Gnd instead of +5, and tweak the software a bit. What's wrong with that?

I do not understand your solution completly, in need to see it visually, sorry. (no pro)

But I found the real problem this time. Before I tested higher resistors, I first tried to replicate the problem on another arduino. But it still kept working fine with those buttons on pin 0 and 1. The buttons I used can be solderd as a break or make contact. I solderd them as a break contract, and thats the problem. (my fault) I go and change it to a make contact, that works, I tested it. I gues I can upload at the moment, only when I keep pressing the buttons down.

I may still even be posible to monitor temperature and fanspeed from serial. When I press a button, one single block character apears in the serial monitor. But that may just be a single character error in the serial communication, and 99% of the serial communication might be just fine to monitor everything and make graphs out of the data.

I' am thinken how to make serial communication posible when the buttons are not used.

For example, when the buttons are used to start a flashlight light program, and start the program, serial communication can start, and stop when the potentiometer or some other trigger is activated. And while the serial is active, the buttons should be disabled (in the code). I don't know what happens when the code say, listen to input, but also send serial on that pin. And for the recieve pin, when the code is listening to the button, it may recieve serial from the pc, and sees it as a button press. I know the start and stop serial commands, but how can I detect an active serial communication with code?