Yup, the D80's built-in pop-up flash has commander mode, so you can use the SB-600 remotely with it with full i-TTL support. For the D40 if you just want off-camera flash and an arm's length is ok, you can get an SC-28/29 cable. One end goes on the hot shoe and the flash goes on the other end. I have one of these too and it works pretty well with the D40.